Backing up VPS from the inside

This guide will show you how to backup your vsp/container "from the inside vps".
First of all create a directory in which you will backup your container.

mkdir /backup

Below command creates an archive named ctbackup.tar.gz in folder you have created earlier.

tar -zcvpf /backup/ctbackup.tar.gz --directory=/ --exclude=proc --exclude=sys --exclude=dev/pts --exclude=backup .

The backup can be sent to remote server:

scp ctbackup.tar.gz user@host:/path/to/copy

To extract files type:

tar -C /path/to/extract -zxvpf ctbackup.tar.gz

 

Was this answer helpful?

 Print this Article

Also Read

FreePBX

FreePBX is an open source GUI (graphical user interface) that controls and manages Asterisk (PBX)...

Configure OpenVPN client on Windows

How to configure OpenVPN client on Windows: First download and install the client. Then...

Generating public/private ssh keys

How to generate and use public / private ssh keys This guide is tested on Centos 6 To...

Forward (redirect/nat) traffic with iptables

If you want to redirect/nat some traffic to IP 2.2.2.2 via IP 1.1.1.1, it simply can be done...

Fail2ban

Fail2ban scans log files (e.g. /var/log/apache/error_log) and bans IPs that show the...