Unix BES Agent hanging after running shell script

(imported topic written by SystemAdmin)

Has anyone else noticed this since upgrading to 8.1 …

I have several custom tasks that have an action to run a shell script, in the most these are dynamically created shell scripts. For example I have an action that creates a list of GENxxxxxx SCM scripts that I want to evaluate. The action then creates a dynamic shell script to execute the runme.sh Bigfix script :-

appendfile #!/bin/sh appendfile cd 
{((pathname of parent folder of parent folder of folder (pathname of client folder of current site)) & 
"/SCM")
} appendfile ./runme.sh -F ba_baseline_phase1_scm_list

To execute my dynamic shell script I use:- wait /bin/sh -c “./run_SCM_phase1.sh” in the action (it also happens if I omit the ‘-c’ parameter from the command).

However, the agent doesn’t always recognise that the script has completed and move on to the next task/fixlet in it’s ‘list’. After a while, the server appears in the console as ‘Not Reported’ and I have to log on to the server, stop and start the agent and then the agent carries on OK. Not always but occasionally I see ‘Command failed (Action aborted before completion) wait /bin/sh -c “./run_SCM_phase1.sh” (fixlet 12941)’ in the log but there is definately no ‘run_SCM_phase1.sh’ or ‘runme.sh’ processes running.

There doesn’t seem to be any pattern (except that it is always a shell script that causes it to hang) and quite often it will execute the actions correctly.

(imported comment written by NoahSalzman)

Which 8.1.xxx are you running? What specific version of linux/unix is exhibiting this error?

(imported comment written by SystemAdmin)

Hi Noah,

I’m running 8.1.551.0 agent. I’ve not specifically checked, but as we are most a Rhel 5 shop now the majority of instances have happened on that platform. I do keep meaning to collate some stats on it - but as yet haven’t quite got around to it.

(imported comment written by Jeff Saxton)

Please feel free to contact me at 650-235-0776 I wrote this stuff and can assist you in troubleshooting. There is not currently enough information in this post to offer a diagnosis. Jeff

(imported comment written by SystemAdmin)

Hi Jeff, thanks for that - I think we are going to hit the timezone problem again. I’ll try and call you again this afternoon (your morning).

Cheers, Mark.