summaryrefslogtreecommitdiff
path: root/packages/nslu2-binary-only
diff options
context:
space:
mode:
authorRod Whitby <rod@whitby.id.au>2005-06-10 14:22:35 +0000
committerRod Whitby <rod@whitby.id.au>2005-06-10 14:22:35 +0000
commitdf72ae863d672aa33466f6466fe6300ab7307455 (patch)
tree66974c3d2276f6451f951b265b5508817624402c /packages/nslu2-binary-only
parent72e6945a310f41c42f102a39cd9f1e476a4eb4bc (diff)
Don't create /dev and /var ramdisks in Unslung maintenance mode
BKrev: 42a9a22bmLETdzmldWliogEEWpM_uA
Diffstat (limited to 'packages/nslu2-binary-only')
-rw-r--r--packages/nslu2-binary-only/unslung-rootfs/create-ramdisks.patch30
1 files changed, 30 insertions, 0 deletions
diff --git a/packages/nslu2-binary-only/unslung-rootfs/create-ramdisks.patch b/packages/nslu2-binary-only/unslung-rootfs/create-ramdisks.patch
index e69de29bb2..7245c46b35 100644
--- a/packages/nslu2-binary-only/unslung-rootfs/create-ramdisks.patch
+++ b/packages/nslu2-binary-only/unslung-rootfs/create-ramdisks.patch
@@ -0,0 +1,30 @@
+--- nslu2-linksys-ramdisk-2.3r25/etc/rc.d/rc.sysinit.orig 2004-11-09 21:45:46.000000000 +1030
++++ nslu2-linksys-ramdisk-2.3r25/etc/rc.d/rc.sysinit 2004-11-09 21:41:47.000000000 +1030
+@@ -13,7 +13,25 @@
+
+ mkdir -p /var/lock/samba >/dev/null
+-/bin/echo "Creating ramfs for /var/lock/samba:"; mount -t ramfs none /var/lock/samba -o maxsize=64
+-/bin/echo "Limit the space of log folder:"; mount -t ramfs none /var/log -o maxsize=128
++
++if ( [ ! -f /.ramdisk ] && [ ! -f /.sda1root ] && [ ! -f /.sda2root ] && [ ! -f /.sdb1root ] && [ ! -f /.sdb2root ] ) ; then
++ /bin/echo "Creating ramfs for /dev:"
++ /bin/mount -t ramfs ramfs /mnt/tmpmnt
++ /bin/cp -rp /dev/* /mnt/tmpmnt/
++ /bin/mkdir -p /dev.state
++ /bin/mount -o bind /dev /dev.state
++ /bin/mount -o bind /mnt/tmpmnt /dev
++ /bin/umount /mnt/tmpmnt
++ /bin/echo "Creating ramfs for /var:"
++ /bin/mount -t ramfs ramfs /mnt/tmpmnt -o maxsize=256
++ /bin/cp -rp /var/* /mnt/tmpmnt/
++ /bin/mkdir -p /var.state
++ /bin/mount -o bind /var /var.state
++ /bin/mount -o bind /mnt/tmpmnt /var
++ /bin/umount /mnt/tmpmnt
++ /bin/killall syslogd
++ /bin/killall klogd
++fi
++
+ mkdir -p /var/log/samba >/dev/null
+ touch /var/log/server.log >/dev/null
+ chmod 755 /var/log/samba >/dev/null