summaryrefslogtreecommitdiffstats
path: root/hooks/shutdown
diff options
context:
space:
mode:
authorDave Reisner <dreisner@archlinux.org>2011-11-15 15:25:20 +0100
committerDave Reisner <dreisner@archlinux.org>2012-01-05 21:14:25 +0100
commit03deaed9f3f5b0c0537eb65e8f1862f53bc21fec (patch)
treea7ae64df327b4f1351ede76d0efd6e9a9bdf7053 /hooks/shutdown
parentbd4f7d6ee8f8527625b9f240a7e5b68b2d1f87bb (diff)
downloadmkinitcpio-03deaed9f3f5b0c0537eb65e8f1862f53bc21fec.tar.gz
mkinitcpio-03deaed9f3f5b0c0537eb65e8f1862f53bc21fec.tar.xz
shutdown: add new hook0.8.1
This adds functionality to pivot to back to the initramfs on shutdown, thereby allowing the system to unmount the real root device. This will be necessary for anyone with /usr as a separate partition.
Diffstat (limited to 'hooks/shutdown')
-rw-r--r--hooks/shutdown7
1 files changed, 7 insertions, 0 deletions
diff --git a/hooks/shutdown b/hooks/shutdown
new file mode 100644
index 0000000..7c5d9e8
--- /dev/null
+++ b/hooks/shutdown
@@ -0,0 +1,7 @@
+#!/usr/bin/ash
+
+run_hook() {
+ cp -ax / /run/initramfs
+}
+
+# vim: set ft=sh ts=4 sw=4 et: