Hi there,
Is there any possible way of removing ALL data related to postgresql?
I've tried
su -
yum remove *postgres*
But i dont thing it removes everything...
I want to do it, because i want to re-install everything again (postgresql,postgres-server, etc..)
Thanks in advance,
Filipe
Removing postgresql
Re: Removing postgresql
[code]
yum remove postgres\*
mv /var/lib/pgsql /var/lib/old.pgsql
yum install postgres-whatever
[/code]
Please be aware that postgres-libs is a dependency for a large number of packages so running yum remove postgres\* may nuke considerably more than you expect so make sure you inspect the list of packages carefully before you blindly say 'y'!
yum remove postgres\*
mv /var/lib/pgsql /var/lib/old.pgsql
yum install postgres-whatever
[/code]
Please be aware that postgres-libs is a dependency for a large number of packages so running yum remove postgres\* may nuke considerably more than you expect so make sure you inspect the list of packages carefully before you blindly say 'y'!
Re: Removing postgresql
Thank you very much for your answer. I'm going to give it a try, first thing tomorrow.
I'll let you know if it worked for me.
I'm trying this, because I am trying to (re)install Postgresql. And when i try to command service postgresql-9.0 start it outputs FAILED.
Once again, thank you for your time,
Filipe
I'll let you know if it worked for me.
I'm trying this, because I am trying to (re)install Postgresql. And when i try to command service postgresql-9.0 start it outputs FAILED.
Once again, thank you for your time,
Filipe
-
- Retired Moderator
- Posts: 18276
- Joined: 2006/12/13 20:15:34
- Location: Tidewater, Virginia, North America
- Contact:
Removing postgresql
[quote]
fgoncalo wrote:
...
I'm trying this, because I am trying to (re)install Postgresql. And when i try to command service postgresql-9.0 start it outputs FAILED.
...[/quote]
You are not running CentOS postgresql-server as there is no such service. The CentOS packages are:
postgresql-server-8.1.23-1.el5_6.1
postgresql84-server-8.4.7-1.el5_6.1
Both provide /etc/rc.d/init.d/postgresql and not "postgresql-9.0". None of the well-known repos provides postgresql 9.0. The previous advice may not be applicable.
fgoncalo wrote:
...
I'm trying this, because I am trying to (re)install Postgresql. And when i try to command service postgresql-9.0 start it outputs FAILED.
...[/quote]
You are not running CentOS postgresql-server as there is no such service. The CentOS packages are:
postgresql-server-8.1.23-1.el5_6.1
postgresql84-server-8.4.7-1.el5_6.1
Both provide /etc/rc.d/init.d/postgresql and not "postgresql-9.0". None of the well-known repos provides postgresql 9.0. The previous advice may not be applicable.
Re: Removing postgresql
So shall i remove evrything about postgresql that i have on my pc, and re install those packages that you've mentioned? Via yum?
Thank you for your time,
Filipe
Thank you for your time,
Filipe
-
- Retired Moderator
- Posts: 18276
- Joined: 2006/12/13 20:15:34
- Location: Tidewater, Virginia, North America
- Contact:
Re: Removing postgresql
If you want to reinstall then remove all you have installed, but given the "foreign" version it may not have been installed by the package manager, which would make things more difficult.
You don't want to install both package I mentioned. They are alternative versions, and you will need others.[code]
# yum list postgresql\*
Loaded plugins: fastestmirror, priorities
Loading mirror speeds from cached hostfile
Excluding Packages from CentOS-5 - Extras
Finished
95 packages excluded due to repository priority protections
Installed Packages
postgresql.i386 8.1.23-1.el5_6.1 installed
postgresql-libs.i386 8.1.23-1.el5_6.1 installed
postgresql-python.i386 8.1.23-1.el5_6.1 installed
postgresql-server.i386 8.1.23-1.el5_6.1 installed
Available Packages
postgresql-contrib.i386 8.1.23-1.el5_6.1 updates
postgresql-devel.i386 8.1.23-1.el5_6.1 updates
postgresql-docs.i386 8.1.23-1.el5_6.1 updates
postgresql-jdbc.i386 8.1.407-1jpp.4 base
postgresql-odbc.i386 08.01.0200-3.1 base
postgresql-pl.i386 8.1.23-1.el5_6.1 updates
postgresql-tcl.i386 8.1.23-1.el5_6.1 updates
postgresql-test.i386 8.1.23-1.el5_6.1 updates
postgresql84.i386 8.4.7-1.el5_6.1 updates
postgresql84-contrib.i386 8.4.7-1.el5_6.1 updates
postgresql84-devel.i386 8.4.7-1.el5_6.1 updates
postgresql84-docs.i386 8.4.7-1.el5_6.1 updates
postgresql84-libs.i386 8.4.7-1.el5_6.1 updates
postgresql84-plperl.i386 8.4.7-1.el5_6.1 updates
postgresql84-plpython.i386 8.4.7-1.el5_6.1 updates
postgresql84-pltcl.i386 8.4.7-1.el5_6.1 updates
postgresql84-python.i386 8.4.7-1.el5_6.1 updates
postgresql84-server.i386 8.4.7-1.el5_6.1 updates
postgresql84-tcl.i386 8.4.7-1.el5_6.1 updates
postgresql84-test.i386 8.4.7-1.el5_6.1 updates
[/code]
You don't want to install both package I mentioned. They are alternative versions, and you will need others.[code]
# yum list postgresql\*
Loaded plugins: fastestmirror, priorities
Loading mirror speeds from cached hostfile
Excluding Packages from CentOS-5 - Extras
Finished
95 packages excluded due to repository priority protections
Installed Packages
postgresql.i386 8.1.23-1.el5_6.1 installed
postgresql-libs.i386 8.1.23-1.el5_6.1 installed
postgresql-python.i386 8.1.23-1.el5_6.1 installed
postgresql-server.i386 8.1.23-1.el5_6.1 installed
Available Packages
postgresql-contrib.i386 8.1.23-1.el5_6.1 updates
postgresql-devel.i386 8.1.23-1.el5_6.1 updates
postgresql-docs.i386 8.1.23-1.el5_6.1 updates
postgresql-jdbc.i386 8.1.407-1jpp.4 base
postgresql-odbc.i386 08.01.0200-3.1 base
postgresql-pl.i386 8.1.23-1.el5_6.1 updates
postgresql-tcl.i386 8.1.23-1.el5_6.1 updates
postgresql-test.i386 8.1.23-1.el5_6.1 updates
postgresql84.i386 8.4.7-1.el5_6.1 updates
postgresql84-contrib.i386 8.4.7-1.el5_6.1 updates
postgresql84-devel.i386 8.4.7-1.el5_6.1 updates
postgresql84-docs.i386 8.4.7-1.el5_6.1 updates
postgresql84-libs.i386 8.4.7-1.el5_6.1 updates
postgresql84-plperl.i386 8.4.7-1.el5_6.1 updates
postgresql84-plpython.i386 8.4.7-1.el5_6.1 updates
postgresql84-pltcl.i386 8.4.7-1.el5_6.1 updates
postgresql84-python.i386 8.4.7-1.el5_6.1 updates
postgresql84-server.i386 8.4.7-1.el5_6.1 updates
postgresql84-tcl.i386 8.4.7-1.el5_6.1 updates
postgresql84-test.i386 8.4.7-1.el5_6.1 updates
[/code]