Team,
I did a restore to a new UTM, differen't hardware. I expected my networks not to get a new hardware assigned but I guess I kinda hoped I'd get lucky. So now I'm locked out of the unit since none of the ports have an active network.
what commands would I have to use on the console to get the networks re-assigned to a correct eth device? Thanks in avdance!
If the new unit has fewer NICs than the old one had in use, Interface definitions will be lost along with all of the rules using them. You can change the NIC order as root:
edit /etc/udev/rules.d/70-persistent-net.rules
Save the file and reboot to load the new order.
Cheers - Bob
Thank you Bob,
after a call with support, I decided to just reconfigure from scratch. In this case, the new device (SG-230) had more ports than the old device (Software UTM with 5 physical ports)
Can someone please explain the process with a little more detail if I want to restore a backup to new hardware that has fewer NICs; without loosing any rules?
Say my current software box has one built-in NIC (eth0) on the motherboard and a four port add-on card (eth1-4). eth1 is used for internal and eth2 is used for external.
The new hardware has only eth0 and eth1.
Do I edit '/etc/udev/rules.d/70-persistent-net.rules' on the new hardware, before restoring, and rename eth0 to eth1 and rename eth1 to eth2, reboot and then restore the backup? This doesn't seem correct because the naming starts with eth1 instead of eth0.
Or, on the old box before I create the backup, should I rename eth1 to eth0 and rename eth2 to eth1, reboot, then create the backup or will this cause me to loose rules? Or are simply saying on the old box I don't edit any of the lines, I just reorder them like below:
Change from:
# This file was automatically generated by the Astaro Installer, then
# possibly later on written by the /lib/udev/write_net_rules generator
# script.
#
# You can modify it, as long as you keep each rule on a single line.
# PCI device 0x8086:0x1502 (e1000e)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="2c:43:38:9d:1f:d5", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"
# PCI device 0x14e4:0x1639 (bnx2)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:13:14:85:cc:40", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"
# PCI device 0x14e4:0x1639 (bnx2)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:13:14:85:cc:42", ATTR{type}=="1", KERNEL=="eth*", NAME="eth2"
# PCI device 0x14e4:0x1639 (bnx2)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:13:14:85:cc:44", ATTR{type}=="1", KERNEL=="eth*", NAME="eth3"
# PCI device 0x14e4:0x1639 (bnx2)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:13:14:85:cc:46", ATTR{type}=="1", KERNEL=="eth*", NAME="eth4"
To:
# This file was automatically generated by the Astaro Installer, then
# possibly later on written by the /lib/udev/write_net_rules generator
# script.
#
# You can modify it, as long as you keep each rule on a single line.
# PCI device 0x14e4:0x1639 (bnx2)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:13:14:85:cc:40", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"
# PCI device 0x14e4:0x1639 (bnx2)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:13:14:85:cc:42", ATTR{type}=="1", KERNEL=="eth*", NAME="eth2"
# PCI device 0x8086:0x1502 (e1000e)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="2c:43:38:9d:1f:d5", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"
# PCI device 0x14e4:0x1639 (bnx2)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:13:14:85:cc:44", ATTR{type}=="1", KERNEL=="eth*", NAME="eth3"
# PCI device 0x14e4:0x1639 (bnx2)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:13:14:85:cc:46", ATTR{type}=="1", KERNEL=="eth*", NAME="eth4"
--------------------------------------------------------------------
Sophos UTM 9.719-3 - Home User
Virtual machine on Dell Optiplex 3070
i3-9100 @ 3.60 GHz, 16 GB RAM
--------------------------------------------------------------------
Renumbering is done after the restore to the new device, so you can't use this trick as only the Interface definitions using the first two NICs will survive the restore on the unit with only two NICs. Only objects and rules related to the surviving Interfaces will survive.
Cheers - Bob