pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Scott Marlowe <smarlowe@g2switchworks.com>
To: Joel Fradkin <jfradkin@wazagua.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Installing 8 using a different drive for data
Date: Thu, 10 Feb 2005 15:59:50 -0600
Message-ID: <1108072790.11967.35.camel@state.g2switchworks.com> (raw)
In-Reply-To: <001201c50faf$ac0cf170$797ba8c0@jfradkin>
References: <001201c50faf$ac0cf170$797ba8c0@jfradkin>

On Thu, 2005-02-10 at 14:32, Joel Fradkin wrote:
> I tried changing the directory in postgres.conf, but it is looking for a
> PG_VERSION?
> Do I need to do a dbinti or something?
> I only want my data to be in the pgdata drive I want the rest in
> /var/lib/pgsql/data
> I actually want my wal in /wal (a different drive as well).
> I have the instructions
> 
> 0) backup your data
> 1) stop postmaster and verify.
> 2) cd $PGDATA; mv pg_xlog original_pg_xlog; ln -s /wal pg_xlog; cp 
> original_pg_xlog/* pg_xlog
> 3) start postmaster and confirm correct startup in log files.
> 
> Does this look like it will work for 8, do I do it from the /pgdata  folder
> once II get that working or from /var/lib/pgsql/data?

Hi Joel, not sure exactly what your methods are here.  There are a few
ways you can do this.  Are you looking at moving the whole database,
lock stock and barrel to another location, or just adding another
location for a single database instance in the cluster while leaving the
original database in place?  If so, then pre 8.0 you can use alternate
locations (see initlocation in the docs) to do it.  It's a bit awkward,
which is why table spaces were implemented in 8.0.

If you want to move the whole database, then you either need to use a
different -D switch on postmaster startup if you're starting it by hand,
or with a different $PGDATA env var if you use pg_ctl to start it.

Are you running from RPMs with /etc/rc.d/init.d/postgresql startup
script?  Let me know, I've got some nice tips for that situation too.



view thread (2+ messages)

Message-ID: <1108072790.11967.35.camel@state.g2switchworks.com>
Permalink:  ../1108072790.11967.35.camel@state.g2switchworks.com/
Also on:    postgresql.org/message-id/1108072790.11967.35.camel@state.g2switchworks.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: smarlowe@g2switchworks.com, jfradkin@wazagua.com
  Subject: Re: Installing 8 using a different drive for data
  In-Reply-To: <1108072790.11967.35.camel@state.g2switchworks.com>
  References: <001201c50faf$ac0cf170$797ba8c0@jfradkin> <1108072790.11967.35.camel@state.g2switchworks.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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