Skip site navigation (1)Skip section navigation (2)
Date:      13 Feb 2001 13:54:02 +0100
From:      Dag-Erling Smorgrav <des@ofug.org>
To:        arch@freebsd.org
Subject:   sparse core dumps
Message-ID:  <xzpsnlizqtx.fsf@flood.ping.uio.no>

next in thread | raw e-mail | index | archive | help
I finally found the time to finish hacking savecore(8) to generate
sparse dumps. The good news is it's even noticeably faster than the
old version :) There's a patch up on freefall:

    http://people.freebsd.org/~des/software/savecore-20010213.diff

Here's a side-by-side comparison (using a version of savecore(8) that
doesn't clear the dump after saving it):

root@rsa /var/crash2# time savecore $(pwd)
savecore: reboot after panic: from debugger
savecore: system went down at Tue Feb 13 11:33:22 2001
savecore: /var/crash2/bounds: No such file or directory
savecore: writing core to /var/crash2/vmcore.0
savecore: writing kernel to /var/crash2/kernel.0
savecore /var/crash2  0.17s user 32.25s system 19% cpu 2:48.72 total
root@rsa /var/crash2# time /tmp/savecore $(pwd)
savecore: reboot after panic: from debugger
savecore: system went down at Tue Feb 13 11:33:22 2001
savecore: writing core to /var/crash2/vmcore.1
savecore: writing kernel to /var/crash2/kernel.1
/tmp/savecore /var/crash2  18.29s user 5.62s system 19% cpu 1:59.96 total
root@rsa /var/crash2# du -k vmcore.0 vmcore.1
524352  vmcore.0
35712   vmcore.1
root@rsa /var/crash2# cmp vmcore.0 vmcore.1 && echo 'Mrreaow!'
Mrreaow!

This is with a 4096-byte block size (equal to PAGE_SIZE), which was
noticeably better than my original choice of 512 bytes. I think the
best overall block size is the crashed kernel's page size, as most of
the holes will originate from (series of) zeroed pages; I tried
8192-byte blocks (my /var/crash and /var/crash2 file systems have 64k
blocks and 8k fragments) but noticed no improvement. Writing to a file
system with smaller (1024-byte) fragments gave a smaller actual disk
usage but a 50% increase in system time.

DES
-- 
Dag-Erling Smorgrav - des@ofug.org


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-arch" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?xzpsnlizqtx.fsf>