Re: migrating/spliting Postgres data directory on OpenIndiana

Поиск
Список
Период
Сортировка
От Thomas Munro
Тема Re: migrating/spliting Postgres data directory on OpenIndiana
Дата
Msg-id CADLWmXW7m_7P0nUbGJcbDimMHDrfsBkizKhi4xp0umbX8Fy=qg@mail.gmail.com
обсуждение исходный текст
Ответ на migrating/spliting Postgres data directory on OpenIndiana  (Boris Epstein <borepstein@gmail.com>)
Список pgsql-general
On 25 October 2012 19:46, Boris Epstein <borepstein@gmail.com> wrote:
> And if I want to split the storage - i.e., put databases into different
> directories - can I do that?

Take a look at the tablespace feature:

http://www.postgresql.org/docs/current/static/sql-createtablespace.html

You can move existing tables with ALTER TABLE (likewise for indexes),
and change the default for new tables created in future in a database
with ALTER DATABASE:

http://www.postgresql.org/docs/9.2/static/sql-altertable.html
http://www.postgresql.org/docs/9.2/static/sql-alterdatabase.html

Before the tablespace feature was added, people used to create
symlinks in the data directory if they wanted to use different storage
for different objects (say, a special fast disk array for certain
data).  The tablespace feature actually works the same way, but it's
managed for you via DDL commands.

Hope that helps,
Thomas


В списке pgsql-general по дате отправления:

Предыдущее
От: "Xiong He"
Дата:
Сообщение: Re: migrate from PostgreSQL to Oracle
Следующее
От: John R Pierce
Дата:
Сообщение: Re: migrating/spliting Postgres data directory on OpenIndiana