1 |
Neil Bothwick <neil@××××××××××.uk> writes: |
2 |
|
3 |
> On Thu, 22 Dec 2016 04:15:50 +0100, lee wrote: |
4 |
> |
5 |
>> > There are no config files to edit with the predictable names, the |
6 |
>> > names are created from the physical location of the port. That's why |
7 |
>> > they are called predictable, |
8 |
>> |
9 |
>> I only know what the names are when I can look them up when the computer |
10 |
>> is running. I don't call that "predictable". |
11 |
> |
12 |
> If they are constructed according to specific rules, they are |
13 |
> predictable, by definition. |
14 |
|
15 |
You're overlooking that you need to know exactly, in advance, what the |
16 |
rules are applied to, and all the rules, for having a chance that your |
17 |
prediction turns out to be correct. Provided you know all that, you can |
18 |
predict the universe, assuming that everything always goes according to |
19 |
rules. You can not prove that it does and only disprove that it does |
20 |
when you find a case in which it doesn't. So what's your definition and |
21 |
your predictions worth? |
22 |
|
23 |
>> They were much more predictable before because I could be reasonably |
24 |
>> sure that each of the ports would be called 'ethN', starting with N = 0, |
25 |
> "Reasonably sure" is not predictable. |
26 |
|
27 |
It's still better than something entirely unpredictable. |
28 |
|
29 |
Show me that the names are predictable by writing them down, then |
30 |
grabbing an arbitrary computer and plugging in a network card the |
31 |
port(s) of which will then have the names you wrote down. |
32 |
|
33 |
> A lot of this stuff is designed to |
34 |
> make automated management easier, so editing rules or config files is |
35 |
> undesirable. It is more about being able to automatically provision and |
36 |
> configure new systems, whether hardware or virtual. |
37 |
|
38 |
How does it help with that? Wouldn't it help even more if you could |
39 |
just give them the names you wanted them to have? |
40 |
|
41 |
Like if you have N machines with an interface each you want to do |
42 |
something with, the only thing you'd have to do is make sure that this |
43 |
interface gets the right name assigned. |
44 |
|
45 |
With unrecognisable names, the interface can still have a different name |
46 |
on each machine. What's the advantage of that? |
47 |
|
48 |
>> unless I changed a card for a different one after an udev rule had |
49 |
>> already been created. |
50 |
> |
51 |
> and being able to make changes without messing with the rest of your |
52 |
> system. I stand by my previous analogy of disk devices nodes vs UUIDs. |
53 |
|
54 |
Are they predictable? |
55 |
|
56 |
> One is readable the other is safe. Yes, you can use filesystem labels, |
57 |
> which can be both, but that requires intervention, just like your udev |
58 |
> rules. That doesn't make either approach wrong, just suited to different |
59 |
> purposes. |
60 |
|
61 |
And I would find it much better if network ports had recognisable names |
62 |
without intervention. |
63 |
|
64 |
>> > unless you move the NIC to a different PCI slot, it will always have |
65 |
>> > the same name, no matter what other hardware you add or remove. Yes, |
66 |
>> > the names are cumbersome, but they have to be like that to guarantee |
67 |
>> > their uniqueness. |
68 |
>> |
69 |
>> You don't need to defend the unrecognisable names. The names used for |
70 |
>> referring to network ports don't need to be like that. |
71 |
> |
72 |
> No they don't. It is merely one solution to the problem, and the names |
73 |
> are recognisable, Alan posted the key earlier. They are complex and may |
74 |
> look cryptic until you understand them, but so is English. |
75 |
|
76 |
They don't become any more recognisable by knowing the rules. They |
77 |
simply remain a combination of letters and numbers which is difficult to |
78 |
recognise. |
79 |
|
80 |
>> The perceived advantage lies in being able to refer to network ports in |
81 |
>> a more reliable way, and I don't see how using unrecognisable names |
82 |
>> instead of recognisable ones would make anything easier. |
83 |
> |
84 |
> See above re automation. It doesn't really matter whether you see the |
85 |
> need or not. If you don't have the need, don't use it, they are an |
86 |
> option for those who do want them. |
87 |
|
88 |
Unfortunately, that option has been made the default. |
89 |
|
90 |
>> It would have made things easier if the problem had been solved by |
91 |
>> giving them recognisable names (or aliases) by default --- or even if |
92 |
>> the default names (aliases) were the same as the unrecognisable names |
93 |
>> --- and allowing to easily configure the names (aliases) actually used |
94 |
>> to refer to the ports. |
95 |
> |
96 |
> That's a good point, and surely doable with udev rules, making the whole |
97 |
> argument moot. I haven't investigated because I don't have the need, but |
98 |
> I would be interested to hear what you discover. |
99 |
> and not that unrecognisable once you understand the systax. |
100 |
|
101 |
I haven't investigated either because I figured there isn't much point |
102 |
in it because if I wanted recognisable names, I would have to put some |
103 |
extra work into every machine, which isn't a good option. In the long |
104 |
run, it might be less time consuming to use recognisable names, but who |
105 |
knows if there isn't going to be yet another change, defeating a way I |
106 |
might have found to get such names back. |
107 |
|
108 |
>> Being able to refer to things in more reliable ways improves the quality |
109 |
>> of the software. Using unrecognisable names for things reduces the |
110 |
>> quality. |
111 |
> |
112 |
> They are reliable, unlike your "reasonably sure" approach, |
113 |
|
114 |
I never said they aren't. I don't see them as more reliable, either, |
115 |
not for any practical purposes. Technically, they might be more |
116 |
reliable, but it doesn't matter to me. |
117 |
|
118 |
>> This is like you're defending a type of new pliers. |
119 |
> |
120 |
> I'm not so much defending them and expressing an opinion. I can see the |
121 |
> benefits and the drawbacks. They are an option, albeit one that is turned |
122 |
> on by default (but since when have Gentoo users ever been bothered about |
123 |
> upstream defaults?). Portage even gives you explicit instuctions on how |
124 |
> to permanently disable them with a single command, although I generally |
125 |
> use the net.ifnames=0 kernel option instead on single NIC machines, where |
126 |
> the feature is pointless. |
127 |
|
128 |
I didn't see portage or anything else give me any instructions or |
129 |
warnings about this. The names just suddenly changed, and that screwed |
130 |
things up. |
131 |
|
132 |
>> But who knows, perhaps it is now possible to easily, on the fly, name |
133 |
>> the network ports through a neat configuration file. I'm merely asking |
134 |
>> if there is because I don't know and would find that very useful. |
135 |
> |
136 |
> Can't ifrename do what you want? |
137 |
|
138 |
Dunno, I haven't heard of it before, it doesn't seem to be installed, |
139 |
and eix shows no hits for it. |
140 |
|
141 |
>> > How often you you have to type interface names anyway, and how many of |
142 |
>> > those are in a shell with tab completion that takes care of it for |
143 |
>> > you? |
144 |
>> |
145 |
>> None of them are, and I don't type the names. They require copy and |
146 |
>> paste, or very careful and tedious typing after looking them up. |
147 |
> |
148 |
> Well, if you're scripting them, you only need to do it once per |
149 |
> interface, surely? That might be less work that setting up ifrename, but |
150 |
> use whatever works for you, your choices include, but are not restricted |
151 |
> to, and in no particular order. |
152 |
|
153 |
The issue comes up every now and then when I need to do something with |
154 |
network interfaces. The unrecognisable names waste my time because they |
155 |
are unrecognisable, and that's really all they do for me. |
156 |
|
157 |
> Learn how the predictable names work |
158 |
> Disable the feature entirely and hope the eth0 names work as expected |
159 |
> Use udev rules |
160 |
> Use ifrename |
161 |
> Some combination of the above. |