Before we check if dad is done we should first make sure,
that there is a link local address where we do the check.
Due to this issue, on ipv6 only setups sometimes dhclient started
asking for ip address, before the link local address was present
and failed immediately.
busybox seems to not properly support this option,
and it can be be safely ommitted or replaced
with piping the output through head.
Rev 2:
* rebased on master
* addressed open points from review
In kdump, if dump-target is ssh on ipv6, we need to sync until ipv6 addr
is ready. Currently ip=auto6/dhcp6 provides such function. But in 1st kernel,
it is hard to know whether the ipv6 addr is got by dhcpv6 or SLAAC.
E.g ifcfg-eth* contains DHCPV6C=yes direction, but there is no dhcpv6
server in the network, and then after the system is up, the user
echo 1 > /proc/sys/net/ipv6/conf/eth0/autoconf && accept_ra by manual
to obtain a ipv6 addr. Or vice.
So this patch suggests to make dhcpv6 as auto6 fallback
Signed-off-by: Pingfan Liu <piliu@redhat.com>
Install ifcfg-* files with team configuration in the initramfs.
Improve the slave configuration of the team interface, by looking up
ifcfg files in the initramfs.
Create a default loadbalance team config, if none present in the
initramfs.
forward port of
4c88c2859e
ip=2620:0052:0000:2220:0226:b9ff:fe81:cde4::[2620:0052:0000:2220:0000:0000:0000:03fe]:64::ibft0:none
should be
ip=[2620:0052:0000:2220:0226:b9ff:fe81:cde4]::[2620:0052:0000:2220:0000:0000:0000:03fe]:64::ibft0:none
https://bugzilla.redhat.com/show_bug.cgi?id=1322592#c19
(cherry picked from commit b8e6c051c6)
IPv6 addresses should be specified in brackets so that the
ip= scanning code doesn't get confused.
References: bnc#887542
Signed-off-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Thomas Renninger <trenn@suse.com>
Users can pass the DNS information throught "nameserver=" cmdline,
there maybe duplicated inputs.
"/etc/resolv.conf" have some restrictions on the number of DNS items
effective, so make sure that this file contains no duplicated items.
We achieve this by simply making the file have no duplicated lines.
Signed-off-by: Xunlei Pang <xlpang@redhat.com>
rename iface_has_link() to iface_has_carrier() to clarify usage
Only assign static "wildcard interface" settings, if the interface has a
carrier.
If the interface name was specified with a name, do not do carrier
checking for static configurations.
all_ifaces_up() is true, if all interfaces are up.
all_ifaces_setup() is true, if all interfaces are up and the gateways
and nameserver are setup.
(cherry picked from commit 63e75dc4cd)
rd.net.dhcp.retry=<cnt>
If this option is set, dracut will try to connect via dhcp
<cnt> times before failing. Default is 1.
rd.net.timeout.dhcp=<arg>
If this option is set, dhclient is called with "-timeout <arg>".
rd.net.timeout.iflink=<seconds>
Wait <seconds> until link shows up. Default is 60 seconds.
rd.net.timeout.ifup=<seconds>
Wait <seconds> until link has state "UP". Default is 20 seconds.
rd.net.timeout.route=<seconds>
Wait <seconds> until route shows up. Default is 20 seconds.
rd.net.timeout.ipv6dad=<seconds>
Wait <seconds> until IPv6 DAD is finished. Default is 50 seconds.
rd.net.timeout.ipv6auto=<seconds>
Wait <seconds> until IPv6 automatic addresses are assigned.
Default is 40 seconds.
rd.net.timeout.carrier=<seconds>
Wait <seconds> until carrier is recognized. Default is 5 seconds.
(cherry picked from commit d8ad687e1a)
Some hosting providers need a static route set in order to be
able to reach the default gateway. Be sure to retry adding
the default gateway after setting the static routes.
For targets with colons in the iSCSI target name:
"iqn.2000-09.com.foo:storage-system.e2000:00000001cm1p1"
the parser was confused with the optional iscsi_iface_name and
iscsi_netdev_name.
This patch reintroduces the old IQN, EUI and NAA parsing and enhances
the fallback parser by checking the LUN for a numerical value.
In the judgment sentence, it will print the following warning message,
becasuse of lacking the blank on the left of ']'.
/lib/net-lib.sh: line 110: [: missing `]'
Signed-off-by: Minfei Huang <mhuang@redhat.com>
When installing OS to a VLAN enabled iscsi LUN (extracted from iBFT), "/tmp/net.{xyz}.has_ibft_config" is not being set properly.
Then anaconda installer requires 'BOOTPROTO="ibft"' populated in ifcfg of the vlan interface (ex: ibft0.20), for it to properly populate the kernel parameters post installation. The setting 'BOOTPROTO="ibft"' is populated by write-ifcfg.sh script only if the corresponding interface has a file /tmp/net.{xyz}.has_inft_config
To get around this issue, in ibft_to_cmdline() function in net-lib.sh file, I made the following changes to populate the has_ibft_config file for the vlan interface(ex: ibft0.20):
By convention, strstr should be a literal string match. Previously, it
would match as a glob pattern. Some code used that, so add new
functions strglob and strglobin to do what that code expects, and
specify them tightly too. strglob tests whether the glob pattern
matches the entire string (the name strglob is also used in the yorick
language, and that's what it does there), while strglobin tests whether
the glob pattern matches anywhere in the string.
Also tightens str_starts, str_ends, and str_replace to deal with
literal strings only. In a quick grep I did not find code that depended
on these functions matching globs.
Changes the call sites where strstr was used with glob patterns to use
strglobin or strglob as the intention seemed to be (or, in one case,
strstr with the * removed as it did not affect the result anyway).