Thread

  1. Re: [NOVICE] createdb problem

    Larry Rosenman <ler@lerami.lerctr.org> — 1999-11-14T19:32:40Z

    THis is how it starts on my 2.1.3 system.  
    
    SOMETHING HAS CHANGED between UnixWare 7.1.0 and 2.1.3 and 6.5.3 
    
    Since I'm not the only one seeing this, I suspect it is the
    code and the interaction of the OS. 
    
    Larry
    Robert J. Sprawls wrote:
    > 
    > 
    > On Sun, 14 Nov 1999, Larry Rosenman wrote:
    > 
    > > Here ya go:
    > > 
    > > $ su - postmaster
    > > UX:su: ERROR: Unknown user id: postmaster
    > > $ su - postgres
    > > Password:
    > > 
    > > $ postmaster -i &
    > > [1]     18803
    > > $ psql
    > > No pg_hba.conf entry for host localhost, user postgres, database postgres
    > > Connection to database 'postgres' failed.
    > > No pg_hba.conf entry for host localhost, user postgres, database postgres
    > 
    > Ya need a few more options in there. Here is how I have mine startup on
    > Slackware Linux:
    > 
    > # Start up the PostgreSQL postmaster
    > echo "Starting postmaster..."
    > su postgres -c "/usr/local/pgsql/bin/postmaster -i -S -D /usr/local/pgsql/data"
    > 
    > Also, did you define the environment variable PGDATA and the others?
    > 
    > Robert
    > 
    > 
    > 
    > ************
    > 
    
    
    -- 
    Larry Rosenman                      http://www.lerctr.org/~ler
    Phone: +1 972-414-9812 (voice) Internet: ler@lerctr.org
    US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749
    
    
  2. Re: [NOVICE] createdb problem

    Larry Rosenman <ler@lerami.lerctr.org> — 1999-11-14T19:37:08Z

    Just to prove stuff here is the latest:
    
     $ su - postgres
    Password:
    
    $ env
    _=/bin/env
    TZ=:US/Central
    PATH=/usr/bin:/usr/ccs/bin:/usr/ccs/bin:/usr/local/pgsql/bin
    XKEYBOARD=C/US
    LANG=C
    LOGNAME=postgres
    LD_LIBRARY_PATH=:/usr/local/pgsql/lib
    HZ=
    PGLIB=/usr/local/pgsql/lib
    MANPATH=:/usr/local/pgsql/man
    XNLSPATH=/usr/X/lib/Xsi/C/US
    XMODIFIERS=@im=Local
    NUMLOCK=no
    KEYBOARD=C/US
    PWD=/usr/local/pgsql
    MAPCHAN=/usr/lib/mapchan/88591.dk
    SHIFTDOWN=yes
    HOME=/usr/local/pgsql
    PGDATA=/usr/local/pgsql/data
    TERMCAP=/etc/termcap
    _TTYNAME=/dev/pts011
    TERM=dtterm
    _AST_FEATURES=UNIVERSE - att
    $ postmaster -i &
    [1]     2863
    $ psql template1
    No pg_hba.conf entry for host localhost, user postgres, database template1
    Connection to database 'template1' failed.
    No pg_hba.conf entry for host localhost, user postgres, database template1
    $ tail -3 $PGDATA/pg_hba.conf
    
    local        all                                         trust
    host         all         127.0.0.1     255.255.255.255   trust
    $ 
    
    
    And here is the *WORKING* startup on the 2.1.2 box:
    
    #!/bin/sh
    
    case "$1" in
    'start')
    
    	PGDATA=/usr/local/pgsql/data;export PGDATA
    	PGLIB=/usr/local/pgsql/lib;export PGLIB
    	LD_LIBRARY_PATH=/usr/local/pgsql/lib;export LD_LIBRARY_PATH
            su postgres -c "cd /usr/local/pgsql/;nohup /usr/local/pgsql/bin/postmaster -i >>pgsql.log 2>&1 & "
            exit 0
            ;;
    
    'stop')
    	;;
    *)
            echo "Usage: $0 { start | stop }"
            ;;
    esac
                    
    Robert J. Sprawls wrote:
    > 
    > 
    > On Sun, 14 Nov 1999, Larry Rosenman wrote:
    > 
    > > Here ya go:
    > > 
    > > $ su - postmaster
    > > UX:su: ERROR: Unknown user id: postmaster
    > > $ su - postgres
    > > Password:
    > > 
    > > $ postmaster -i &
    > > [1]     18803
    > > $ psql
    > > No pg_hba.conf entry for host localhost, user postgres, database postgres
    > > Connection to database 'postgres' failed.
    > > No pg_hba.conf entry for host localhost, user postgres, database postgres
    > 
    > Ya need a few more options in there. Here is how I have mine startup on
    > Slackware Linux:
    > 
    > # Start up the PostgreSQL postmaster
    > echo "Starting postmaster..."
    > su postgres -c "/usr/local/pgsql/bin/postmaster -i -S -D /usr/local/pgsql/data"
    > 
    > Also, did you define the environment variable PGDATA and the others?
    > 
    > Robert
    > 
    > 
    > 
    > ************
    > 
    
    
    -- 
    Larry Rosenman                      http://www.lerctr.org/~ler
    Phone: +1 972-414-9812 (voice) Internet: ler@lerctr.org
    US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749