WHM Backup & User List

georgeb

Well-Known Member
May 23, 2010
49
1
58
Montreal, QC, Canada
cPanel Access Level
Root Administrator
Hi. There is a way to stop updating the list for accounts to be included for daily automatically back-up? Because every time when an account is created is automatically added to the list and mark as on. (or maybe just to mark the new created account like OFF?!)

Regards,
George B.
 

georgeb

Well-Known Member
May 23, 2010
49
1
58
Montreal, QC, Canada
cPanel Access Level
Root Administrator
Wouldn't turning off backups accomplish the same thing?
Thanks for your answer. I would like to backup only certain accounts not all accounts. That's why I would like to disable daily backup for other users, so I need something on that list. Can I use something like a hook after any creation of account, or to disable (by default ) user to be backup?

Regards,
George B.
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
Wouldn't it be easier just to automate backing up set accounts without using the backup area at all if you only need some accounts to be backed up? You could simply create a script to cron run "/scripts/pkgacct username" for the set accounts that need to be backed up that way. You could also put the accounts into a file like /root/backupaccounts and then have the script run a for loop to backup the users in that list. That way whenever you want to backup a new account, you simply add it to /root/backupaccounts list by username, then the script will simply continue working.
 

minosjl

Well-Known Member
Jun 4, 2011
168
0
66
India
cPanel Access Level
Root Administrator
Hello,

According to the WHM backup configuration options there is no facility to take some account backups on the server.If you really need to do that so , please run a cron job for accounts you need to take backups.You can make a shell script for these ,if you have multiple accounts.
 

georgeb

Well-Known Member
May 23, 2010
49
1
58
Montreal, QC, Canada
cPanel Access Level
Root Administrator
Thanks, I thought there is a way from WHM to modify that list (and no new account will be added to that list) or from postwwwacct. I already have a script to backup using /scripts/pkgacct. with a loop.

Regards,
George B.
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
There isn't a way from WHM to modify the list, and it is a lot less intrusive to simply control a list of users like I've mentioned at /root/backupaccounts and only add to that list each time you want an account to be added as part of the loop to backup for the cron script you use. This way, you aren't checking every single time an account is created to back it up or not, but only adding accounts you want backed up to that one file.

As for a postwwwacct script, you could certainly script to add to /root/backupaccounts list whenever you want an account added there, possibly by detecting it's on a set package type (backupaccount package type let's say). Then you would only have to select that package for an account you want backed up to have it then add to the account list you are using for the backups.