zoukankan      html  css  js  c++  java
  • rsync 07-confxml.xml配置文件

    [root@centos6]# cat confxml.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <head version="2.5">
        <!-- 设置本地IP和端口 -->
        <host hostip="localhost" port="8008"></host>
        <!-- 开启DUBUG模式  -->
    	<debug start="false"/>
        <!-- 开启xfs文件系统 -->
        <fileSystem xfs="false"/>
    
        <!-- 同步时忽略推送的文件(正则表达式),默认关闭  -->
        <filter start="false">
            <exclude expression="(.*).svn"></exclude>
            <exclude expression="(.*).gz"></exclude>
            <exclude expression="^info/*"></exclude>
            <exclude expression="^static/*"></exclude>
        </filter>
    
        <!-- 设置要监控的事件 -->
        <inotify>
            <delete start="false"/>
            <createFolder start="true"/>
            <createFile start="false"/>
            <closeWrite start="true"/>
            <moveFrom start="true"/>
            <moveTo start="true"/>
            <attrib start="false"/>
            <modify start="false"/>
        </inotify>
    
        <sersync>
      	<!-- 本地监视目录路径 -->
            <localpath watch=" /data/bakup/"> 
    			<!-- 定义同步Server ip和模块 -->
                <remote ip="192.168.0.132" name="bakup"/>
            </localpath>
    
    		<rsync>
    			<!-- rsync指令参数 -->
                <commonParams params="-artuz"/>
                <!--  rsync同步认证 -->
                <auth start="true" users="rsync_bakup" passwordfile="/etc/rsyncd.password"/>
                <!-- 设置rsync远程服务端口,非默认端口需要打开自定义(若开启rsync+ssh, 则这里需定义SSH端口) -->
                <userDefinedPort start="false" port="873"/>
    			<!-- 设置超时时间 -->
                <timeout start="ture" time="100"/>
    			<!-- 设置rsync+ssh加密传输模式,默认关闭,开启需设置SSH加密证书 -->
                <ssh start="false"/>
            </rsync>
    
    		<!-- sersync传输失败日志脚本路径,每隔60会重新执行该脚本,执行完毕会自动清空。 -->
            <failLog path="/usr/local/sersync/logs/rsync_fail_log.sh" timeToExecute="60"/>
    			<!-- 设置rsync定时传输,默认关闭 -->
    	        <crontab start="false" schedule="600">
    	            <crontabfilter start="false">
    	                <exclude expression="*.php"></exclude>
    	                <exclude expression="info/*"></exclude>
    	            </crontabfilter>
    	        </crontab>
    
    			<!-- 设置sersync传输后调用name指定的插件脚本,默认关闭 -->
            <plugin start="false" name="command"/>
        </sersync>
    
        <!-- 插件脚本范例 -->
        <plugin name="command">
            <param prefix="/bin/sh" suffix="" ignoreError="true"/> <!--prefix /opt/tongbu/mmm.sh suffix-->
            <filter start="false">
                <include expression="(.*).php"/>
                <include expression="(.*).sh"/>
            </filter>
        </plugin>
    
        <!-- 插件脚本范例 -->
        <plugin name="socket">
            <localpath watch="/opt/tongbu">
                <deshost ip="192.168.138.20" port="8009"/>
            </localpath>
        </plugin>
        <plugin name="refreshCDN">
            <localpath watch="/data0/htdocs/cms.xoyo.com/site/">
                <cdninfo domainname="ccms.chinacache.com" port="80" username="xxxx" passwd="xxxx"/>
                <sendurl base="http://pic.xoyo.com/cms"/>
                <regexurl regex="false" match="cms.xoyo.com/site([/a-zA-Z0-9]*).xoyo.com/images"/>
            </localpath>
        </plugin>
    </head>
    
  • 相关阅读:
    110. 平衡二叉树-前序遍历-简单
    207. 课程表-有向图判断有无环状-中等难度
    java错误集锦
    199. 二叉树的右视图-二叉树,dfs,从右往左遍历-中等难度
    114. 二叉树展开为链表-二叉树,dfs-中等难度
    236. 二叉树的最近公共祖先-中序遍历-中等难度
    Kendo ui 入门知识点
    Css样式压缩、美化、净化工具 源代码
    Linq与Lambda常用查询语法
    15个超强悍的CSS3圆盘时钟动画赏析
  • 原文地址:https://www.cnblogs.com/liangjingfu/p/9759124.html
Copyright © 2011-2022 走看看