view log apache 2

C++
sudo tail /var/log/apache2/error.log
Source

Also in C++: