]> git.ipfire.org Git - thirdparty/dracut.git/log
thirdparty/dracut.git
9 years agoGenerate reproducible initramfs images
Harald Hoyer [Thu, 3 Jul 2014 10:52:58 +0000 (12:52 +0200)] 
Generate reproducible initramfs images

With the same source of files, it should be possible to generate the
same image file with every dracut run.

To accomplish this, we modify the timestamps of the files we generate at
runtime, call gzip with "-n" and cpio with "--reproducible".

The cpio --reproducible option is not yet upstream though, so if you
feel like it should be then please nag at the cpio mailing list.
http://lists.gnu.org/archive/html/bug-cpio/2014-08/msg00000.html

9 years agodracut-functions.sh:get_persistent_dev(): use printf, instead of echo
Harald Hoyer [Fri, 15 Aug 2014 10:36:04 +0000 (12:36 +0200)] 
dracut-functions.sh:get_persistent_dev(): use printf, instead of echo

9 years agoIntroduce ARM specific modules needed by drm
Nicolas Chauvet [Mon, 4 Aug 2014 20:04:39 +0000 (22:04 +0200)] 
Introduce ARM specific modules needed by drm

9 years agoCategorize needed modules on ARM
Nicolas Chauvet [Mon, 4 Aug 2014 20:04:38 +0000 (22:04 +0200)] 
Categorize needed modules on ARM

9 years agoTest soc path for modalias needed by drm
Nicolas Chauvet [Mon, 4 Aug 2014 20:04:37 +0000 (22:04 +0200)] 
Test soc path for modalias needed by drm

On ARM, both pci and soc path can be tested for drm.

With this patchset, that was missing in recent kernel,
the tegra_drm case is not needed anymore:
http://patchwork.ozlabs.org/patch/361765/
http://www.spinics.net/lists/linux-tegra/msg17948.html

9 years agodracut-functions: get_persistent_dev() fall back to the original name
WANG Chao [Mon, 28 Jul 2014 14:26:28 +0000 (22:26 +0800)] 
dracut-functions: get_persistent_dev() fall back to the original name

In case of raw disk/partition, ex. /dev/vda1, which doesn't contain any
filesystem on it. get_persistent_dev() would return empty. Now fix it to
return its original name, /dev/vda1 in above case. So that we don't have
to check its return string every time.

Signed-off-by: WANG Chao <chaowang@redhat.com>
9 years agodracut.usage.asc: also add a link for RHEL-7 storage admin guide
Harald Hoyer [Fri, 15 Aug 2014 09:50:31 +0000 (11:50 +0200)] 
dracut.usage.asc: also add a link for RHEL-7 storage admin guide

9 years agodracut.usage.asc: extend parameters for shutdown debug procedure
Harald Hoyer [Fri, 15 Aug 2014 09:44:26 +0000 (11:44 +0200)] 
dracut.usage.asc: extend parameters for shutdown debug procedure

9 years agoi18n: check for $i18n_install_all == "yes" rather than being set
Harald Hoyer [Thu, 14 Aug 2014 10:56:53 +0000 (12:56 +0200)] 
i18n: check for $i18n_install_all == "yes" rather than being set

i18n_install_all="no" does not have the expected effect without this
patch

9 years agobridging: update the ifcfg files generated for bridge slaves
Alex Harpin [Sat, 2 Aug 2014 19:08:25 +0000 (20:08 +0100)] 
bridging: update the ifcfg files generated for bridge slaves

Update the ifcfg files generated for bridge slaves so they reference
the bridge they are part of.  Related to early patch submitted as a
fix for Bug #1123552.

Bug #1123552 https://bugzilla.redhat.com/show_bug.cgi?id=1123552

9 years agotest: make testsuite work with the new systemd minimal root req
Harald Hoyer [Fri, 8 Aug 2014 11:34:04 +0000 (13:34 +0200)] 
test: make testsuite work with the new systemd minimal root req

systemd needs more directories to switch root

9 years agofixed bridge setup
Harald Hoyer [Fri, 1 Aug 2014 11:16:29 +0000 (13:16 +0200)] 
fixed bridge setup

renamed "ethnames" in bridge.info to "bridgeslaves"

fixed ifcfg generation

9 years agoTEST-20-NFS: add more commands and fix client root dirs
Harald Hoyer [Fri, 1 Aug 2014 11:15:44 +0000 (13:15 +0200)] 
TEST-20-NFS: add more commands and fix client root dirs

9 years agoTEST-20-NFS:client-init.sh: add shell on rd.shell
Harald Hoyer [Fri, 1 Aug 2014 11:15:05 +0000 (13:15 +0200)] 
TEST-20-NFS:client-init.sh: add shell on rd.shell

9 years agoNEWS: update
Harald Hoyer [Tue, 29 Jul 2014 09:04:09 +0000 (11:04 +0200)] 
NEWS: update

9 years agodracut.spec: fixed license file packaging
Harald Hoyer [Thu, 24 Jul 2014 12:47:14 +0000 (14:47 +0200)] 
dracut.spec: fixed license file packaging

9 years agodracut.sh: add DRACUT_PATH
Harald Hoyer [Tue, 22 Jul 2014 12:43:33 +0000 (14:43 +0200)] 
dracut.sh: add DRACUT_PATH

DRACUT_PATH can now be used to specify the PATH used by dracut
to search for binaries instead of the default
/usr/sbin:/sbin:/usr/bin:/bin

This should be set in the distribution config file
/usr/lib/dracut/dracut.conf.d/01-dist.conf

9 years agotest/TEST-30-ISCSI: add rd.shell to client root
Harald Hoyer [Tue, 22 Jul 2014 12:22:21 +0000 (14:22 +0200)] 
test/TEST-30-ISCSI: add rd.shell to client root

9 years agoadd "--install-optional" and install_optional_items
Harald Hoyer [Tue, 22 Jul 2014 12:09:06 +0000 (14:09 +0200)] 
add "--install-optional" and install_optional_items

9 years agonetwork: add rd.route parameter
Harald Hoyer [Tue, 22 Jul 2014 09:03:56 +0000 (11:03 +0200)] 
network: add rd.route parameter

9 years agobase/dracut-lib:pidof() turn off debugging
Harald Hoyer [Tue, 22 Jul 2014 09:51:08 +0000 (11:51 +0200)] 
base/dracut-lib:pidof() turn off debugging

9 years agoARM: update modules for ARM host only options
Peter Robinson [Sun, 20 Jul 2014 21:20:04 +0000 (22:20 +0100)] 
ARM: update modules for ARM host only options

9 years agodracut-functions.sh: fix inst*() functions for "-H" handling
Harald Hoyer [Mon, 21 Jul 2014 14:58:15 +0000 (16:58 +0200)] 
dracut-functions.sh: fix inst*() functions for "-H" handling

because some inst*() functions check the existance of the source files
and do not know about the "-H" option, some failed to install the
hostonly files.

9 years agoInstalling an OS with VLAN enabled to an ISCSI LUN (from ibft)
Praveen_Paladugu@Dell.com [Tue, 10 Jun 2014 15:35:16 +0000 (10:35 -0500)] 
Installing an OS with VLAN enabled to an ISCSI LUN (from ibft)

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):

9 years agodracut-functions.sh: speed up ldconfig_paths()
Harald Hoyer [Tue, 8 Jul 2014 10:54:21 +0000 (12:54 +0200)] 
dracut-functions.sh: speed up ldconfig_paths()

9 years agoplymouth: also find the pkglibdir on debian
Harald Hoyer [Tue, 8 Jul 2014 09:50:51 +0000 (11:50 +0200)] 
plymouth: also find the pkglibdir on debian

9 years agodracut.sh: always copy prelink files in FIPS mode
Harald Hoyer [Tue, 8 Jul 2014 09:50:04 +0000 (11:50 +0200)] 
dracut.sh: always copy prelink files in FIPS mode

regardless of the the prelink={yes|no} switch

9 years agolvm:module-setup.sh: check for existance of 69-dm-lvm-metad.rules
Harald Hoyer [Thu, 3 Jul 2014 13:04:17 +0000 (15:04 +0200)] 
lvm:module-setup.sh: check for existance of 69-dm-lvm-metad.rules

fixup for 12819a579900b9691e2bfaf14e76fbb025851530

9 years agomodsign: do not hardcode path to keyctl
Alexander Tsoy [Mon, 31 Mar 2014 13:56:13 +0000 (17:56 +0400)] 
modsign: do not hardcode path to keyctl

https://bugs.gentoo.org/show_bug.cgi?id=506094

9 years agoNEWS: update for version 038 038
Harald Hoyer [Tue, 24 Jun 2014 16:09:07 +0000 (18:09 +0200)] 
NEWS: update for version 038

9 years agoTEST-15-BTRFSRAID: install /etc/os-release
Harald Hoyer [Mon, 30 Jun 2014 09:29:56 +0000 (11:29 +0200)] 
TEST-15-BTRFSRAID: install /etc/os-release

makes systemd switch-root happy

9 years agotest: add udev settle after sfdisk
Harald Hoyer [Mon, 30 Jun 2014 09:29:37 +0000 (11:29 +0200)] 
test: add udev settle after sfdisk

9 years agoifcfg: depends on network
Harald Hoyer [Mon, 30 Jun 2014 09:28:08 +0000 (11:28 +0200)] 
ifcfg: depends on network

9 years agobase/init.sh: use loop counter with unique varname
Harald Hoyer [Fri, 27 Jun 2014 16:05:37 +0000 (18:05 +0200)] 
base/init.sh: use loop counter with unique varname

$i can be polluted too easily

9 years agoresume: only install hostonly files, if in hostonly mode
Harald Hoyer [Fri, 27 Jun 2014 10:47:56 +0000 (12:47 +0200)] 
resume: only install hostonly files, if in hostonly mode

9 years agoAdd "rd.cmdline=ask" kernel command line parameter
Harald Hoyer [Fri, 27 Jun 2014 10:02:14 +0000 (12:02 +0200)] 
Add "rd.cmdline=ask" kernel command line parameter

prompts the user for additional kernel command line parameters

9 years agodefault to hostonly_cmdline=yes, if hostonly
Harald Hoyer [Wed, 25 Jun 2014 14:54:04 +0000 (16:54 +0200)] 
default to hostonly_cmdline=yes, if hostonly

if hostonly_cmdline is not yet set, set it to "yes", if in hostonly
mode.

9 years agokernel-modules: add tegra arm modules
Harald Hoyer [Wed, 25 Jun 2014 10:02:30 +0000 (12:02 +0200)] 
kernel-modules: add tegra arm modules

9 years agoTEST-04-FULL-SYSTEMD/test.sh: removed debug comments
Harald Hoyer [Wed, 25 Jun 2014 09:45:42 +0000 (11:45 +0200)] 
TEST-04-FULL-SYSTEMD/test.sh: removed debug comments

9 years agoprint out, what kernel command line parameters are used
Harald Hoyer [Tue, 24 Jun 2014 16:55:49 +0000 (18:55 +0200)] 
print out, what kernel command line parameters are used

9 years agousable_root(): only check for ld-*.so
Harald Hoyer [Tue, 24 Jun 2014 16:54:35 +0000 (18:54 +0200)] 
usable_root(): only check for ld-*.so

current systemd allows booting with only /usr on the root partition

see, if we can find an elf loader

9 years agoAdd rd.hostonly kernel command line parameters
Harald Hoyer [Tue, 24 Jun 2014 16:13:28 +0000 (18:13 +0200)] 
Add rd.hostonly kernel command line parameters

rd.hostonly=0 will remove all configuration compiled in the initramfs
from the host on which it was build

9 years agoMakefile: add debugtestimage and debughostimage targets
Harald Hoyer [Tue, 24 Jun 2014 16:12:04 +0000 (18:12 +0200)] 
Makefile: add debugtestimage and debughostimage targets

9 years agoinstall: add -H flag for install
Harald Hoyer [Tue, 24 Jun 2014 16:11:47 +0000 (18:11 +0200)] 
install: add -H flag for install

inst* functions and dracut-install now accept the "-H" flag, which
logs all installed files to /lib/dracut/hostonly-files. This is used
to remove those files, if rd.hostonly is given on the kernel command line.

9 years agolsinird: Adding option "-m|--mod" to list dracut modules in the image
Hari Bathini [Mon, 2 Jun 2014 10:57:37 +0000 (16:27 +0530)] 
lsinird: Adding option "-m|--mod" to list dracut modules in the image

This patch adds option "-m|--mod" to lsinitrd to list dracut
modules in the image  because sometimes  having an option to
only list the dracut modules in the image could be handy.

Sample output:
--------------

[hbathini@localhost dracut]$ sudo ./lsinitrd.sh initramfs-3.11.10-100.fc18.x86_64.img -m
Image: initramfs-3.11.10-100.fc18.x86_64.img: 33M
========================================================================
Version: dracut-029-1.fc18.2

dracut modules:
i18n
network
ifcfg
drm
plymouth
btrfs
crypt
dm
dmraid
kernel-modules
lvm
mdraid
cifs
iscsi
nfs
resume
rootfs-block
terminfo
udev-rules
biosdevname
systemd
usrmount
base
fs-lib
shutdown
========================================================================

Signed-off-by: Hari Bathini <hbathini@linux.vnet.ibm.com>
9 years agolsinitrd.sh: don't choke on LZO-compressed images
Tobias Geerinckx [Tue, 3 Jun 2014 02:59:34 +0000 (04:59 +0200)] 
lsinitrd.sh: don't choke on LZO-compressed images

lsinitrd (and hence dracut) currently fail to list the contents of any
LZO-compressed image, and merely spit out misleading xzcat errors.

I guess no-one actually uses them.

9 years ago98systemd: also install systemd-journald-dev-log.socket
Daniel Schaal [Thu, 19 Jun 2014 09:38:25 +0000 (11:38 +0200)] 
98systemd: also install systemd-journald-dev-log.socket

The /dev/log socket was moved to /run on systemd 214, install the
newly added socket unit.

9 years agosystemd: Optionally, include efivarsfs module
Cristian Rodríguez [Mon, 16 Jun 2014 05:13:44 +0000 (01:13 -0400)] 
systemd: Optionally, include efivarsfs module

It is, however not an error if this module can't be found.

9 years agodeprecate "ip=ibft" kernel command line parameter
Harald Hoyer [Fri, 20 Jun 2014 12:27:09 +0000 (14:27 +0200)] 
deprecate "ip=ibft" kernel command line parameter

rd.iscsi.ibft[=1] should be used instead.

Thing is, 'ip=ibft' is not really an ip setting, but rather a marker
that iBFT should be evaluated.

Also removed the trigger of the warning:
"Warning: Please supply bootdev argument for multiple ip= lines"

9 years agodracut.sh: add libgcc_s, if libpthread is installed
Harald Hoyer [Fri, 20 Jun 2014 09:19:49 +0000 (11:19 +0200)] 
dracut.sh: add libgcc_s, if libpthread is installed

workaround the fact, that pthread_cancel() wants to
dlopen libgcc_s.so.1

9 years agoiscsi: correctly install the settled iscsiroot dummy call
Harald Hoyer [Wed, 11 Jun 2014 12:58:55 +0000 (14:58 +0200)] 
iscsi: correctly install the settled iscsiroot dummy call

initqueue parses $1 as the executable command

9 years agoiscsi: correctly install the timeout iscsiroot dummy call
Harald Hoyer [Wed, 11 Jun 2014 12:55:11 +0000 (14:55 +0200)] 
iscsi: correctly install the timeout iscsiroot dummy call

initqueue parses $1 as the executable command

9 years agoudev-rules: add uaccess rules
Harald Hoyer [Thu, 5 Jun 2014 10:30:22 +0000 (12:30 +0200)] 
udev-rules: add uaccess rules

plymouth needs the seat rules, also without systemd

9 years agoudev-rules: added seat rules
Harald Hoyer [Wed, 4 Jun 2014 11:26:08 +0000 (13:26 +0200)] 
udev-rules: added seat rules

plymouth needs the seat rules, also without systemd

9 years agonetwork/ifup.sh: Don't try to modprobe ipv6, if already available
Vasiliy Tolstov [Mon, 26 May 2014 11:28:43 +0000 (15:28 +0400)] 
network/ifup.sh: Don't try to modprobe ipv6, if already available

Signed-off-by: Vasiliy Tolstov <v.tolstov@selfip.ru>
[Edited-by: Harald Hoyer]
Simplified logic.

9 years agobonding: use hwaddr of the slave rather than the master
Alex Harpin [Tue, 6 May 2014 22:41:17 +0000 (23:41 +0100)] 
bonding: use hwaddr of the slave rather than the master

When a bonded interface is brought up, any slaves included in the bond
have their hardware address set to that of the bond master.  Although
this allows an interface to be brought up on start up, when the
configuration file is imported into the booted system it prevents
the bonded interface being successfully restarted.

The fix involves obtaining the hardware address of the slaves before
they are added to the bond and then using this value in the
configuration file.

9 years agokernel-modules: Fix storage module selection for sdhci/mmc/ahci
Peter Robinson [Fri, 23 May 2014 10:54:01 +0000 (11:54 +0100)] 
kernel-modules: Fix storage module selection for sdhci/mmc/ahci

Currently the block driver detection for generic initrd doesn't include
the SD/MMC drivers so we fail to boot generic images on any device using
those platforms as boot devices when using a generic initrd. Add logic
to detect those modules. This primarily fixes embedded ARM devices but
also likely intel tablets/dev boards and enterprise hypervisors that
have the ability to boot from SD.

Also the ahci_init_controller misses a number of drivers that use the
libahci_platform module for the init so this fixes some missing achi
moduless too.

Finally it cleans up the ARM storage module hacks that the above now
deals with in a more generic manner.

Signed-off-by: <pbrobinson@gmail.com>
9 years agodracut-functions.sh:require_binaries() clarify message
Harald Hoyer [Tue, 20 May 2014 11:23:43 +0000 (13:23 +0200)] 
dracut-functions.sh:require_binaries() clarify message

The info message written by require_binaries() was a bit frighten to
users. So just be a little bit more verbose.

If you have ideas on how to improve the message for these "soft"
dependency modules, please submit patches.

9 years agodracut-pre-pivot pulls in remote-fs.target
WANG Chao [Fri, 4 Apr 2014 06:37:42 +0000 (14:37 +0800)] 
dracut-pre-pivot pulls in remote-fs.target

It turns out that commit f30b74e (dracut-initqueue service runs before
remote-fs-pre.target) is partial fix for remote fs mounts. Because no
one pulls in remote-fs.target, we can never start remote fs mounts.
Now pull in remote-fs.target in dracut-pre-pivot.

Signed-off-by: WANG Chao <chaowang@redhat.com>
9 years agoresume/module-setup.sh: filter out empty resume= options in cmdline()
Alexander Tsoy [Fri, 16 May 2014 17:12:36 +0000 (21:12 +0400)] 
resume/module-setup.sh: filter out empty resume= options in cmdline()

cmdline() prints empty "resume=" options for non-persistent swap
devices, for example zram. Add a check for that.

This patch also fixes printf formatting and removes unused variables.

9 years agoudev-rules: include 59-scsi-sg3_utils.rules
Julian Wolf [Thu, 3 Apr 2014 12:55:19 +0000 (14:55 +0200)] 
udev-rules: include 59-scsi-sg3_utils.rules

Without the 59-scsi-sg3_utils.rules udev-rule a couple of devices are missing
in /dev/disk/by-id.

If the luks device is specified by-id in /etc/crypttab and rd.luks.uuid not
passed as a commandline parameter during boot, systemd tries to start its
crypto services which depend on those missing devices until it times out and
exits to dracut rescue shell.

Signed-off-by: Julian Wolf <juwolf@suse.com>
9 years ago98systemd: fixup rootfs-generator installation path
Hannes Reinecke [Tue, 20 May 2014 09:20:10 +0000 (11:20 +0200)] 
98systemd: fixup rootfs-generator installation path

The rootfs-generator was installed in the wrong path
in the initrd, cause it never to be run.

References: bnc#878714

Signed-off-by: Hannes Reinecke <hare@suse.de>
9 years agodracut-functions.sh:print_vars() fix for values with spaces
Harald Hoyer [Tue, 20 May 2014 09:27:42 +0000 (11:27 +0200)] 
dracut-functions.sh:print_vars() fix for values with spaces

for a variable with spaces, e.g.:
EXT_KEYMAPS='backspace keypad euro2'

The following would occur:
print_vars: eval printf -v _value %s '$EXT_KEYMAPS'
print_vars: printf -v _value %s backspace keypad euro2
print_vars: [[ -n backspacekeypadeuro2 ]]
print_vars: printf '%s=\"%s\"\n' EXT_KEYMAPS backspacekeypadeuro2

Thanks to Sebastian Köln for the fix!

9 years agofcoe-uefi/parse-uefifcoe.sh: fixed parameter generation from UEFI
Harald Hoyer [Tue, 20 May 2014 09:22:26 +0000 (11:22 +0200)] 
fcoe-uefi/parse-uefifcoe.sh: fixed parameter generation from UEFI

"fcoe=" was missing for the parameter specifying the interface

9 years agonbd/nbdroot.sh: call nbd-client with "--systemd-mark"
Harald Hoyer [Fri, 16 May 2014 11:33:33 +0000 (13:33 +0200)] 
nbd/nbdroot.sh: call nbd-client with "--systemd-mark"

otherwise nbd-client will get killed by systemd

9 years agoifcfg/write-ifcfg.sh: include net-lib.sh
Harald Hoyer [Fri, 16 May 2014 11:32:47 +0000 (13:32 +0200)] 
ifcfg/write-ifcfg.sh: include net-lib.sh

otherwise is_persistent_ethernet_name() is missing

9 years agomdraid/module-setup.sh: fixed print-cmdline for empty UUID
Harald Hoyer [Wed, 14 May 2014 14:38:49 +0000 (16:38 +0200)] 
mdraid/module-setup.sh: fixed print-cmdline for empty UUID

fixes

/usr/lib/dracut/modules.d/90mdraid/module-setup.sh: line 60:
_activated["${UUID}"]: bad array subscript

Thanks to Jan ONDREJ for spotting this!

9 years agocms/cmssetup.sh: convert SUBCHANNELS to lowercase
Harald Hoyer [Mon, 12 May 2014 12:36:08 +0000 (14:36 +0200)] 
cms/cmssetup.sh: convert SUBCHANNELS to lowercase

In udev rules, the channels need to be expressed in lower case.

9 years agoifcfg/write-ifcfg.sh: "IPV6INIT=yes" check also for non-dhcp
Harald Hoyer [Mon, 12 May 2014 11:53:38 +0000 (13:53 +0200)] 
ifcfg/write-ifcfg.sh: "IPV6INIT=yes" check also for non-dhcp

9 years agoresume/parse-resume.sh: correctly write timeout hook
Harald Hoyer [Wed, 7 May 2014 13:30:01 +0000 (15:30 +0200)] 
resume/parse-resume.sh: correctly write timeout hook

9 years agoDo not log to kmsg/syslog and files for "--print-cmdline"
Harald Hoyer [Wed, 7 May 2014 12:54:56 +0000 (14:54 +0200)] 
Do not log to kmsg/syslog and files for "--print-cmdline"

9 years agodracut-lib.sh: fixed return value of pidof()
Harald Hoyer [Wed, 7 May 2014 11:33:14 +0000 (13:33 +0200)] 
dracut-lib.sh: fixed return value of pidof()

pidof always returned with 0, so any "while pidof" loop would not
terminate.

Thanks "Consus" for the hint!

10 years agoi18n/parse-i18n.sh: fixed typo s/$key/$_key
Harald Hoyer [Mon, 28 Apr 2014 10:47:45 +0000 (12:47 +0200)] 
i18n/parse-i18n.sh: fixed typo s/$key/$_key

Thanks xtraeme!

10 years agoCorrect strstr/strglobin in test suite.
Chapman Flack [Sat, 5 Apr 2014 01:24:51 +0000 (21:24 -0400)] 
Correct strstr/strglobin in test suite.

Previous commit included versions of strstr/strglobin in the test
suite files that did not match those in dracut-lib.sh.

10 years agoSpecify strstr tightly, add strglob/strglobin.
Chapman Flack [Sat, 5 Apr 2014 01:11:38 +0000 (21:11 -0400)] 
Specify strstr tightly, add strglob/strglobin.

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).

10 years agoifcfg: only bind to HWADDR, if addr_assign_type == 0
Harald Hoyer [Fri, 4 Apr 2014 10:52:39 +0000 (12:52 +0200)] 
ifcfg: only bind to HWADDR, if addr_assign_type == 0

/sys/class/net/$netif/addr_assign_type is != 0 for random MAC address
interfaces

10 years agoifcfg: do not bind persistent interface names to HWADDR
Harald Hoyer [Fri, 4 Apr 2014 10:48:03 +0000 (12:48 +0200)] 
ifcfg: do not bind persistent interface names to HWADDR

10 years agofs-lib: always install fsck.$fs, if present
Harald Hoyer [Fri, 4 Apr 2014 09:33:02 +0000 (11:33 +0200)] 
fs-lib: always install fsck.$fs, if present

10 years agodracut-initqueue service runs before remote-fs-pre.target
WANG Chao [Thu, 3 Apr 2014 07:49:26 +0000 (15:49 +0800)] 
dracut-initqueue service runs before remote-fs-pre.target

With the following commit, dracut doesn't mount anything from /etc/fstab

commit e920bfb
Author: WANG Chao <chaowang@redhat.com>
Date:   Tue Apr 1 15:20:49 2014 +0800

    fstab: do not mount and fsck from fstab if using systemd

But systemd doesn't mount nfs at all, because no unit is pulling in
remote-fs.target.

dracut must pull in these remote fs mount and all these remote mounts
should start only after network is up (ie. after dracut-initqueue).

Signed-off-by: WANG Chao <chaowang@redhat.com>
10 years agoBreak at switch_root only for bare rd.break
Chapman Flack [Thu, 3 Apr 2014 01:57:00 +0000 (21:57 -0400)] 
Break at switch_root only for bare rd.break

Previously, any rd.break=breakpoint would cause a break at the
given breakpoint and also at switch_root.

10 years agolvm:module-setup.sh: check for existance of 69-dm-lvm-metad.rules
Harald Hoyer [Thu, 3 Apr 2014 06:54:27 +0000 (08:54 +0200)] 
lvm:module-setup.sh: check for existance of 69-dm-lvm-metad.rules

Before modifying 69-dm-lvm-metad.rules, we should check for the
existance first. Otherwise this results in error messages on
distributions (debian), which do not ship these rules.

10 years agoifcfg/write-ifcfg.sh: turn on IPV6INIT, if any inet6 address is found
Harald Hoyer [Thu, 3 Apr 2014 06:53:09 +0000 (08:53 +0200)] 
ifcfg/write-ifcfg.sh: turn on IPV6INIT, if any inet6 address is found

If "ip -6 addr" finds any inet6 address, assume IPV6INIT=yes for the
ifcfg file.

10 years agofstab: do not mount and fsck from fstab if using systemd
WANG Chao [Tue, 1 Apr 2014 07:20:49 +0000 (15:20 +0800)] 
fstab: do not mount and fsck from fstab if using systemd

If using systemd in initramfs, we could run into a race condition when
dracut and systemd both are trying to mount and run fsck for the same
filesystem, and mount or fsck could be a failure.

To fix such failure, we should use systemd to mount/fsck from /etc/fstab
only.

v2: check $DRACUT_SYSTEMD suggested by Alexander Tsoy

Signed-off-by: WANG Chao <chaowang@redhat.com>
10 years agofcoe: workaround fcoe timing issues
Harald Hoyer [Mon, 31 Mar 2014 14:21:49 +0000 (16:21 +0200)] 
fcoe: workaround fcoe timing issues

10 years agodm: add dm-cache modules
Harald Hoyer [Thu, 27 Mar 2014 11:34:40 +0000 (12:34 +0100)] 
dm: add dm-cache modules

https://bugzilla.redhat.com/show_bug.cgi?id=1081435

10 years agonetwork: DCHPv6: set valid_lft and preferred_lft
Harald Hoyer [Thu, 27 Mar 2014 11:31:23 +0000 (12:31 +0100)] 
network: DCHPv6: set valid_lft and preferred_lft

https://bugzilla.redhat.com/show_bug.cgi?id=1064365

10 years agolsinitrd.sh: prevent < <$() construct
Harald Hoyer [Thu, 27 Mar 2014 08:27:53 +0000 (09:27 +0100)] 
lsinitrd.sh: prevent < <$() construct

Running dracut in a chroot environment, which has /dev not correctly
setup will result in errors like:

/usr/bin/lsinitrd: line 164: /dev/fd/62: No such file or directory
cpio: Malformed number �5�OK��
cpio: Malformed number 5�OK��
cpio: Malformed number �OK��

This is because bash wants /dev/fd/<num> for constructs like:
foo < <$(bar)

10 years agonetwork: handle "ip=dhcp6" for all interfaces
Harald Hoyer [Tue, 25 Mar 2014 14:39:56 +0000 (15:39 +0100)] 
network: handle "ip=dhcp6" for all interfaces

https://bugzilla.redhat.com/show_bug.cgi?id=1064365

10 years agofcoe: wait for lldpad to be ready
Harald Hoyer [Tue, 25 Mar 2014 14:28:19 +0000 (15:28 +0100)] 
fcoe: wait for lldpad to be ready

10 years agosystemd: add systemd-gpt-auto-generator
Harald Hoyer [Thu, 20 Mar 2014 12:42:08 +0000 (13:42 +0100)] 
systemd: add systemd-gpt-auto-generator

10 years agodracut-initramfs-restore: fix unpacking with early microcode
Harald Hoyer [Thu, 20 Mar 2014 12:18:13 +0000 (13:18 +0100)] 
dracut-initramfs-restore: fix unpacking with early microcode

10 years agoNEWS: update for 037 037
Harald Hoyer [Wed, 19 Mar 2014 16:16:08 +0000 (17:16 +0100)] 
NEWS: update for 037

10 years agosystemd/dracut-shutdown.service: make failure non-fatal
Harald Hoyer [Wed, 12 Mar 2014 14:39:08 +0000 (15:39 +0100)] 
systemd/dracut-shutdown.service: make failure non-fatal

10 years agoshutdown: if kexec failed, do a simple reboot
Harald Hoyer [Tue, 18 Mar 2014 12:21:22 +0000 (13:21 +0100)] 
shutdown: if kexec failed, do a simple reboot

10 years agonetwork:dhclient-script do PREINIT6 for DHCP6
Harald Hoyer [Mon, 17 Mar 2014 12:00:17 +0000 (13:00 +0100)] 
network:dhclient-script do PREINIT6 for DHCP6

10 years agolvm:lvm_scan.sh handle one LV at a time with lvchange
Harald Hoyer [Fri, 24 Jan 2014 15:37:13 +0000 (16:37 +0100)] 
lvm:lvm_scan.sh handle one LV at a time with lvchange

10 years agoNEWS: update for dracut-037
Harald Hoyer [Wed, 5 Mar 2014 16:27:51 +0000 (17:27 +0100)] 
NEWS: update for dracut-037

10 years agoAUTHORS: update
Harald Hoyer [Wed, 5 Mar 2014 12:42:37 +0000 (13:42 +0100)] 
AUTHORS: update

10 years agoDo not wait_for_dev if hostonly_cmdline not set
Harald Hoyer [Thu, 6 Mar 2014 08:54:36 +0000 (09:54 +0100)] 
Do not wait_for_dev if hostonly_cmdline not set

10 years agofcoe-up: remove initlog logic
Harald Hoyer [Wed, 5 Mar 2014 12:20:35 +0000 (13:20 +0100)] 
fcoe-up: remove initlog logic