Thread

  1. btree_delete_page_redo: lost target page

    Chris Dunlop <chris@onthe.net.au> — 2007-01-25T07:37:59Z

    G'day all,
    
    PG version: 7.4.7    (debian 7.4.7-6sarge2)
    OS: Linux (debian sarge)
    
    I started a 'vacuum full analyze' using pgsql, then, after
    about 10 minutes, I issued a control-c in pgsql.  This hadn't
    returned my prompt after another 10 minutes or so.  A glance at
    the backend showed other processes running and some apparently
    hanging around, possibly blocked by the vacuum.
    
    Eventually I did a shutdown using the debian
    /etc/init.d/postgresql script.  This tried shutting the
    postmaster down cleanly, but eventually 'kill -9'ed the
    postmaster (much to my surpise, given the ever present "TIP 2:
    Don't 'kill -9' the postmaster" - just goes to show, you
    shouldn't trust *anyone*!).
    
    Anyhow, given the 'kill -9' I guess you could stop reading right
    here...
    
    Trying to start the postmaster again failed, with what looks
    like the relevent message being:
    
      PANIC:  btree_delete_page_redo: lost target page
    
    See the attached syslog.txt for the system logs.
    
    Googling 'postgres "lost target page"' only came back with
    extracts from nbtxlog.c rather than any previously reported
    problems like this.
    
    At this point I restored the database from our backups, however
    I still have a copy of the corrupted data directory if there's
    interest in trying to diagnose the problem.
    
    The entire data directory is around 5 Gb so let me know if you'd
    like to see something specific in there.
    
    Cheers,
    
    Chris.