Text Size: Normal / Large

Chapter 1. Installation Instructions

This chapter describes the installation of PostgreSQL from the source code distribution.

1.1. Short Version

./configure
gmake
su
gmake install
adduser postgres
mkdir /usr/local/pgsql/data
chown postgres /usr/local/pgsql/data
su - postgres
/usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data
/usr/local/pgsql/bin/postmaster -D /usr/local/pgsql/data >logfile 2>&1 &
/usr/local/pgsql/bin/createdb test
/usr/local/pgsql/bin/psql test

The long version is the rest of this chapter.


User Comments


John Green <jggreen>
01 Oct 2003 15:36:43

When compiling on Solaris make sure that you have set your LD_LIBRARY_PATH.  In the doc directory there is a FAQ_Solaris that specifies that your LD_LIBRARY_PATH may need to be set, so make sure that you set it to something like:
LD_LIBRARY_PATH=/usr/local/lib:/usr/local/ssl/lib
export LD_LIBRARY_PATH

I was able to successfully compile 7.3.2 on Solaris 9 using the following link as a guide:
http://techdocs.postgresql.org/v2/Guides/Installation%20Guides/Compiling%20PostgreSQL%207.3.2%20on%20Solaris%208%209/view

Peter <peter_csaba AT yahoo.com>
16 Jul 2004 22:07:47

Hi

i had the same problem with
*** Could not execute a simple test program. This may be a problem

After all I figured out. I had in /usr/local/lib an old readline.so.* file.
And I had a newer ones in /lib directory.

After I made shure that in ld.so.conf the /lib directory is sooner in appearance then the /usr/local/lib and run ldconfig everything was fine.

Hope this helps for others aswell. So \'locate /usr/lib/libreadline.so\' and see if this is the problem for yourselfs.

-Peter

Alex Zarutin <<alexzar AT gmail DOT com>>
24 Oct 2004 6:21:52

Try to create user with home directory, like this

useradd -d /export/home/postgres -s /bin/bash -m postgres
passwd postgres

Philipp <pillepop2003 AT yahoo.de>
10 Apr 2006 16:52:05

I had a lot of trouble installing postgres on a open suse 10.0 box.

(1) readline error
-> fixed by installing readline-devel rpm, found at rpmfind.net

(2) zlib error
-> fixed by installing zlib-devel rpm, found at rpmfind.net

(3) "Could not execute a simple test program"
-> fixed by adding the path under which the recently installed readline library can be found to the /etc/ld.conf.so file, in my case it was "/lib" and very important that it is mentioned before /usr/local/lib


I'm a very newbie to this linux stuff, but I kinda get to like it ;-)

Add Comment

Please use this form to add your own comments regarding your experience with particular features of PostgreSQL, clarifications of the documentation, or hints for other users. Please note, this is not a support forum, and your IP address will be logged. If you have a question or need help, please see the faq, try a mailing list, or join us on IRC. Note that submissions containing URLs or other keywords commonly found in 'spam' comments may be silently discarded. Please contact the webmaster if you think this is happening to you in error.

In order to submit a comment, you must have a community account.

* Comment
 

* denotes required field

Privacy Policy | Project hosted by hub.org | Designed by tinysofa
Copyright © 1996 – 2007 PostgreSQL Global Development Group