Fix: cPanel Service Failing to Start, cPanel / WHM Not Working!

Helposoft Staff

Administrator
Staff member
Points
178
If you're encountering issues where cPanel or WHM services are failing to start, it can be frustrating. This article will guide you through troubleshooting steps to resolve common problems that prevent cPanel from starting properly.

1. Check Service Status

Start by checking the status of the cPanel service to get an overview of any immediate errors:

Code:
sudo systemctl status cpanel.service -l

Review the output for any specific error messages or issues that could give clues about why the service isn't starting.

2. Review System Logs

Check the system logs for more detailed information on why the cPanel service might be failing:

Code:
sudo journalctl -xe

The logs often contain additional context that can help in diagnosing the problem.

3. Examine cPanel Log Files

The cPanel log files provide specific information about issues related to cPanel:

Code:
tail -n 50 /usr/local/cpanel/logs/error_log
tail -n 50 /usr/local/cpanel/logs/access_log
tail -n 50 /usr/local/cpanel/logs/license_log
tail -n 50 /usr/local/cpanel/logs/serviceauth_log

These logs might reveal issues such as configuration errors, license problems, or authentication failures.

4. Check Available Storage Space

Sometimes, services fail to start due to a lack of storage space. Check your available disk space with:

Code:
df -h

If the storage is full, free up space by deleting unnecessary files and directories:

Code:
# Example commands to remove old backups or log files
sudo rm -rf /path/to/old/backup
sudo rm -rf /path/to/old/logs

5. Fix File and Directory Permissions

Incorrect file and directory permissions can cause cPanel to fail to start. Fix permissions using the following scripts:

Code:
sudo /scripts/fixquotas
sudo /scripts/fixeverything

These scripts will correct file ownership and permissions issues.

6. Check for Missing Dependencies

Ensure that all necessary services and dependencies are correctly installed and running:

Code:
sudo systemctl restart httpd
sudo systemctl restart dovecot
sudo systemctl restart exim

Check for missing or corrupt packages and fix them:

Code:
sudo /scripts/check_cpanel_rpms --fix
sudo yum -y update
sudo /scripts/upcp --force

7. Verify the License

Sometimes issues arise from license problems. Update and verify your cPanel license:

Code:
/usr/local/cpanel/cpkeyclt

Check if the license has been updated successfully and if it is still valid.
If you need a license, consider getting a cost-effective one from LicenseDash at $4.99/month.

8. Reboot the Server

If all else fails, try rebooting the server. Sometimes a simple reboot can resolve transient issues:

Code:
sudo reboot

9. Contact Support

If you’ve followed all the steps and cPanel still isn’t working, consider contacting cPanel support or consulting with a professional. They can provide more detailed diagnostics and assistance.

By following these steps, you should be able to diagnose and resolve most issues with cPanel services not starting. Ensure you keep your system and software up-to-date to prevent future issues.
 
Top