Subject: gcore/PT_DUMPCORE causes kernel page fault in uvm_fault()
To: None <current-users@NetBSD.org>
From: Kirk Russell <kirk@ba23.org>
List: current-users
Date: 03/09/2006 22:59:12
Hello,
This is with NetBSD 3.0 (GENERIC) on i386. Did you want me to try with
current and/or create a problem report?
: {3} uname -a
NetBSD 3.0 NetBSD 3.0 (GENERIC) #0: Mon Dec 19 01:04:02 UTC 2005 builds@works.netbsd.org:/home/builds/ab/netbsd-3-0-RELEASE/i386/200512182024Z-obj/home/builds/ab/netbsd-3-0-RELEASE/src/sys/arch/i386/compile/GENERIC i386
: {4} cat corecrash.sh
#!/bin/ksh
while true
do
rm *.core
for x in 1 2 3 4 5 6 7 8 9
do
sleep 10000 &
done
for x in $(ps | awk '/sleep/ { print $1}')
do
gcore -c $x.core $x $$ $x $$ $x $$ $x &
done
ps | awk '/sleep/ {print $1}' | xargs kill
done
: {5} chmod a+x corecrash.sh
: {6} ./corecrash.sh
gcore: ptrace(PT_DUMPCORE) failed: No such process
kill: 463: No such process
gcore: ptrace(PT_DUMPCORE) failed: No such process
gcore: ptrace(PT_DUMPCORE) failed: No such process
gcore: ptrace(PT_DUMPCORE) failed: No such process
gcore: ptrace(PT_DUMPCORE) failed: No such process
gcore: ptrace(PT_DUMPCORE) failed: No such process
gcore: ptrace(PT_DUMPCORE) failed: No such process
gcore: ptrace(PT_DUMPCORE) failed: No such process
gcore: ptrace(PT_DUMPCORE) failed: No such process
gcore: ptrace(PT_DUMPCORE) failed: No such process
uvm_fault(0xcb1a1624, 0, 0, 1) -> 0xe
kernel: page fault trap, code=0
Stopped in pid 542.1 (gcore) at netbsd:coredump_notes_elf32+0x1db: movl 0
x8(%edx),%eax
db> bt
coredump_notes_elf32(cb15d4d0,ca38bbdc,cb16c888,ca3800fc,cadd091c) at netbsd:cor
edump_notes_elf32+0x1db
coredump_elf32(ca38bbdc,cb16c888,ca3800fc,2,1) at netbsd:coredump_elf32+0x22c
coredump(ca38bbdc,c0ccd110,8,0,ca395700) at netbsd:coredump+0x29c
sys_ptrace(cb1a43a0,cadd0f64,cadd0f5c,0,cadd0fa4) at netbsd:sys_ptrace+0x3c5
syscall_plain() at netbsd:syscall_plain+0x7e
--- syscall (number 26) ---
0xbdb48946:
db>
: {2} dmesg
NetBSD 3.0 (GENERIC) #0: Mon Dec 19 01:04:02 UTC 2005
builds@works.netbsd.org:/home/builds/ab/netbsd-3-0-RELEASE/i386/200512182024Z-obj/home/builds/ab/netbsd-3-0-RELEASE/src/sys/arch/i386/compile/GENERIC
total memory = 127 MB
avail memory = 116 MB
BIOS32 rev. 0 found at 0xf0f50
mainbus0 (root)
cpu0 at mainbus0: (uniprocessor)
cpu0: AMD Athlon Model 4 (Thunderbird) (686-class), 1210.89 MHz, id 0x642
cpu0: features c1c7f9ff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR>
cpu0: features c1c7f9ff<PGE,MCA,CMOV,PAT,PSE36,PN,MMXX,MMX>
cpu0: features c1c7f9ff<FXSR,3DNOW2,3DNOW>
cpu0: "AMD Athlon(tm) Processor"
cpu0: I-cache 64 KB 64B/line 2-way, D-cache 64 KB 64B/line 2-way
cpu0: L2 cache 256 KB 64B/line 16-way
cpu0: ITLB 16 4 KB entries fully associative, 8 4 MB entries fully associative
cpu0: DTLB 24 4 KB entries fully associative, 8 4 MB entries 4-way
cpu0: 8 page colors
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: VIA Technologies VT8363 (Apollo KT133) Host Bridge (rev. 0x03)
agp0 at pchb0: aperture at 0xe6000000, size 0x10000000
ppb0 at pci0 dev 1 function 0: VIA Technologies VT8363 (Apollo KT133) PCI to AGP Bridge (rev. 0x00)
pci1 at ppb0 bus 1
pci1: i/o space, memory space enabled
pcib0 at pci0 dev 4 function 0
pcib0: VIA Technologies VT82C686A PCI-ISA Bridge (rev. 0x40)
viaide0 at pci0 dev 4 function 1
viaide0: VIA Technologies VT82C686A (Apollo KX133) ATA100 controller
viaide0: bus-master DMA support present
viaide0: primary channel configured to compatibility mode
viaide0: primary channel interrupting at irq 14
atabus0 at viaide0 channel 0
viaide0: secondary channel configured to compatibility mode
viaide0: secondary channel interrupting at irq 15
atabus1 at viaide0 channel 1
uhci0 at pci0 dev 4 function 2: VIA Technologies VT83C572 USB Controller (rev. 0x16)
uhci0: interrupting at irq 12
usb0 at uhci0: USB revision 1.0
uhub0 at usb0
uhub0: VIA Technologies UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
uhci1 at pci0 dev 4 function 3: VIA Technologies VT83C572 USB Controller (rev. 0x16)
uhci1: interrupting at irq 12
usb1 at uhci1: USB revision 1.0
uhub1 at usb1
uhub1: VIA Technologies UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub1: 2 ports with 2 removable, self powered
VIA Technologies VT82C686A SMBus Controller (miscellaneous bridge, revision 0x40) at pci0 dev 4 function 4 not configured
eap0 at pci0 dev 9 function 0: Ensoniq AudioPCI 97 CT5880-A (rev. 0x07)
eap0: interrupting at irq 12
eap0: ac97: SigmaTel STAC9708 codec; 18 bit DAC, 18 bit ADC, SigmaTel 3D
eap0: ac97: ext id 80<SDAC>
audio0 at eap0: full duplex, mmap, independent
midi0 at eap0: AudioPCI MIDI UART
unknown vendor 0x1287 product 0x001e (video multimedia, revision 0x02) at pci0 dev 10 function 0 not configured
fxp0 at pci0 dev 11 function 0: i82559 Ethernet, rev 8
fxp0: interrupting at irq 10
fxp0: Ethernet address 00:04:ac:d3:7e:2f
inphy0 at fxp0 phy 1: i82555 10/100 media interface, rev. 4
inphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
vga1 at pci0 dev 12 function 0: ATI Technologies 3D Rage II+ (rev. 0x9a)
wsdisplay0 at vga1 kbdmux 1
wsmux1: connecting to wsdisplay0
pdcide0 at pci0 dev 17 function 0
pdcide0: Promise Ultra100/ATA Bus Master IDE Accelerator (rev. 0x02)
pdcide0: bus-master DMA support present
pdcide0: primary channel configured to native-PCI mode
pdcide0: using irq 10 for native-PCI interrupt
atabus2 at pdcide0 channel 0
pdcide0: secondary channel configured to native-PCI mode
atabus3 at pdcide0 channel 1
isa0 at pcib0
lpt0 at isa0 port 0x378-0x37b irq 7
com0 at isa0 port 0x3f8-0x3ff irq 4: ns16550a, working fifo
com0: console
com1 at isa0 port 0x2f8-0x2ff irq 3: ns16550a, working fifo
pckbc0 at isa0 port 0x60-0x64
pcppi0 at isa0 port 0x61
midi1 at pcppi0: PC speaker
sysbeep0 at pcppi0
isapnp0 at isa0 port 0x279: ISA Plug 'n Play device support
npx0 at isa0 port 0xf0-0xff: using exception 16
fdc0 at isa0 port 0x3f0-0x3f7 irq 6 drq 2
isapnp0: no ISA Plug 'n Play devices found
fd0 at fdc0 drive 0: 1.44MB, 80 cyl, 2 head, 18 sec
Kernelized RAIDframe activated
wd0 at atabus0 drive 0: <Maxtor 90845D4>
wd0: drive supports 16-sector PIO transfers, LBA addressing
wd0: 8063 MB, 16383 cyl, 16 head, 63 sec, 512 bytes/sect x 16514064 sectors
wd0: 32-bit data port
wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2 (Ultra/33)
wd0(viaide0:0:0): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA)
atapibus0 at atabus1: 2 targets
cd0 at atapibus0 drive 1: <FX4820T, , D03A> cdrom removable
cd0: 32-bit data port
cd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2 (Ultra/33)
cd0(viaide0:1:1): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA)
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)
--
Kirk Russell <kirk@ba23.org> http://www.ba23.org/
Bridlewood Software Testers Guild Ottawa Ontario Canada