Skip to content

Restoring a cPanel account from JetBackup — full walkthrough

A step-by-step JetBackup account restore on a different working slug, covering both the WHM UI path and the jetbackup5api path, with pre-flight checks that prevent half-restores.

A single cPanel account on a shared host needs to come back from yesterday’s snapshot — a plugin update broke things, an editor wiped a directory, the customer called. The straightforward path is JetBackup’s account-level restore, but the muscle memory matters: skipping the pre-flight makes the restore worse than the original problem.

What’s happening

JetBackup 5 exposes account restore in two scopes: from WHM (server-side, for an existing or missing account) and from cPanel (user-side, for a corrupted-but-present account). The WHM-side path is what you reach for when the home directory has problems that would block in-place overwriting. The user-side path is fine for “I want yesterday’s wp-content back” if the home is otherwise healthy.

How to verify

Before doing anything, confirm the snapshot exists and is complete:

jetbackup5api -F getBackupJobs
jetbackup5api -F getRestorePoints -D '{"account":"<user>"}'
jetbackup5api -F getRestoreItems -D '{"snapshot_id":"<id>","account":"<user>"}'

Look for Home Directory, MySQL Databases, DNS Zones, Email Accounts. A snapshot missing MySQL Databases is files-only and won’t produce a working CMS.

The fix

  1. From WHM > JetBackup 5 > Restore > Accounts, find the account and pick the verified snapshot. Select all components from the same snapshot — mixing sources (home from snapshot A, databases from snapshot B) creates version mismatches.
  2. Submit the restore. Watch the queue: jetbackup5api -F getQueueItems. A queued item that stays “scheduled” for more than two minutes means another backup or restore is blocking — abort and reorder.
  3. After completion, the verification triad: home size matches snapshot, restore log at /usr/local/jetapps/var/jetbackup/logs/restore-<id>.log shows zero database errors, site loads and exercises a write path (publish a draft, then delete it).
  4. If you see “collation mismatch” warnings in the database import section, fix them now. The site will appear up but searches will misbehave.
  5. Communicate completion with the snapshot ID and timestamp used. The customer wants “we restored to the 04:00 snapshot from Saturday”, not “everything looks fine now”.

Stack Harbor runs these restores under environment management when speed and verification matter together.