Re: Problems starting up postgres

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Denis Perchine <dyp@perchine.com>
Cc: pgsql-hackers@postgresql.org
Date: 2001-09-05T16:23:59Z
Lists: pgsql-hackers
Denis Perchine <dyp@perchine.com> writes:
> Sep  5 08:42:30 mx postgres[5341]: [9] FATAL 2:  XLogFlush: request is not satisfied 

Hmm.  I think you must be running into some kind of logic bug (boundary
condition maybe?) in XLogFlush.  Could you add some debugging printouts,
along the line of

*** src/backend/access/transam/xlog.c~	Wed Sep  5 12:18:07 2001
--- src/backend/access/transam/xlog.c	Wed Sep  5 12:20:17 2001
***************
*** 1266,1272 ****
  			XLogWrite(WriteRqst);
  			S_UNLOCK(&(XLogCtl->logwrt_lck));
  			if (XLByteLT(LogwrtResult.Flush, record))
! 				elog(STOP, "XLogFlush: request is not satisfied");
  			break;
  		}
  		S_LOCK_SLEEP(&(XLogCtl->logwrt_lck), spins++, XLOG_LOCK_TIMEOUT);
--- 1266,1274 ----
  			XLogWrite(WriteRqst);
  			S_UNLOCK(&(XLogCtl->logwrt_lck));
  			if (XLByteLT(LogwrtResult.Flush, record))
! 				elog(STOP, "XLogFlush: request (%u, %u) is not satisfied --- flushed to (%u, %u)",
! 					 record.xlogid, record.xrecoff,
! 					 LogwrtResult.Flush.xlogid, LogwrtResult.Flush.xrecoff);
  			break;
  		}
  		S_LOCK_SLEEP(&(XLogCtl->logwrt_lck), spins++, XLOG_LOCK_TIMEOUT);


(this patch is for current sources, line numbers are probably different
in 7.1.*)

BTW, how did you get into this state --- did you have a system crash?

			regards, tom lane