LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices

Reply
 
Search this Thread
Old 01-07-2007, 02:44 PM   #1
pier0w
LQ Newbie
 
Registered: Jan 2007
Posts: 4

Rep: Reputation: 0
Question crontab - Multiple Instances of same Process


Hi,

I'm running Redhat ES4 and am having some problems with a crontab entry that imports data into a mysql data base.

The thing is when crontab runs this process it creates three instances of it. I think this may be causing the import to freeze because three processes are importing to the same tables at the same time.

Is this normal for crontab to do, to create three instances of any process that it is executing? Or is it actually just the one process that shows up three time in the ps list?

Any information on this would be much appreciated.

Thank you for your help.
 
Old 01-07-2007, 11:41 PM   #2
blackhole54
Senior Member
 
Registered: Mar 2006
Posts: 1,896

Rep: Reputation: 61
If you only have one entry in crontab then it should only be launched once. If you want to put your mind at ease, try running ps where it shows both the process id (PID) and the parent's process id (PPID), so you can see the relationship between them.

You can do that with:

ps -o pid,ppid,user,cmd -C <command name>

(Substitute the real command name for <command name>)
 
Old 01-09-2007, 02:33 PM   #3
pier0w
LQ Newbie
 
Registered: Jan 2007
Posts: 4

Original Poster
Rep: Reputation: 0
Awesome thanks for the help man.

For a little more info I was using the following command to find the processes:

ps -ef | grep <command name>

Probably should have mentioned that in the first post
 
Old 01-10-2007, 05:45 AM   #4
blackhole54
Senior Member
 
Registered: Mar 2006
Posts: 1,896

Rep: Reputation: 61
Quote:
Originally Posted by pier0w
For a little more info I was using the following command to find the processes:

ps -ef | grep <command name>

Probably should have mentioned that in the first post
I hesitated to post on this thread because ps is a command I've had a lot of trouble getting my head around. Initially I pretty much tried to force top to do everything I needed. I am slowly learning ps, and your reply gave me another incremental amount of knowledge. Thanks.
 
  


Reply

Tags
crontab, redhat


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple instances of artsd Mojojo Linux - Software 0 10-13-2005 11:41 AM
SAMBA: Multiple Instances? Matir Linux - Software 0 02-18-2005 10:43 AM
Mplayer and Multiple instances Spaz007 Linux - Software 0 09-16-2004 10:59 PM
preventing multiple process instances the_dayi Programming 2 07-14-2003 05:57 AM
Multiple instances of same user justinv Linux - General 7 01-19-2003 04:05 PM


All times are GMT -5. The time now is 12:05 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration