Skip site navigation (1) Skip section navigation (2)

Re: [HACKERS] createdb problem

From: jwieck(at)debis(dot)com (Jan Wieck)
To: gyurika(at)prolan(dot)hu (Lendvary Gyorgy)
Cc: pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: [HACKERS] createdb problem
Date: 1998-11-24 09:54:15
Message-ID: m0ziFAm-000EBYC@orion.SAPserv.Hamburg.dsh.de (view raw or flat)
Thread:
Lists: pgsql-hackers
> 
> I use postgres v6.4. My standard database is in /usr/local/pgsql/data
> directory and the PGDATA environment variable points to this database
> directory. But I'd like to create another database into another
> directory. So I tried this:
> killall postmaster
> initdb --pgdata=/home/postgres/database    --that's OK
> postmaster -i -D /home/postgres/database -S -o -F
> createdb -D /home/postgres/database  gazmuvek   --that's not good
>     the answer is:
> ERROR: Unable to locate path '/home/postgres/database/gazmuvek'
>                  This may be due to a missing environment variable in
> the server
> 
> After this I tried to type another command:
> createdb gazmuvek
> It was successfull, but the database 'gazmuvek' was created into
> $PGDATA. But it wasn't my desire. I need the database 'gazmuvek' in the
> directory: /home/postgres/database!
> 
> 
> What is the solution?

    man initlocation


Jan


-- 

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#======================================== jwieck(at)debis(dot)com (Jan Wieck) #


In response to

pgsql-hackers by date

Next:From: Lendvary GyorgyDate: 1998-11-24 10:13:58
Subject: createdb problem
Previous:From: Jan WieckDate: 1998-11-24 09:31:38
Subject: Re: [SQL] cursor and update + view

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group