Harald Hoyer [Mon, 23 Mar 2009 14:28:14 +0000 (15:28 +0100)]
Merge branch 'enhanced-test-framework' of git://fnordovax.org/dracut into test
Conflicts:
modules.d/50plymouth/63-luks.rules
modules.d/50plymouth/cryptroot.sh
modules.d/50plymouth/install
modules.d/90crypt/63-luks.rules
modules.d/90crypt/cryptroot.sh
modules.d/90crypt/install
Victor Lowther [Thu, 12 Mar 2009 11:30:14 +0000 (06:30 -0500)]
do not use grep to test if sysroot is mounted
Victor Lowther [Fri, 20 Mar 2009 08:51:05 +0000 (03:51 -0500)]
Updated test-init to only create fstab symlink as needed.
Victor Lowther [Fri, 20 Mar 2009 08:40:02 +0000 (03:40 -0500)]
Don't regenerate the test image when anything changes
Only regenerate it if we changed test-init or make-test-root
Victor Lowther [Fri, 20 Mar 2009 08:36:21 +0000 (03:36 -0500)]
Move loading crypt kernel modules to the crypt module
Victor Lowther [Fri, 20 Mar 2009 08:34:30 +0000 (03:34 -0500)]
Minor updates to the testing framework
Victor Lowther [Fri, 20 Mar 2009 07:58:58 +0000 (02:58 -0500)]
Just pass args the kernel passed to us, not /proc/cmdline args.
Victor Lowther [Fri, 20 Mar 2009 07:25:13 +0000 (02:25 -0500)]
Silence in the initramfs is golden.
Get rid of gratuitous text -- we should only talk if asking a question or
if something screwed up.
Victor Lowther [Fri, 20 Mar 2009 07:19:33 +0000 (02:19 -0500)]
Change default install target for udev rules.
Also make sure that udev does not complain about a missing rules.d directory.
Victor Lowther [Thu, 19 Mar 2009 17:20:26 +0000 (12:20 -0500)]
Load all our usual dracut modules
Victor Lowther [Thu, 19 Mar 2009 17:15:02 +0000 (12:15 -0500)]
Move finding and mounting root on block devices into its own hook.
Victor Lowther [Thu, 19 Mar 2009 17:07:31 +0000 (12:07 -0500)]
Split out resume handling into its own hook.
Victor Lowther [Thu, 19 Mar 2009 15:41:03 +0000 (10:41 -0500)]
Move parsing rootfs options to a pre-udev hook.
Victor Lowther [Thu, 19 Mar 2009 15:38:22 +0000 (10:38 -0500)]
Update plymouth to work with running cryptsetup from a udev rule.
Victor Lowther [Thu, 19 Mar 2009 14:59:06 +0000 (09:59 -0500)]
Unlock our encrypted root in a udev rule.
Victor Lowther [Thu, 19 Mar 2009 14:31:28 +0000 (09:31 -0500)]
Move processing root options into a pre-udev hook.
Also make changes that will make it easier to udevify resuming
from hibernate and mounting root.
Victor Lowther [Mon, 16 Mar 2009 09:42:02 +0000 (04:42 -0500)]
Update test framework to create and use LVM on cryptroot
Harald Hoyer [Mon, 9 Mar 2009 12:18:06 +0000 (13:18 +0100)]
changed mode of modules.d/90dmsetup/check to 0755
Harald Hoyer [Mon, 9 Mar 2009 12:11:38 +0000 (13:11 +0100)]
removed exit 1 from debug
Harald Hoyer [Mon, 9 Mar 2009 11:55:02 +0000 (12:55 +0100)]
trigger root mount via udev rules
Harald Hoyer [Mon, 9 Mar 2009 11:54:01 +0000 (12:54 +0100)]
removed trailing \
Harald Hoyer [Mon, 9 Mar 2009 11:53:19 +0000 (12:53 +0100)]
get crypt password with rules
Harald Hoyer [Mon, 9 Mar 2009 08:23:24 +0000 (09:23 +0100)]
Revert "Make plymouth play nice with the current crypt code, part 1"
This reverts commit
79ec17c74d74e3b23706542ec548874d36be2de3.
Harald Hoyer [Mon, 9 Mar 2009 11:49:17 +0000 (12:49 +0100)]
add full patch to /sbin/ip and check for dhclient $pid before kill
Harald Hoyer [Mon, 9 Mar 2009 11:55:38 +0000 (12:55 +0100)]
ignore testimages
Harald Hoyer [Mon, 9 Mar 2009 08:18:25 +0000 (09:18 +0100)]
do not display "file not found" for /etc/lsb-release
Harald Hoyer [Mon, 9 Mar 2009 08:17:41 +0000 (09:17 +0100)]
fixed bash error in inst_binary()
./dracut-functions: line 108: syntax error near unexpected token `<'
./dracut-functions: line 108: ` done < <(ldd $bin 2>/dev/null)'
Victor Lowther [Sun, 8 Mar 2009 15:49:44 +0000 (10:49 -0500)]
Modify Makefile to use new test harness
Victor Lowther [Sun, 8 Mar 2009 14:23:11 +0000 (09:23 -0500)]
Add a very simple test harness
This creates a basic root filesystem, creates an initramfs, and tries
to boot to the basic filesystem.
The init code on the test filesystem prints how much memory is used vs. free
and then drops to a shell. Exiting the shell will power off the VM.
Victor Lowther [Sun, 8 Mar 2009 15:38:25 +0000 (10:38 -0500)]
Make udevd shut up
Do this by loading /etc/group and /lib*/libnss_files.so.* onto the initramfs
Victor Lowther [Sun, 8 Mar 2009 14:21:06 +0000 (09:21 -0500)]
Fixup 90kernel-modules-loaded
The inst functions do not know how to handle directories directly.
Just find the files, and they will create the directories as needed.
Victor Lowther [Sun, 8 Mar 2009 14:18:12 +0000 (09:18 -0500)]
Make dracutmodules default to "auto"
We have OS-specific modules, and it is vital that we skip then on
OSes that they do not apply to.
Victor Lowther [Sun, 8 Mar 2009 14:15:18 +0000 (09:15 -0500)]
Remove all files on the initramfs before switching root
The code from pjones's tree did not include the recursive remove code,
so I readded it from the nash source code.
Victor Lowther [Sat, 7 Mar 2009 14:32:02 +0000 (08:32 -0600)]
Some versions of udevd do not look for rules in /lib/udev/rules.d
For those versions, install rules to /etc/udev/rules.d instead.
Victor Lowther [Sat, 7 Mar 2009 14:25:22 +0000 (08:25 -0600)]
Clean up logic for auto vs. hostonly
The mass of conditional checking and multiple variables was a little
hard to read, split some of it into its own function.
Victor Lowther [Sat, 7 Mar 2009 14:02:03 +0000 (08:02 -0600)]
Move root option processing into a pre-mount hook.
This will make it easier to add support for root on nfs, root on iscsi,
root on multipath, and other such oddities.
Harald Hoyer [Sat, 7 Mar 2009 13:01:32 +0000 (14:01 +0100)]
add hostonly check procedure
Harald Hoyer [Sat, 7 Mar 2009 12:14:59 +0000 (13:14 +0100)]
fixed Makefile and removed dracut.conf obsoleted by skip-missing
Seewer Philippe [Sat, 7 Mar 2009 11:59:13 +0000 (12:59 +0100)]
combine --skip-missing to /check infrastructure
This patch introduces --skip-missing to skip modules failing /check,
allowing to use the check infrastructure not only for
dracutmodules="auto".
Result: dracutmodules="auto" becomes obsolete, automatically setting
dracutmodules="all" and skipmissing="yes"
Patch is built on top of Harald Hoyers merge tree
(git://git.surfsite.org/pub/git/dracut.git)
Seewer Philippe [Sat, 7 Mar 2009 11:24:07 +0000 (12:24 +0100)]
add /check for dmraim module
With the /check infrastucture in place, dmraid is missing a check file.
Patch is built on top of Harald Hoyers merge tree
(git://git.surfsite.org/pub/git/dracut.git)
Harald Hoyer [Sat, 7 Mar 2009 11:19:55 +0000 (12:19 +0100)]
do not autoinstall 90kernel-modules-loaded 95udev-rules.ub810
Harald Hoyer [Sat, 7 Mar 2009 11:18:44 +0000 (12:18 +0100)]
set dracutmodules to "auto"
Harald Hoyer [Sat, 7 Mar 2009 11:18:09 +0000 (12:18 +0100)]
fixed conffile and dracutmodules handling
Harald Hoyer [Sat, 7 Mar 2009 11:06:17 +0000 (12:06 +0100)]
fixed -c parameter handling and Makefile
Seewer Philippe [Sat, 7 Mar 2009 10:53:40 +0000 (11:53 +0100)]
priorize -m over dracut.conf, add --modules and get rid of automatic use of ./dracut.conf
Victor Lowther introduced -c to freely set dracut.conf. Means we can get
rid of automatic use of ./dracut.conf if -l is used, use -c instead.
Second this patch prefers options before config files and adds an option
-d|--drivers to set the modules= option.
Patch is built on top of Harald Hoyers merge tree
(git://git.surfsite.org/pub/git/dracut.git)
Victor Lowther [Sat, 7 Mar 2009 04:32:37 +0000 (22:32 -0600)]
Simplify switch_root.c a bit
Shift some required functionality from switch_root.c to init.
String manipulation and filtering, and testing for the existence of init
is easier in the init script than in C.
Victor Lowther [Sat, 7 Mar 2009 03:45:34 +0000 (21:45 -0600)]
Added a comment for instmods.
Victor Lowther [Sat, 7 Mar 2009 03:41:31 +0000 (21:41 -0600)]
Fix broken -c handling and give instmods a little optimization.
Victor Lowther [Sat, 7 Mar 2009 03:16:41 +0000 (21:16 -0600)]
Added -c switch to dracut to use a custom dracut.conf
Also some doc updates.
Victor Lowther [Fri, 6 Mar 2009 23:04:05 +0000 (17:04 -0600)]
Minor changes to network scripts to bring inline with my current patch series
Victor Lowther [Fri, 6 Mar 2009 22:53:29 +0000 (16:53 -0600)]
Tighten up the ubuntu 8.10 udev rules installation script.
We need to add a check file here, but I ahve no idea how to do that for ubuntu.
Victor Lowther [Fri, 6 Mar 2009 22:42:05 +0000 (16:42 -0600)]
Modify modprobe.d installation and add check for plymouth
Victor Lowther [Fri, 6 Mar 2009 22:30:17 +0000 (16:30 -0600)]
Chop tons of unneeded stuff out of the plymouth module
Most of plymouth-populate-initrd appears to have been unneeded, and is gone.
The rest was updated to match dracut usage.
Victor Lowther [Fri, 6 Mar 2009 22:01:15 +0000 (16:01 -0600)]
Make plymouth play nice with current ctypt code, part 2.
The reason this works is that inst will refuse to overwrite a file that
already exists. We jsut make plymouth's code to ask for a password have the
same name as 90crypt's password asking script, and it will override 90crypt's
script while leaving everything else intact.
Victor Lowther [Fri, 6 Mar 2009 22:00:56 +0000 (16:00 -0600)]
Make plymouth play nice with the current crypt code, part 1
Victor Lowther [Fri, 6 Mar 2009 21:36:41 +0000 (15:36 -0600)]
Tighten up 90kernel-modules-loaded a bit.
Victor Lowther [Fri, 6 Mar 2009 21:34:43 +0000 (15:34 -0600)]
Tighten up 90kernel-modules/install a bit.
Victor Lowther [Fri, 6 Mar 2009 21:29:09 +0000 (15:29 -0600)]
Make 90lvm load the device-mapper rules instead of 95udev-rules
Victor Lowther [Fri, 6 Mar 2009 21:26:24 +0000 (15:26 -0600)]
Make 90dmraid load the dm-raid udev rules instead of 95udev-rules
Victor Lowther [Fri, 6 Mar 2009 21:15:59 +0000 (15:15 -0600)]
Use new check functionaloty to only load cryptoroot when needed
Victor Lowther [Fri, 6 Mar 2009 20:29:28 +0000 (14:29 -0600)]
Use new check functionality to make 10redhat-i18n only work on redhat.
Victor Lowther [Fri, 6 Mar 2009 20:27:03 +0000 (14:27 -0600)]
Make dash module use new check functionality
Victor Lowther [Fri, 6 Mar 2009 20:23:37 +0000 (14:23 -0600)]
Add dracutmodules=auto functionality
To use this, your module needs to supply a check script which returns 0
if the module is applicable to this system, 1 otherwise.
If a module does not include a check script, it will be sourced. If no modules
have check scripts, then dracutmodules=auto behaves exactly like
dracutmodules=all
Victor Lowther [Fri, 6 Mar 2009 20:06:48 +0000 (14:06 -0600)]
Some minor formatting fixups in the main dracut script
Victor Lowther [Fri, 6 Mar 2009 20:00:34 +0000 (14:00 -0600)]
Fix formatting in instmods a bit.
Victor Lowther [Fri, 6 Mar 2009 19:58:56 +0000 (13:58 -0600)]
Simplify inst_script a bit
We do not need separate source and target parameters, so do not use them.
Victor Lowther [Fri, 6 Mar 2009 19:56:06 +0000 (13:56 -0600)]
Rename find_file to find_binary and simplify it.
Since we are not using find_file as a general-purpose file existence
testing function anymore, it can be made simpler.
Victor Lowther [Fri, 6 Mar 2009 19:51:28 +0000 (13:51 -0600)]
Make calling modprobe look prettier.
Victor Lowther [Fri, 6 Mar 2009 19:50:04 +0000 (13:50 -0600)]
Remove a useless use of cat in instmods
We also need to decide whenter we are going to support modules.* files.
Not only are they Fedora-specific, but doing so makes =* arguments to instmods
have two different and incompatible meanings depending on whether that file
exists.
Victor Lowther [Fri, 6 Mar 2009 19:44:48 +0000 (13:44 -0600)]
inst never takes 3 arguments anymore.
Remove the misleading help message and the 3 argument processing.
Harald Hoyer [Fri, 6 Mar 2009 16:12:51 +0000 (17:12 +0100)]
fixed the previous incomplete patch for 95udev-rules.ub810
Harald Hoyer [Fri, 6 Mar 2009 15:58:44 +0000 (16:58 +0100)]
/etc/modprobe.d might have subdirs, so install them also
Seewer Philippe [Fri, 6 Mar 2009 15:18:53 +0000 (16:18 +0100)]
dracut and ubuntu 8.10
Followup: Harald Hoyers "Merge" repository boots on ub8.10 with a dracut.conf similar to the following one and the attached patch applied
> cat dracut.conf
modules="ata_piix sd_mod sg"
dracutmodules="dash kernel-modules debug terminfo udev-rules.ub810 base"
Harald Hoyer [Fri, 6 Mar 2009 15:31:43 +0000 (16:31 +0100)]
add 90kernel-modules-loaded to install currently loaded kernel modules
Harald Hoyer [Fri, 6 Mar 2009 15:27:56 +0000 (16:27 +0100)]
be more precise, when checking the dracutmodules string, also print
message which module is used
Harald Hoyer [Fri, 6 Mar 2009 14:44:50 +0000 (15:44 +0100)]
install modprobe.d for special rules and blacklists
Harald Hoyer [Fri, 6 Mar 2009 14:44:25 +0000 (15:44 +0100)]
add sd_mod to hardcode module list of doom
Harald Hoyer [Fri, 6 Mar 2009 14:39:02 +0000 (15:39 +0100)]
add --ignore-install to modprobe calls
Harald Hoyer [Fri, 6 Mar 2009 14:37:16 +0000 (15:37 +0100)]
fixed the use of e.g. instmods =drivers/foobar
Harald Hoyer [Fri, 6 Mar 2009 14:25:04 +0000 (15:25 +0100)]
fixed the use of e.g. instmods =drivers/foobar
Harald Hoyer [Fri, 6 Mar 2009 14:11:42 +0000 (15:11 +0100)]
fixed instmods
Harald Hoyer [Fri, 6 Mar 2009 14:09:44 +0000 (15:09 +0100)]
add the special "=ata" case for instmods
Harald Hoyer [Fri, 6 Mar 2009 13:36:18 +0000 (14:36 +0100)]
add /sbin to $PATH
Harald Hoyer [Fri, 6 Mar 2009 13:35:19 +0000 (14:35 +0100)]
used modules.<subsystem> if present for instmod =<subsystem>
Harald Hoyer [Fri, 6 Mar 2009 13:33:42 +0000 (14:33 +0100)]
use $(( instead of $[
Harald Hoyer [Fri, 6 Mar 2009 11:32:54 +0000 (12:32 +0100)]
use udev rules to autoassemble a md raid and added mdmon pre-pivot
Harald Hoyer [Fri, 6 Mar 2009 10:36:32 +0000 (11:36 +0100)]
mount move instead of umount and fix the search for fallback inits
chdir to newroot, then mount move instead of umount /dev, /sys, etc.
search for fallback init bins in current dirs
Harald Hoyer [Fri, 6 Mar 2009 09:56:52 +0000 (10:56 +0100)]
start udevd with --resolve-names=never
Harald Hoyer [Fri, 6 Mar 2009 09:48:46 +0000 (10:48 +0100)]
use switch_root code from pjones.fedorapeople.org/mkstart/usr/lib/mkstart/switchroot.c
Harald Hoyer [Fri, 6 Mar 2009 09:31:48 +0000 (10:31 +0100)]
added mdraid module
Harald Hoyer [Fri, 6 Mar 2009 09:30:36 +0000 (10:30 +0100)]
fail, if install failed
Harald Hoyer [Fri, 6 Mar 2009 09:16:56 +0000 (10:16 +0100)]
added mdraid autoassembling
Harald Hoyer [Thu, 5 Mar 2009 18:12:18 +0000 (19:12 +0100)]
/usr/libexec -> /usr/lib
Harald Hoyer [Thu, 5 Mar 2009 18:05:16 +0000 (19:05 +0100)]
add gitignore
Harald Hoyer [Thu, 5 Mar 2009 18:02:54 +0000 (19:02 +0100)]
fixed modules install
Harald Hoyer [Thu, 5 Mar 2009 17:56:12 +0000 (18:56 +0100)]
do not rename dracut-functions to functions
Harald Hoyer [Thu, 5 Mar 2009 17:55:51 +0000 (18:55 +0100)]
s/error /echo /
Harald Hoyer [Thu, 5 Mar 2009 16:17:44 +0000 (17:17 +0100)]
removed rule files (better use upstream rules)
Harald Hoyer [Thu, 5 Mar 2009 16:17:32 +0000 (17:17 +0100)]
redirect more to null
Harald Hoyer [Thu, 5 Mar 2009 16:16:56 +0000 (17:16 +0100)]
added plymouth with crypt handling