System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

run a script while disassociating it from parent process

Jason Moorhead_2
Frequent Advisor

run a script while disassociating it from parent process

I really hope the title explains well enough..

Basically, I have a 32-bit 4GL database script that can execute a unix command from within it. What I need is to have it do it execute a unix command without the 4GL program as its parent.

The issue is that the unix command bombs out if called from within the db script, yet it runs fine when run from the shell or from cron.

OS: RHEL 5.5 x64
2 REPLIES
Steven Schweda
Honored Contributor

Re: run a script while disassociating it from parent process

> Basically, [...]

A dangerous beginning.

> [...] a unix command [...]

Not a very detailed description of the
command.

> The issue [...]

Is that anything like a _problem_?

> [...] the unix command bombs out [...]

Not a very detailed description of the
failure.

It might make more sense to try to fix the
actual original problem than to try to
implement some particular potential solution
which may or may not make any sense.
Dennis Handly
Acclaimed Contributor

Re: run a script while disassociating it from parent process

Perhaps use nohup?

Bombs out how? Perhaps you need to invoke a script that does your command. That way you can control any needed environment variables.