Sample Header Ad - 728x90

Unison and Incron shell script

2 votes
0 answers
1002 views
I have successfully installed unison and incron. I get unison to run just fine. I'm doing this all logged in as root by the way, I figure that's how this will be executed when i'm not logged in. I'm using ssh, and have a passwordless key file. I can successfully call unison and have it sync just fine. I can call the shellscript and that works too. But Nothing happens when the incron is triggered and unison is called. I also modified my incrontab to run unison directly and that doesn't work. And I don't see any errors. any help would be greatly appreciated! I'm still getting use to linux. **Unison default.prf** # Unison preferences file sshargs = -i uni batch = true silent = true log = true logfile = /var/log/unison.log root = /var/www root = ssh://ipaddress//var/www/ path = test ignore = Name test/sub2/suber confirmbigdel = false **Incrontab -e** /var/www/test/ IN_ALL_EVENTS /root/au.sh **au.sh** #!/bin/bash unison -batch I can run my shellscript just fine. I'm adding the batch flag again just for kicks. I know that incrontab is working, I see output in the **/var/log/sys.log** Oct 18 19:38:27 inctrg-dev-01 incrond: (root) CMD (/root/au.sh)
Asked by aibarra (121 rep)
Oct 18, 2016, 07:42 PM
Last activity: Oct 19, 2016, 03:56 PM