Bug #671: server corrupt

From: pgsql-bugs(at)postgresql(dot)org
To: pgsql-bugs(at)postgresql(dot)org
Subject: Bug #671: server corrupt
Date: 2002-05-22 12:41:17
Message-ID: 20020522124117.D192D475A95@postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Dmitry Riachtchentsev (diamondrain(at)mail(dot)ru) reports a bug with a severity of 1
The lower the number the more severe it is.

Short Description
server corrupt

Long Description
The follow short sequence of SQL requests leads to server corrupt:
1. Run psql and type:
begin;
CREATE SEQUENCE B;
commit;
\q

2. After exiting run psql again and type:
begin;
SELECT nextval('B');
DROP SEQUENCE B;
CREATE SEQUENCE B1;
commit;

> Here I get: "NOTICE: LockRelease: no such lock"
> Then type:

begin;
CREATE SEQUENCE B2;

> Here I get messages:
---------------------------------------------------------------
server closed the connection unexpectedly
This probably means the server terminated abnormally
before or while processing the request.
The connection to the server was lost. Attempting reset: NOTICE: Message from PostgreSQL backend:
The Postmaster has informed me that some other backend
died abnormally and possibly corrupted shared memory.
I have rolled back the current transaction and am
going to terminate your database system connection and exit.
Please reconnect to the database system and repeat your query.
Failed.
---------------------------------------------------------------

Then until restarting the server, connection to the server can not be established.
The database log is:
---------------------------------------------------------------
DEBUG: database system was shut down at 2002-05-21 11:40:09 EDT
DEBUG: checkpoint record is at 0/276B98
DEBUG: redo record is at 0/276B98; undo record is at 0/0; shutdown TRUE
DEBUG: next transaction id: 1421; next oid: 24991
DEBUG: database system is ready
DEBUG: pq_recvbuf: unexpected EOF on client connection

NOTICE: LockRelease: no such lock
DEBUG: server process (pid 10918) was terminated by signal 10
DEBUG: terminating any other active server processes

NOTICE: Message from PostgreSQL backend:
The Postmaster has informed me that some other backend
died abnormally and possibly corrupted shared memory.
I have rolled back the current transaction and am
going to terminate your database system connection and exit.
Please reconnect to the database system and repeat your query.
NOTICE: Message from PostgreSQL backend:
The Postmaster has informed me that some other backend
died abnormally and possibly corrupted shared memory.
I have rolled back the current transaction and am
going to terminate your database system connection and exit.
Please reconnect to the database system and repeat your query.
NOTICE: Message from PostgreSQL backend:
The Postmaster has informed me that some other backend
died abnormally and possibly corrupted shared memory.
I have rolled back the current transaction and am
going to terminate your database system connection and exit.
Please reconnect to the database system and repeat your query.
NOTICE: Message from PostgreSQL backend:
The Postmaster has informed me that some other backend
died abnormally and possibly corrupted shared memory.
I have rolled back the current transaction and am
going to terminate your database system connection and exit.
Please reconnect to the database system and repeat your query.
NOTICE: Message from PostgreSQL backend:
The Postmaster has informed me that some other backend
died abnormally and possibly corrupted shared memory.
I have rolled back the current transaction and am
going to terminate your database system connection and exit.
Please reconnect to the database system and repeat your query.
NOTICE: Message from PostgreSQL backend:
The Postmaster has informed me that some other backend
died abnormally and possibly corrupted shared memory.
I have rolled back the current transaction and am
going to terminate your database system connection and exit.
Please reconnect to the database system and repeat your query.
NOTICE: Message from PostgreSQL backend:
The Postmaster has informed me that some other backend
died abnormally and possibly corrupted shared memory.
I have rolled back the current transaction and am
going to terminate your database system connection and exit.
Please reconnect to the database system and repeat your query.
NOTICE: Message from PostgreSQL backend:
The Postmaster has informed me that some other backend
died abnormally and possibly corrupted shared memory.
I have rolled back the current transaction and am
going to terminate your database system connection and exit.
Please reconnect to the database system and repeat your query.
DEBUG: all server processes terminated; reinitializing shared memory and semaphores
DEBUG: database system was interrupted at 2002-05-21 11:40:46 EDT
DEBUG: checkpoint record is at 0/276B98
DEBUG: redo record is at 0/276B98; undo record is at 0/0; shutdown TRUE
DEBUG: next transaction id: 1421; next oid: 24991
DEBUG: database system was not properly shut down; automatic recovery in progress
DEBUG: redo starts at 0/276BD8
DEBUG: ReadRecord: record with zero length at 0/28F640
DEBUG: redo done at 0/28F618
DEBUG: database system is ready
---------------------------------------------------------------

PostgreSQL version is 7.2.1
Operation system is SunOS 5.8

Is my sequence of requests legal?
Is there a patch that fixs this problem?
If there is no patch, what is the root of the problem? Is there a kit of rules to avoid this situation?

I am ready to provide you any more required information to reproduce and trace this situation. Please e-mail me.

Thanks
Dmitry

Sample Code

No file was uploaded with this report

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message jose 2002-05-22 13:38:07 in(NULL)
Previous Message Tom Lane 2002-05-21 18:54:05 Re: Bug #668: cursors with params: mismatched parentheses;