#994857 iwatch: Fails to send sendxmpp

Package:
iwatch
Source:
iwatch
Submitter:
Sérgio Abrantes
Date:
2021-09-22 03:48:03 UTC
Severity:
important
#994857#5
Date:
2021-09-22 03:26:37 UTC
From:
To:
Hello,

I'm setting up sending xmpp in a test environment and realized that:

1) Running iwatch from the system, sending xmpp does not happen.

root@debian11:/var/log# /etc/init.d/iwatch status
● iwatch.service - realtime filesystem monitoring program using inotify
     Loaded: loaded (/lib/systemd/system/iwatch.service; enabled; vendor preset: enabled)
     Active: active (running) since Tue 2021-09-21 23:26:11 -03; 4min 2s ago
       Docs: man:iwatch
    Process: 537 ExecStart=/usr/bin/iwatch -f $CONFIG_FILE -p /run/iwatch.pid -d (code=exited, status=0/SUCCESS)
   Main PID: 690 (iwatch)
      Tasks: 1 (limit: 1133)
     Memory: 23.3M
        CPU: 169ms
     CGroup: /system.slice/iwatch.service
             └─690 /usr/bin/perl -T /usr/bin/iwatch -f /etc/iwatch/iwatch.xml -p /run/iwatch.pid -d

set 21 23:26:10 debian11 systemd[1]: Starting realtime filesystem monitoring program using inotify...
set 21 23:26:11 debian11 systemd[1]: Started realtime filesystem monitoring program using inotify.
set 21 23:26:11 debian11 su[890]: (to nobody) root on none
set 21 23:26:11 debian11 su[890]: pam_unix(su:session): session opened for user nobody(uid=65534) by (uid=0)
set 21 23:26:12 debian11 su[890]: pam_unix(su:session): session closed for user nobody

2) Running the same command line shown above with "/etc/init.d/iwatch status", removing the daemon "-d"
parameter and inserting the verbose "-v" parameter, the send works. Without changing anything in the configuration file.

root@debian11:/var/log# /usr/bin/perl -T /usr/bin/iwatch -f /etc/iwatch/iwatch.xml -p /run/iwatch.pid -v
Watch /bin
Watch /sbin
Watch /etc
Watch /lib
Watch /tmp
[21/set/2021 23:31:45] IN_CREATE /tmp/2
[21/set/2021 23:31:45] * Command: (echo iWatch: IN_CREATE /tmp/2;w;ps -ef)|sendxmpp -t user@example
[21/set/2021 23:31:45] * Send email to root@localhost
[21/set/2021 23:31:49] IN_CLOSE_WRITE /tmp/2
[21/set/2021 23:31:49] * /tmp/2 is closed
[21/set/2021 23:31:49] * Command: (echo iWatch: IN_CLOSE_WRITE /tmp/2;w;ps -ef)|sendxmpp -t user@example
[21/set/2021 23:31:49] * Send email to root@localhost

Regards