Hi, I was reading all helps about how to configure Unison to work with cron, but was impossible for me.
I write a simple script to use unison profile to syncronize my data:
---------------------------------------------------
#!/bin/bash
server1="192.168.1.2"
server2="172.16.1.2"
perfil="profile.prf"
unison="$(which unison)"
if ping -c 1 $server1
then
$unison $perfil
elif ping -c 1 $server2
then
$unison $perfil
else
echo "No tiene Acceso al Server"
fi
date >> unison-script.log
---------------------------------------------------
If I run this script from shell, it's do the work, but if I run this script from CRON, doesn't work the "unison" part, but the last line, the "log" work Ok.
why??
Thanks for your help or ideas!
Bookmarks