pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedHow to place a table on a separate partition?
2+ messages / 2 participants
[nested] [flat]
* How to place a table on a separate partition?
@ 2001-03-29 18:51 Rodin A. Porrata <porrata@west.llnl.gov>
1 sibling, 0 replies; 2+ messages in thread
From: Rodin A. Porrata @ 2001-03-29 18:51 UTC (permalink / raw)
To: pgsql-admin
Hi,
I am putting together a large database and want the
table to reside on a partition separate from the
default under 'base'. How can I do this?
I tried the following: First I created the place I
wanted to put the table:
mkdir /taos/01/postgres
chown taos /taos/01/postgres
Then I modified the .profile of postgres
so that:
PGDATA2 = /taos/01/postgres
export PGDATA2
then on the command line of the postgres
account I typed
initlocation $PGDATA2
which was successful.
Then I typed
initdb -D $PGDATA2 -i 1095
Now I had to kill the old postmaster and restart it. However,
I could only give it one location to utilize the data base, i.e.,
postmaster -D /taos/01/postgres
createdb -U taos -D $PGDATA2 large_table
So does this mean I have to start a separate postmaster for
the new location? How would I do that?
What we would like is a single postmaster to handle
all database queries, etc. However, for the especially
large table have a special user and table only.
Rodin
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: How to place a table on a separate partition?
@ 2001-03-29 19:39 Stefan Huber <schweinsaug@crosswinds.net>
1 sibling, 0 replies; 2+ messages in thread
From: Stefan Huber @ 2001-03-29 19:39 UTC (permalink / raw)
To: pgsql-admin
>I am putting together a large database and want the
>table to reside on a partition separate from the
>default under 'base'. How can I do this?
You could create symlinks for the larger tables pointing to another location:
ln -s /path/to/table/bigtable /usr/local/pgsql/data/base/whatever/bigtable
(supposed /usr/local/pgsql is your Postgres directory)
If there are serious troubles to be expected, I'd like to know that, because we have used this method once (not so important DB, without any probs till now)
Stefan
--
Atheism is a non-prophet organization.
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2001-03-29 19:39 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-03-29 18:51 ` Rodin A. Porrata <porrata@west.llnl.gov>
2001-03-29 19:39 ` Stefan Huber <schweinsaug@crosswinds.net>
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