summaryrefslogtreecommitdiffstats
path: root/testModule
diff options
context:
space:
mode:
authortorben2015-04-13 20:15:29 +0200
committertorben2015-04-13 20:15:29 +0200
commit75abace71d151e3420e171496c50d2c6a3091163 (patch)
tree492fe2d5a0ee7b96541c7c4389cf82f20baf9b36 /testModule
parentCode refactoring. (diff)
downloadsystemd-init-75abace71d151e3420e171496c50d2c6a3091163.tar.gz
systemd-init-75abace71d151e3420e171496c50d2c6a3091163.tar.xz
systemd-init-75abace71d151e3420e171496c50d2c6a3091163.zip
Fix refactoring bugs.
Diffstat (limited to 'testModule')
-rw-r--r--testModule/hooks/cmdline.sh5
-rw-r--r--testModule/hooks/pre-mount.sh7
-rw-r--r--testModule/module-setup.sh6
3 files changed, 4 insertions, 14 deletions
diff --git a/testModule/hooks/cmdline.sh b/testModule/hooks/cmdline.sh
index 5731242f..340467df 100644
--- a/testModule/hooks/cmdline.sh
+++ b/testModule/hooks/cmdline.sh
@@ -1,10 +1,6 @@
# Converts ip configuration format given by the pxe pre boot provider to a
# dracut compatible static ip configuration.
-# TODO
-warn 'LOAD ...........................'
-warn 'LOAD ...........................'
-
source /usr/lib/test-library.sh
for parameter in $(getargs ip=); do
@@ -23,7 +19,6 @@ for parameter in $(getargs ip=); do
warn "PXE given net configuration: ip: $ip server_ip: $server_ip gateway_ip: $gateway_ip net_mask: $net_mask"
local final_dracut_ip_config="$ip::$gateway_ip:$net_mask:dracut_test_client:enp0s3:none"
warn "Final dracut ip config: $final_dracut_ip_config"
- #final_dracut_ip_config="enp0s3:dhcp"
replace_cmd ip "$final_dracut_ip_config"
done
diff --git a/testModule/hooks/pre-mount.sh b/testModule/hooks/pre-mount.sh
index 301381e6..79ae47fa 100644
--- a/testModule/hooks/pre-mount.sh
+++ b/testModule/hooks/pre-mount.sh
@@ -2,13 +2,8 @@
warn '............START.............'
insmod /usr/lib/modules/3.10.0-229.1.2.el7.x86_64/extra/dnbd3.ko
-
-#dnbd3-client --daemon &
-#sleep 3
local dnbd3_device_node="$(dnbd3-client -h 132.230.4.1 -i stage4/torben/test -r 1 -d /dev/dnbd0)"
dnbd3_device_node='/dev/dnbd0'
qemu-img create -f qcow2 -o backing_file="$dnbd3_device_node",backing_fmt=qcow2 /test.qcow2
insmod /usr/lib/modules/3.10.0-229.1.2.el7.x86_64/extra/nbd.ko
-wrap qemu-nbd -c /dev/nbd0 /test.qcow2
-
-#wrap /usr/bin/bash -c 'while true; do wget http://10.126.2.184:8080; sleep 10; done' &
+systemd_preserve_process_marker qemu-nbd -c /dev/nbd0 /test.qcow2
diff --git a/testModule/module-setup.sh b/testModule/module-setup.sh
index 5451bb42..5e0696b4 100644
--- a/testModule/module-setup.sh
+++ b/testModule/module-setup.sh
@@ -36,9 +36,9 @@ install() {
inst "$moddir/kernel_modules/nbd.ko" /usr/lib/modules/3.10.0-229.1.2.el7.x86_64/extra/nbd.ko
# NOTE: Priority has to be greater than the network cmdline parsing hooks
# since we have to modify the some kernel parameter before.
- inst_hook cmdline 100 "$moddir/cmdline.sh"
- inst_hook pre-mount 100 "$moddir/pre-mount.sh"
- inst_hook pre-pivot 100 "$moddir/pre-pivot.sh"
+ inst_hook cmdline 100 "$moddir/hooks/cmdline.sh"
+ inst_hook pre-mount 100 "$moddir/hooks/pre-mount.sh"
+ inst_hook pre-pivot 100 "$moddir/hooks/pre-pivot.sh"
#inst_hook pre-mount 20 "$moddir/setup_network.sh"
inst_multiple lsblk ping ip ifconfig sshd htop dhclient tail head cat vim touch sed lsmod insmod qemu-img qemu-nbd sleep route wget find
# FINAL: inst_multiple insmod qemu-img qemu-nbd