LSWS does not restart after adding domain from WHM/cPanel
1. Make sure LSWS has correct settings
Admin Console => Configuration => Server => General => Using Apache Configuration File
Load Apache Configuration: Yes
Auto Reload On Changes: Use Apache Binary wrapper
2. Make sure httpd is enabled in WHM/cPanel Service Manager
WHM/cPanel => Service Configuration => Service Manager
Enabled Monitor Service Information
checked checked httpd Web Server
3. Check if /etc/disable_apache or /etc/disable_httpd exists, if so, Apache service is disabled and cPanel will not restart Apache when change.
4. Check if /usr/local/lsws/logs/ap_cmd_param.log record an entry of restart as follows:
Thu Aug 2 15:06:17 EDT 2012: -k stop -DSSL
Thu Aug 2 15:06:21 EDT 2012: -k start -DSSL
if no restart is logged, it means WHM/cPanel does not send restart signal to LSWS.
5. Check if /usr/local/cpanel/logs/safeapacherestart_log does record every safeapacherestart when whm made change.
[2012-08-02 18:04:20 +0000] info [safeapacherestart] Restart elapsed seconds: 0
6. Check /usr/local/apache/logs/queueprocd.log record the Apache restart
7. Check if httpd can be restart from WHM restart services
WHM/cPanel => Restart Services => HTTP Server (Apache) => Yes
if the follow message pops up:
"Apache build currently in progress. Restarts disabled by existence of /var/cpanel/mgmt_queue/apache_update_no_restart. Restarting Apache now may result in a broken Apache build"
Go to step 7.
8. Check if EasyApache is still running which would prevent Apache from restart
ps -ef | grep easyapache
a. if EA is still running, wait until it finishes. Check the latest log file in /usr/local/cpanel/logs/easy/apache/ for progress
b. if EA process is not running, check if /usr/local/apache/AN_EASYAPACHE_BUILD_IS_CURRENTLY_RUNNING still exists
ls -l /usr/local/apache/AN_EASYAPACHE_BUILD_IS_CURRENTLY_RUNNING
if the file is present, remove the file.