cPanel/WHM Update and Service Status Logs
/var/cpanel/updatelogs/update-[TIMESTAMP].log
Contains all output from each upcp. Named with the timestamp from which the upcp process was executed.
Service Status Logs
The service monitoring daemon (chkservd) logs all service checks here. Failed services are represented with a [-], and active are represented with [+].
Most commonly accessed cpanel log files.
When investigating any issue, the first thing you should always do is check the log files, as they generally provide insight as to what’s causing the erroneous behavior.
The following is a break down of the most commonly accessed log files, for cPanel and cPanel managed services:
/usr/local/cpanel/logs/error_log
cPanel logs any error it incurs here. This should always be the first place you look when you encounter errors or strange behavior in cPanel/WHM.
/usr/local/cpanel/logs/license_log
All license update attempts are logged here. If you run into any license errors when logging in, check here.
/usr/local/cpanel/logs/stats_log
The stats daemon (cpanellogd) logs the output from all stats generators (Awstats, Webalizer, Analog) here.
/usr/local/cpanel/logs/access_log
General information pertaining to cPanel requests is logged here (Client Information, Request URI)
Easy Apache 3 & PHP
cPanel recommends that only one version of PHP is selected so that configuration and management is simplified.
When only one version of PHP is installed, a CGI binary is installed to /usr/bin/php and a CLI binary is installed to /usr/local/bin/php.
When both PHP4 and PHP5 are enabled, PHP5 will be installed to the standard locations /usr/bin/php and /usr/local/bin/php. PHP4 will be installed in /usr/php4/bin/php and /usr/local/php4/bin/php.
EasyApache 3 includes the ability to install, uninstall or update several popular PHP extensions as part of the Apache and PHP build process. When EasyApache runs it will automatically determine which extensions are active in main php.ini file at /usr/local/lib/php.ini. Active extensions will automatically be selected in the EasyApache 3 interface.
Rerunning EasyApache 3 is not required to enable or disable the standard PHP extensions. cPanel 11 provides a tool called /scripts/phpextensionmgr that can also be used for installation or removal.
Run the below command for detailed information.
/scripts/phpextensionmgr –help
Configuring Reverse DNS in WHM
Reverse DNS uses pointer records (PTR) to convert IP addresses into domain names. This is the opposite of forward DNS, which uses A records to convert domain names into IP addresses.
First, add a new DNS zone file. You can accomplish this using the Add a DNS Zone feature in the DNS Functions section of your WHM interface (Main >> DNS Functions >> Add a DNS Zone).
To continue, enter the IP address and proper reverse DNS zone name in the appropriate fields.
To properly format the Domain field in the interface.
Take the first 3 octets of the IP address, Reverse them, and Affix in-addr.arpa to the end. So, for example, the reverse DNS entry for 192.168.0.1 is 0.168.192.in-addr.arpa. After you have filled out these 2 fields, click the Add Zone button.
One you have created your zone file, you can edit it. You can do this using the WHM Edit DNS Zone screen (Main >> DNS Functions >> Edit DNS Zone). Your zone file should already contain an NS entry for every authoritative nameserver associated with your server. To finish this process, we need to add a PTR record for each IP address we wish to name in the last octet of 192.168.0.
After the reverse DNS zone has propagated, run a test to ensure that you have properly configured reverse DNS. To do so, you can use the following command:
If you have properly configured your reverse DNS zone file, the output should resemble the following:
user@host: [~]# host 192.168.0.1
1.0.168.192.in-addr.arpa domain name pointer serverbuddies.com.
What to Do If MySQL Keeps Crashing on your cPanel Server
First, you should try to find out whether the problem is that the mysqld server dies or whether your problem has to do with your client. You can check how long your mysqld server has been up by executing mysqladmin version. If mysqld has died and restarted, you may find the reason by looking in the server’s error log.
There may be some internal lock problem. mysqladmin -u root processlist usually is able to make a connection even in these cases, and can provide useful information about the current number of connections and their status.
Run the command mysqladmin -i 5 status or mysqladmin -i 5 -r status in a separate window to produce statistics while you run your other queries.
Stop the mysqld server with mysqladmin shutdown, run myisamchk from the data directory to check all MyISAM tables, and restart mysqld.
myisamchk –silent –force */*.MYI