diff options
Diffstat (limited to 'scripts/live-helpers')
| -rw-r--r-- | scripts/live-helpers | 14 |
1 files changed, 14 insertions, 0 deletions
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 +} |
