rootでパスワード無しでsshでバックアップする
# sudo su
# cd ~
# ssh-keygen -t rsa -b 2048
root@wordpress:/home/ckenko25# ssh-keygen -t rsa -b 2048
Generating public/private rsa key pair.
Enter file in which to save the key (/root/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /root/.ssh/id_rsa.
Your public key has been saved in /root/.ssh/id_rsa.pub.
The key fingerprint is:
SHA256:FpsZXMaP/udwEZjG8sP3mqqH5BFEpSsvLft1ZrcnlAo root@wordpress
The key’s randomart image is:
+—[RSA 2048]—-+
| o+.. |
| . ooo o |
| +.oo= . |
| *o*. . |
| S…+ o. |
| . +E ooo |
| ooo=oo= o|
| +o.+*o+o|
| ..oo.++o.|
+—-[SHA256]—–+
# rsync -auv –delete /var/www/wordpress/ root@192.168.1.3:/var/www/wordpress/
コメント