Install problems for postgresql-8.4.1

From: Don Fox <donfox1(at)mac(dot)com>
To: "Mark H(dot) Nichols" <info(at)markhnichols(dot)com>, pgsql-novice(at)postgresql(dot)org, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Install problems for postgresql-8.4.1
Date: 2009-11-01 17:18:42
Views: Raw Message | Whole Thread | Download mbox
Lists: pgsql-novice

Here is record of my attempt to do the install! I've used several sets
of instructions for installing from src, mainly
which appears to be the clearest.

Obviously something has been omitted! Any suggestions are greatly

This installation will be used with python and an opens source
application 'GNUmed' used for electronic medical records.



./configure --with-perl --with-python --with-openssl --with-bonjour
PERL=/usr/bin/perl PYTHON=/usr/bin/python
sudo make install

Resulted with apparent success

PostgreSQL installation complete.

This is in .profile

if [ -d /usr/local/pgsql/bin ] ; then
export PATH

I'm using 103

sudo dseditgroup -o create -i 102 -r "PostgreSQL Users" postgres

Shouldn't the following result in a postgres file under /Users?
It doesn't!

sudo dscl . -create /Users/postgres
sudo dscl . -create /Users/postgres UniqueID 102
sudo dscl . -create /Users/postgres UserShell /bin/bash
sudo dscl . -create /Users/postgres RealName "Postgres Administrator"
sudo dscl . -create /Users/postgres NFSHomeDirectory /usr/local/pgsql
sudo dscl . -create /Users/postgres PrimaryGroupID 102
sudo dscl . -create /Users/postgres Password postgres
sudo chown -R postgres:postgres /usr/local/pgsql

Then did this and went tosystem prefs pane and reset Accounts for
Postgres Admin to 'postgres'.

cd /usr/local/
...:local donfox1$ su postgres
bash-3.2$ whoami

bash-3.2$ /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data
The files belonging to this database system will be owned by user
This user must also own the server process.

The database cluster will be initialized with locale en_US.UTF-8.
The default database encoding has accordingly been set to UTF8.
The default text search configuration will be set to "english".

creating directory /usr/local/pgsql/data ... ok
creating subdirectories ... ok
selecting default max_connections ... 100
selecting default shared_buffers ... 32MB
creating configuration files ... ok
creating template1 database in /usr/local/pgsql/data/base/1 ... ok
initializing pg_authid ... ok
initializing dependencies ... ok
creating system views ... ok
loading system objects' descriptions ... ok
creating conversions ... ok
creating dictionaries ... ok
setting privileges on built-in objects ... ok
creating information schema ... ok
vacuuming database template1 ... ok
copying template1 to template0 ... ok
copying template1 to postgres ... ok

WARNING: enabling "trust" authentication for local connections
You can change this by editing pg_hba.conf or using the -A option the
next time you run initdb.

Success. You can now start the database server using:

/usr/local/pgsql/bin/postgres -D /usr/local/pgsql/data
/usr/local/pgsql/bin/pg_ctl -D /usr/local/pgsql/data -l logfile


bash-3.2$ /usr/local/pgsql/bin/pg_ctl -D /usr/local/pgsql/data -l
logfile.log start
server starting
bash-3.2$ sh: logfile.log: Permission denied

But this works!

bash-3.2$ pg_ctl -D /usr/local/pgsql/data status
pg_ctl: server is running (PID: 60134)
/usr/local/pgsql/bin/postgres "-D" "/usr/local/pgsql/data"

bash-3.2$ pg_ctl -D /usr/local/pgsql/data start &
[1] 60129
bash-3.2$ server starting
LOG: database system was shut down at 2009-11-01 11:49:21 EST
LOG: autovacuum launcher started
LOG: database system is ready to accept connections

bash-3.2$ createdb testdb
Bus error

sh-3.2# ls -l
total 0
drwxr-xr-x 23 postgres postgres 782 Nov 1 00:15 bin
drwx------ 15 postgres postgres 510 Nov 1 00:31 data
drwxr-xr-x 24 postgres postgres 816 Nov 1 00:15 include
drwxr-xr-x 50 postgres postgres 1700 Nov 1 00:15 lib
drwxr-xr-x 21 postgres postgres 714 Nov 1 00:15 share


Browse pgsql-novice by date

  From Date Subject
Next Message Mark H. Nichols 2009-11-01 20:00:27 Re: Install problems for postgresql-8.4.1
Previous Message Tom Lane 2009-11-01 15:37:11 Re: Apple switched to BSDtar from GNUtar with Leopard