> Well, bad news. After a few more tries to crash the backend, the whole
> postmaster crashed and didn't rise back.
> It fails to start up reporting "Apr  4 18:53:05 wale 
> postgres[71618]: [9]
> FATAL 2:  XLogWrite: write request is past end of log" to syslog.

Ok, this one is easy to fix. From Konstantin startup log:

...
> REDO @ 0/220716996; LSN 0/220717056: ...
                            ^^^^^^^^^
End of 8K page!

...
> INSERT @ 0/220717064: prev 0/220716996; ... checkpoint ...
> XLogFlush: rqst 0/220717128; wrt 0/220717056; flsh 0/220717056

Checkpoint is the first record on new page. To satisfy

    if (!XLByteLT(LogwrtResult.Write, XLogCtl->xlblocks[Write->curridx]))
        elog(STOP, "XLogWrite: write request is past end of log");

in XLogWrite() we have to initialize XLogCtl->xlblocks[0] to the next page
(where checkpoint will go) in StartupXLOG().

Still not related to original problem. But this is second bug discovered
since issue was rised -:)

Vadim

Wed, 4 Apr 2001 18:31:21 -0700 
"Mikheev, Vadim" <vmikheev@SECTORBASE.COM>
RE: [BUGS] Loosing files after backend crash 
> > FATAL 2:  XLogWrite: write request is past end of log" to syslog.

Ok, I hope this one is fixed. Tom, please review changes.
Konstantin, are you able to compile PG from CVS?
To restart postmaster with current version...

Vadim



Thu, 5 Apr 2001 02:41:27 -0700
"Vadim Mikheev" <vmikheev@sectorbase.com>
Re: RE: [BUGS] Loosing files after backend crash 