Talk:Main Page > Special:Specialpages > EdgyPostgresql81
EdgyPostgresql81
From SwitchBL8's wiki
- Modify /etc/apt/sources.list
Add the following line:
deb http://www.freshnet.org/debian/ edgy/
- Rebuild the database
apt-get update
- Verify the new database
apt-cache search "postgresql.*8.1"
This command should output several Postgresql (related) packages with version number 8.1. If this is not the case, check that you correctly modified /etc/apt/sources.list. You can copy & paste the line above.
- Get and install Postgresql 8.1
apt-get install postgresql-8.1 -y
That should do the trick. If things went well, the last lines of output on your screen will be something like:
Configuring postgresql.conf to use port 5432... * Starting PostgreSQL 8.1 database server [ ok ]
- Still extra packages needed?
If for some reason the last install command resulted in an error instead of [ok], then try to install the following:
apt-get install ledit libreadline5 readline-common -y
After that, retry to install Postgresql.
- Optional
To use PostgreSQL from PHP, you need the php-pgsql package.
apt-cache search "php.*pgsql"
That will probably display php5-pgsql as one of the choices. Install that with the following command:
apt-get install php5-pgsql -y
- Done!
Now you can start using Postgresql.