Unix Technical Forum

Installing 8 using a different drive for data

This is a discussion on Installing 8 using a different drive for data within the pgsql Admins forums, part of the PostgreSQL category; --> I tried changing the directory in postgres.conf, but it is looking for a PG_VERSION? Do I need to do ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Admins

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-10-2008, 01:22 AM
Joel Fradkin
 
Posts: n/a
Default Installing 8 using a different drive for data

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?

Joel Fradkin
*
Wazagua, Inc.
2520 Trailmate Dr
Sarasota, Florida 34243
Tel.* 941-753-7111 ext 305
*
jfradkin@wazagua.com
www.wazagua.com
Powered by Wazagua
Providing you with the latest Web-based technology & advanced tools.
© 2004. WAZAGUA, Inc. All rights reserved. WAZAGUA,*Inc
*This email message is for the use of the intended recipient(s) and may
contain confidential and privileged information.* Any unauthorized review,
use, disclosure or distribution is prohibited.* If you are not the intended
recipient, please contact the sender by reply email and delete and destroy
all copies of the original message, including attachments.
*

*



---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-10-2008, 01:23 AM
Scott Marlowe
 
Posts: n/a
Default Re: Installing 8 using a different drive for data

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.

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 09:14 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com