Skip to main content

eth0+N headache in linux with virtual templates

If you keep getting eth1 instead of eth0 as your main ethernet interface on a (newer) linux template/clone in a virtualized environment it's most likely because your udev rules is in affect and creates a new eth1 since eth0 is already defined and bound to the clone/template source's MAC address.

This can be fixed in a couple of ways (in your template/clone source image):

1) You can delete the 'SUBSYSTEM' line in your /etc/udev/rules.d/70-persistent-net.rules:

Edit the rules files
  vi /etc/udev/rules.d/70-persistent-net.rules

Delete the SUBSYSTEM line(s), feel free to also delete the comment about PCI device just above:

# This file was automatically generated by the /lib/udev/write_net_rules
# program, run by the persistent-net-generator.rules rules file.
#
# You can modify it, as long as you keep each rule on a single
# line, and change only the value of the NAME= key.

# PCI device 0x8086:0x100e (e1000)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="08:00:27:4b:05:e0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

2) A more dirty hack would just be to delete the /etc/udev/rules.d/70-persistent-net.rules file and create a directory named as the file. This tip is taken from six degrees of fredom blog (link):

  rm /etc/udev/rules.d/70-persistent-net.rules
  mkdir /etc/udev/rules.d/70-persistent-net.rules





Comments

Popular posts from this blog

Force Dell BIOS Upgrade

I just experienced a problem upgrading a Huawei N8300 OceanStor NAS Engine node (OEM'ed Dell PowerEdge R710 server). Running the linux binary update file looked good and it asked me to reboot. After reboot the same old v2.1.15 BIOS was there, not the latest v6.4.0 (as of writing this small post). Next up was creating a FreeDOS Bootable ISO with the bios update program included (see this page for how to do that in Windows). Running the BIOS upgrade program from FreeDOS (virtual media and DRAC) I got this error: Cannot use a "Dell System PowerEdge R710" BIOS in a " -  " Pres any key to exit. ROM update not performed. After some googleing I found the solution on Dell Community Forum - use the /FORCETYPE option. So to force the update, I just ran the update package with that option (I had renamed the file for 8.3 DOS filename): R710-640.exe /FORCETYPE And thats it. v6.4.0 BIOS up and running :)

How to configure multiple VLANs on QNAP TS-869U

It's unbelievable that QNAP still doesn't support multiple VLANs on a single bond0 interface via GUI when they now just released the QTS v4.1.0 NAS Operation System for QNAP. The underlying Linux OS (QTS) does support it, and there should at least not be any problems with Intel chipsets. Some are reporting problems with Marvell.. but I haven't tried. I wanted to use the QNAP as a iSCSI storage for my LAB using a second interface while having full redundancy and get max bandwith (2x1GbE) for my ESXi hosts, and I didn't want that interface routed. At the same time I of course need the possibility to manage the QNAP system via the main interface, which is routed. This CLI "hack" will at configure the QNAP for a second VLAN interface that will be persistent during reboots. It's not been verified that it works after an upgrade of the firmware, but I presumed it will. To get this to work I presume you already have the following working: Network onfigured