yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #91487
[Bug 2011298] [NEW] network config can't override kernel command line arguments
Public bug reported:
This isn't really a bug, it's more of a missing functionality.
The quick description is that if you specify the network configuration
by a kernel command line parameter (`ip=blahblahblah`), there doesn't
appear to be a way to override it by defining a different network setup
in cloud-init. The kernel command line will always take precedence no
matter what you define in `meta-data` or `user-data`.
This is the conclusion I drew both from the documentation, as well as by
looking at the source on GitHub. The kernel command line has absolute
priority and can't be overriden. I found a workaround, by writing the
config file (`/etc/netplan/50-cloud-init.yml` in my case) directly
through "write_files" and then executing "netplan apply" in "runcmd".
This does what I want, but it doesn't look nice.
Perhaps you're wondering why I need this. I boot ubuntu MAAS images over
network. In some data centers DHCP isn't available and at the same time
I need to assign more than one IP address to the system, and/or
configure bonding. So the bootloader constructs the kernel command line,
the machine boots, but only has one ethernet interface configured, with
one IP address. I can't remove the kernel command line argument, as then
cloud-init doesn't know how to configure the network in order to
download the `user-data` / `meta-data`.
Please consider providing an alternative approach to the workaround I
explained above.
** Affects: cloud-init
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to cloud-init.
https://bugs.launchpad.net/bugs/2011298
Title:
network config can't override kernel command line arguments
Status in cloud-init:
New
Bug description:
This isn't really a bug, it's more of a missing functionality.
The quick description is that if you specify the network configuration
by a kernel command line parameter (`ip=blahblahblah`), there doesn't
appear to be a way to override it by defining a different network
setup in cloud-init. The kernel command line will always take
precedence no matter what you define in `meta-data` or `user-data`.
This is the conclusion I drew both from the documentation, as well as
by looking at the source on GitHub. The kernel command line has
absolute priority and can't be overriden. I found a workaround, by
writing the config file (`/etc/netplan/50-cloud-init.yml` in my case)
directly through "write_files" and then executing "netplan apply" in
"runcmd". This does what I want, but it doesn't look nice.
Perhaps you're wondering why I need this. I boot ubuntu MAAS images
over network. In some data centers DHCP isn't available and at the
same time I need to assign more than one IP address to the system,
and/or configure bonding. So the bootloader constructs the kernel
command line, the machine boots, but only has one ethernet interface
configured, with one IP address. I can't remove the kernel command
line argument, as then cloud-init doesn't know how to configure the
network in order to download the `user-data` / `meta-data`.
Please consider providing an alternative approach to the workaround I
explained above.
To manage notifications about this bug go to:
https://bugs.launchpad.net/cloud-init/+bug/2011298/+subscriptions
Follow ups