Friday September 19, 2008
Bill Sommerfeld's WeblogStill Under Construction. Watch for falling objects Knowing when a crash dump is complete If you're doing kernel development on solaris, every so often you'll crash a machine. It will save a crash dump to the dump device and then on reboot, the dumpadm service (svc:/system/dumpadm:default) will invoke savecore to copy from the dump device to the filesystem.
Since SMF goes out of its way to let services start in parallel, and dumpadm is one of those services, it might not be done by the time you log in to start investigating the crime scene. It's annoying to have to periodically poll to see if it's done (sometimes it takes a while) so you can do something like: cd /var/crash/$(hostname); svcadm -v enable -s dumpadm; mdb -k N and then go about your business until you see an mdb prompt in that window. This relies on the the -s option to svcadm (which causes it to wait until the service is done attempting to start) as well as the fact that enabling an already-enabled service is a no-op. (2008-09-19 17:19:34.0) Permalink Comments [2]Post a Comment: Comments are closed for this entry. |
Calendar
RSS Feeds
All /General /IETF /IPsec /Music /OpenSolaris /Solaris SearchLinks
Navigation |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Better still would be 'svcadm ... && mdb ...', since it is possible for svcadm -s to fail (e.g. if the dumpadm service's dependencies are unsatisfiable).
Posted by Dave on September 19, 2008 at 08:45 PM EDT #
Hmmm... I always uttered "pwait `pgrep savecore` ; mdb" but yours (and Dave's) is an improvement.
Posted by Dan McDonald on September 22, 2008 at 02:25 PM EDT #