Yes!!
I have done this very successfully. I have mounts:
/usr/local/pgsql/data 8Gig slice on Primary IDE-Slave
/usr/local/pgsql/data2 8Gig slice on Secondary IDE-Master
/usr/local/pgsql/data3 4Gig slice on Primary IDE-Master
Then I move files from data/base/<dbdir> to data2/base/<dbdir> and create a
symbolic link with the following.
$ pg_ctl stop
*NOTE* Make sure it really shut down, I have some long running tasks which
have bitten me during a moment of stupidity
$ cd /usr/local/pgsql/data/base/<dbdir>
$ mv <datafile> /usr/local/pgsql/data2/base/<dbdir>/<datafile>
$ ln -s /usr/local/pgsql/data2/base/<dbdir>/<datafile> .
$ pg_ctl start
I currently only have the pg_xlog directory on data3 because that drive is
also shared with the operating system. But just moving the pg_xlog
directory alone gave me a significant performance boost. By freeing up the
data drives from having to write those log files, I am less likely to have
to wait for the heads to move around after fsyncing a log file. You can
also move entire database directories using commands similar to those above.
- brian
----- Original Message -----
From: "Andy Samuel" <andysamuel@geocities.com>
To: <pgsql-admin@postgresql.org>
Sent: Thursday, May 31, 2001 11:55 PM
Subject: [ADMIN] Re: Database over multiple drives
> Has anybody *really* tried this solution ?
> Is it safe ?
>
> TIA
> Andy
>
> ----- Original Message -----
> From: "Ragnar Kjørstad" <postgres@ragnark.vestdata.no>
> To: "David Lizano" <david.lizano@izanet.com>
> Cc: <pgsql-admin@postgresql.org>
> Sent: Thursday, May 31, 2001 4:33 PM
> Subject: Re: Database over multiple drives
>
>
> > On Thu, May 31, 2001 at 10:37:26AM +0200, David Lizano wrote:
> > > You can't do it with Postgres. To do it, Postgres must implement
> > > "tablespaces" to spread the database in different localizations (who
can
> be
> > > different physical localizations, of course). Then a table can be
> assigned
> > > to a tablespace.
> >
> > Sure you can.
> > You can move some files to a different drive, and put a symlink in the
> > original directory.
> >
> > Or, if you have an operatingsystem that has an logical volume manager,
> > you can concatenate several disks, use striping or whatever, to get a
> > logical device that spans several physical devices.
> >
> >
> > --
> > Ragnar Kjørstad
> > Big Storage
> >
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>