Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I am new to PostgreSQL and I can not found info about this. I am using pgAdmin III and my databse files are kept in instalation directory of PostgreSQL. So far so good. But now, I need to create huge DB, that is out of my HDD capacity. So I create RAID and want to move this single DB to this location. How can I specify path for single database to be somewhere else?

I dont want other on the same disk, since I have them on fast SSDs. The big one will be only for some data mining and I will remove it afterwards.

share|improve this question

1 Answer 1

up vote 2 down vote accepted

Have a look a tablespaces. You can keep the main and small parts of the database in the SSD drives and migrate the bigger tables to the tablespaces in your other drive.

http://www.postgresql.org/docs/9.4/static/manage-ag-tablespaces.html

In alternative the whole database can be put into the tablespace by setting the default tablespace parameter.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.