Lsyncd é executado, mas não atualiza arquivos

Lsyncd é executado, mas não atualiza arquivos

Então instalei o daemon e configurei-o como:

matias@~ 
 $ cat /etc/lsyncd/lsyncd.conf.lua 
settings {
        logfile = "/var/log/lsyncd/lsyncd.log",
        statusFile = "/tmp/lsyncd.stat",
        statusInterval = 1,
        verbose = false,
}

sync {
        default.rsync,
        source    = '/home/matias/Remoto',
        target    = '[email protected]:./Remoto',
        delay     = 1,
    rsync= {
        owner = true,
        perms = true,
        group = true,
        acls = true,
        verbose = true,
        rsh = "/usr/bin/ssh -i /home/matias/.ssh/id_rsa.pub -p 22 -o StrictHostKeyChecking=no"
    }
}

Posso ver que o daemon está instalado e funcionando:

matias@~ 
 $ sudo systemctl status lsyncd
[sudo] password for matias: 
● lsyncd.service - LSB: lsyncd daemon init script
   Loaded: loaded (/etc/init.d/lsyncd; bad; vendor preset: enabled)
   Active: active (exited) since jue 2020-01-23 16:18:05 -03; 3h 28min ago
     Docs: man:systemd-sysv-generator(8)
  Process: 13723 ExecStop=/etc/init.d/lsyncd stop (code=exited, status=0/SUCCESS
  Process: 13731 ExecStart=/etc/init.d/lsyncd start (code=exited, status=0/SUCCE

ene 23 16:18:05 lenovoI5 systemd[1]: Starting LSB: lsyncd daemon init script...
ene 23 16:18:05 lenovoI5 lsyncd[13731]:  * Starting synchronization daemon lsync
ene 23 16:18:05 lenovoI5 lsyncd[13731]:    ...done.
ene 23 16:18:05 lenovoI5 systemd[1]: Started LSB: lsyncd daemon init script.

E se eu executar o journalctl, posso ver isso:

matias@~ 
 $ sudo journalctl -u lsyncd 
-- Logs begin at jue 2020-01-23 10:20:58 -03, end at jue 2020-01-23 19:47:45 -03
......
ene 23 16:06:46 lenovoI5 lsyncd[13218]: Error: error preparing /etc/lsyncd/lsync
ene 23 16:06:46 lenovoI5 lsyncd[13218]:    ...fail!
ene 23 16:18:05 lenovoI5 systemd[1]: Starting LSB: lsyncd daemon init script...
ene 23 16:18:05 lenovoI5 lsyncd[13731]:  * Starting synchronization daemon lsync
ene 23 16:18:05 lenovoI5 lsyncd[13731]:    ...done.
ene 23 16:18:05 lenovoI5 systemd[1]: Started LSB: lsyncd daemon init script

Estas linhas provam que ele realmente lê o arquivo de configuração e eu o corrigi:

ene 23 16:06:46 lenovoI5 lsyncd[13218]: Error: error preparing /etc/lsyncd/lsyncd.conf.lua: Parameter "identityFile" unknown. (if this is not a ty
ene 23 16:06:46 lenovoI5 lsyncd[13218]:    ...fail!

Posso ver o log de estatísticas sendo criado:

matias@~ 
 $ cat /tmp/lsyncd.stat 
Lsyncd status report at Thu Jan 23 16:18:05 2020

Sync1 source=/home/matias/Remoto/
There are 1 delays
active Init 
Excluding:
  nothing.


Inotify watching 4 directories
  1: /home/matias/Remoto/
  2: /home/matias/Remoto/Documentos/
  3: /home/matias/Remoto/Archivos/
  4: /home/matias/Remoto/Mas/

O problema é que arquivos e diretórios não estão sendo sincronizados no servidor remoto. Criei a pasta Mas após reiniciar o serviço e após 1 hora ela não foi atualizada.

O estranho é que funcionou quando eu o executei manualmente como:

lsyncd /etc/lsyncd/lsyncd.conf.lua 

O que estou fazendo de errado?

informação relacionada