zoukankan      html  css  js  c++  java
  • fedora25的免密码rsync服务配置

     

    目标:实现免密同步数据;

    1、安装rsync包;

    2、手工添加配置文件;

    cat  /etc/rsyncd.conf

    
    # See rsyncd.conf man page for more options.
    
    # configuration example:
    
    pid file = /var/run/rsyncd.pid
    max connections = 5
    exclude = lost+found/
    motd file = /etc/rsyncd.motd 
    log file = /var/log/rsyncd.log
    log format = %t %a %m %f %b
    timeout = 30 
    port=873
    
    [rsynsc]
    uid = root 
    gid = root
    use chroot = yes 
    read only = yes
    path = /xxxxxxxx/path/
    comment = welcome
    list=yes 
    #auth users = test
    #secrets file = /etc/rsyncd.secrets

    开启rsync服务

    /usr/bin/rsync --daemon --config=/etc/rsyncd.conf

    查看rsync服务是否正常运行

    [root@localhost ]# netstat -an | grep 873
    tcp 0 0 0.0.0.0:873 0.0.0.0:* LISTEN 
    tcp6 0 0 :::873 :::* LISTEN 
    unix 3 [ ] STREAM CONNECTED 23873 /run/systemd/journal/stdout

    同步方法:

    rsync -avzP rsync://rsync_server_ip/path/    localpath

    note:

    查看rsync服务器下的目录信息

    rsync -v  rsync://rsync_server_ip/path/ 

  • 相关阅读:
    外观模式
    享元模式
    c#中的抽象类和接口
    装饰者模式
    组合模式
    适配器模式
    springboot 源码篇002## web层自动装配部分源码
    springboot 源码篇002## 自动装配原理
    springboot 源码篇 01
    shell 脚本基础 第二篇
  • 原文地址:https://www.cnblogs.com/noxy/p/9261890.html
Copyright © 2011-2022 走看看