dbTalk Databases Forums  

Re-installing PostreSQL

comp.databases.postgresql comp.databases.postgresql


Discuss Re-installing PostreSQL in the comp.databases.postgresql forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
news
 
Posts: n/a

Default Re-installing PostreSQL - 01-15-2009 , 04:19 AM






Hello everyone,

I'm running two postgresql servers on linux redhat.
(pgsql versions : 7.2 and 8.2).
I compiled postgresql from source and installed it in the /opt
directory.

The servers are in production state.

Now i would like to add PL/Perl support. (It's not urgent,
but I sart considering it). I don't want to upgrade
the postgresql version, i just want to add PL/perl support.

I intend to do this on both servers :

1. stop postgresql
2. backup the binary directory, (just in case)
backup the $PGDATA directory
3. uninstall postgresql ( #make uninstall )
4. configure postgresql with --with-perl support
5. run #make and #make install
6. start postgresql
7. check everything runs fine

Is it safe to do so, or am I missing something ?


.... Or is it safe to :
1. configure --with-perl
2. #make
2. stop postgresql
3. #make install
3. restart postgresql ?

I just want to make sure... I want to minimize the downtime
of my servers, and of course I can't afford to mess up something.


Thanks in advance for your comments.


Tanguy

Reply With Quote
  #2  
Old   
Laurenz Albe
 
Posts: n/a

Default Re: Re-installing PostreSQL - 01-15-2009 , 08:44 AM






news <tanguy (AT) nowhere (DOT) fr> wrote:
Quote:
I'm running two postgresql servers on linux redhat.
(pgsql versions : 7.2 and 8.2).
I compiled postgresql from source and installed it in the /opt
directory.

The servers are in production state.

Now i would like to add PL/Perl support. (It's not urgent,
but I sart considering it). I don't want to upgrade
the postgresql version, i just want to add PL/perl support.

I intend to do this on both servers :

1. stop postgresql
2. backup the binary directory, (just in case)
backup the $PGDATA directory
3. uninstall postgresql ( #make uninstall )
4. configure postgresql with --with-perl support
5. run #make and #make install
6. start postgresql
7. check everything runs fine

Is it safe to do so, or am I missing something ?


... Or is it safe to :
1. configure --with-perl
2. #make
2. stop postgresql
3. #make install
3. restart postgresql ?

I just want to make sure... I want to minimize the downtime
of my servers, and of course I can't afford to mess up something.
The second version is perfectly safe.

You could even install PL/Perl without restarting the server, I think.

As far as I know, all the switch does is build plperl.so.

You could just copy this file to the lib directory, and it should work.

Of course your pg_config would then reflect the wrong build flags,
and maybe the plperl entries would be missing from pg_pltemplate,
which would make CREATE LANGUAGE a little more tricky.

But unless you really cannot live without downtime, use your second option.

A backup of the old installation can never be a mistake!

Yours,
Laurenz Albe


Reply With Quote
  #3  
Old   
Tanguy
 
Posts: n/a

Default Re: Re-installing PostreSQL - 01-16-2009 , 04:17 AM



Laurenz Albe a écrit :

Quote:
... Or is it safe to :
1. configure --with-perl
2. #make
2. stop postgresql
3. #make install
3. restart postgresql ?

I just want to make sure... I want to minimize the downtime
of my servers, and of course I can't afford to mess up something.

The second version is perfectly safe.

You could even install PL/Perl without restarting the server, I think.

As far as I know, all the switch does is build plperl.so.

You could just copy this file to the lib directory, and it should work.

Of course your pg_config would then reflect the wrong build flags,
and maybe the plperl entries would be missing from pg_pltemplate,
which would make CREATE LANGUAGE a little more tricky.

But unless you really cannot live without downtime, use your second option.

Thanks very much for your reply.

I think i can afford to stop postgresql for a couple of minutes, in
order to reinstall it. I'd rather have a 'clean' setup, instead
of tweaking the server as it is now...



Quote:
A backup of the old installation can never be a mistake!


Of course
I think i'll also backup my data before doing this,
it can't do any harm...


Quote:
Yours,
Laurenz Albe




Best regards,
Tanguy


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



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.