If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > PostgreSQL > Createdb failed

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 11-03-04, 11:44
govindan govindan is offline
Registered User
 
Join Date: Jan 2004
Posts: 8
Createdb failed

Dear all,

when i run the createdb statement is is giving the following error:
$ createdb test
psql: FATAL: File /usr/local/pgsql/data/base/1/PG_VERSION is missing. This is not a valid data directory.
createdb: database creation failed.

i am able to start the te postgre server using the pg_ctl command and te postmaster is running .

i am using postgresql 7.3.4 and Red Hat Enterprise Linux ES release 3 (Taroon)

please help
Reply With Quote
  #2 (permalink)  
Old 11-04-04, 00:22
josh77 josh77 is offline
Registered User
 
Join Date: Nov 2004
Posts: 4
I don't think you should start PostgreSQL with the command pg_ctl anymore....
try starting PostgreSQL from the init script:

# /etc/init.d/postgresql start

That script will run initdb if necesary, and set the PGDATA environment variable if needed also.
Reply With Quote
  #3 (permalink)  
Old 11-04-04, 01:47
govindan govindan is offline
Registered User
 
Join Date: Jan 2004
Posts: 8
Ok, anyway postmaster is running and i am able to login to use the template1 database.

but createdb only is failing
Reply With Quote
  #4 (permalink)  
Old 11-19-04, 06:34
eperich eperich is offline
Registered User
 
Join Date: Sep 2001
Location: Vienna
Posts: 400
initdb

did you make an initdb to initialize a database

PG_VERSION is only a textfiel with the postgresql version in it which created the instance
__________________
http://www.postgresql.org
--Postgresql is the only kind of thing--
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On