• Uncategorized

About linux : Why-second-shell-scriptnohup-not-triggered-after-first-script

Question Detail

I have two shell scripts abc.sh and def.sh(which just echos something).
Third script ghi.sh has:

nohup /home/tomcat/automation/abc.sh &
sleep 20
nohup /home/tomcat/automation/def.sh &

After running ghi.sh, abc.sh is triggered and hangs; def.sh is not triggered at all. How can I fix this issue.

Question Answer

My output on reproducing the issue:

 I ran : abc.txt
 I am also running def.sh

Does def.sh has executable permission?
Add set -x in all files and see where its getting stuck.

You may also like...

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.