Detecting IFACE


#1

Hi all
First a great congratulations and big thanks for this amazing script.

I’ve got a problem in the set of the IFACE, it seems that this commit doesn’t work right in my lab.

Esxi -> ProxMox -> Ubuntu -> Quickbox
In this enviroment the IFACE returned is “[email protected]”.

I would cut before the @ with “cut [email protected] -f 1”, this way :
ip link show|grep -i broadcast|grep UP|cut -d: -f 2|cut [email protected] -f 1|sed -e ‘s/ //g’

This is the execution :

[[email protected]]:(0b)~$ ip link show|grep -i broadcast|grep UP|cut -d: -f 2|sed -e 's/ //g’
[email protected]
[[email protected]]:(0b)~$ ip link show|grep -i broadcast|grep UP|cut -d: -f 2|cut [email protected] -f 1|sed -e 's/ //g’
eth0

Hope this help.

Best Regards


#2

Thanks for the contribution on this one @Beachsun! I will run a few trials across various environment and OS to ensure it’s validity (just a precaution). I don’t think we have had many ProxMox users so this is a welcome addition to those that are using it for containers. :slight_smile:


#3

Glad to help.
Thank you very much for considering this.

Keep on good work.

Regards