initdb failure

Lists: pgsql-admin
From: "Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com>
To: <pgsql-admin(at)postgresql(dot)org>
Subject: initdb failure
Date: 2010-04-09 00:28:40
Message-ID: 2873D0DE40695D48B76CDF7C6620A1540A2D5334@xmb-sjc-226.amer.cisco.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Hi All

I have been trying to install PostgreSQL-8.4 on Windows 2000 server and
keep getting the following

creating template1 database in
C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/data/base/1 ...
initdb: could not execute command
""C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/bin/postgres.exe"
--boot -x1 -F ": No error

initdb: removing contents of data directory
"C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/data"

I have checked the archives but did not see any solution so far.

The data directory does have inheritable permissions for user postgres
to read, write, modify etc.

Thanks

Pankaj


From: Jaime Casanova <jcasanov(at)systemguards(dot)com(dot)ec>
To: "Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: initdb failure
Date: 2010-04-09 07:01:08
Message-ID: x2z3073cc9b1004090001oca58e1edl3c9db4c61b8b72e9@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

On Thu, Apr 8, 2010 at 7:28 PM, Pankaj Mandal (pmandal)
<pmandal(at)cisco(dot)com> wrote:
> Hi All
>
>
>
> I have been trying to install PostgreSQL-8.4 on Windows 2000 server and keep
> getting the following
>
>
> creating template1 database in
> C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/data/base/1 ... initdb:
> could not execute command
> ""C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/bin/postgres.exe"
> --boot -x1 -F ": No error
>
>                 initdb: removing contents of data directory
> "C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/data"
>
>
>
> I have checked the archives but did not see any solution so far.
>
> The data directory does have inheritable permissions for user postgres to
> read, write, modify etc.
>
>

are you executing the installer with a privileged user?

--
Atentamente,
Jaime Casanova
Soporte y capacitación de PostgreSQL
Asesoría y desarrollo de sistemas
Guayaquil - Ecuador
Cel. +59387171157


From: "Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com>
To: "Jaime Casanova" <jcasanov(at)systemguards(dot)com(dot)ec>
Cc: <pgsql-admin(at)postgresql(dot)org>
Subject: Re: initdb failure
Date: 2010-04-09 10:21:08
Message-ID: 2873D0DE40695D48B76CDF7C6620A1540A2D53C5@xmb-sjc-226.amer.cisco.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Hi Jaime

The installer is being executed as Administrator
I have check to ensure that, it will fail otherwise before even starting to install PostgreSQL.

Thanks
Pankaj

-----Original Message-----
From: Jaime Casanova [mailto:jcasanov(at)systemguards(dot)com(dot)ec]
Sent: Friday, April 09, 2010 12:01 AM
To: Pankaj Mandal (pmandal)
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: [ADMIN] initdb failure

On Thu, Apr 8, 2010 at 7:28 PM, Pankaj Mandal (pmandal)
<pmandal(at)cisco(dot)com> wrote:
> Hi All
>
>
>
> I have been trying to install PostgreSQL-8.4 on Windows 2000 server and keep
> getting the following
>
>
> creating template1 database in
> C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/data/base/1 ... initdb:
> could not execute command
> ""C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/bin/postgres.exe"
> --boot -x1 -F ": No error
>
>                 initdb: removing contents of data directory
> "C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/data"
>
>
>
> I have checked the archives but did not see any solution so far.
>
> The data directory does have inheritable permissions for user postgres to
> read, write, modify etc.
>
>

are you executing the installer with a privileged user?

--
Atentamente,
Jaime Casanova
Soporte y capacitación de PostgreSQL
Asesoría y desarrollo de sistemas
Guayaquil - Ecuador
Cel. +59387171157


From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: "Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com>, <pgsql-admin(at)postgresql(dot)org>
Subject: Re: initdb failure
Date: 2010-04-09 14:26:39
Message-ID: 4BBEF2CF020000250003064F@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

"Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com> wrote:

> initdb: could not execute command
> ""C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/bin/
> postgres.exe" --boot -x1 -F ": No error

I would check permissions related to the user and that postgres.exe
file.

-Kevin


From: "Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com>
To: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>, <pgsql-admin(at)postgresql(dot)org>
Subject: Re: initdb failure
Date: 2010-04-10 01:42:21
Message-ID: 2873D0DE40695D48B76CDF7C6620A1540A2D5799@xmb-sjc-226.amer.cisco.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Hi Kevin,

I have checked this several times. The installer is executed by user
Administrator (which apparently has all Administrator privileges)
The user postgres is also being created and the data directory is owned
by this user, which does have read, write, execute, modify, list folder
contents and they are all inheritable. Here I am copying few more lines
from the logs, upto when initdb failed.

"
Ensuring we can write to the data directory (using cacls):
processed dir:
C:\PROGRA~1\CISCOS~1\CSCONccm\objects\PostgreSQL\8.4\data

The files belonging to this database system will be owned by
user "Administrator".
This user must also own the server process.

The database cluster will be initialized with locale
English_United States.1252.
The default text search configuration will be set to "english".

fixing permissions on existing directory
C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/data ... ok
creating subdirectories ... ok
selecting default max_connections ... 10
selecting default shared_buffers ... 400kB
creating configuration files ... ok
creating template1 database in
C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/data/base/1 ...
initdb: could not execute command
""C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/bin/postgres.exe"
--boot -x1 -F ": No error
initdb: removing contents of data directory
"C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/data"

"

Thank you
Pankaj

-----Original Message-----
From: Kevin Grittner [mailto:Kevin(dot)Grittner(at)wicourts(dot)gov]
Sent: Friday, April 09, 2010 7:27 AM
To: Pankaj Mandal (pmandal); pgsql-admin(at)postgresql(dot)org
Subject: Re: [ADMIN] initdb failure

"Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com> wrote:

> initdb: could not execute command
> ""C:/PROGRA~1/CISCOS~1/CSCONccm/objects/PostgreSQL/8.4/bin/
> postgres.exe" --boot -x1 -F ": No error

I would check permissions related to the user and that postgres.exe
file.

-Kevin


From: Jan-Peter Seifert <Jan-Peter(dot)Seifert(at)gmx(dot)de>
To: pgsql-admin(at)postgresql(dot)org
Subject: Re: initdb failure
Date: 2010-04-11 22:17:33
Message-ID: 4BC24A7D.3020602@gmx.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Hello,

> The files belonging to this database system will be owned by
> user "Administrator".
> This user must also own the server process.

the user here should be postgres.
Are you 'locally'/'directly' installing on the server machine?

Good luck.

Peter


From: "Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com>
To: "Jan-Peter Seifert" <Jan-Peter(dot)Seifert(at)gmx(dot)de>, <pgsql-admin(at)postgresql(dot)org>
Subject: Re: initdb failure
Date: 2010-04-12 04:57:55
Message-ID: 2873D0DE40695D48B76CDF7C6620A1540A2D58DE@xmb-sjc-226.amer.cisco.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Hi Peter,

First I create the user postgres using the createuser.exe script.
After that I run the following scripts from postgres installer in the
order listed below. In between I do have checks to make sure the
previous commands returned
0 exit code and that database server did start successfully before
trying to load modules etc.

initcluster.vbs
startupcfg.vbs
createshortcuts.vbs
startserver.vbs
loadmodules.vbs

This pretty much seems to work on about half a dozen other machines
where I have tested it. Meaning the data directory gets initialized
properly,
Servers start properly and modules get loaded correctly and later I am
able to create database and execute SQL as well.

On this one machine (Windows 2000 server) I get this problem, which
results in unsuccessful install.
I also get another error message as posted in the forum
http://archives.postgresql.org/pgsql-admin/2010-04/msg00097.php
With all the installs but that does not seem to cause any problem to my
application so far.

Thanks
Pankaj

-----Original Message-----
From: pgsql-admin-owner(at)postgresql(dot)org
[mailto:pgsql-admin-owner(at)postgresql(dot)org] On Behalf Of Jan-Peter Seifert
Sent: Sunday, April 11, 2010 3:18 PM
To: pgsql-admin(at)postgresql(dot)org
Subject: Re: [ADMIN] initdb failure

Hello,

> The files belonging to this database system will be owned by
> user "Administrator".
> This user must also own the server process.

the user here should be postgres.
Are you 'locally'/'directly' installing on the server machine?

Good luck.

Peter


From: "Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com>
To: "Jan-Peter Seifert" <Jan-Peter(dot)Seifert(at)gmx(dot)de>, <pgsql-admin(at)postgresql(dot)org>
Subject: Re: initdb failure
Date: 2010-04-12 05:25:18
Message-ID: 2873D0DE40695D48B76CDF7C6620A1540A2D58E5@xmb-sjc-226.amer.cisco.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Hi Peter,

The scripts are executed by user Administrator on this specific machine
which has all the privileges that postgres user has (note postgres user
account is also created)
I also checked that the data directory and it contents are owned by user
postgres and user postgres's permissions are inheritable.

Thanks
Pankaj

-----Original Message-----
From: pgsql-admin-owner(at)postgresql(dot)org
[mailto:pgsql-admin-owner(at)postgresql(dot)org] On Behalf Of Jan-Peter Seifert
Sent: Sunday, April 11, 2010 3:18 PM
To: pgsql-admin(at)postgresql(dot)org
Subject: Re: [ADMIN] initdb failure

Hello,

> The files belonging to this database system will be owned by
> user "Administrator".
> This user must also own the server process.

the user here should be postgres.
Are you 'locally'/'directly' installing on the server machine?

Good luck.

Peter


From: Jan-Peter Seifert <Jan-Peter(dot)Seifert(at)gmx(dot)de>
To: "Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: initdb failure
Date: 2010-04-22 19:44:54
Message-ID: 4BD0A736.5030801@gmx.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Hello Pankaj,

well - obviously initdb wasn't run by (the operating system's user)
postgres. The owner of the server process (normally named postgres)
mustn't have any administrator privileges:

http://www.postgresql.org/docs/8.4/interactive/app-initdb.html

Good luck.

Maybe there wasn't any problem so far because the other PostgreSQL
servers have been installed on non-NTFS file systems?

Good luck,

Peter

Am 12.04.2010 07:25, schrieb Pankaj Mandal (pmandal):

> The scripts are executed by user Administrator on this specific machine
> which has all the privileges that postgres user has (note postgres user
> account is also created)
> I also checked that the data directory and it contents are owned by user
> postgres and user postgres's permissions are inheritable.
>
> Thanks
> Pankaj
>
> -----Original Message-----
> From: pgsql-admin-owner(at)postgresql(dot)org
> [mailto:pgsql-admin-owner(at)postgresql(dot)org] On Behalf Of Jan-Peter Seifert
> Sent: Sunday, April 11, 2010 3:18 PM
> To: pgsql-admin(at)postgresql(dot)org
> Subject: Re: [ADMIN] initdb failure
>
> Hello,
>
>> The files belonging to this database system will be owned by
>> user "Administrator".
>> This user must also own the server process.
>
> the user here should be postgres.
> Are you 'locally'/'directly' installing on the server machine?
>
> Good luck.
>
> Peter
>


From: "Pankaj Mandal (pmandal)" <pmandal(at)cisco(dot)com>
To: "Jan-Peter Seifert" <Jan-Peter(dot)Seifert(at)gmx(dot)de>
Cc: <pgsql-admin(at)postgresql(dot)org>
Subject: Re: initdb failure
Date: 2010-04-22 20:52:46
Message-ID: 2873D0DE40695D48B76CDF7C6620A1540A4D8AFA@xmb-sjc-226.amer.cisco.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-admin

Hi Peter,

The link you mention below does not say that Operating System user
postgres, should not have Administrator privileges,
It says user postgres may not have sufficient privileges and could fail
to create the Data directory, in that case, create Data directory by
root user and change ownership to postgres. This is not the case here,
the Data directory does get created and the owner is postgres. It fails
subsequently during initdb though.

Also I have successfully tested the installation on more than half dozen
machines and they are all NTFS file systems.

Thanks
Pankaj

-----Original Message-----
From: Jan-Peter Seifert [mailto:Jan-Peter(dot)Seifert(at)gmx(dot)de]
Sent: Thursday, April 22, 2010 12:45 PM
To: Pankaj Mandal (pmandal)
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: [ADMIN] initdb failure

Hello Pankaj,

well - obviously initdb wasn't run by (the operating system's user)
postgres. The owner of the server process (normally named postgres)
mustn't have any administrator privileges:

http://www.postgresql.org/docs/8.4/interactive/app-initdb.html

Good luck.

Maybe there wasn't any problem so far because the other PostgreSQL
servers have been installed on non-NTFS file systems?

Good luck,

Peter

Am 12.04.2010 07:25, schrieb Pankaj Mandal (pmandal):

> The scripts are executed by user Administrator on this specific
machine
> which has all the privileges that postgres user has (note postgres
user
> account is also created)
> I also checked that the data directory and it contents are owned by
user
> postgres and user postgres's permissions are inheritable.
>
> Thanks
> Pankaj
>
> -----Original Message-----
> From: pgsql-admin-owner(at)postgresql(dot)org
> [mailto:pgsql-admin-owner(at)postgresql(dot)org] On Behalf Of Jan-Peter
Seifert
> Sent: Sunday, April 11, 2010 3:18 PM
> To: pgsql-admin(at)postgresql(dot)org
> Subject: Re: [ADMIN] initdb failure
>
> Hello,
>
>> The files belonging to this database system will be owned by
>> user "Administrator".
>> This user must also own the server process.
>
> the user here should be postgres.
> Are you 'locally'/'directly' installing on the server machine?
>
> Good luck.
>
> Peter
>