diff --git a/luci-app-openmptcprouter/root/etc/hotplug.d/net/99-omr-rename b/luci-app-openmptcprouter/root/etc/hotplug.d/net/99-omr-rename index 9d741c683..f2c19dc55 100644 --- a/luci-app-openmptcprouter/root/etc/hotplug.d/net/99-omr-rename +++ b/luci-app-openmptcprouter/root/etc/hotplug.d/net/99-omr-rename @@ -23,7 +23,7 @@ _set_intf_name() { chk_modalias=$MODALIAS [ -z "$chk_modalias" ] && chk_modalias="$(cat /sys/class/net/${INTERFACE}/device/uevent | grep MODALIAS | cut -d '=' -f2 | tr -d '\n')" if [ -n "$chk_modalias" ]; then - logger -t "OMR-Rename" "dir: $i - modalias: $modalias - chk_modalias: $chk_modalias - ifname: $ifname - INTERFACE: $INTERFACE" + logger -t "OMR-Rename" "modalias: $modalias - chk_modalias: $chk_modalias - ifname: $ifname - INTERFACE: $INTERFACE" if [ "$modalias" = "$chk_modalias" ] && [ "$INTERFACE" != "$ifname" ]; then logger -t "OMR-Rename" "Rename ${INTERFACE} to ${ifname}" existif=0 @@ -45,6 +45,7 @@ _set_intf_name() { fi } [ -z "$modalias" ] && [ -n "$device" ] && [ -n "$ifname" ] && [ "/sys${DEVPATH}" = "$device" ] && [ "$INTERFACE" != "$ifname" ] && { + logger -t "OMR-Rename" "device: $device - devpath: $DEVPATH - ifname: $ifname - INTERFACE: $INTERFACE" logger -t "OMR-Rename" "Rename ${INTERFACE} to ${ifname}" ip link set ${INTERFACE} down 2>&1 >/dev/null existif=0 @@ -58,7 +59,7 @@ _set_intf_name() { } } -if [ "$(uci -q get openmptcprouter.settings.disableintfrename)" != "0" ]; then +if [ "$(uci -q get openmptcprouter.settings.disableintfrename)" != "1" ]; then config_load network config_foreach _set_intf_name interface config_foreach _set_intf_name interface