Setup: system "prime" with Ubuntu 16.04 and a second hard drive just for backups.
/dev/sdb1 is mounted at /mnt
I created a subdirectory named /mnt/prime for the first backup, of the prime boot SSD contents.
--> Running the command:
sudo rsync -aAXv / --delete --ignore-errors --exclude={"/dev/*","/proc/*","/sys/*","/tmp/*","/run/*","/mnt/*","/media/*","/lost+found"} /mnt/prime
does indeed make a nice mirror copy of the root file system into that directory /mnt/prime
So now, in attempting to set up a rsync server for the rest of the Linux systems (Another Ubuntu and a handful of Raspian Jessie systems), I am following these directions:
How to Use rsync to Backup Your Data on Linux
EXCERPT: it says to enter the following two commands:
yum -y install ssh rsync
sudo apt-get install ssh rsync
First problem is that there is no yum command on this system, so I skipped that step. rsync installed with no problems.
All of my systems have done the passwordless login setup
ssh-keygen
ssh-copy-id ~/.ssh/id_rsa.pub prime
and I have no problem with passwordless scp copies.
The question is: how to I proceed so this system can become a rsync server for other Linux systems.
You're using the wrong tool for the job. In the Debian world (which includes Ubuntu), packages are installed using
apt
orapt-get
. This is the system's package manager. You were trying to use a package manager (yum
) from a different family of distributions, the Red Hat family. This is actually mentioned in the site you linked to:So, instead of this:
Do this:
And forget about
yum
.If "prime" prompts for a password even after the public key has been installed, then you need to review /etc/ssh/sshd_config and ~/.ssh on "prime".
/etc/ssh/sshd_config:
~/.ssh: (check permissions and naming)
Also check /etc/ssh/ssh_config on "solar" to ensure it references the private key you generated.