Hello. my system has been completely compromised.
What is the minimal list of files I need to backup if I need to restore it in the another server the same IP (I'm planning to restore rights using -r option of the installer)?
Full backup
- DragonZX
- Closed
- Thread is marked as Resolved.
-
-
/var/www/virtual/
/var/mail/virtual/
Complete db Export
/etc/imscp/It's enough to rerun the installer without any parameters to set new rights..
PS: do also a complete backup
-
-
Thank you. But what about plugins? As I remember, we have its configuration in the DB...
UPD: Any advises of full backup of MySQL with all existing passwords?
-
-
-
-
So nice you googled it now. I wrote /etc/imscp/, it's just the complete folder...
-
-
I made some script (I'm posting a bit of it)
Code- if [ $choice -eq backip ] ; then
- echo '#### Backuping an i-MSCP ####'
- read -p 'Please enter the MySQL root password: ' mypass
- apt-get -y install bzip2 xz-utils
- mkdir /tmp/imscpbkp
- cd /tmp/imscpbkp
- mysqldump -u root --password=$mypass --all-databases > imscp.sql
- tar cvfJ www.txz /var/www/virtual
- tar cvfJ mail.txz /var/mail/virtual
- tar cvfJ config.txz /etc/imscp
- cd ..
- tar cvf imscp.bkp imscpbkp
- cp imscp.bkp /root/imscp.bkp
- echo Take it from root directory
- cd /root
- exit
- elif [ $choice -eq restore ] ; then
- echo '#### Restoring an i-MSCP ####'
- read -p 'Please enter the MySQL root password: ' mypass
- apt-get -y install bzip2 xz-utils
- mkdir /tmp/imscpbkp
- cp /root/imscp.bkp /tmp/imscp.bkp
- cd /tmp
- tar xvf imscp.bkp
- cd /tmp/imscpbkp
- tar xvfJ www.txz -C /
- tar xvfJ mail.txz -C /
- tar xvfJ config.txz -C /
- mysql -u root --password=$mypass < imscp.sql
- rm f /root/imscp.bkp
- cd /root
- echo Restoring complete
- exit
- else
- exit
It works fine, but restoring a database "takes a lot of time" or doesn't work at all -
script work? i need backup my server to migration Thanks
-