一、rsync通过服务同步分为服务端(server1) 和客户端(server2)服务端(server1):[root@litongyao ~]# vim /etc/rsyncd.confport=873
分类:
系统相关 时间:
2017-12-13 00:13:54
阅读次数:
251
企业实践题16:企业案例:写网络服务独立进程模式下rsync的系统启动脚本 例如:/etc/init.d/rsyncd{start|stop|restart} 。要求:1.要使用系统函数库技巧。2.要用函数,不能一坨SHI的方式。3.可被chkconfig管理。 脚本1: #!/bin/bash p ...
分类:
系统相关 时间:
2017-12-05 00:59:42
阅读次数:
235
需求 保障数据安全,防止因数据丢失造成不必要的损失 需要备份的文件 各种配置文件 防火墙 日志 开机自启动 脚本 定时任务 规划 部署 基础环境 查看安装包 配置rsyncd.conf 创建 rsync 账户 创建备份目录 创建密码文件 启动服务 开机自启动 客户端配置 创建密码文件 创建目录 测试 ...
分类:
其他好文 时间:
2017-11-14 15:33:31
阅读次数:
191
一.if语句二.case语句if语句case语句对比三.while语句四.for循环五.fun函数五.fun函数六.check检测mysqld服务脚本的几种方法七.服务启动脚本1.httpd服务启动脚本2.rsyncd的启动脚本3.nginx的启动脚本还有一个更为标准的nginx启动脚本
分类:
系统相关 时间:
2017-11-11 22:11:52
阅读次数:
148
创建脚本cat/server/scripts/rsyncd.conf.sh修改rsync配置文件cat>>/etc/rsyncd.conf<<EOFuid=rsyncgid=rsyncusechroot=nomaxconnections=200timeout=300pidfile=/var/run/rsyncd.pidlockfile=/var/run/rsync.locklogfile=/var/log/rsyncd.logignoreerrorsreadonly..
分类:
其他好文 时间:
2017-10-29 17:34:51
阅读次数:
276
rsync+inotfiy文件同步 1.部署rsync服务 yum install rsync #安装rsync,如果嫌yum版本过低也可以源码安装 2.vim /etc/rsyncd.conf #默认rsync没有配置文件,创建一个,文件中#和汉字仅为注释,使用中请将所有注释清除 #Rsync s ...
分类:
其他好文 时间:
2017-10-27 13:19:37
阅读次数:
158
server端——————————————chkconfigiptablesoffchkconfigip6tablesoffvim/etc/selinux/configSELINUX=disabledyuminstall-yxinetdrsyncchkconfigxinetdonchkconfigrsynconvim/etc/xinetd.d/rsyncdisable=noserver_args=--daemon--config=/etc/rsyncd.confuseradd-M..
分类:
其他好文 时间:
2017-10-24 18:21:35
阅读次数:
153
准备: 主服务器 192.168.0.1 备份服务器 192.168.0.2 备份服务器 注意需要开放873端口 而且小心selinux 开始: sudo vim /etc/rsyncd.passwd rsync_user:123456 注意格式,每行一个用户名:密码 sudo chmod 600 ...
分类:
系统相关 时间:
2017-10-13 10:09:59
阅读次数:
180
rsync服务器配置步骤:1、vi/etc/rsyncd.conf#Rsyncserver#createdbylijianfeng18:262017-9-24#rsyncd.confstart#uid=rsyncgid=rsyncusechroot=nomaxconnections=2000timeout=600pidfile=/var/run/rsyncd.pidlockfile=/var/run/rsync.locklogfile=/var/log/rsyncd.logignoreerr..
分类:
其他好文 时间:
2017-10-10 16:48:02
阅读次数:
127
一、服务节点安装inotify-tools。 确保系统后以下输出=> yum -y install inotify-tools.x86_64 二、客户端 rsync --daemon --config=/etc/rsyncd.conf -v ...
分类:
其他好文 时间:
2017-09-26 09:28:05
阅读次数:
166