| 41 | * /tftpboot/node_root/sbin/init 是由 /opt/drbl/setup/files/misc/init.drbl 拷貝而來,因此如果要 patch 的話,應該先 patch /opt/drbl/setup/files/misc/init.drbl 這個檔案,如此未來只要跑 drblsrv 或 drblsrv-offline 均會把 br* 加入考慮。 |
| 42 | {{{ |
| 43 | #!diff |
| 44 | --- /opt/drbl/setup/files/misc/init.drbl.org 2011-09-29 12:04:10.000000000 +0800 |
| 45 | +++ /opt/drbl/setup/files/misc/init.drbl 2011-09-29 12:04:33.000000000 +0800 |
| 46 | @@ -158,7 +158,7 @@ |
| 47 | create_dev |
| 48 | |
| 49 | # find my IP address |
| 50 | -NETDEVICES="$(cat /proc/net/dev | awk -F: '/eth.:|tr.:/{print $1}')" |
| 51 | +NETDEVICES="$(cat /proc/net/dev | awk -F: '/eth.:|tr.:|br.:/{print $1}')" |
| 52 | for DEVICE in $NETDEVICES; do |
| 53 | IP_tmp="$(ifconfig $DEVICE | grep -A1 $DEVICE | grep -v $DEVICE | grep "inet addr" | sed -e 's/^.*inet addr:\([0-9\.]\+\).*$/\1/')" |
| 54 | if [ -n "$IP_tmp" ]; then |
| 55 | }}} |
| 56 | --- |