NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: kern/37425: fss_snapshot_mount panic during fsck



The following reply was made to PR kern/37425; it has been noted by GNATS.

From: Scott Ellis <scotte%warped.com@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: hannken%NetBSD.org@localhost, gnats-admin%netbsd.org@localhost, 
netbsd-bugs%netbsd.org@localhost
Subject: Re: kern/37425: fss_snapshot_mount panic during fsck
Date: Mon, 24 Nov 2008 18:05:23 -0800

 This is a multi-part message in MIME format.
 --------------050807060401010309000309
 Content-Type: text/plain; charset=ISO-8859-1; format=flowed
 Content-Transfer-Encoding: 7bit
 
 On 11/24/2008 1:45 AM, Juergen Hannken-Illjes wrote:
 > The following reply was made to PR kern/37425; it has been noted by GNATS.
 >
 > From: Juergen Hannken-Illjes<hannken%eis.cs.tu-bs.de@localhost>
 > To: gnats-bugs%netbsd.org@localhost
 > Cc:
 > Subject: Re: kern/37425: fss_snapshot_mount panic during fsck
 > Date: Mon, 24 Nov 2008 10:43:48 +0100
 >
 >   On Sun, Nov 23, 2008 at 07:45:02PM +0000, Scott Ellis wrote:
 >   >  The following reply was made to PR kern/37425; it has been noted by 
 > GNATS.
 >
 >   Please send the following information:
 >
 >   - The exact panic string above ffs_copyonwrite+0x9c
 >   - The output of dmesg
 >   - The script you use to test
 >
 >   --
 >   Juergen Hannken-Illjes - hannken%eis.cs.tu-bs.de@localhost - TU 
 > Braunschweig (Germany)
 >
 
 Sure thing.
 
 The panic string is:
 
 uvm_fault(0xffffffff80bf58c0, 0xffff800005ef4000, 1) -> e
 fatal page fault in supervisor mode
 trap type 6 code 0 rip ffffffff80286987 cs 8 rflags 10206 cr2 
 ffff800005ef4e00 cpl 0 rsp ffff8000023cac040
 kernel: page trap fault, code=0
 Stopped in pid 361.1 (fssconfig) at netbsd:ffs_copyonwrite+0x9c: movq 0
 (%rdi,%rax,8),%rax
 
 Script used to test is attached (yes, it's a hack, but it was quick to 
 write!) as pffstest.pl.  It requires the directory structure of 
 /.snapshot/.store to be created, and vnd 11-14 to be available.
 
 Dmesg is attached as vmware.dmesg.  It's GENERIC running on VMware. 
 Don't imagine there's much machine-specific stuff there.
 
 
 
 
 --------------050807060401010309000309
 Content-Type: text/plain;
  name="pffstest.pl"
 Content-Transfer-Encoding: 7bit
 Content-Disposition: attachment;
  filename="pffstest.pl"
 
 #!/usr/bin/perl
 
 # Use vnd?? starting at $startvnode, to eliminate conflicts with other
 # vnd users on the system
 $startvnode=10;
 
 $snapshotdir="/.snapshot";
 $snapshotstore="/.snapshot/.store";
 $datetime=`date "+%C%y.%m.%d-%H.%M.%S"`;
 chomp($datetime);
 
 
 # Number of generations of backups that should be kept
 $generations=5;
 
 fill_vnd();
 fill_store();
 
 # If all the vnd are free, use them up!
 # Assume this only happens after a fresh reboot
 if (scalar(keys %vnd) <= 1)
 {
        freshstart();
        exit(10);
 }
 
 rotate();
 
 # Take new snapshot, and attach it to a vnode
 if ($vnd{""})
 {
        $newfile=$snapshotstore."/".$datetime;
 
        # Make a new store file
        exec(`fssconfig -c fss0 / $newfile`);
        exec(`fssconfig -u fss0`);
 
        # Attach it to the vnode
        exec(`vnconfig -r $vnd{""} $newfile`);
 
        # Make a directory and mount it
        $newdir=$snapshotdir."/".$datetime;
        mkdir($newdir);
        exec(`mount -o ro /dev/$vnd{""}a $newdir`);
 }
 else
 {
        print "Hey, no free vnodes!\n";
        exit(20);
 }
 
 ##################################################################
 sub sort_store { 
        # Sort the list of files in %store in decending order
        @inodesorted= reverse sort { $store{$a} cmp $store{$b} } keys %store;
 }
 
 sub fill_vnd {
        # Populate vnd list with vnode devices
        $i=$startvnode;
        while ($i < ($startvnode+$generations))
        {
                @vntemp=split(" ",`vnconfig -l vnd$i`);
 
                # Add hash entry with key of inode, value of associated vnode
                chop($vntemp[0]);
                $vnd{$vntemp[4]}=$vntemp[0];
                $i++;
        }
 }
 
 sub fill_store {
        # Create list of all store files
        @storelist=split('\n',`ls $snapshotstore`);
 
        # Populate store list with list of filenames
        $i=0;
        while ($storelist[$i])
        {
                $tempfile=$snapshotstore."/".$storelist[$i];
                $tempnode=`stat -f "%i" $tempfile`;
                chomp($tempnode);
 
                # Add hash entry with key of inode, value of associated filename
                $store{$tempnode}=$tempfile;
 
                $i++;
        }
 }
 
 sub freshstart {
        print "Empty vnd, populating\n";
 
        $i=0;
        while (($inode,$filename)=each(%store))
        {
                $tempvnode=$startvnode+$i;
                exec(`vnconfig -r vnd$tempvnode $store{$inode}`);
                $i++;
        }
 }
 
 sub rotate {
        # Sort the list of store files, so we can clear old ones out
        sort_store();
 
        # See if we need to remove any extra files
        $i=0;
        while ($currentinode = @inodesorted[$i])
        {
                if ($i >= ($generations-1))
                {
                        # We have too many files...remove them
                        print "Removing ";
                        if ($vnd{$currentinode})
                        {
                                # Forcibly unmount it first
                                $dirname=$snapshotdir."/".`basename 
$store{$currentinode}`;
                                chomp($dirname);
                                exec(`umount -f $dirname`);
                                rmdir($dirname);
 
                                # Next, remove the vnode association
                                exec(`vnconfig -u $vnd{$currentinode}`);
 
                                # Mark this vnode as clear
                                $vnd{""}=$vnd{$currentinode};
                        }
 
                        unlink($store{$currentinode});
                }
                else
                {
                        print "Keeping ";
                }
 
                print "File:".$store{@inodesorted[$i]}." 
".$vnd{@inodesorted[$i]}."\n";
 
                $i++;
        }
 }
 
 --------------050807060401010309000309
 Content-Type: text/plain;
  name="vmware.dmesg"
 Content-Transfer-Encoding: 7bit
 Content-Disposition: attachment;
  filename="vmware.dmesg"
 
 Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
     2006, 2007, 2008
     The NetBSD Foundation, Inc.  All rights reserved.
 Copyright (c) 1982, 1986, 1989, 1991, 1993
     The Regents of the University of California.  All rights reserved.
 
 NetBSD 5.99.02 (GENERIC) #0: Mon Nov 17 20:41:39 PST 2008
        
scotte@intrepid:/nbu/source/netbsd/src/obj.amd64/nbu/source/netbsd/src/sys/arch/amd64/compile/GENERIC
 total memory = 511 MB
 avail memory = 481 MB
 timecounter: Timecounters tick every 10.000 msec
 timecounter: Timecounter "i8254" frequency 1193182 Hz quality 100
 SMBIOS rev. 2.4 @ 0xe4010 (45 entries)
 VMware, Inc. VMware Virtual Platform (None)
 mainbus0 (root)
 cpu0 at mainbus0 apid 0: Intel 686-class, 3600MHz, id 0x6fb
 cpu1 at mainbus0 apid 1: Intel 686-class, 3600MHz, id 0x6fb
 ioapic0 at mainbus0 apid 2: pa 0xfec00000, version 11, 24 pins
 acpi0 at mainbus0: Intel ACPICA 20080321
 acpi0: X/RSDT: OemId <INTEL ,440BX   ,06040000>, AslId <VMW ,01324272>
 acpi0: SCI interrupting at int 9
 acpi0: fixed-feature power button present
 timecounter: Timecounter "ACPI-Safe" frequency 3579545 Hz quality 900
 ACPI-Safe 24-bit timer
 PIC (PNP0001) at acpi0 not configured
 attimer1 at acpi0 (TIME, PNP0100): AT Timer
 attimer1: io 0x40-0x43 irq 0
 pcppi1 at acpi0 (SPKR, PNP0800)
 pcppi1: io 0x61
 midi0 at pcppi1: PC speaker (CPU-intensive output)
 sysbeep0 at pcppi1
 pckbc1 at acpi0 (KBC, PNP0303): kbd port
 pckbc1: io 0x60,0x64 irq 1
 pckbc2 at acpi0 (MOUS, PNP0F13): aux port
 pckbc2: irq 12
 LPTB (PNP0400) at acpi0 not configured
 COMA (PNP0501) at acpi0 not configured
 COMB (PNP0501) at acpi0 not configured
 FDC (PNP0700) at acpi0 not configured
 acpiacad0 at acpi0 (ACAD, ACPI0003-1): ACPI AC Adapter
 attimer1: attached to pcppi1
 pckbd0 at pckbc1 (kbd slot)
 pckbc1: using irq 1 for kbd slot
 wskbd0 at pckbd0: console keyboard
 pms0 at pckbc1 (aux slot)
 pckbc1: using irq 12 for aux slot
 wsmouse0 at pms0 mux 0
 pci0 at mainbus0 bus 0: configuration mode 1
 pci0: i/o space, memory space enabled, rd/line, rd/mult, wr/inv ok
 pchb0 at pci0 dev 0 function 0
 pchb0: vendor 0x8086 product 0x7190 (rev. 0x01)
 ppb0 at pci0 dev 1 function 0: vendor 0x8086 product 0x7191 (rev. 0x01)
 pci1 at ppb0 bus 1
 pci1: i/o space, memory space enabled
 pcib0 at pci0 dev 7 function 0
 pcib0: vendor 0x8086 product 0x7110 (rev. 0x08)
 piixide0 at pci0 dev 7 function 1
 piixide0: Intel 82371AB IDE controller (PIIX4) (rev. 0x01)
 piixide0: bus-master DMA support present
 piixide0: primary channel configured to compatibility mode
 piixide0: primary channel interrupting at ioapic0 pin 14
 atabus0 at piixide0 channel 0
 piixide0: secondary channel configured to compatibility mode
 piixide0: secondary channel ignored (disabled)
 piixpm0 at pci0 dev 7 function 3
 piixpm0: vendor 0x8086 product 0x7113 (rev. 0x08)
 timecounter: Timecounter "piixpm0" frequency 3579545 Hz quality 1000
 piixpm0: 24-bit timer
 piixpm0: SMBus disabled
 vga0 at pci0 dev 15 function 0: vendor 0x15ad product 0x0405 (rev. 0x00)
 wsdisplay0 at vga0 kbdmux 1: console (80x25, vt100 emulation), using wskbd0
 wsmux1: connecting to wsdisplay0
 drm at vga0 not configured
 mpt0 at pci0 dev 16 function 0: vendor 0x1000 product 0x0030
 mpt0: applying 1030 quirk
 mpt0: interrupting at ioapic0 pin 17
 scsibus0 at mpt0: 16 targets, 8 luns per target
 ppb1 at pci0 dev 17 function 0: vendor 0x15ad product 0x0790 (rev. 0x02)
 pci2 at ppb1 bus 2
 pci2: i/o space, memory space enabled, rd/line, wr/inv ok
 wm0 at pci2 dev 0 function 0: Intel i82545EM 1000BASE-T Ethernet, rev. 1
 wm0: interrupting at ioapic0 pin 18
 wm0: 32-bit 66MHz PCI bus
 wm0: 256 word (8 address bits) MicroWire EEPROM
 wm0: Ethernet address 00:0c:29:2b:56:65
 makphy0 at wm0 phy 1: Marvell 88E1011 Gigabit PHY, rev. 3
 makphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 
1000baseT-FDX, auto
 isa0 at pcib0
 lpt0 at isa0 port 0x378-0x37b irq 7
 com0 at isa0 port 0x3f8-0x3ff irq 4: ns16550a, working fifo
 com1 at isa0 port 0x2f8-0x2ff irq 3: ns16550a, working fifo
 fdc0 at isa0 port 0x3f0-0x3f7 irq 6 drq 2
 timecounter: Timecounter "clockinterrupt" frequency 100 Hz quality 0
 ERROR: 305 cycle TSC drift observed
 acpiacad0: AC adapter online.
 scsibus0: waiting 2 seconds for devices to settle...
 fd0 at fdc0 drive 0: 1.44MB, 80 cyl, 2 head, 18 sec
 atapibus0 at atabus0: 2 targets
 cd0 at atapibus0 drive 1: <VMware Virtual IDE CDROM Drive, 
0100000000000000000, 0000000> cdrom removable
 cd0: 32-bit data port
 cd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2 (Ultra/33)
 wd0 at atabus0 drive 0: <VMware Virtual IDE Hard Drive>
 wd0: drive supports 64-sector PIO transfers, LBA addressing
 wd0: 2048 MB, 4161 cyl, 16 head, 63 sec, 512 bytes/sect x 4194304 sectors
 wd0: 32-bit data port
 wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2 (Ultra/33)
 wd0(piixide0:0:0): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA)
 cd0(piixide0:0:1): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA)
 Kernelized RAIDframe activated
 pad0: outputs: 44100Hz, 16-bit, stereo
 audio0 at pad0: half duplex
 boot device: wd0
 root on wd0a dumps on wd0b
 root file system type: ffs
 wsdisplay0: screen 1 added (80x25, vt100 emulation)
 wsdisplay0: screen 2 added (80x25, vt100 emulation)
 wsdisplay0: screen 3 added (80x25, vt100 emulation)
 wsdisplay0: screen 4 added (80x25, vt100 emulation)
 
 --------------050807060401010309000309--
 


Home | Main Index | Thread Index | Old Index