Changeset 535dcdb in freewrt for target/linux/brcm-2.4/squashfs-overlay/files/etc/init.d/S20jffsclean
- Timestamp:
- Jun 12, 2007, 1:24:02 AM (19 years ago)
- Branches:
- freewrt_1_0, freewrt_2_0
- Children:
- 4e87d9a
- Parents:
- 9bb72d2
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
target/linux/brcm-2.4/squashfs-overlay/files/etc/init.d/S20jffsclean
r9bb72d2 r535dcdb 1 1 #!/bin/sh 2 # if / is tmpfs, we have an old or broken jffs2 3 # erase data partition and set flag between bootloader and kernel 4 { mount|grep "on / type tmpfs" 1>&-; } && { 5 mtd erase data 6 jffs2root --clean 7 reboot 8 } 2 3 case $1 in 4 autostart) 5 exec $0 start 6 ;; 7 start) 8 # if / is tmpfs, we have an old or broken jffs2 9 # erase data partition and set flag between bootloader and kernel 10 { mount|grep "on / type tmpfs" 1>&-; } && { 11 mtd erase data 12 jffs2root --clean 13 /bin/sync && /bin/busybox reboot -f 14 } 15 ;; 16 stop) 17 echo "no stop function implemented..." 18 ;; 19 *) 20 echo "Usage: $0 {start | stop }" 21 exit 1 22 ;; 23 esac 24 exit $?
Note:
See TracChangeset
for help on using the changeset viewer.
