Welcome Guest | Login

!!! PID file log/mongrel.pid does not exist.

Today I'm having a spot of trouble getting my app to stop and restart (but it worked previously). I think i've done something strange and i'm having difficulty fixing it.

"mongrel_rails start -e production -p 4066 -d" seems to work (no errors and the mongrel_rails process shows up in top)

"mongrel_rails stop" and "mongrel_rails restart" both give the error "!!! PID file log/mongrel.pid does not exist.  Not running?"

The pid file indeed doesn't exist. Does anyone know what i need to do to correct this?

2007-05-06 07:34 AM

Hey Bitbutter, yes - to correct this problem run a ps or top from your shell and note the process id of the mongrel_rails that will not stop/start

Then you just need to kill this process (kill -9 <pid>) and run your "mongrel_rails start -e production -p 4066 -d" again

This problem occurs when you have your mongrel_rails running but the pid file is removed somehow from the railsapp/log folder

2007-05-06 07:56 AM

Thanks very much for the clarification. I had forgotten to try the kill command, that worked :)

2007-05-06 10:25 AM

Sorry to bring this up again. At this moment, of the 3 apps i have running, only one of them (app A) has a mongrel.pid file (mongrel.4066.pid). Should pid files be created automatically when running mongrel_rails start? if so i don't kow why the other two apps don't currently have one..

I need to kill the mongrel_rails process of one of the other pid-less apps (app B), but without a pid file i don't know how to find out which process corresponds to this app.

1. Is there any way to figure out which process i need to kill in order to restart app B?

2. Are there any common causes of pid files going missing that i should look into?

thanks again

2007-07-15 06:35 AM

Hi Bitbutter,

> 1. Is there any way to figure out which process I need to kill in order to restart app B?
You can use the "top" command to find the PID of the exact process you wish to kill.
2. Are there any common causes of pid files going missing that i should look into?
> I don't have any specific reasons on the top of my head, but did you make sure that you are killing the exact process for which the PID is missing ?

2007-07-15 07:17 AM

thanks for the reply. im not sure how 'top' helps because i don't know which of the three mongrel_rails processes that it displays belongs to the app i need to restart.

2007-07-15 09:57 AM

Try 'ps auxf' instead.  This will tell you the exact command line arguments used for the process and will help to distinguish between them.

2007-07-15 10:35 AM

'ps auxf' resulted in a 'No such file or directory' error
but 'ps' alone did the trick, (i could see the port numbers that had been used for each mongrel_rails command). Thanks very much!

2007-07-15 11:02 AM

I have run into the same problem, and I believe I killed the pid as William instructed using kill. However, I am now unable to start up mongrel from my shell, and am getting a 503 error in my browser.

I am still getting the error "!!! Path to log file not valid: log/mongrel.log" when I try to run "mongrel_rails start"

When I run ps I get the following:
root      2393  0.0  0.0  8168 2260 ?        Ss   19:27   0:00 sshd: mottema [priv]
mottema   2396  0.0  0.0  8168 1680 ?        S    19:27   0:00 sshd: mottema@pts/1
mottema   2400  0.0  0.0  3692 1292 ?        S    19:27   0:00 -jailshell
mottema   4386  0.0  0.0  3528  796 ?        R+   19:42   0:00 ps aux
mottema   4387  0.0  0.0  3064  472 ?        R+   19:42   0:00 grep mottema

2007-08-18 07:43 PM

Hello,

Please check it out now. I have restarted the mongrel using the command pattern (given below) and it started just fine.

mongrel_rails start -e production -p <port n.o> -d

2007-08-18 08:45 PM

Regards,
Rahul
hmmm. now I seem to have 2 problems. Your start did work. I can view the login screen of my app http://mottemanagers.com/account BUT...

1. I can't login. When I login I am getting the "We're sorry, but something went wrong" error. I've made no changes to my login settings or plugin - using acts_as_authenticated.

2. Cap deploy indicates it is working, but never actually deploys the new version. For example, I have tried changing the upper left text MotteAmerican to MotteAmerican - temp. Furthermore, Cap deploy:cold is giving me the same problem as before "Path to log file not valid: log/mongrel.log."

Any ideas?

2007-08-19 05:56 PM

Hello,

Can you please get back to us using a personal ticket rather than a forum query...we need your log-ins so that we can recreate the issue at our local end and find a solution to your problems...

2007-08-19 06:06 PM

Regards,
Rahul

Hello Guest! In order to post you must be an active client with us, please log in or sign up.