Thread: Tables in one disk and indexes in another ??

Tables in one disk and indexes in another ??

From
Gastón Simone
Date:
I have unly one database and two disks. In order to use all my hardware
resources I want to store (for example) the tables in one of the disks and
the indexes in the other one. How can I do that?

Thanks a lot!!

Regards.

Gaston.


Re: Tables in one disk and indexes in another ??

From
Gaetano Mendola
Date:
Gastón Simone wrote:

> I have unly one database and two disks. In order to use all my hardware
> resources I want to store (for example) the tables in one of the disks and
> the indexes in the other one. How can I do that?

Using the tablespace feature in the future 8.0 version or right now
with help of symlink. However a suggest you to put in the other disk
just the WAL:  directory  data/pg_xlog



Regards
Gaetano Mendola









Re: Tables in one disk and indexes in another ??

From
"Scott Marlowe"
Date:
On Fri, 2004-08-06 at 11:51, Gastón Simone wrote:
> I have unly one database and two disks. In order to use all my hardware
> resources I want to store (for example) the tables in one of the disks and
> the indexes in the other one. How can I do that?

Right now, you have three possible choices:

1:  Move to RAID-1, or 1 on 0, or 0 on 1, which will automatically
spread everything over multiple disks for you, and give great
performance for things like report databases.  Still has good write
performance.  Caching RAID controllers can give a big wrote boost with
battery backed cache.  Pros:  Stable and reliable data storage.  Cons:
Costs the most.

2:  Identify which files are which in the data store.  Shut down the
postmaster.  Move the files by hand and soft link them back to the data
store.  Restart Server.  Repeat every time you drop / create the index
or reindex.

3:  Start testing 8.0 beta and wait for it to get "good enough" for your
production environment.  8.0 will support table spaces, which directly
addresses your problem.