Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Running Scripts in a background process

Status
Not open for further replies.

warburp

IS-IT--Management
Oct 27, 2003
44
GB
Hi

I have created a series of menus to execute korn scripts that run Oracle SQL commands on a database. At the moment it is running the scripts in the foregound 'interactively', which locks the session.

What I want to do is to be able to run these scripts in a background process without any dependancy on the submitting session. This is so you can submit the script and log off or do something else. I have tried using &&, am I on the right track or do I need to do something like an at command?

Thanks for your helpd

Phil.
 
Using && ?
To run command in background, you must end the line with &. Take care of i/o redirection.

Hope This Help, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884
 
If you wish your script will run even you close the session do:
nohup Your_Script_2_run_in_BG > Your_Log_File 2>&1 &
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top