Vesta Control Panel - Forum

Community Forum

Skip to content

Advanced search
  • Quick links
    • Main site
    • Github repo
    • Google Search
  • FAQ
  • Login
  • Register
  • Board index Main Section General Discussion Debian/Ubuntu
  • Search

Restore VestaCP from files

Debian/Ubuntu related topics
Post Reply
  • Print view
Advanced search
2 posts • Page 1 of 1
ralbrightii
Posts: 11
Joined: Sat Nov 23, 2019 1:37 am

Os: Ubuntu 17x
Web: apache + nginx
Restore VestaCP from files
  • Quote

Post by ralbrightii » Fri Sep 04, 2020 10:59 pm

I recently had a server crash on me, but I had good system level backups. Unfortunately I am having to move to a new server for various reasons. (Old provider gives little to no support.) What would be the necessary steps to restore a VestaCP install to a new server when ALL i have access to is files/folders? I assume I would install VestaCP on the new server, then just transfer files over from the backups.... but what. And how do I update the IP addresses for everything?

Please help. I am really screwed here.
Top

mwlandolsi
Posts: 4
Joined: Sat Aug 17, 2019 9:02 pm

Os: Ubuntu 17x
Web: apache + nginx
Re: Restore VestaCP from files
  • Quote

Post by mwlandolsi » Wed Oct 21, 2020 11:10 am

Restore or Migrating VestaCP User Data Between Servers
I got the same issue. My VSP crushed and Fortunately, I have a backup of my content saved locally. Just restored my server to a previous snapshot and followed this tutorial from digital ocean.
VestaCP comes with some scripts to help back up and restore user data. We will migrate all users using these scripts.

On the server you are migrating from, use v-backup-users to backup all users:

v-backup-users

Note: If you get a command not found error when running the backup program, you may need to update your PATH by running:

export PATH=$PATH:/usr/local/vesta/bin

This is handled automatically if you log out and back in after installing VestaCP.

The command will output no status information. You can check for the resulting backup files in /backup:

ls /backup

Output
admin.2018-04-11_13-07-02.tar exampleuser.2018-04-11_13-07-02.tar

The above output shows two users backed up, admin and exampleuser. To transfer these files to your new server, we’ll use the scp utility. The following steps will work the same whether you have one backup file or multiple.

If you’re using password authentication on the new server, it’s easiest to transfer the files directly from the old server to the new, like so:

scp /backup/* [email protected]:/backup/

This won’t easily work if you use SSH keys instead of passwords. In that case it’s easiest to download the files to your local machine, then upload them to the new server. We will create a temporary local directory to hold the files first. On your local command line, do the following:

mkdir /tmp/vesta-backups
scp [email protected]:/backup/* /tmp/vesta-backups/
scp /tmp/vesta-backups/* [email protected]:/backup/

Now, with the backup .tar files uploaded to the new server’s /backup directory, log back in to the new server and use the v-restore-user command to complete the process:

v-restore-user admin admin.2018-04-11_13-07-02.tar

Note that the v-restore-user command needs the filename of the .tar file, but not the full path to the file. It is assumed that the filename you provide is in the /backup directory.

The command will output a summary of the items it has restored. Repeat this command for each user you need to restore, replacing the username and .tar file name as need. Your migration is now complete.

From : https://www.digitalocean.com/community/ ... -user-data
Top


Post Reply
  • Print view

2 posts • Page 1 of 1

Return to “Debian/Ubuntu”



  • Board index
  • All times are UTC
  • Delete all board cookies
  • The team
Powered by phpBB® Forum Software © phpBB Limited
*Original Author: Brad Veryard
*Updated to 3.2 by MannixMD
 

 

Login  •  Register

I forgot my password