Manually backing up an account

GoWilkes

Well-Known Member
Sep 26, 2006
583
21
168
cPanel Access Level
Root Administrator
I'm always nervous about plugging code directly in to SSH, just because I know that one day I'll accidentally do something stupid and delete everything! LOL

Would someone please glance at this and make sure that it's correct? I'm planning to copy everything in the /www/ directory (and all subdirectories) from account "domain1" to "domain2" (on the same server).

cp /home/domain1/www/* /home/domain2/www/

The account has about 200MB worth of storage.

TIA,

Jason
 

stan01

Member
Jul 9, 2009
5
0
51
Hi Jason,

As most Linux programs, cp also needs an argument in order to copy everything.

Ty it this way:

cp -r /home/domain1/www/* /home/domain2/www/

bith this will omit dotfiles. It will be much easier to:

cd /home/domain1/ ; cp -r www/ /home/domain2/

assuming, there isn't www/ in /home/domain2/

and don't forget to chown once the copy is over ;)