pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedDatafiles for Databases
4+ messages / 4 participants
[nested] [flat]
* Datafiles for Databases
@ 2003-09-19 05:38 Kumar <sgnerd@yahoo.com.sg>
0 siblings, 2 replies; 4+ messages in thread
From: Kumar @ 2003-09-19 05:38 UTC (permalink / raw)
To: pgsql-sql
Dear Friends,
I was looking for a structure like oracle or ms Sql server in Postgres. What I have expected is individual datafiles for individual databases. But i cant fine such items in the /usr/local/pgsql/data directory.
Will the postgres create individual data file for databases?
How to get the datafile path of a database?
Please shed light.
Regards
Kumar
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: Datafiles for Databases
@ 2003-09-19 07:53 A.Bhuvaneswaran <bhuvan@symonds.net>
parent: Kumar <sgnerd@yahoo.com.sg>
1 sibling, 0 replies; 4+ messages in thread
From: A.Bhuvaneswaran @ 2003-09-19 07:53 UTC (permalink / raw)
To: Kumar <sgnerd@yahoo.com.sg>; +Cc: pgsql-sql
> Will the postgres create individual data file for databases?
Yes.
> How to get the datafile path of a database?
/var/lib/pgsql/data/base/, database directory name = pg_database.oid. You
can also use oid2name contrib module for finer detail.
regards,
bhuvaneswaran
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: Datafiles for Databases
@ 2003-09-19 10:48 Christopher Browne <cbbrowne@acm.org>
parent: Kumar <sgnerd@yahoo.com.sg>
1 sibling, 1 reply; 4+ messages in thread
From: Christopher Browne @ 2003-09-19 10:48 UTC (permalink / raw)
To: pgsql-sql
In the last exciting episode, sgnerd@yahoo.com.sg ("Kumar") wrote:
> I was looking for a structure like oracle or ms Sql server in Postgres. What I have expected is individual
> datafiles for individual databases. But i cant fine such items in the /usr/local/pgsql/data directory.
>
> Will the postgres create individual data file for databases?
No. Just as with Oracle, PostgreSQL creates multiple files for each
database.
> How to get the datafile path of a database?
select oid, datname from pg_database;
The path for database 'datname' will be:
$PGDATA/base/oid/
--
"aa454","@","freenet.carleton.ca"
http://cbbrowne.com/info/x.html
People can be set wondering by loading obscure personal patchable
systems, and sending bug reports. Who would not stop and wonder upon
seeing "Experimental TD80-TAPE 1.17, MegaDeath 2.5..."? The same for
provocatively-named functions and variables in stack traces.
-- from the Symbolics Guidelines for Sending Mail
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: Datafiles for Databases
@ 2003-09-24 16:12 Bruce Momjian <pgman@candle.pha.pa.us>
parent: Christopher Browne <cbbrowne@acm.org>
0 siblings, 0 replies; 4+ messages in thread
From: Bruce Momjian @ 2003-09-24 16:12 UTC (permalink / raw)
To: Christopher Browne <cbbrowne@acm.org>; +Cc: pgsql-sql
Christopher Browne wrote:
> In the last exciting episode, sgnerd@yahoo.com.sg ("Kumar") wrote:
> > I was looking for a structure like oracle or ms Sql?server in Postgres. What I have expected is individual
> > datafiles for individual databases. But i cant fine such items in the /usr/local/pgsql/data directory.
> >
> > Will the postgres create individual data file for databases?
>
> No. Just as with Oracle, PostgreSQL creates multiple files for each
> database.
>
> > How to get the datafile path of a database?
>
> select oid, datname from pg_database;
>
> The path for database 'datname' will be:
> $PGDATA/base/oid/
See the "Monitoring Disk Space" section in our manuals.
--
Bruce Momjian | http://candle.pha.pa.us
pgman@candle.pha.pa.us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2003-09-24 16:12 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2003-09-19 05:38 Datafiles for Databases Kumar <sgnerd@yahoo.com.sg>
2003-09-19 07:53 ` A.Bhuvaneswaran <bhuvan@symonds.net>
2003-09-19 10:48 ` Christopher Browne <cbbrowne@acm.org>
2003-09-24 16:12 ` Bruce Momjian <pgman@candle.pha.pa.us>
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