Rsync服务架设

2009-05-13 16:00:20来源:未知 阅读 ()

新老客户大回馈,云服务器低至5折


1. 安装:yum install rsync
2. Rsync服务器的配置文件(手动创建)
mkdir /etc/rsyncd
touch /etc/rsyncd/rsyncd.conf
touch /etc/rsyncd/rsyncd.secrets
chmod 600 /etc/rsyncd/rsyncd.secrets
touch /etc/rsyncd/rsyncd.motd
3. 启动:/usr/bin/rsync --daemon --config=/etc/rsyncd/rsyncd.conf
4. 同步:rsync -avzP
[email=user@IP::服务器同步目录]user@IP::服务器同步目录[/email]
/home
配置文件如下:
#
# Create by 2008/09/14
#
###################################################################
# Main configuration
pid file = /var/run/rsyncd.pid
port = 873
address = IP
uid = nobody
gid = nobody
use chroot = no
read only = no
hosts allow = IP
hosts deny = *
max connections = 5
motd file = /etc/rsyncd/rsyncd.motd
log file = /var/log/rsync.log
transfer logging = yes
log format = %t %a %m %f %b
syslog facility = local3
timeout = 300
[home]
path = /home
list = yes
ignore errors
auth users = admin
secrets file = /etc/rsyncd/rsyncd.secrets
comment = home directory
exclude = './.bash_history.txt'
#exclude = www/ './.bash_history.txt'
其中启动时出现错误:
2009/01/14 22:57:50 [23291] bind() failed: Cannot assign requested address (address-family 2)
原因是没有开启防火墙端口,请注意!

本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/10599/showart_1797934.html

标签:

版权申明:本站文章部分自网络,如有侵权,请联系:west999com@outlook.com
特别注意:本站所有转载文章言论不代表本站观点,本站所提供的摄影照片,插画,设计作品,如需使用,请与原作者联系,版权归原作者所有

上一篇:Carp+IPVS实现热备及负载均衡freebsd 6.4

下一篇:如何用光盘升级系统