pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jeff Eckermann <jeff_eckermann@yahoo.com>
To: pgsql-sql@postgresql.org
Subject: Re: How to check postgres running or not ?
Date: Sun, 19 Sep 2004 09:08:18 -0700 (PDT)
Message-ID: <20040919160818.58480.qmail@web20825.mail.yahoo.com> (raw)
In-Reply-To: <m3r7ozqysw.fsf@wolfe.cbbrowne.com>


--- Christopher Browne <cbbrowne@acm.org> wrote:

> In an attempt to throw the authorities off his
> trail, sgaikwad@vertex.co.in ("Sandeep Gaikwad")
> transmitted:
> > Hello Sir,
> >                 I want to know how to check
> whether postgres database
> > is running or not ? when  I give command like
> ./postmaster -i &,
> > whether all databases in that postgres will run or
> any one [default] ? 
> > If any one, then how to detect that database ?

The "standard" way would be "pg_ctl status".  "man
pg_ctl" is recommended reading for anyone
administering a PostgreSQL setup.

> 
> Well, the way I usually check on what databases are
> running is thus:
> 
> cbbrowne@wolfe:/tmp/mm5/doc> netstat -an | grep PG  
>                                                     
>                                  Saturday 13:18:30
> unix  2      [ ACC ]     STREAM     LISTENING    
> 2793 /var/run/postgresql/.s.PGSQL.5432
> 
> One could presumably script things further to get
> more out of that; it
> doesn't normally seem worthwhile to do so...
> -- 
> output = ("cbbrowne" "@" "ntlug.org")
> http://www.ntlug.org/~cbbrowne/postgresql.html
> "As long as war is regarded as wicked, it will
> always have
>  its fascination.  When it is looked upon as vulgar,
>  it will cease to be popular."
>     --Oscar Wilde
> 
> ---------------------------(end of
> broadcast)---------------------------
> TIP 2: you can get off all lists at once with the
> unregister command
>     (send "unregister YourEmailAddressHere" to
> majordomo@postgresql.org)
> 



		
_______________________________
Do you Yahoo!?
Declare Yourself - Register online to vote today!
http://vote.yahoo.com



view thread (22+ messages)  latest in thread

Message-ID: <20040919160818.58480.qmail@web20825.mail.yahoo.com>
Permalink:  ../20040919160818.58480.qmail@web20825.mail.yahoo.com/
Also on:    postgresql.org/message-id/20040919160818.58480.qmail@web20825.mail.yahoo.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: jeff_eckermann@yahoo.com
  Subject: Re: How to check postgres running or not ?
  In-Reply-To: <20040919160818.58480.qmail@web20825.mail.yahoo.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox