* [PATCH 1/3] Handle upper case MAC addresses in ifname option
@ 2011-12-26 22:08 Anton Blanchard
2011-12-26 22:08 ` [PATCH 2/3] server-id in ip= is not optional Anton Blanchard
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Anton Blanchard @ 2011-12-26 22:08 UTC (permalink / raw)
To: initramfs-u79uwXL29TY76Z2rM5mHXA
[-- Attachment #1: udev_mac_lowercase.patch --]
[-- Type: text/plain, Size: 1798 bytes --]
While the documentation states that ifname MAC addresses must be
lower case, we silently accept upper case ones and fail later on
when udev doesn't rename the device.
Instead of adding sanity checking on the MAC address just convert
it to lower case and remove the requirement completely.
---
Index: dracut/modules.d/40network/parse-ifname.sh
===================================================================
--- dracut.orig/modules.d/40network/parse-ifname.sh 2011-12-27 09:01:08.000000000 +1100
+++ dracut/modules.d/40network/parse-ifname.sh 2011-12-27 09:02:05.420745541 +1100
@@ -25,7 +25,8 @@ parse_ifname_opts() {
case $# in
7)
ifname_if=$1
- ifname_mac=$2:$3:$4:$5:$6:$7
+ # udev requires MAC addresses to be lower case
+ ifname_mac=`echo $2:$3:$4:$5:$6:$7 | tr '[:upper:]' '[:lower:]'`
;;
*)
die "Invalid arguments for ifname="
Index: dracut/dracut.cmdline.7.xml
===================================================================
--- dracut.orig/dracut.cmdline.7.xml 2011-12-27 09:01:11.507776290 +1100
+++ dracut/dracut.cmdline.7.xml 2011-12-27 09:02:05.424745613 +1100
@@ -464,7 +464,6 @@ This parameter can be specified multiple
<term><envar>ifname=</envar><replaceable><interface></replaceable>:<replaceable><MAC></replaceable></term>
<listitem>
<para>Assign network device name <interface> (ie eth0) to the NIC with MAC <MAC>.
-Note letters in the MAC-address must be lowercase!
<remark>Note: If you use this option you <emphasis remap="B">must</emphasis> specify an ifname= argument for all interfaces used in ip= or fcoe= arguments.</remark>
This parameter can be specified multiple times.</para>
</listitem>
^ permalink raw reply [flat|nested] 7+ messages in thread* [PATCH 2/3] server-id in ip= is not optional
2011-12-26 22:08 [PATCH 1/3] Handle upper case MAC addresses in ifname option Anton Blanchard
@ 2011-12-26 22:08 ` Anton Blanchard
[not found] ` <20111226220903.656046366-eUNUBHrolfbYtjvyW6yDsg@public.gmane.org>
2011-12-26 22:08 ` [PATCH 3/3] ip= server-id should be server-IP Anton Blanchard
[not found] ` <20111226220903.564739340-eUNUBHrolfbYtjvyW6yDsg@public.gmane.org>
2 siblings, 1 reply; 7+ messages in thread
From: Anton Blanchard @ 2011-12-26 22:08 UTC (permalink / raw)
To: initramfs-u79uwXL29TY76Z2rM5mHXA
[-- Attachment #1: ip_not_optional.patch --]
[-- Type: text/plain, Size: 1451 bytes --]
The documentation suggests that server-id is an optional argument
but ip_to_var fails if it is not specified. Fix the documentation.
---
Index: dracut/dracut.cmdline.7.xml
===================================================================
--- dracut.orig/dracut.cmdline.7.xml 2011-12-27 09:02:05.424745613 +1100
+++ dracut/dracut.cmdline.7.xml 2011-12-27 09:02:31.321211186 +1100
@@ -452,9 +452,9 @@ with a valid DHCP root-path.</para>
</listitem>
</varlistentry>
<varlistentry>
- <term><envar>ip=</envar><replaceable><client-IP></replaceable>:<optional>
+ <term><envar>ip=</envar><replaceable><client-IP></replaceable>:
<replaceable><server-id></replaceable>
- </optional>:<replaceable><gateway-IP></replaceable>:<replaceable><netmask></replaceable>:<replaceable><client_hostname></replaceable>:<replaceable><interface></replaceable>:<replaceable>{none|off}</replaceable></term>
+ :<replaceable><gateway-IP></replaceable>:<replaceable><netmask></replaceable>:<replaceable><client_hostname></replaceable>:<replaceable><interface></replaceable>:<replaceable>{none|off}</replaceable></term>
<listitem>
<para>explicit network configuration. If you want do define a IPv6 address, put it in brackets (e.g. [2001:DB8::1]).
This parameter can be specified multiple times.</para>
^ permalink raw reply [flat|nested] 7+ messages in thread* [PATCH 3/3] ip= server-id should be server-IP
2011-12-26 22:08 [PATCH 1/3] Handle upper case MAC addresses in ifname option Anton Blanchard
2011-12-26 22:08 ` [PATCH 2/3] server-id in ip= is not optional Anton Blanchard
@ 2011-12-26 22:08 ` Anton Blanchard
[not found] ` <20111226220903.738439469-eUNUBHrolfbYtjvyW6yDsg@public.gmane.org>
[not found] ` <20111226220903.564739340-eUNUBHrolfbYtjvyW6yDsg@public.gmane.org>
2 siblings, 1 reply; 7+ messages in thread
From: Anton Blanchard @ 2011-12-26 22:08 UTC (permalink / raw)
To: initramfs-u79uwXL29TY76Z2rM5mHXA
[-- Attachment #1: fix_server_id.patch --]
[-- Type: text/plain, Size: 1793 bytes --]
From looking at the code it seems like server-id should really
be named server-IP.
---
Index: dracut/dracut.cmdline.7.xml
===================================================================
--- dracut.orig/dracut.cmdline.7.xml 2011-12-27 09:02:31.321211186 +1100
+++ dracut/dracut.cmdline.7.xml 2011-12-27 09:02:54.261623619 +1100
@@ -453,7 +453,7 @@ with a valid DHCP root-path.</para>
</varlistentry>
<varlistentry>
<term><envar>ip=</envar><replaceable><client-IP></replaceable>:
- <replaceable><server-id></replaceable>
+ <replaceable><server-IP></replaceable>
:<replaceable><gateway-IP></replaceable>:<replaceable><netmask></replaceable>:<replaceable><client_hostname></replaceable>:<replaceable><interface></replaceable>:<replaceable>{none|off}</replaceable></term>
<listitem>
<para>explicit network configuration. If you want do define a IPv6 address, put it in brackets (e.g. [2001:DB8::1]).
Index: dracut/modules.d/40network/parse-ip-opts.sh
===================================================================
--- dracut.orig/modules.d/40network/parse-ip-opts.sh 2011-12-27 09:01:07.000000000 +1100
+++ dracut/modules.d/40network/parse-ip-opts.sh 2011-12-27 09:02:54.261623619 +1100
@@ -7,7 +7,7 @@
#
# ip=<interface>:[dhcp|on|any]
#
-# ip=<client-IP-number>:<server-id>:<gateway-IP-number>:<netmask>:<client-hostname>:<interface>:[dhcp|on|any|none|off]
+# ip=<client-IP-number>:<server-IP-number>:<gateway-IP-number>:<netmask>:<client-hostname>:<interface>:[dhcp|on|any|none|off]
#
# When supplying more than only ip= line, <interface> is mandatory and
# bootdev= must contain the name of the primary interface to use for
^ permalink raw reply [flat|nested] 7+ messages in thread[parent not found: <20111226220903.564739340-eUNUBHrolfbYtjvyW6yDsg@public.gmane.org>]
end of thread, other threads:[~2012-01-23 11:05 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-26 22:08 [PATCH 1/3] Handle upper case MAC addresses in ifname option Anton Blanchard
2011-12-26 22:08 ` [PATCH 2/3] server-id in ip= is not optional Anton Blanchard
[not found] ` <20111226220903.656046366-eUNUBHrolfbYtjvyW6yDsg@public.gmane.org>
2012-01-23 11:05 ` Harald Hoyer
2011-12-26 22:08 ` [PATCH 3/3] ip= server-id should be server-IP Anton Blanchard
[not found] ` <20111226220903.738439469-eUNUBHrolfbYtjvyW6yDsg@public.gmane.org>
2012-01-23 11:05 ` Harald Hoyer
[not found] ` <20111226220903.564739340-eUNUBHrolfbYtjvyW6yDsg@public.gmane.org>
2011-12-29 9:06 ` [PATCH 1/3] Handle upper case MAC addresses in ifname option David Dillow
2012-01-23 11:04 ` Harald Hoyer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox