Results 1 to 16 of 16
Hybrid View
-
06-20-2009, 10:30 AM #1Newbie
- Join Date
- Jul 2007
- Posts
- 14
Want to tarball my website files and restore with WHM - Please help...
I have moved the server and server accounts are now in the new server but my websites files are in /restore/home and the databases are in /restore/var/lib/mysql
I am little confused and looking for someone's guidance on tarballing the whole files with database of each accounts and to be restored in my new server through WHM. Can anyone show me the right path to do this?
I am in urgent need of this so anybody could help on this I would be greatful to them.
-
06-20-2009, 11:31 AM #2Newbie
- Join Date
- Apr 2009
- Posts
- 21
Hello,
If your old server is accessible now, you could use the "Copy multiple accounts" option in the new server's WHM to transfer all the accounts from the old server to the new server. Otherwise, you could make tar.gz backup of your accounts using /scripts/pkgacct. Then you could copy these backup files to the new server's home directory(/home) using scp or rsync. Then ssh to the new server and run "/script/restorepkg accountname" to restore the accounts in the new server.
-
06-20-2009, 11:47 AM #3Newbie
- Join Date
- Jul 2007
- Posts
- 14
I have no access to my old server.
-
06-20-2009, 12:13 PM #4Newbie
- Join Date
- Apr 2009
- Posts
- 21
If you have no access to the old server, the account cannot be restored easily. Don't you have the backups of /var/named, /usr/local/apache/conf, /var/cpanel and some other important directories? Do you have root access to the new server?
Anyway you could try the following steps at your own risk:
1. Copy the contents of /restore/home/* to /home.
rsync -vrplogDtH /restore/home/* /home
2. Copy all folders in /restore/var/lib/mysql to /var/lib/mysql
rsync -vrplogDtH /restore/var/lib/mysql /var/lib
These steps are not complete as you haven't provided enough details.
-
06-20-2009, 12:33 PM #5Newbie
- Join Date
- Jul 2007
- Posts
- 14
Yes I have all those backups of /var/named, /usr/local/apache/conf, /var/cpanel and some other important directories? in /restore
So please give me the correct command to put all those important directories in correct place. I don't want to take the risk so please give the correct command.
-
06-20-2009, 12:39 PM #6Corporate Member
- Join Date
- Feb 2008
- Location
- Houston, Texas, USA
- Posts
- 3,262
UNIXy - Fully Managed Servers and Clusters - Established in 2006
Server Management - Unlimited Servers. Unlimited Requests. One Plan!
cPanel Varnish Plugin -- Seamless SSL Caching (Let's Encrypt, AutoSSL, etc)
Slow Site or Server? Unable to handle traffic? Same day performance fix: joe@unixy
-
06-20-2009, 12:50 PM #7Newbie
- Join Date
- Jul 2007
- Posts
- 14
-
06-20-2009, 12:37 PM #8Corporate Member
- Join Date
- Feb 2008
- Location
- Houston, Texas, USA
- Posts
- 3,262
UNIXy - Fully Managed Servers and Clusters - Established in 2006
Server Management - Unlimited Servers. Unlimited Requests. One Plan!
cPanel Varnish Plugin -- Seamless SSL Caching (Let's Encrypt, AutoSSL, etc)
Slow Site or Server? Unable to handle traffic? Same day performance fix: joe@unixy
-
06-20-2009, 09:07 PM #9Temporarily Suspended
- Join Date
- Jun 2009
- Posts
- 5
If you have access to your old server then you can copy cpanel accounts using the whm migrate account functions.
However, if you do not have access to old server and have limited access to certain data then the migration will need to be done manually.
Few important files here are httpd.conf, named.conf, /etc/localdomains, /etc/userdomains and various folders such as /var/lib/mysql, /var/named, /usr/local/cpanel, etc.
I would suggest you to ellaborate in depth about the backup of data that you have. If you are not sure, then I would suggest you to hire a system admin rather than playing with the server.
-
06-20-2009, 09:21 PM #10Junior Guru
- Join Date
- Mar 2009
- Location
- Chicago, IL
- Posts
- 219
Since you don't have access to your old server, Your options are fairly limited here. It really depends on exactly *what* you managed to backup prior to losing the old host.
Option 1: If you look in /scripts/cpbackup, you'll find a list of accounts *necessary* for a full server restoration. If you want a bit of help with sorting that list out, just reply to this thread and let me know.
If you have all of the necessary files and directories, it's pretty simple. You do a fresh installation of cPanel, overwrite the existing copies with your old ones and then do a big upcp --force which will fix up just about everything necessary.
However I need to REALLY stress that if you don't have all of the necessary components, this will break things in a very ugly fashion.
Option 2. You're going to need to recreate the cPanel accounts, email boxes, etc by hand and then do a big restoration of /home/. Once that's done, you'll need to go through and hunt down permissions and slowly fix things up after that. It's not going to be easy, but at least you have the data necessary to redo this.
As to the MySQL DBs, I'd strongly suggest doing an initial full mysqldump 'mysqldump -u root -A >fullbackup.sql' as this gives you a recovery point. After that, you can move the databases back into /var/lib/mysql/ and hope for the best. However since you changed IPs, you're going to need to keep an eye out for anyone that had remote database access setup. Anyone referring to 127.0.0.1/localhost in their configs should be fine. (this also assumes roughly the same version of MySQL) If it's differing versions, you're going to have to add the databases themselves manually and then start setting username/password permissions yourself by hand.
I'm sorry I don't have a better answer for you here, but there's probably not an easy way to restore this given the data that you have. It's going to be piece by piece and require quite a bit of work to get everything fully working again I believe.
I wish you luck, and if we can be of assistance here on the forums, just let us know.
-
06-20-2009, 10:51 PM #11Newbie
- Join Date
- Jul 2007
- Posts
- 14
When I try with /scripts/cpbackup it says Backup is not done today as per whm...
Yes I have all the necessary files and directories from old server at /restore. A good thing is I have successfully restored only one account after a long struggle after moving all cpanel user accounts to /var/cpanel/users and userdata. I feel I am somewhere stucking eventhough everything is perfect.
-
06-21-2009, 01:49 AM #12Newbie
- Join Date
- Jul 2007
- Posts
- 14
I have manually created another account by deleting the old user data it was created successfully buy when I check the WHM it shows 0 disk space even though all files are there.
-
06-21-2009, 01:58 AM #13Disabled
- Join Date
- Sep 2005
- Location
- A box
- Posts
- 2,051
-
06-21-2009, 02:05 AM #14Newbie
- Join Date
- Jul 2007
- Posts
- 14
All the important files are overwritten in appropriate places in /home
Tried your command /scripts/fixquotas, /scripts/fixeverything still no change in file size.
Another issue is it shows FTP time out fatal error in cpanel and the options are blank.Last edited by mharrisr; 06-21-2009 at 02:11 AM.
-
06-21-2009, 04:42 AM #15Newbie
- Join Date
- Jul 2007
- Posts
- 14
I found that there is a permission conflict in the account folder since I tried to download a file and uploaded but it ends with 550 permission denied error and also not able to delete a file so if anyone can give a correct command for setting the correct permission I think my problem will be solved.
-
06-21-2009, 04:34 PM #16Web Hosting Guru
- Join Date
- May 2008
- Posts
- 340
It turns out there is incorrect permissions set to the directory/file from preventing the web server user from accessing it.
Post the output of the following commands,
ls -ald /homels -ald /home/user/public_html
ls -al /home/user/public_html
Similar Threads
-
save restore dot com + website
By wise in forum Domain Name with Web Site OffersReplies: 3Last Post: 09-10-2008, 10:15 AM -
please help : need to restore my old files
By X-x-X in forum Hosting Security and TechnologyReplies: 8Last Post: 06-27-2007, 06:28 PM -
Restore to MYI files
By netcommander in forum Hosting Security and TechnologyReplies: 5Last Post: 02-01-2006, 02:36 PM -
strange files after restore...
By aisusa in forum Hosting Security and TechnologyReplies: 1Last Post: 11-16-2004, 04:51 AM -
php tarball?
By nnormal in forum Programming DiscussionReplies: 2Last Post: 03-26-2004, 01:30 PM