From: Ken Hill <ken@scottshill.com>
To: Jeff Frost <jeff@frostconsultingllc.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: How to find data directory
Date: Sun, 18 Dec 2005 16:34:16 -0800
Message-ID: <1134952457.7555.5.camel@localhost.localdomain> (raw)
In-Reply-To: <Pine.LNX.4.64.0512161933170.28807@discord.dyndns.org>
References: <1134772264.7276.2.camel@localhost.localdomain>
<Pine.LNX.4.64.0512161549190.11428@glacier.frostconsultingllc.com>
<1134784056.7354.2.camel@localhost.localdomain>
<Pine.LNX.4.64.0512161933170.28807@discord.dyndns.org>
That works nice. It shows my data directory in
'/var/lib/postgresql/7.4/main'. When I do an ls command, I get:
$ sudo ls /var/lib/postgresql/7.4/main
base pg_clog pg_ident.conf pg_xlog postmaster.opts
root.crt
global pg_hba.conf PG_VERSION postgresql.conf postmaster.pid
I have created two database named 'testdb' and 'csalgorithm'. How do I
find these databases? I was expecting the databases to be subdirectories
under the database directory (e.g. /var/lib/postresql/7.4/main/testdb
and /var/lib/postgresql/7.4/main/csalgorithm).
On Fri, 2005-12-16 at 19:34 -0800, Jeff Frost wrote:
> Then an easy way is likely to look at the init script that starts it, or use
> ps auxwww |grep postmaster to have a look at how it was started. The last
> command will likely yield something that looks like this:
>
> postgres 3026 0.0 0.3 20064 3176 ? S 08:21 0:00 /usr/bin/postmaster -p 5432 -D /var/lib/pgsql/data
>
> Which means the data directory is /var/lib/pgsql/data.
>
> >>> database, but I can find the directory where the database are kept. How
> >>> do I find where the postgresql database directory is from a command
> >>> line?
>
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: ken@scottshill.com, jeff@frostconsultingllc.com
Subject: Re: How to find data directory
In-Reply-To: <1134952457.7555.5.camel@localhost.localdomain>
References: <1134772264.7276.2.camel@localhost.localdomain> <Pine.LNX.4.64.0512161549190.11428@glacier.frostconsultingllc.com> <1134784056.7354.2.camel@localhost.localdomain> <Pine.LNX.4.64.0512161933170.28807@discord.dyndns.org> <1134952457.7555.5.camel@localhost.localdomain>
* 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