Bug#824025: injecting boot parameters from packages (was Re: Bug#824025: udev: Please split rule for MAC-based name of USB network interface out of 73-special-net-names.rules)

Thorsten Glaser t.glaser at tarent.de
Thu Jun 2 16:49:06 BST 2016


(If you know of a better place to follow this up to, please do so!)

On Thu, 12 May 2016, Raphael Hertzog wrote:

> > I also changed the rule to be inert when "net.ifnames=0" is given on
> > the kernel command line, to be consistent with the *.link files:
> 
> Excellent idea. I even wanted to use this at some point but we lack a good
> way to inject kernel boot parameters through packages IIRC.

This sounds just wrong to me – this isn’t a kernel parameter, after
all, just passed on the kernel command line to init, for convenience.

I think it could be possible to have an /etc/profile.d/-like structure
somewhere in the filesystem that is read at some point during boot,
probably in the initrd considering how much is done in it currently
(unclear if it has to be copied to the initrd for this, or if it’s
sufficient to do that after mounting the root… probably copied, to
take NFS root into account), whose contents are then added to “the
init environment” to act exactly the same as kernel parameters that
are passed to userspace.

Of course, this requires all users to use the environment instead of
reading /proc/cmdline directly, but that’s, after all, the way it’s
supposed to be used in the first place anyway.

bye,
//mirabilos
-- 
>> Why don't you use JavaScript? I also don't like enabling JavaScript in
> Because I use lynx as browser.
+1
	-- Octavio Alvarez, me and ⡍⠁⠗⠊⠕ (Mario Lang) on debian-devel




More information about the Pkg-systemd-maintainers mailing list