zoukankan      html  css  js  c++  java
  • rsync 设置

    客户端(待备份):
    配置/etc/rsyncd.conf
    [root@linuxas3 root]# vi /etc/rsyncd.conf

    uid
    =root
    gid
    =root
    max connections
    =4
    use chroot=no
    log file
    =/var/log/rsyncd.log
    pid file
    =/var/run/rsyncd.pid
    lock file=/var/run/rsyncd.lock
    #auth users=root
    secrets file
    =/etc/rsyncd.pwd

    [postfix]
    path
    =/var/mail
    comment
    = backup mail
    ignore errors
    read only
    = yes
    list
    = no
    auth users
    = postfix

    [netkiller]
    path
    =/home/netkiller/web
    comment
    = backup 9812.net
    ignore errors
    read only
    = yes
    list
    = no
    auth users
    = netkiller

    [pgsqldb]
    path
    =/var/lib/pgsql
    comment
    = backup postgresql database
    ignore errors
    read only
    = yes
    list
    = no

    rsync
    --daemon

    echo  
    "rsync  --daemon"  >>  /etc/rc.d/rc.local
    服务端(备份区):
    rsync -avIR --delete--password-file=/etc/rsyncd.scrt name@ip::model 存放的文件


    编写存放在一个文件中,赋予其可执行权限,之后编辑/etc/crontab控制其执行时间
  • 相关阅读:
    Spring----MyBatis整合
    VueRouter案列
    Vue-Router
    axios用法
    Fetch的使用
    Promise用法
    组件之间传值
    局部组件注册方式
    学习组件与模板
    如何实现new,call,apply,bind的底层原理。
  • 原文地址:https://www.cnblogs.com/feiling/p/2558926.html
Copyright © 2011-2022 走看看