~2 min read • Updated Feb 18, 2026
1. Autofixer – Browser-Based Automatic Repair Tool
Autofixer is a collection of lightweight repair scripts that allow you to fix common cPanel & WHM issues directly from your browser without requiring SSH access.
How to Use Autofixer
- Open the following URL:
https://serverip:2087/scripts2/autofixer - Log in as root.
- Enter the Autofixer script name.
- Click Submit.
- The output will appear in your browser.
Available Autofixer Scripts (as of 2026)
| Script Name | Description | Important Note |
|---|---|---|
| safesshrestart | Repairs SSH configuration and restarts the SSH service | Use only when SSH login is broken |
| test | Test script – makes no changes | Useful for verifying Autofixer functionality |
| update_gatherer_permissions | Fixes permissions for Configuration Analytics | Use when analytics features malfunction |
Warning: Only run Autofixer scripts when instructed by cPanel Support. Misuse may cause system issues.
2. Cloud-Hosted Hostname Solution
On cloud servers (Google Cloud, AWS, Hetzner, etc.), dhclient may overwrite the server’s hostname. This causes:
- Hostname resets
- cPanel license failures
- WHM → Change Hostname not working
Fix: dhclient Exit Hook
Create the following file:
/etc/dhcp/dhclient-exit-hooks.d/zzz-set-hostname
Contents:
#!/bin/sh
hostname server.yourdomain.com
/scripts/fixetchosts
Quick Create Command
mkdir -p /etc/dhcp/dhclient-exit-hooks.d/ && \
echo -ne '#!/bin/sh\nhostname server.yourdomain.com\n/scripts/fixetchosts\n' > /etc/dhcp/dhclient-exit-hooks.d/zzz-set-hostname && \
chmod +x /etc/dhcp/dhclient-exit-hooks.d/zzz-set-hostname
Note: File permissions must be 0755.
3. Restore Database Grants
Sometimes a database user loses its GRANT permissions. This is a common issue and can be fixed using the restoregrants utility.
Restore Grants for a Specific Database User
/usr/local/cpanel/bin/restoregrants --cpuser=USERNAME --db=mysql --dbuser=DBUSER
Restore All Database Users for an Account
/usr/local/cpanel/bin/restoregrants --cpuser=USERNAME --db=mysql --all
If restoregrants Does Not Work
Reset the cPanel account password via WHM or cPanel. This often re-applies all GRANT permissions automatically.
4. scl Utility – Managing Multiple PHP Versions in EasyApache 4
EasyApache 4 uses the Software Collection Library (SCL) to run multiple PHP versions simultaneously (ea-php81, ea-php82, ea-php83).
Syntax
scl enable ea-php81 'php -m'
scl enable ea-php82 'php -v'
scl enable ea-phpWritten & researched by Dr. Shahin Siami