X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=scripts%2Flive-helpers;h=f49eaf78e4e7969be52f37531b85fe889b930db8;hb=refs%2Ftags%2Fupstream%2F1.110.4;hp=ccc3a4ad5e2aab54b4fb7b75409a40465d403dac;hpb=482099e5a39fa3f8eec108a4e26182647c8cb4d6;p=live-boot-grml.git diff --git a/scripts/live-helpers b/scripts/live-helpers index ccc3a4a..f49eaf7 100644 --- a/scripts/live-helpers +++ b/scripts/live-helpers @@ -288,3 +288,17 @@ find_files () done done } + +get_mac () +{ + mac="" + for adaptor in /sys/class/net/*;do + status=$(cat ${adaptor}/iflink) + if [ ${status} -eq 2 ]; + then + mac=$(cat ${adaptor}/address) + mac=$(echo ${mac}|sed 's/:/-/g'|tr '[a-z]' '[A-Z]') + fi + done + echo $mac +}