summaryrefslogtreecommitdiffstats
path: root/boot-env/preboot/uclib-rootfs/init
diff options
context:
space:
mode:
authorDirk von Suchodoletz2009-01-29 00:22:21 +0100
committerDirk von Suchodoletz2009-01-29 00:22:21 +0100
commitf3adc477f4acd44d1981498a0ca163c359052149 (patch)
tree9829ffee28753e35ba44f5e133ae5a844cb1f5a6 /boot-env/preboot/uclib-rootfs/init
parentWebserver interaction for client configuration. (diff)
downloadcore-f3adc477f4acd44d1981498a0ca163c359052149.tar.gz
core-f3adc477f4acd44d1981498a0ca163c359052149.tar.xz
core-f3adc477f4acd44d1981498a0ca163c359052149.zip
Adding mac address to webserver request ...
git-svn-id: http://svn.openslx.org/svn/openslx/openslx/trunk@2554 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'boot-env/preboot/uclib-rootfs/init')
-rwxr-xr-xboot-env/preboot/uclib-rootfs/init5
1 files changed, 5 insertions, 0 deletions
diff --git a/boot-env/preboot/uclib-rootfs/init b/boot-env/preboot/uclib-rootfs/init
index f2e4f50e..7018a1e2 100755
--- a/boot-env/preboot/uclib-rootfs/init
+++ b/boot-env/preboot/uclib-rootfs/init
@@ -129,6 +129,11 @@ fetchip
ip addr add $ip/$(ipcalc -s -p $ip $subnet|sed s/.*=//) dev $nwif
ip route add default via $router
+# get the mac address of the boot network adaptor
+macaddr=$(ip link show dev $nwif 2>/dev/null | \
+ sed -n "/ether [0-9e-f]\{2\}:.*/p" | sed -e "s/.*ether //;s/ .*//")
+echo "macaddr=$macaddr" >>/etc/initramfs-setup
+
# at this point a little selection script could be downloaded, which lets the
# user choose what kind of SLX client he wants to get
echo "Fetching preboot interactive part and configuration from the net ..."