summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorMarc Kleine-Budde <mkl@pengutronix.de>2009-12-19 23:08:12 +0100
committerMarc Kleine-Budde <mkl@pengutronix.de>2009-12-24 12:56:02 +0100
commit75601e100c9dfc1285ab93b2bc20dd27aad7a01e (patch)
treea8368f8140bc9513fedc3b366404b38be224c3a8 /generic
parent905c863216042e524c9daee62fc30369f38d3d53 (diff)
downloadptxdist-75601e100c9dfc1285ab93b2bc20dd27aad7a01e.tar.gz
ptxdist-75601e100c9dfc1285ab93b2bc20dd27aad7a01e.tar.xz
[net2flash] obsolete, removed
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'generic')
-rw-r--r--generic/etc/init.d/net2flash68
1 files changed, 0 insertions, 68 deletions
diff --git a/generic/etc/init.d/net2flash b/generic/etc/init.d/net2flash
deleted file mode 100644
index 3f270b36d..000000000
--- a/generic/etc/init.d/net2flash
+++ /dev/null
@@ -1,68 +0,0 @@
-#!/bin/sh
-#
-# /etc/init.d/net2flash:
-#
-
-ROOTFS="/dev/mtdblock/2"
-
-case $1 in
-
- start)
- # check if we already run from flash
- if [ "x`mount | grep root | grep mtdblock`" != "x" ]; then
- echo "net2flash does only work when running from NFS";
- exit 1;
- fi
- # check if /mnt is already in use
- if [ "x`mount | grep /mnt`" != "x" ]; then
- echo "mountpoint /mnt already in use";
- exit 1;
- fi
-
- echo -n "mounting $ROOTFS..."
- mount -t jffs2 $ROOTFS /mnt
- if [ "$?" != "0" ]; then
- echo "could not mount $ROOTFS on /mnt"
- exit 1
- fi
- echo "done"
- echo -n "save /home..."
- cp -a /mnt/home /tmp
- echo "done"
- echo -n "cleaning old content..."
- rm -fr /mnt/*
- echo "done"
- echo -n "copying files..."
- cp -ax / /mnt/
- echo "done"
- echo -n "generating md5 sums..."
- rm -f /tmp/files.md5
- cd /mnt
- find . -type f | xargs md5sum > /tmp/files.md5
- echo "done"
- echo -n "checking md5sums..."
- cd /;
- failures=`md5sum -c /tmp/files.md5 | grep FAILED`
- echo -n "status: "
- if [ "x$failures" != "x" ]; then
- echo "!!! INCONSISTENCIES DETECTED !!!"
- echo $failures
- else
- echo "all files consistent";
- fi
- rm /tmp/files.md5
- echo -n "restore /home..."
- cp -a /tmp/home /mnt/
- echo "done"
- echo -n "unmounting $ROOTFS..."
- umount /mnt
- sync
- echo "done"
- ;;
- *)
- echo "usage: $0 [start|stop]"
- exit 0;
- ;;
-
-esac
-