From 61375f9d9a76a0771b00a32412b7afd296551454 Mon Sep 17 00:00:00 2001 From: Scott James Remnant Date: Mon, 21 Dec 2009 23:06:53 +0000 Subject: init: Mount devtmpfs on /dev falling back to a tmpfs if not supported by the kernel. [ merge of 0.92bubuntu61 ] Signed-off-by: maximilian attems --- init | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'init') diff --git a/init b/init index e1d4151..68ceac7 100755 --- a/init +++ b/init @@ -17,9 +17,11 @@ tmpfs_size="10M" if [ -e /etc/udev/udev.conf ]; then . /etc/udev/udev.conf fi -mount -t tmpfs -o size=$tmpfs_size,mode=0755 udev /dev -[ -e /dev/console ] || mknod -m 0600 /dev/console c 5 1 -[ -e /dev/null ] || mknod /dev/null c 1 3 +if ! mount -t devtmpfs -o mode=0755 none /dev; then + mount -t tmpfs -o size=$tmpfs_size,mode=0755 udev /dev + [ -e /dev/console ] || mknod -m 0600 /dev/console c 5 1 + [ -e /dev/null ] || mknod /dev/null c 1 3 +fi > /dev/.initramfs-tools mkdir /dev/.initramfs -- cgit v1.2.3