initramfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: LAHAYE Olivier <olivier.lahaye-KCE40YydGKI@public.gmane.org>
To: "initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
	<initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: Dracut network on CentOS-8.1 (NetworkManager)
Date: Wed, 4 Mar 2020 13:42:49 +0000	[thread overview]
Message-ID: <D840ECAC-1ECA-4F9D-A01C-136FCD7A467E@cea.fr> (raw)

Hi,
 
As SystemImager developer I’m heavily using dracut to generate the imager. (SystemImager is a software aimed at cluster nodes images deployment)
 
I’ve just discovered that in CentOS-8.1, the 40network dracut module is now splitted in 35network-legacy and 35network-manager.
 
My systemimager dracut module used to requires network, and did use net-lib.sh to retrieve some network informations. It did also use /tmp/net.ifaces that is also used by net-lib.sh. It was also heavily using /tmp/dhclient.$DEVICE.dhcpopts or /tmp/net.$DEVICE.override /tmp/leaseinfo.$DEVICE.dhcp.ipv4 in a initqueue/online hook ($DEVICE is $1 in this hook)
 
Now that 40network uses by default 35network-manager, all is broken:
• Net-lib.sh  (from 40network) that uses /tmp/net.ifaces is broken. (e.g. configured_ifaces() returns nothing).
• /tmp/dhclient.$DEVICE.dhcpopts or /tmp/net.$DEVICE.override don’t exists anymore
 
My question is thus simple:
• Will you fix net-lib.sh? (or will it move to 35network-legacy?)
• How do I retrieve DHCP specific custom fields like $new_option_144 that was present in /tmp/dhclient.*.dhcpopts?
o Note: on SuSE, I was using /tmp/leaseinfo.$DEVICE.dhcp.ipv4)
o Ideally, is there an equivalent of /etc/*dhcpopts or /etc/*override that could be sourced and that would define device relevant informations?
 
Note:s 
•  need to keep compatibility with CentOS-6, CentOS-7, SuSE, …
• I’d like to avoid 35network-legacy as it won’t last forever and after imaging, I give control back to system and finish to boot the just installed OS without rebooting. Using legacy-network would prevent doing direct boot.
• At minimum, I need to get needed infos for creating the ifcfg file. I also need to know the dhcp server ip (if using dhcp) and getting options would let mee keep compatibility with old systemimager.
 
Any help would be greatly appreciated as for now I don’t see a clean way to handle the change. (nmcli doesn’t work as it doesn’t run as a daemon when initqueue/online hook is triggered)
 
SystemImager dracut module can be found here: https://github.com/finley/SystemImager/tree/SystemImager-NG/lib/dracut/modules.d/51systemimager
 
Best regards,
 
Olivier.

PS: I've found this https://bugzilla.redhat.com/show_bug.cgi?id=1727904 and I'm afraid to be stuck :-/
-- 
Olivier LAHAYE
 


                 reply	other threads:[~2020-03-04 13:42 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=D840ECAC-1ECA-4F9D-A01C-136FCD7A467E@cea.fr \
    --to=olivier.lahaye-kce40yydgki@public.gmane.org \
    --cc=initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).