The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
shell script takes long time to complete ozzman Shell Programming and Scripting 12 02-05-2007 08:25 PM
ls -t arg list too long CSU_Ram UNIX for Dummies Questions & Answers 4 05-05-2005 07:19 AM
C long long HP-UX Shobhit High Level Programming 1 04-19-2002 09:33 AM
arg list too long vingupta UNIX for Dummies Questions & Answers 5 08-02-2001 08:43 PM

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1  
Old 03-05-2006
Registered User
 

Join Date: Mar 2006
Posts: 2
A very long script.

Hello,
I wrote a script, which would ideally take about 480 hours to runs (It has to do a same thing 60 times.) But the problem is I have to use a VPN Client to get to the network before connecting to the machine. The Client automatically closes after 10 hours, closing my console and thus my script. So my question is:
Is there some way by which I can run the script as a batch process in the background so that closing of the console doesn't affect its running?
My script invokes a few programs (matlab compiled programs and the FE package ABAQUS) which produce a few warning messages.
Thanks
-sakya
Reply With Quote
Forum Sponsor
  #2  
Old 03-05-2006
Registered User
 

Join Date: Feb 2006
Location: msk.ru.earth
Posts: 43
You can use cron
Just add this script in /etc/crontab and reread config this command
# crontab /etc/crontab
to launch script under your account

If it must be runing under root account - don't rereading config (OS will be doing this itself)
Reply With Quote
  #3  
Old 03-05-2006
Perderabo's Avatar
Unix Daemon
 

Join Date: Aug 2001
Location: Washington DC Area
Posts: 8,608
Just use nohup:
nohup /path/to/my/long/running/script
Reply With Quote
  #4  
Old 03-05-2006
Registered User
 

Join Date: Mar 2006
Posts: 2
Thanks guys for your help.
nohup did the trick
-s
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 04:32 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0