Re: BUG #1549: initdb doesn't work

Lists: pgsql-bugs
From: "Daniel van Eeden" <daniel_e(at)dds(dot)nl>
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #1549: initdb doesn't work
Date: 2005-03-16 21:58:10
Message-ID: 20050316215810.4C3EFF0E42@svr2.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-bugs


The following bug has been logged online:

Bug reference: 1549
Logged by: Daniel van Eeden
Email address: daniel_e(at)dds(dot)nl
PostgreSQL version: 8.0.1
Operating system: Debian GNU/Linux for SPARC (sarge)
Description: initdb doesn't work
Details:

creating template1 database in /opt/postgresql/data/base/1 ... FATAL:
semctl(10977333, 16, SETVAL, 536) failed: Invalid argument
child process exited with exit code 1
initdb: removing data directory "/opt/postgresql/data"

Postgresql is compiled from the official sources in 64-bit mode.


From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Daniel van Eeden <daniel_e(at)dds(dot)nl>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #1549: initdb doesn't work
Date: 2005-03-18 17:16:14
Message-ID: 200503181716.j2IHGEH12107@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-bugs

Daniel van Eeden wrote:
>
> The following bug has been logged online:
>
> Bug reference: 1549
> Logged by: Daniel van Eeden
> Email address: daniel_e(at)dds(dot)nl
> PostgreSQL version: 8.0.1
> Operating system: Debian GNU/Linux for SPARC (sarge)
> Description: initdb doesn't work
> Details:
>
> creating template1 database in /opt/postgresql/data/base/1 ... FATAL:
> semctl(10977333, 16, SETVAL, 536) failed: Invalid argument
> child process exited with exit code 1
> initdb: removing data directory "/opt/postgresql/data"

That is a problem with semaphores in your kernel. Have you modified
your postgresql.conf from the default? If so, you should read the
PostgreSQL documentation on how to modify your kernel for larger
settings.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: Daniel van Eeden <daniel_e(at)dds(dot)nl>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #1549: initdb doesn't work
Date: 2005-03-18 17:41:56
Message-ID: 8977.1111167716@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-bugs

Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> Daniel van Eeden wrote:
>> creating template1 database in /opt/postgresql/data/base/1 ... FATAL:
>> semctl(10977333, 16, SETVAL, 536) failed: Invalid argument

> That is a problem with semaphores in your kernel. Have you modified
> your postgresql.conf from the default? If so, you should read the
> PostgreSQL documentation on how to modify your kernel for larger
> settings.

But it's failing at semctl() not semget(). So it seems he hasn't run
out of semaphores. I wonder if SEMVMX is unusually small on his setup
(ie, less than 536). My Linux semctl man page says that that case would
return ERANGE not EINVAL, but ...

regards, tom lane