想要遠端備份嗎?可以使用Rsync

1.sudo apt-get install rsync

2.sudo vim /etc/default/rsyncd
  RSYNC_ENABLE=false => RSYNC_ENABLE=true

3.sudo touch /etc/rsyncd.conf


4.sudo vim /etc/rsyncd.conf
max connections = 5
log file = /var/log/rsyncd.log
#timeout = 300

[share]
comment = Public Share
path = /home/share
read only = no
list = no
uid = root
gid = root
auth users = test
secrets file = /etc/rsyncd.secrets

5.touch /etc/rsyncd.secrets

6.sudo vim /etc/rsyncd.secrets
#帳號:密碼
test:123

7.chmod 600 /etc/rsyncd.secrets
PS:沒有設定成600使用者會認證錯誤。

8.sudo /etc/init.d/rsync restart

arrow
arrow
    全站熱搜

    蒼穹 發表在 痞客邦 留言(0) 人氣()