Voyage 0.10: Ethernet bug when moving CF-disks to other boards discovered

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Voyage 0.10: Ethernet bug when moving CF-disks to other boards discovered

Andreas Delleske
Hi list,

I guess I have discovered a bug:

With an Alix board and Voyage Linux 0.10.0, I prepared a Compact Flash
with the usual script.

It started fine, I got ssh access etc., DHCP was working, Ethernet..

Then when I stopped the machine (orderly shutdown) and plugged the
CF-card into another ALIX board (with a different Ethernet MAC, the
Ethnernet interface eth0 did not even come up at boot - it was not
present even in "ifconfig".

The problem is, that when starting up and the following file does not
yet exist, the system "hardwires" the MAC address into the file, like
so:

xx:~# cat /etc/udev/rules.d/70-persistent-net.rules
# 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 0x1106:0x3053 (via-rhine)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*",
ATTR{address}=="00:0d:b9:17:fc:d0", ATTR{dev_id}=="0x0",
ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

I think it is this problem.

http://unix.stackexchange.com/questions/110496/cloned-linux-system-and-etc-udev-rules-d-70-persistent-net-rules

Could the voyage code be adapted or is this a Debian thing? Come
something be done?


--
Cheers
Andreas

_______________________________________________
Voyage-linux mailing list
[hidden email]
http://list.voyage.hk/mailman/listinfo/voyage-linux
Reply | Threaded
Open this post in threaded view
|

Re: Voyage 0.10: Ethernet bug when moving CF-disks to other boards discovered

Jon Meek
I don't think that this is a bug. Those rules keep your Ethernet port names consistent over time. In my cloning notes I have a step to delete the appropriate lines before moving the disk / CF card to a new system.

I would have expected a new line for eth1 to be added to the file, which is not what you want, of course.

Jon


On Sat, Nov 26, 2016 at 8:00 AM, Andreas Delleske <[hidden email]> wrote:
Hi list,

I guess I have discovered a bug:

With an Alix board and Voyage Linux 0.10.0, I prepared a Compact Flash
with the usual script.

It started fine, I got ssh access etc., DHCP was working, Ethernet..

Then when I stopped the machine (orderly shutdown) and plugged the
CF-card into another ALIX board (with a different Ethernet MAC, the
Ethnernet interface eth0 did not even come up at boot - it was not
present even in "ifconfig".

The problem is, that when starting up and the following file does not
yet exist, the system "hardwires" the MAC address into the file, like
so:

xx:~# cat /etc/udev/rules.d/70-persistent-net.rules
# 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 0x1106:0x3053 (via-rhine)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*",
ATTR{address}=="00:0d:b9:17:fc:d0", ATTR{dev_id}=="0x0",
ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

I think it is this problem.

http://unix.stackexchange.com/questions/110496/cloned-linux-system-and-etc-udev-rules-d-70-persistent-net-rules

Could the voyage code be adapted or is this a Debian thing? Come
something be done?


--
Cheers
Andreas

_______________________________________________
Voyage-linux mailing list
[hidden email]
http://list.voyage.hk/mailman/listinfo/voyage-linux



--

_______________________________________________
Voyage-linux mailing list
[hidden email]
http://list.voyage.hk/mailman/listinfo/voyage-linux
Reply | Threaded
Open this post in threaded view
|

Re: Voyage 0.10: Ethernet bug when moving CF-disks to other boards discovered

Andreas Delleske
Hi Jon,

> I don't think that this is a bug. Those rules keep your Ethernet port names
> consistent over time. In my cloning notes I have a step to delete the
> appropriate lines before moving the disk / CF card to a new system.

Objection, your honour :)

At least when we chose DHCP I guess everyone wants the device working
at a new place in a new hardware. It's not even possible to swap a
broken board this way. Everyone should know this at least, and I think
this behaviour had been different in previous versions of voyage
(which is fantastic BTW).

So I think the installer could offer to add your modification..

And yes, I would have expected at least an eth1 popping up ..

--
Andreas

_______________________________________________
Voyage-linux mailing list
[hidden email]
http://list.voyage.hk/mailman/listinfo/voyage-linux
Reply | Threaded
Open this post in threaded view
|

Re: Voyage 0.10: Ethernet bug when moving CF-disks to other boards discovered

Jon Meek
Hi Andreas - I have checked my notes and this has been "an issue" going back to at least SuSE Linux (a fine German product) in 2006. So, it is not Voyage-linux specific, but maybe Debian related. 
Here is at least one good reason for this: suppose you have a server running in a data center and you need to add some more Ethernet ports. You have the DC people put in the card and turn the machine back on. It would be very bad if the port assignment algorithm decided to assign one of the new ports to eth0. That new port would likely not even be plugged into a switch port at boot time and you would have to use the serial console (if you have one) to sort out the mess.

However, I agree that your situation was frustrating, and I have experienced it myself.

Jon


On Sat, Nov 26, 2016 at 2:15 PM, Andreas Delleske <[hidden email]> wrote:
Hi Jon,

> I don't think that this is a bug. Those rules keep your Ethernet port names
> consistent over time. In my cloning notes I have a step to delete the
> appropriate lines before moving the disk / CF card to a new system.

Objection, your honour :)

At least when we chose DHCP I guess everyone wants the device working
at a new place in a new hardware. It's not even possible to swap a
broken board this way. Everyone should know this at least, and I think
this behaviour had been different in previous versions of voyage
(which is fantastic BTW).

So I think the installer could offer to add your modification..

And yes, I would have expected at least an eth1 popping up ..

--
Andreas



--

_______________________________________________
Voyage-linux mailing list
[hidden email]
http://list.voyage.hk/mailman/listinfo/voyage-linux