Skip to main content

Restore 200+ fullbackup account on my WHM

Comments

3 comments

  • cPanelMichael
    Hello :) You could try using a command like this to restore all accounts via SSH: for i in `ls /home/*.tar.gz|cut -d \- -f 2 | cut -d . -f 1 `;do /scripts/restorepkg $i;done
    Note that you may want to run this command in a "screen" session as it may take a while to complete. Thank you.
    0
  • al_bozorgi
    Thank you so much. i change your script cat result is not return correct value of user name then i change for these script and work correctly : [QUOTE][COLOR="#0000FF">for i in `ls /home/*.tar.gz|cut -f3 -d'_'|cut -f1 -d'.'`;do /scripts/restorepkg $i;done
    Thank you again for fast replay and save my time.
    0
  • regulararticles
    Restore multiple backup in one command ssh if the filename of the full backups varied, you could store a list of the full paths to each backup in a text file, such as a text file at "/root/list_of_backups.txt" and then the command could be altered as follows: [QUOTE]# for x in $(cat /root/list_of_backups.txt); do echo /scripts/restorepkg $x; done;
    0

Please sign in to leave a comment.