I have a server that is 80G total size and has no more space so i cannot backup on the server. I found this command
ssh server2 "tar -zc -C /srcdir ./path" | tar -zx -C /destination
but it is not making sense. ./path
refers to what?
So I was thinking of doing this:
localserver:~$ ssh root@remoteserver "tar czvf / " | tar xzvf /mnt/backup
Compress root of remote server and uncompress in my backup directory.
/mnt/backup
is mounted on a 300G drive. Would this work?
I have passwordless access to the remote server using public key.