Skip to content

WHM Tweak Settings — the 20 that actually move the needle on a busy server

WHM ships with hundreds of Tweak Settings. A short list of the ones that change real behaviour for a busy multi-tenant box — and a few that look important and aren't.

The Tweak Settings interface in WHM has roughly four hundred entries by the last count. Most are inert on a typical server; a few materially change reliability, security, or customer experience. A new operator usually finds out about the important ones by accident — an outage caused by a default they didn’t know existed, or a customer complaint that turns out to be a default no one changed. Twenty-odd settings is the short list of what to actually review on every server you take over.

What’s happening

Tweak Settings is the user-facing name for cPanel’s central configuration store, persisted in /var/cpanel/cpanel.config. Settings live in categories — Mail, Security, System, Stats, Backup. Most defaults are conservative and work for a typical hosting workload; a few defaults are wrong for any production server but cPanel keeps them for backward compatibility. The on-take-over audit is twenty minutes of grep and a checklist.

How to verify

Read the current state of the settings you care about:

whmapi1 get_tweaksetting key=skipboxtrapper
whmapi1 get_tweaksetting key=maxemailsperhour
whmapi1 get_tweaksetting key=allowwhmparkonothers
whmapi1 get_tweaksetting key=referrersafetycheck
grep -E '(maxemailsperhour|skipboxtrapper|allowwhmparkonothers)' /var/cpanel/cpanel.config
tail -f /usr/local/cpanel/logs/error_log | grep cpanel.config

For a full dump, whmapi1 get_tweaksettings --output=jsonpretty returns every setting. Pipe it through jq and grep for the categories you want.

The fix

The twenty I check on every server takeover, with the value I usually set:

  1. maxemailsperhour — set to 500 (default 0/unlimited). Limits outbound volume per account.
  2. maxemailsperdomain_perhour — set to 250. Per-domain cap stops one account’s spam from blocking others.
  3. skipboxtrapper — set to 1 (off). BoxTrapper challenge-response is dead; leaving it on confuses customers.
  4. enableselectserverquota — set to 1. Allows reseller quotas to apply at create time.
  5. requiressl — set to 1. Forces WHM and cPanel to redirect HTTP to HTTPS.
  6. disable_xss_checks — leave at 0 (on). Don’t disable the XSS protection.
  7. allowwhmparkonothers — set to 0. Resellers cannot park domains on accounts they don’t own.
  8. referrersafetycheck — set to 1. CSRF protection on WHM forms.
  9. unprotectedssh — set to 1. Disable password-only SSH for root.
  10. emailusersbandwidthexceed — set to 1. Customers learn about overages before you do.
  11. emailusersbandwidthexceed80 — set to 1. Early warning at 80%.
  12. autoupdate — set to RELEASE or STABLE, never CURRENT on production.
  13. compressedlogs — set to 1. Gzipped access logs save disk on busy hosts.
  14. statsexpiretime — set to 365. Keep stats a year, not the default 12 months in some versions.
  15. anonymous_session — set to 0 (off). No anonymous WHM sessions.
  16. maxbgworkers — set to 4 on a typical 8-core box; tune up for bigger.
  17. upstart — set to 1 if on systemd; ensures daemons restart cleanly.
  18. cpsrvd_ssl_default_key_type — set to ecdsa-secp384r1. Modern key type.
  19. mailbox_format — set to maildir not mbox. Mbox is a corruption magnet.
  20. emailpasswords — set to 0. Never email plaintext passwords.

For multi-server fleets where Tweak Settings drift across hosts is a real problem, Stack Harbor’s cPanel and WHM management practice maintains a baseline config and audits each server against it at the start of every quarter.