Changeset 2750
- Timestamp:
- 06/08/07 17:39:40 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/freewrt/package/base-files/files/etc/preinit
r2494 r2750 14 14 # failsafe via hotplug 15 15 trap 'FAILSAFE=true' USR1 16 echo '/sbin/hotplug.failsafe' >/proc/sys/kernel/hotplug16 echo /sbin/hotplug.failsafe >/proc/sys/kernel/hotplug 17 17 ip link set up dev eth0 18 18 ip addr add 192.168.1.1/24 broadcast 192.168.1.255 dev eth0 19 netmsg 192.168.1.255 "Press reset now ,to enter Failsafe!"19 netmsg 192.168.1.255 "Press reset now to enter Failsafe!" 20 20 echo "Press reset now to enter Failsafe!" 21 21 sleep 2 22 22 eval ${FAILSAFE:+failsafe} 23 trap - USR1 23 24 24 25 # reset to normal mode 26 echo /sbin/hotplug >/proc/sys/kernel/hotplug 27 mount_root 28 cat /etc/.rnd >/dev/urandom 2>&1 29 [ -x /sbin/fwcf ] && fwcf setup 2>&1 | while IFS= read -r line; do 30 netmsg 192.168.1.255 "fwcf diag: $line" 31 done 25 32 ip addr delete 192.168.1.1/24 broadcast 192.168.1.255 dev eth0 26 echo '/sbin/hotplug' > /proc/sys/kernel/hotplug27 mount_root28 cat /etc/.rnd >/dev/urandom 2>&129 [ -x /sbin/fwcf ] && fwcf setup 2>&1 | logger -t fwcf30 33 exec /sbin/init trunk/freewrt/package/base-files/files/sbin/hotplug.failsafe
r2322 r2750 1 1 #!/bin/sh 2 case "$1"in3 button) kill -USR1 1;;2 case $1 in 3 button) kill -USR1 1;; 4 4 esac


