<feed xmlns='http://www.w3.org/2005/Atom'>
<title>vyos-1x.git/src/systemd/vyos-net-name-resolve-hotplug.service, branch rolling</title>
<subtitle>VyOS command definitions, scripts, and utilities (mirror of https://github.com/vyos/vyos-1x.git)
</subtitle>
<id>https://git.amelek.net/vyos/vyos-1x.git/atom?h=rolling</id>
<link rel='self' href='https://git.amelek.net/vyos/vyos-1x.git/atom?h=rolling'/>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-1x.git/'/>
<updated>2026-10-31T09:58:29+00:00</updated>
<entry>
<title>interfaces: T3871: give a re-created Hyper-V NIC the name of the NIC it replaced</title>
<updated>2026-10-31T09:58:29+00:00</updated>
<author>
<name>Alex Kudentsov</name>
<email>43482574+alexk37@users.noreply.github.com</email>
</author>
<published>2026-10-14T13:46:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-1x.git/commit/?id=153dd688b327c922ec4b371db1fdd11b8ee8cf9e'/>
<id>urn:sha1:153dd688b327c922ec4b371db1fdd11b8ee8cf9e</id>
<content type='text'>
A Hyper-V NIC is known by its MAC alone. One deleted and created again on
the same VM - an Azure NIC re-created, or a Hyper-V adapter removed and
added - comes back with a new MAC, so nothing on it matched the store: its
name stayed reserved, the new NIC got a new name, and its configuration
was left on a name with no NIC. cloud-init does not run again on the same
instance, so nothing else repairs it.

At boot, a vacant name now goes to a new NIC only when the pairing is not
in doubt:
- exactly one recorded name has no NIC, and exactly one new Hyper-V NIC
  appeared. With more of either, the order the NICs come up in does not
  say which replaced which, so nothing is handed over and the names stay
  reserved, as before;
- the name went missing at this pass. The store records which names were
  missing at the last pass, so a NIC removed for good does not hand its
  name to a NIC added at a later boot;
- the name's own NIC was a Hyper-V one. The store records which names sat
  on a Hyper-V NIC; a MAC-keyed name can belong to other hardware, and a
  store written before this was recorded hands nothing over (the boot pass
  logs that when it holds a name back);
- only at boot. On a running system the configuration under a name is not
  applied to the NIC that takes it, so the hotplug unit passes --hotplug,
  which names the new NIC like any other and records the vacant name as
  missing, so the next boot does not hand it over either.

An adoption is logged as a warning, reported under 'adopted' in the status
file (kept there across hotplug passes while it holds), and repeated by
vyos-router, as a slot match is: verify the port before relying on its
configuration.
</content>
</entry>
<entry>
<title>interfaces: T3871: name hot-plugged interfaces</title>
<updated>2026-10-31T09:58:29+00:00</updated>
<author>
<name>Christian Breunig</name>
<email>christian@breunig.cc</email>
</author>
<published>2026-10-07T17:56:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-1x.git/commit/?id=c95aae771d74e11bedc095e92e4c38ce7d25fa59'/>
<id>urn:sha1:c95aae771d74e11bedc095e92e4c38ce7d25fa59</id>
<content type='text'>
An interface already in the mapping store is renamed by udev from the
generated link file as the device is added. Hardware the system has never
seen still has to be assigned a name and recorded, so run the naming pass
from a udev rule as well. It holds off until the boot-time configuration has
been applied, so the boot storm of add events costs nothing.

The rule matches on hardware rather than on its absence. A net device carries
no driver itself, it sits below the one that does, so the negative form was
true for every interface and skipped the very cards this exists for.
</content>
</entry>
</feed>
