Comment 0 for bug 1402042

Revision history for this message
Scott Moser (smoser) wrote :

Kernel documentation at https://www.kernel.org/doc/Documentation/kernel-parameters.txt says:
 | The kernel parses parameters from the kernel command line up to "--";
 | if it doesn't recognize a parameter and it doesn't contain a '.', the
 | parameter gets passed to init: parameters with '=' go into init's
 | environment, others are passed as command line arguments to init.
 | Everything after "--" is passed as an argument to init.

In my experience that was never true, and I can reproduce the kernel paying
attention to a command line like:
  -- root=LABEL=cloudimg-rootfs ro console=ttyS0

and the system booting fine, and with data ton ttyS0 on a 3.13 (trusty) kernel.

The fun begins a 3.16 (utopic/hwe-u) where the kernel documentation quoted above seems to be valid.

Currently maas is takes global command line parameters (as set via 'maas admin set-config name=kernel_opts value="console=ttyS0"') and places them after a '--' in during commissioning and curtin install (and i believe d-i install).

The end result is that setting console=ttyS0 as kernel parameters does not work with 3.16 in the commissioning and install environment.

Curtin (in following with convention I believe to be true in 'd-i' ) will copy parameters after a '--' to the installed system. So, the installed system works fine, but the install and commissioning is 'blind'.

There are 2 solutions here:
 a.) put kernel flags twice (both before and after a '--')
    this could in the future make systemd unhappy as those would then turn into flags to systemd.
 b.) put kernel flags only before and find another way to pass to curtin or d-i

Joy.