Commit c2d61ad
authored
Fix: Make the ifname of host-side part of vEth pair unique (#2570)
We have to connect the host-side part of a vEth pair to a Linux bridge
in a multi-access or multi-provider environment. To do that, we have to
have a unique host-side interface name, and the current mechanisms
failed for people who couldn't possibly make their node names unique in
the first 10 characters.
This fix replaces the 'use the node name prefix' trick that helped keep
the device name under 16 characters (until containerlab started using
long interface names for SR-SIM) with a totally cryptic interface name
that shouldn't exceed 16 characters unless you're doing something truly
crazy (for example, 8-digit multilab ID).
As we're not using the bridge-side interface names anywhere else in the
code ('netlab capture' command is started within the container NS),
this SHOULD NOT (BUT WHO KNOWS) affect anything else.
Fixes #25641 parent f34bc52 commit c2d61ad
1 file changed
+19
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
122 | | - | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
123 | 136 | | |
124 | 137 | | |
125 | 138 | | |
| |||
0 commit comments