V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
Distributions
Ubuntu
Fedora
CentOS
中文资源站
网易开源镜像站
iesvme
V2EX  ›  Linux

lsyncd 无法同步 windows 共享文件。

  •  
  •   iesvme · 2017-11-28 15:37:50 +08:00 · 2724 次点击
    这是一个创建于 2312 天前的主题,其中的信息可能已经有所发展或是发生改变。

    手动运行时,是可以同步过来的,但就是不能自动触发运行;就是 /mnt 有变化了,也不能自动触发同步。
    试了 incron 的 IN_ALL_EVENTS,也是一样,也不能触发自动同步。望高人赐教!

    这是配置文件。

    settings {
    logfile = "/var/log/lsyncd.log",
    statusfile = "/var/log/lsyncd.status"
    }
    sync {
    default.rsync,
    source = "/mnt/pmc",
    target = "/home/总库 /pmc",
    exclude = {".",".tmp","~."}
    }

    mount -t cifs -o ...

    1 条回复    2017-12-21 11:15:06 +08:00
    yulgang
        1
    yulgang  
       2017-12-21 11:15:06 +08:00
    settings {
    statusFile = "/var/log/lsyncd/lsyncd.status",
    statusInterval = 1,
    logfile="/var/log/lsyncd/lsyncd.log",
    insist = true,
    }

    sync {
    default.rsync,
    source = "/opt/tomcat-app-8008/webapps",
    target = "[email protected]::app",

    exclude = { ".*", ".tmp", "/*.zip", "/*.gz", "/*.war", "/*.bak"},
    delay = 600,
    maxProcesses = 4,

    rsync = {
    binary = "/usr/bin/rsync",
    archive = true,
    acls = true,
    compress = true,
    verbose = true,
    owner = true,
    group = true,
    perms = true,
    password_file = "/etc/6666.pwd",
    _extra = {"--bwlimit=300"}
    }
    }

    这是我用的局域网配置,和你的有点区别。仅供参考:

    Version: 2.1.6
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   1244 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 18:00 · PVG 02:00 · LAX 11:00 · JFK 14:00
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.