Обсуждение: initdb error on windows - urgent, please

Поиск
Список
Период
Сортировка

initdb error on windows - urgent, please

От
"Jarek Lubczyński"
Дата:
Hi, everybody,

Please help me with an urgent problem.

I have PostgreSQL version: 7.3.1Alfa1 for Windows (the only Win version available)

I am training installation of ProgreSQL on various PC's WinNT, 2K, XP and 2003
installed. In some cases I've got such a problem (till now on W2K and W2003)

When I try to initialize dbspace using initdb, for example:
    .....
    initdb -D /cygdrive/d/database/postgres --username=myuser -W -E LATIN2
    .....

   (of course specified path exists and is owned by "myuser")

I will get such information:

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

    The database cluster will be initialized with locale C.

    Fixing permissions on existing directory /cygdrive/d/database/postgres... ok
    creating directory /cygdrive/d/database/postgres/base... ok
    creating directory /cygdrive/d/database/postgres/global... ok
    creating directory /cygdrive/d/database/postgres/pg_xlog... ok
    creating directory /cygdrive/d/database/postgres/pg_clog... ok
    creating template1 database in /cygdrive/d/database/postgres/base/1...
    IpcSemaphoreCreate: semget(key=1, num=17, 03600) failed: Function not
implemented

    initdb failed.
    ----

User "myuser" belongs to the administator group of course.
Any set of initdb options causes the same result (even initdb with no parameters)


What is happening? How can I avoid such a problem? Why this seems to occur only
on:
  some Win2k installations (two of tested five or six),
  Win2003(first attempt passed through, second one on the other machine failed)

and never (so far) on
  WinNT (I've tried one) nor
  WinXP (four or five cases).

All Windows (except of WinNT) were Polish edition

I have thought it's a matter of service pack installed, but today I installed PostgreSQL
on one machine with W2003 SE PL and everything went OK, but on other machine
with the same W2003 initdb failed.

I need an urgent help.
Thanks in advance.

--
greetings
Jaroslaw Lubczynski

---
There are 10 kinds of people:
Those who understand binary and those who don't.



Re: initdb error on windows - urgent, please

От
Kerv
Дата:
Jarek Lubczyn'ski wrote:
> Hi, everybody,
>
> Please help me with an urgent problem.
>
> I have PostgreSQL version: 7.3.1Alfa1 for Windows (the only Win version available)
>
> I am training installation of ProgreSQL on various PC's WinNT, 2K, XP and 2003
> installed. In some cases I've got such a problem (till now on W2K and W2003)
>
> When I try to initialize dbspace using initdb, for example:
>     .....
>     initdb -D /cygdrive/d/database/postgres --username=myuser -W -E LATIN2
>     .....
>
>    (of course specified path exists and is owned by "myuser")
>
> I will get such information:
>
>     ----
>     The files belonging to this database system will be owned by user "myuser".
>     This user must also own the server process.
>
>     The database cluster will be initialized with locale C.
>
>     Fixing permissions on existing directory /cygdrive/d/database/postgres... ok
>     creating directory /cygdrive/d/database/postgres/base... ok
>     creating directory /cygdrive/d/database/postgres/global... ok
>     creating directory /cygdrive/d/database/postgres/pg_xlog... ok
>     creating directory /cygdrive/d/database/postgres/pg_clog... ok
>     creating template1 database in /cygdrive/d/database/postgres/base/1...
>     IpcSemaphoreCreate: semget(key=1, num=17, 03600) failed: Function not
> implemented
>
>     initdb failed.
>     ----
>
> User "myuser" belongs to the administator group of course.
> Any set of initdb options causes the same result (even initdb with no parameters)
>
>
> What is happening? How can I avoid such a problem? Why this seems to occur only
> on:
>   some Win2k installations (two of tested five or six),
>   Win2003(first attempt passed through, second one on the other machine failed)
>
> and never (so far) on
>   WinNT (I've tried one) nor
>   WinXP (four or five cases).
>
> All Windows (except of WinNT) were Polish edition
>
> I have thought it's a matter of service pack installed, but today I installed PostgreSQL
> on one machine with W2003 SE PL and everything went OK, but on other machine
> with the same W2003 initdb failed.
>
> I need an urgent help.
> Thanks in advance.
>

Hi,
You need the IPC support for cygwin. Find it and download the cygipc
package for cygwin. For set up and running PostgreSQL for cygwin please
  read postgresql-...README from ...cygwin\usr\doc\Cygwin
Regards,
    Kerv


Re: initdb error on windows - urgent, please

От
"Jarek Lubczyński"
Дата:

On 1 Oct 2003 at 22:19, Mailing List wrote:

>
> >[...]
> > now on W2K and W2003
> > When I try to initialize dbspace using initdb, for example:
> [...]
> > I will get such information:
> [...]
> >     IpcSemaphoreCreate: semget(key=1, num=17, 03600) failed:
> >     Function not
> > implemented
> >
> >     initdb failed.
>
>
> I think your problem is related to cygwin.
> [...]
> Bye, Chris.
>
>

Thanks, Chris. I haven't noticed, that a service named ipc-daemon (displayed as
"Cygwin IPC Daemon") had not been installed at all during PostgreSQL installation
process! So, after creating this service "by hand" using Windows' "sc" utility everything
seems to work.

But the strange thing occurred: yesterday I have installed PostgreSQL on twin-made
computers: the same hardware, the same OS - Win 2003 SE PL installed. The only
difference between them were the Windows serial numbers as my coleaques from our
service dept told me :-). And in the first case installation ended succesfully, but in the
second one problems with initdb ocuured (as described before). Cute, isn't it? :-/.

Thanks again for your help!

PS. Previously I have sent my answer to your priv by mistake, sorry

--
Pozdrawiam
Jarek LubczyÄski

There are 10 kinds of people:
Those who understand binary and those who don't

Re: initdb error on windows - urgent, please

От
"Jarek Lubczyński"
Дата:

On 2 Oct 2003 at 10:45, Kerv wrote:

> Jarek Lubczyn'ski wrote:

> > Hi, everybody,
> >
> > Please help me with an urgent problem.
> >
> > [...]
> >
> > When I try to initialize dbspace using initdb, for example:
> >     .....
> >     initdb -D /cygdrive/d/database/postgres --username=myuser -W -E
> >     LATIN2 .....
> >
> > I will get such information:
> >
> >[...]
> >     initdb failed.
> >     ----
> >
>
> Hi,
> You need the IPC support for cygwin. Find it and download the cygipc
> package for cygwin. For set up and running PostgreSQL for cygwin
> please
>   read postgresql-...README from ...cygwin\usr\doc\Cygwin
> Regards,
>  Kerv
>
>

I have just read, thanks.



But I have noticed that some things fails during PostgreSQL installation on some
Win2k, such as:

- under bash files in /usr/bin are owned by 'unknown' - I have to chown them to proper
user by hand

- ipc-daemon service isn't created - I must do it by my own using sc utility

- file /usr/bin/postmaster is missing - I must create it

- "PostgreSQL Server" service isn't created as well - I must use script
/usr/bin/serviceinstall.bat to create it

After performing those commands Postgres really wants to work (tested on only one
machine). But the strangest thing is that those problems seems to appear only on Win
2000 & 2003 and, moreover, not always. For example yesterday my coleaques gave
me two _identically_ configured machines - the same hardware and with the same
software installed on them. On one machine everything seems to work perfectly, but
on the second one problems occurred. Why???


--
Greetings
Jarek LubczyÄski

There are 10 kinds of people:
Those who understand binary and those who don't