[arch-projects] [PATCH 4/7] udev: exit on shutdown

Dan McGee dpmcgee at gmail.com
Thu Oct 27 00:03:52 EDT 2011

On Wed, Oct 26, 2011 at 10:51 PM, Dave Reisner <d at falconindy.com> wrote:
> On Wed, Oct 26, 2011 at 07:12:13PM -0500, Dan McGee wrote:
>> On Wed, Oct 26, 2011 at 6:38 PM, Tom Gundersen <teg at jklm.no> wrote:
>> > udev was receiving some events (due to e.g. swapoff) on shutdown
>> > that caused it to fork new processes. These then receivde TERM before
>> s/received/
>> > they could finish, and complained on the console.
>> >
>> > In principle, I'm worried that, with the right ammonut of bad luck,
>> s/amount/
>> > we could fork off some process at exactly the wrong time which escapes
>> > the killall logic.
>> >
>> > This, by the way, highlights the frailty of the killall stuff.
>> Two quick thoughts here
>> 1. Is there a need to even call swapoff? I can't believe it is
>> essential for swap partitions. It unfortunately does makes sense for
>> swap files so we can later unmount the file system they live on, but
>> it looks like there is no way to differentiate. Dave, I know you want
>> to submit a patch to util-linux for this... :)
> I'm such a tool. Preliminary patchwork for this now exists:
> http://code.falconindy.com/cgit/util-linux.git/log/?h=swapon
> If anyone wants to give it a once over from a user or developer
> perspective, that'd be awesome.

Wow, you're awesome. I guess my first question would be- does it
actually work? :) Just hotpatch the old initscripts to only swapoff
file partitions and try shutting down and make sure it actually goes
off without a hitch. This could definitely save some shutdown time on
machines that have paged a non-trivial amount to swap.


More information about the arch-projects mailing list