rsync 添加开机服务
vim /etc/systemd/system/rsyncd.service
服务代码
[Unit]
Description=rsync daemon
After=network.target
[Service]
Type=forking
PIDFile=/var/run/rsyncd.pid
ExecStart=/usr/bin/rsync --daemon
ExecReload=/usr/bin/kill -HUP $MAINPID
KillMode=process
Restart=on-failure
TimeoutSec=0
[Install]
WantedBy=multi-user.target