[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Jailkit-users] nohup in jail

From: Martin
Subject: [Jailkit-users] nohup in jail
Date: Wed, 10 Aug 2011 16:23:34 +0200
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:5.0) Gecko/20110624 Thunderbird/5.0

Hello all jailkit users,
did anyone tried to exec bash script like this (outside of jail):
printf "#!/bin/bash\n" > /home/jail/tmp/$3.sh;
echo "umask 0007 && cd /home/$3 && touch nohup.out && chmod 750 nohup.out && nohup ./$prog -- $arg" >> /home/jail/tmp/$3.sh;
chmod 755 /home/jail/tmp/$3.sh;
chown root.root /home/jail/tmp/$3.sh;
/usr/sbin/jk_chrootlaunch -j /home/jail -u jailer -g ftpgroup -x /home/jail/tmp/$3.sh

when i exec script manualy nohup.out file is fully filled by ./$prog output, but when this bash script is executed like this (in crontab):
* * * * * /home/rootcmds/home/sc.sh
, then file nohup.out is created, but has 0B size and nothing is inside.

Any idea how to solve or how to force crontab executed bash script that will run program in jail to append it's output to nohup.out file?

Thanks for any reply,

reply via email to

[Prev in Thread] Current Thread [Next in Thread]