Thread: initdb doesn not create template1 database

initdb doesn not create template1 database

From
"mike"
Date:
Tom thanks for the heads up on the bug earlier, thngs worked much better uing the currnet snapshot, though fomr some reason initdb seems to do its job though its not creating database template1.
 
any ideas as to a course of action?
 
Mike   

Re: initdb doesn not create template1 database

From
Tom Lane
Date:
"mike" <matrix@quadrent.net> writes:
> Tom thanks for the heads up on the bug earlier, thngs worked much better ui=
> ng the currnet snapshot, though fomr some reason initdb seems to do its job=
>  though its not creating database template1.

That's an interesting definition of "doing its job" :-(.

How about you show us the exact output you're getting, not an
interpretation?

            regards, tom lane

Re: initdb doesn not create template1 database

From
"mike"
Date:
> That's an interesting definition of "doing its job" :-(.
>
> How about you show us the exact output you're getting, not an
> interpretation?
>
> regards, tom lane


My apollagies
this is everything that initdb returns.

creating directory /usr/local/pgsql/data
creating directory /usr/local/pgsql/data/base
creating directory /usr/local/pgsql/data/global
creating directory /usr/local/pgsql/data/pg_xlog
creating template1 database /usr/local/pgsql/data/base/1
DEBUG: starting up
DEBUG: database system was shutdown at 2001-01-18 22:05:16
DEBUG: Checkpoint record at (0, 8)
DEBUG: Redo record (0, 8); Undo record at (0, 8); Shutdown TRUE
DEBUG: NextTransactionId: 514; NextOID: 16394
DEBUG: database is in production state
ERROR: Error: unknowen type 'ame'.

Creating global relations in /usr/local/pgsql/data/global
DEBUG: starting up
DEBUG: database system was intrupted at 2001-01-18 22:05:16
DEBUG: Checkpoint record at (0, 8)
DEBUG: Redo record (0, 8); Undo record at (0, 8); Shutdown TRUE
DEBUG: NextTransactionId: 514; NextOID: 16394
DEBUG: database system was not properly shut down; automatic recovery in
progress...
FATAL 2: cannot open pg_log: no such file or directory

initdb failed.
Removing /usr/local/pgsql/data.
Removing temp file /tmp/initdb.1011.




Re: initdb doesn not create template1 database

From
Tom Lane
Date:
"mike" <matrix@quadrent.net> writes:
> creating template1 database /usr/local/pgsql/data/base/1
> DEBUG: starting up
> DEBUG: database system was shutdown at 2001-01-18 22:05:16
> DEBUG: Checkpoint record at (0, 8)
> DEBUG: Redo record (0, 8); Undo record at (0, 8); Shutdown TRUE
> DEBUG: NextTransactionId: 514; NextOID: 16394
> DEBUG: database is in production state
> ERROR: Error: unknowen type 'ame'.

Looks like you've still got the genbki problem.  Did you apply the
backslash-removal fix?

            regards, tom lane

Re: initdb doesn not create template1 database

From
Tony Grant
Date:
On 2001.01.19 03:14:32 +0100 Tom Lane wrote:

> That's an interesting definition of "doing its job" :-(.
>
> How about you show us the exact output you're getting, not an
> interpretation?

7.0.3 on RedHat 6.2 with kernel 2.4.0

postgres]$ initdb -D /home/postgres
This database system will be initialized with username "postgres".
This user will own all the data files and must also own the server process.

Fixing permissions on pre-existing data directory /home/postgres
Creating database system directory /home/postgres/base
Creating database XLOG directory /home/postgres/pg_xlog
Creating template database in /home/postgres/base/template1
Creating global relations in /home/postgres/base
Adding template1 database to pg_database
/usr/bin/initdb: /tmp/initdb.29795: Permission denied
/usr/bin/initdb: /tmp/initdb.29795: Permission denied
/usr/bin/initdb: /tmp/initdb.29795: Permission denied
/usr/bin/initdb: /tmp/initdb.29795: No such file or directory

initdb failed.
Removing /home/postgres.
rm: cannot remove directory `/home/postgres': Permission denied
Failed.
Removing temp file /tmp/initdb.29795.

Cheers

Tony Grant

--
It's just some computers connected together...

Re: initdb doesn not create template1 database

From
Tom Lane
Date:
Tony Grant <tg001@dial.oleane.com> writes:
> /usr/bin/initdb: /tmp/initdb.29795: Permission denied

Pretty odd.  Uh, you're sure /tmp is world-writable?

            regards, tom lane

Re: initdb doesn not create template1 database

From
Tony Grant
Date:
On 2001.01.19 16:10:33 +0100 Tom Lane wrote:
> Tony Grant <tg001@dial.oleane.com> writes:
> > /usr/bin/initdb: /tmp/initdb.29795: Permission denied
>
> Pretty odd.  Uh, you're sure /tmp is world-writable?

Ummmm...

I had a mail server problem that nuked my /tmp directory last week. The new
temp directory on the spare partition didn't have the correct permissions.

I'm quite happy that I knew that it was a permissions problem! But that was
about the only folder I hadn't checked (I had my head stuck in /var/lib...)

Thank you very much kind sir - have a virtual beer on me.

Cheers

Tony Grant

--
It's just some computers connected together...

Re: Re: initdb doesn not create template1 database

From
Jan Wieck
Date:
Tom Lane wrote:
> Tony Grant <tg001@dial.oleane.com> writes:
> > /usr/bin/initdb: /tmp/initdb.29795: Permission denied
>
> Pretty odd.  Uh, you're sure /tmp is world-writable?

    What about umask?


Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#================================================== JanWieck@Yahoo.com #



_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com