Ok, I have solved the problem... That the log-files weren't even created
should have made me realize that the problem had to do with file-access
permissions. When I started the app as a service it got other privileges
than when I started it at the prompt and that was why the app didn't start,
because it couldn't create the log files...

Maybe a troubleshooting section should be added to the Win32 Howto
describing this problem? Something like:


Troubleshooting

When running Mongrel as a service you have to think about what permissions
the service is going to get. If the service doesn't have write-access to the
log-files in the gem's bin-directory (something like:
C:\ruby\lib\ruby\gems\1.8\gems\mongrel-0.3.12.4-mswin32\bin) it won't be
able to start and you won't get any log files that tells you why. 

If this is the case, trying to start the service will give you the following
error message:

> There was a problem starting the service:
> The service did not respond to the start or control request in a timely
> fashion.

Also remember that rails needs to be able to write to certain directories
like the log-directory (railsapp/log) and the directories beneath
railsapp/tmp/


What do you think?

/Gabriel Falkenberg
 

> -----Ursprungligt meddelande-----
> Från: [EMAIL PROTECTED] [mailto:mongrel-users-
> [EMAIL PROTECTED] För Gabriel Falkenberg
> Skickat: den 11 maj 2006 09:35
> Till: [email protected]
> Ämne: Re: [Mongrel] Problems starting mongrel running a rails app as
> aservice (win 2k)
> 
> > To pinpoint if the problem is related to mongrel services or rails,
> > please:
> >
> > Create a emtpy rails application.
> > start mongrel for it, and check the webpage (the rails properties one).
> > Then install the service and run it.
> > If everything start and run ok, thre is something during the load of
> > the controllers and models that hang or halt and raises that error.
> 
> Nice suggestion Luis, I hadn't thought about that. It seems like there is
> something wrong with the services part cause even a fresh rails app which
> runs perfectly using just "mongrel_rails start" fails to start as a
> service
> with the same error message:
> 
> There was a problem starting the service:
> The service did not respond to the start or control request in a timely
> fashion.
> 
> I guess my question is, has anyone succeeded in running mongrel as a
> service
> (or any service using win32/service) using windows 2000?
> 
> Thanks,
> Gabriel Falkenberg
> 
> 
> 
> _______________________________________________
> Mongrel-users mailing list
> [email protected]
> http://rubyforge.org/mailman/listinfo/mongrel-users



_______________________________________________
Mongrel-users mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/mongrel-users

Reply via email to