From 24deffc4381cdbbad3a464cbcf30beb131965aca Mon Sep 17 00:00:00 2001 From: Richard Maw Date: Mon, 27 Feb 2012 11:01:27 +0000 Subject: config changes for [um]dev and ssh Mdev is currently being used as it is part of busybox This does not need all of the device nodes previously specified as it is able to create them, so they are removed from create-dev-nodes /dev/console and /dev/null may be needed to boot rcS has been changed to use a tmpfs for /dev, this will be filled by mdev. http://lwn.net/Articles/330985/ suggests that it may be faster to use a devtmpfs as [um]dev only needs to set the permissions though. More users and groups have been added. Many are for the standard [um]dev device configuration. The sshd user and group are for ssh as we do not have a good way to add groups in morph yet. --- create-dev-nodes | 10 ---------- group | 14 +++++++++++++- passwd | 2 ++ rcS | 7 ++++--- 4 files changed, 19 insertions(+), 14 deletions(-) diff --git a/create-dev-nodes b/create-dev-nodes index 0f4b2db..f9297d9 100755 --- a/create-dev-nodes +++ b/create-dev-nodes @@ -26,15 +26,5 @@ then fi DESTDIR=$1 -mknod -m 600 "$DESTDIR/dev/tty0" c 4 0 -mknod -m 600 "$DESTDIR/dev/tty1" c 4 1 -mknod -m 600 "$DESTDIR/dev/tty2" c 4 2 -mknod -m 600 "$DESTDIR/dev/tty3" c 4 3 -mknod -m 600 "$DESTDIR/dev/tty4" c 4 4 -mknod -m 600 "$DESTDIR/dev/ttyS0" c 4 64 -mknod -m 600 "$DESTDIR/dev/ttyS1" c 4 65 mknod -m 600 "$DESTDIR/dev/console" c 5 1 mknod -m 666 "$DESTDIR/dev/null" c 1 3 -mknod -m 666 "$DESTDIR/dev/full" c 1 5 -mknod -m 666 "$DESTDIR/dev/random" c 1 8 -mknod -m 666 "$DESTDIR/dev/urandom" c 1 9 diff --git a/group b/group index 1dbf901..fc76ae8 100644 --- a/group +++ b/group @@ -1 +1,13 @@ -root:x:0: +root:x:0:root +disk:x:6: +cdrom:x:24: +floppy:x:25: +tape:x:26: +audio:x:29: +video:x:44 +lp:x:7: +tty:x:5: +dialout:x:20: +kmem:x:15: +sshd:x:50:sshd +nogroup:x:65534:nobody diff --git a/passwd b/passwd index 1027b96..410def2 100644 --- a/passwd +++ b/passwd @@ -1 +1,3 @@ root::0:0:Super user:/:/bin/sh +sshd:x:50:50::/var/lib/sshd:/bin/false +nobody:x:65534:65534:nobody:/nonexistent:/bin/false diff --git a/rcS b/rcS index bb1136e..af7bd5d 100644 --- a/rcS +++ b/rcS @@ -1,10 +1,11 @@ #!/bin/sh rm /etc/mtab touch /etc/mtab -mount /proc -mount /sys +mount -t proc proc /proc +mount -t sysfs sysfs /sys +mount -t tmpfs -o size=0 tmpfs /dev mkdir -p /dev/pts -mount /dev/pts +mount -t devpts devpts /dev/pts echo /sbin/mdev >/proc/sys/kernel/hotplug mdev -s -- cgit v1.2.1