On 11/21/2016 07:37 AM, Kostis Fardelas wrote: > Hello community, > I am trying to run a script as a Client Run Before Job > > Client Run Before Job = "/etc/bacula/scripts/mysqlxtra_dt" > > The script: > #!/bin/sh > > ICICMD=$(which ici) > $ICICMD -dt 3600 -svc 'mysql-replication' > /dev/null > > But the job keeps failing with: > "ClientRunBeforeJob: /etc/bacula/scripts/mysqlxtra_dt: 7: > /etc/bacula/scripts/mysqlxtra_dt: -dt: not found" > > What am I doing wrong? > > Best regards, > Kostis
Hi Kostis, My fisrt guess is that $(which ici) is returning a null string, so the variable $ICICMD is empty, and hence the command that is actually being called is "-dt 3600 -svc 'mysql-replication' > /dev/null" You need to double-check and verify that $(which ici) returns the full path/filename of the command you are attempting to assign. Best regards, Bill -- Bill Arlofski http://www.revpol.com/bacula -- Not responsible for anything below this line -- ------------------------------------------------------------------------------ _______________________________________________ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users