librelist archives

« back to archive

Find the current config.sqlite for a running instance of mongrel2?

Find the current config.sqlite for a running instance of mongrel2?

From:
Matt Towers
Date:
2011-01-27 @ 23:20
Is it possible to find out which config.sqlite file was used when starting
up mongrel2?  ps -ax only gives a partial path.

I've been playing around with mongrel2 and found myself in a situation 
where I had several config.sqlite files laying around and forgot which one
I used when launching with m2sh.

Given that m2sh requires access to the same config.sqlite that was used at
launch time when shutting down, it took me a bit of trial and error to 
find the one I used and exit mongrel2 cleanly.  Granted I could have just 
killed the mongrel2 process but it would have been handy to be able to 
query for a path to the config that was used when starting.

✈ Matt


Re: [mongrel2] Find the current config.sqlite for a running instance of mongrel2?

From:
Zed A. Shaw
Date:
2011-01-27 @ 23:56
On Thu, Jan 27, 2011 at 03:20:43PM -0800, Matt Towers wrote:
> Is it possible to find out which config.sqlite file was used when
> starting up mongrel2?  ps -ax only gives a partial path.

Hmm, yeah that'd be possible.  Maybe a part of the status command?

-- 
Zed A. Shaw
http://zedshaw.com/

Re: [mongrel2] Find the current config.sqlite for a running instance of mongrel2?

From:
Matt Towers
Date:
2011-01-28 @ 20:09
Works for me.

Is there already a status command in m2sh?  The help output doesn't list one.

✈ Matt



On Jan 27, 2011, at 15:56 , Zed A. Shaw wrote:

> On Thu, Jan 27, 2011 at 03:20:43PM -0800, Matt Towers wrote:
>> Is it possible to find out which config.sqlite file was used when
>> starting up mongrel2?  ps -ax only gives a partial path.
> 
> Hmm, yeah that'd be possible.  Maybe a part of the status command?
> 
> -- 
> Zed A. Shaw
> http://zedshaw.com/

Re: [mongrel2] Find the current config.sqlite for a running instance of mongrel2?

From:
Matt Towers
Date:
2011-01-28 @ 20:28
Disregard.  I found it.

http://mongrel2.org/doc/tip/docs/manual/book.wiki#x1-360003.8

✈ Matt



On Jan 28, 2011, at 12:09 , Matt Towers wrote:

> Works for me.
> 
> Is there already a status command in m2sh?  The help output doesn't list one.
> 
> ✈ Matt
> 
> 
> 
> On Jan 27, 2011, at 15:56 , Zed A. Shaw wrote:
> 
>> On Thu, Jan 27, 2011 at 03:20:43PM -0800, Matt Towers wrote:
>>> Is it possible to find out which config.sqlite file was used when
>>> starting up mongrel2?  ps -ax only gives a partial path.
>> 
>> Hmm, yeah that'd be possible.  Maybe a part of the status command?
>> 
>> -- 
>> Zed A. Shaw
>> http://zedshaw.com/
> 

Re: [mongrel2] Find the current config.sqlite for a running instance of mongrel2?

From:
Sebastian Otaegui
Date:
2011-01-27 @ 23:51
Did you try 'ps axwww' ?

Just a thought.



On Thu, Jan 27, 2011 at 5:20 PM, Matt Towers <matt@ziplinegames.com> wrote:

> Is it possible to find out which config.sqlite file was used when starting
> up mongrel2?  ps -ax only gives a partial path.
>
> I've been playing around with mongrel2 and found myself in a situation
> where I had several config.sqlite files laying around and forgot which one I
> used when launching with m2sh.
>
> Given that m2sh requires access to the same config.sqlite that was used at
> launch time when shutting down, it took me a bit of trial and error to find
> the one I used and exit mongrel2 cleanly.  Granted I could have just killed
> the mongrel2 process but it would have been handy to be able to query for a
> path to the config that was used when starting.
>
> ✈ Matt
>
>
>
>


-- 
Those who do not understand Unix are condemned to reinvent it, poorly.
Any sufficiently recent Microsoft OS contains an ad hoc,
informally-specified, bug-ridden, slow implementation of half of Unix.