sysvinit-devel
[Top][All Lists]
Advanced

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

[sysvinit-devel] SysVinit: support unmounting root


From: Dark Templar
Subject: [sysvinit-devel] SysVinit: support unmounting root
Date: Fri, 27 Jun 2014 23:36:11 +0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0

Hi.

In order to unmount root and properly shutdown lvm/encrypted devices/etc
I've written update for sysvinit. It allows to exec into another
application. It can be used to create new root filesystem in memory in
that application, switch to this new root, and then unmount old root and
shutdown underlying devices.

I've found similar feature request in the bugzilla:
http://savannah.nongnu.org/bugs/?33517
There is even a similar patch attached.

I'm attaching my patch for sysvinit-2.88 and archive with diff for
inittab and test scripts. On test setup I put those scripts into
/usr/local/sbin/. The scripts mostly use static busybox, and right
before shutdown/reboot it invokes shell for debugging purposes. It does
not shut down any lvm/encrypted device/etc, but it's not so much to
write from here. In case of failing to exec into another process init
goes to next record in the inittab, that's why I don't remove plain
poweroff/reboot records. I think in that case it's better to shutdown at
least that way compared to panicking.

I'd like to have this patch merged into sysvinit. I've used gentoo linux
as a test platform for this feature.

Attachment: sysvinit-exec.patch
Description: Text Data

Attachment: sysvinit-data.tar.bz2
Description: application/bzip


reply via email to

[Prev in Thread] Current Thread [Next in Thread]