From: Oli Sennhauser <oli.sennhauser@bluewin.ch>
To: pgsql-admin@postgresql.org
Subject: Shared Memory explanation/little bug?
Date: Fri, 19 Dec 2003 10:23:48 +0100
Message-ID: <3FE2C3A4.3060007@bluewin.ch> (raw)
Hello admins
To days ago I saw that one of my database clusters crashed. I was
looking into the log file and found the following:
2003-12-17 17:42:19 FATAL: pre-existing shared memory block (key
5432001, ID 797966336) is still in use
HINT: If you're sure there are no old server processes still running,
remove the shared memory block with the command "ipcrm", or just delete
the file "/u00/app/pgsql/admin/CLUSTER2/postmaster.pid".
Because I am courious I wanted to know a little more about shared
memories. And I was looking for the problem. I did not find the problem
causing block (see below, probably it was already removed) but two
things were remarkable:
1.) ipcs shows the keys in hex but the alert log in dec:
key 5432001 --> 0x0052E2C1
2.) The ID looked a little strange:
797966336 --> 0x2F900000 (0x2F90 = 12176)
Before I post an enhancment request/bug I would like to know you opinion:
1.) Would it be worth to have the output in hex (also).
2.) Is item 2 a bug or did I not understand something?
Thanks for feedback
Oli
------------------------------------------------------------
postgres@master:/u00/app/pgsql - rdbms740/template0> ipcs
------ Shared Memory Segments --------
key shmid owner perms bytes nattch status
0x0052e6a9 262144 postgres 600 10436608 1
0x0052fa31 294913 postgres 600 10436608 1
0x0052f649 327682 postgres 600 1466368 1
0x0052ee79 360451 postgres 600 1466368 3
0x0052f261 393220 postgres 600 1466368 3
------ Semaphore Arrays --------
key semid owner perms nsems
0x0052e6a9 0 postgres 600 17
0x0052e6aa 32769 postgres 600 17
0x0052e6ab 65538 postgres 600 17
0x0052e6ac 98307 postgres 600 17
0x0052e6ad 131076 postgres 600 17
0x0052e6ae 163845 postgres 600 17
0x0052e6af 196614 postgres 600 17
0x0052fa31 229383 postgres 600 17
0x0052fa32 262152 postgres 600 17
0x0052fa33 294921 postgres 600 17
0x0052fa34 327690 postgres 600 17
0x0052fa35 360459 postgres 600 17
0x0052fa36 393228 postgres 600 17
0x0052fa37 425997 postgres 600 17
0x0052f649 458766 postgres 600 17
0x0052f64a 491535 postgres 600 17
0x0052f64b 524304 postgres 600 17
0x0052ee79 557073 postgres 600 17
0x0052ee7a 589842 postgres 600 17
0x0052ee7b 622611 postgres 600 17
0x0052f261 655380 postgres 600 17
0x0052f262 688149 postgres 600 17
0x0052f263 720918 postgres 600 17
------ Message Queues --------
key msqid owner perms used-bytes messages
-------------------------------------------------------
Oli Sennhauser
Database-Engineer (Oracle & PostgreSQL)
Rebenweg 6
CH - 8610 Uster / Switzerland
Phone (+41) 1 940 24 82 or Mobile (+41) 79 450 49 14
e-Mail oli.sennhauser@bluewin.ch
Website http://mypage.bluewin.ch/shinguz/PostgreSQL/
Secure (signed/encrypted) e-Mail with a Free Personal SwissSign ID: http://www.swisssign.ch
Import the SwissSign Root Certificate: http://swisssign.net/cgi-bin/trust/importAttachments:
smime.p7s (application/x-pkcs7-signature, 3.4K) download
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: oli.sennhauser@bluewin.ch
Subject: Re: Shared Memory explanation/little bug?
In-Reply-To: <3FE2C3A4.3060007@bluewin.ch>
References: <3FE2C3A4.3060007@bluewin.ch>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox