|
DistroBaker |
93d277 |
From a9d2581448ddb4c9cb1904dca06512aa79145f80 Mon Sep 17 00:00:00 2001
|
|
DistroBaker |
93d277 |
From: Jiri Konecny <jkonecny@redhat.com>
|
|
DistroBaker |
93d277 |
Date: Mon, 8 Feb 2021 11:26:06 +0100
|
|
DistroBaker |
93d277 |
Subject: [PATCH 1/3] Revert "Remove support for boot arguments without 'inst.'
|
|
DistroBaker |
93d277 |
prefix from Dracut (#1912502)" (#1907566)
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
Allow to use Anaconda kernel args in Dracut without inst. prefix to not break
|
|
DistroBaker |
93d277 |
beaker. Beaker needs more time for adaptation so avoid to break it for RHEL-9.
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
This reverts commit a45405de99a42e5af047f04b78d168b6d41fa513.
|
|
DistroBaker |
93d277 |
Related: rhbz#1907566
|
|
DistroBaker |
93d277 |
---
|
|
DistroBaker |
93d277 |
dracut/anaconda-diskroot | 2 +-
|
|
DistroBaker |
93d277 |
dracut/anaconda-ks-sendheaders.sh | 4 +--
|
|
DistroBaker |
93d277 |
dracut/fetch-kickstart-disk | 2 +-
|
|
DistroBaker |
93d277 |
dracut/kickstart-genrules.sh | 2 +-
|
|
DistroBaker |
93d277 |
dracut/parse-anaconda-dd.sh | 2 +-
|
|
DistroBaker |
93d277 |
dracut/parse-anaconda-kickstart.sh | 6 ++---
|
|
DistroBaker |
93d277 |
dracut/parse-anaconda-net.sh | 3 ---
|
|
DistroBaker |
93d277 |
dracut/parse-anaconda-options.sh | 39 ++++++++++++++----------------
|
|
DistroBaker |
93d277 |
dracut/parse-anaconda-repo.sh | 6 ++---
|
|
DistroBaker |
93d277 |
9 files changed, 30 insertions(+), 36 deletions(-)
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
diff --git a/dracut/anaconda-diskroot b/dracut/anaconda-diskroot
|
|
DistroBaker |
93d277 |
index 274849fdb3..2797e67625 100755
|
|
DistroBaker |
93d277 |
--- a/dracut/anaconda-diskroot
|
|
DistroBaker |
93d277 |
+++ b/dracut/anaconda-diskroot
|
|
DistroBaker |
93d277 |
@@ -39,7 +39,7 @@ run_checkisomd5() {
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
dev="$1"
|
|
DistroBaker |
93d277 |
path="$2" # optional, could be empty
|
|
DistroBaker |
93d277 |
-kickstart="$(getarg inst.ks=)"
|
|
DistroBaker |
93d277 |
+kickstart="$(getarg ks= inst.ks=)"
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# Log the device that triggered this job.
|
|
DistroBaker |
93d277 |
debug_msg "Trying to find a root image on the device $dev."
|
|
DistroBaker |
93d277 |
diff --git a/dracut/anaconda-ks-sendheaders.sh b/dracut/anaconda-ks-sendheaders.sh
|
|
DistroBaker |
93d277 |
index a479a50667..7bc97393b8 100755
|
|
DistroBaker |
93d277 |
--- a/dracut/anaconda-ks-sendheaders.sh
|
|
DistroBaker |
93d277 |
+++ b/dracut/anaconda-ks-sendheaders.sh
|
|
DistroBaker |
93d277 |
@@ -5,7 +5,7 @@
|
|
DistroBaker |
93d277 |
command -v set_http_header >/dev/null || . /lib/url-lib.sh
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# inst.ks.sendmac: send MAC addresses in HTTP headers
|
|
DistroBaker |
93d277 |
-if getargbool 0 inst.ks.sendmac; then
|
|
DistroBaker |
93d277 |
+if getargbool 0 kssendmac inst.ks.sendmac; then
|
|
DistroBaker |
93d277 |
ifnum=0
|
|
DistroBaker |
93d277 |
for ifname in /sys/class/net/*; do
|
|
DistroBaker |
93d277 |
[ -e "$ifname/address" ] || continue
|
|
DistroBaker |
93d277 |
@@ -21,7 +21,7 @@ if getargbool 0 inst.ks.sendmac; then
|
|
DistroBaker |
93d277 |
fi
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# inst.ks.sendsn: send system serial number in HTTP headers
|
|
DistroBaker |
93d277 |
-if getargbool 0 inst.ks.sendsn; then
|
|
DistroBaker |
93d277 |
+if getargbool 0 kssendsn inst.ks.sendsn; then
|
|
DistroBaker |
93d277 |
system_serial=$(cat /sys/class/dmi/id/product_serial 2>/dev/null)
|
|
DistroBaker |
93d277 |
if [ -z "$system_serial" ]; then
|
|
DistroBaker |
93d277 |
warn "inst.ks.sendsn: can't find system serial number"
|
|
DistroBaker |
93d277 |
diff --git a/dracut/fetch-kickstart-disk b/dracut/fetch-kickstart-disk
|
|
DistroBaker |
93d277 |
index b1ee9f826c..7eb769ea5c 100755
|
|
DistroBaker |
93d277 |
--- a/dracut/fetch-kickstart-disk
|
|
DistroBaker |
93d277 |
+++ b/dracut/fetch-kickstart-disk
|
|
DistroBaker |
93d277 |
@@ -6,7 +6,7 @@ command -v getarg >/dev/null || . /lib/dracut-lib.sh
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
dev="$1"
|
|
DistroBaker |
93d277 |
path="${2:-/ks.cfg}"
|
|
DistroBaker |
93d277 |
-kickstart="$(getarg inst.ks=)"
|
|
DistroBaker |
93d277 |
+kickstart="$(getarg ks= inst.ks=)"
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
[ -e /tmp/ks.cfg.done ] && exit 1
|
|
DistroBaker |
93d277 |
[ -b "$dev" ] || exit 1
|
|
DistroBaker |
93d277 |
diff --git a/dracut/kickstart-genrules.sh b/dracut/kickstart-genrules.sh
|
|
DistroBaker |
93d277 |
index 84277890dd..8e1ba22643 100755
|
|
DistroBaker |
93d277 |
--- a/dracut/kickstart-genrules.sh
|
|
DistroBaker |
93d277 |
+++ b/dracut/kickstart-genrules.sh
|
|
DistroBaker |
93d277 |
@@ -28,7 +28,7 @@ case "${kickstart%%:*}" in
|
|
DistroBaker |
93d277 |
wait_for_kickstart
|
|
DistroBaker |
93d277 |
;;
|
|
DistroBaker |
93d277 |
"")
|
|
DistroBaker |
93d277 |
- if [ -z "$kickstart" -a -z "$(getarg inst.ks=)" ]; then
|
|
DistroBaker |
93d277 |
+ if [ -z "$kickstart" -a -z "$(getarg ks= inst.ks=)" ]; then
|
|
DistroBaker |
93d277 |
when_diskdev_appears $(disk_to_dev_path LABEL=OEMDRV) \
|
|
DistroBaker |
93d277 |
fetch-kickstart-disk \$env{DEVNAME} "/ks.cfg"
|
|
DistroBaker |
93d277 |
fi
|
|
DistroBaker |
93d277 |
diff --git a/dracut/parse-anaconda-dd.sh b/dracut/parse-anaconda-dd.sh
|
|
DistroBaker |
93d277 |
index 8eeceb9a49..3633d29282 100755
|
|
DistroBaker |
93d277 |
--- a/dracut/parse-anaconda-dd.sh
|
|
DistroBaker |
93d277 |
+++ b/dracut/parse-anaconda-dd.sh
|
|
DistroBaker |
93d277 |
@@ -11,7 +11,7 @@
|
|
DistroBaker |
93d277 |
rm -f /tmp/dd_interactive /tmp/dd_net /tmp/dd_disk /tmp/dd_todo
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# parse any dd/inst.dd args found
|
|
DistroBaker |
93d277 |
-for dd in $(getargs inst.dd=); do
|
|
DistroBaker |
93d277 |
+for dd in $(getargs dd= inst.dd=); do
|
|
DistroBaker |
93d277 |
case "$dd" in
|
|
DistroBaker |
93d277 |
# plain 'dd'/'inst.dd': Engage interactive mode!
|
|
DistroBaker |
93d277 |
dd|inst.dd) echo menu > /tmp/dd_interactive ;;
|
|
DistroBaker |
93d277 |
diff --git a/dracut/parse-anaconda-kickstart.sh b/dracut/parse-anaconda-kickstart.sh
|
|
DistroBaker |
93d277 |
index 83b319dc7d..1f4f190db9 100755
|
|
DistroBaker |
93d277 |
--- a/dracut/parse-anaconda-kickstart.sh
|
|
DistroBaker |
93d277 |
+++ b/dracut/parse-anaconda-kickstart.sh
|
|
DistroBaker |
93d277 |
@@ -5,9 +5,9 @@
|
|
DistroBaker |
93d277 |
[ -f /tmp/ks.cfg.done ] && return
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# inst.ks: provide a "URI" for the kickstart file
|
|
DistroBaker |
93d277 |
-kickstart="$(getarg inst.ks=)"
|
|
DistroBaker |
93d277 |
+kickstart="$(getarg ks= inst.ks=)"
|
|
DistroBaker |
93d277 |
if [ -z "$kickstart" ]; then
|
|
DistroBaker |
93d277 |
- getargbool 0 inst.ks && kickstart='nfs:auto'
|
|
DistroBaker |
93d277 |
+ getargbool 0 ks inst.ks && kickstart='nfs:auto'
|
|
DistroBaker |
93d277 |
fi
|
|
DistroBaker |
93d277 |
# no root? the kickstart will probably tell us what our root device is.
|
|
DistroBaker |
93d277 |
[ "$kickstart" ] && [ -z "$root" ] && root="anaconda-kickstart"
|
|
DistroBaker |
93d277 |
@@ -23,7 +23,7 @@ case "${kickstart%%:*}" in
|
|
DistroBaker |
93d277 |
set_neednet
|
|
DistroBaker |
93d277 |
;;
|
|
DistroBaker |
93d277 |
urls) # multiple network kickstarts?
|
|
DistroBaker |
93d277 |
- locations="$(getargs inst.ks=)"
|
|
DistroBaker |
93d277 |
+ locations="$(getargs ks= inst.ks=)"
|
|
DistroBaker |
93d277 |
get_urls "$locations" >/tmp/ks_urls
|
|
DistroBaker |
93d277 |
set_neednet
|
|
DistroBaker |
93d277 |
;;
|
|
DistroBaker |
93d277 |
diff --git a/dracut/parse-anaconda-net.sh b/dracut/parse-anaconda-net.sh
|
|
DistroBaker |
93d277 |
index f09ec8d098..5518546e5b 100755
|
|
DistroBaker |
93d277 |
--- a/dracut/parse-anaconda-net.sh
|
|
DistroBaker |
93d277 |
+++ b/dracut/parse-anaconda-net.sh
|
|
DistroBaker |
93d277 |
@@ -16,9 +16,6 @@ mac_to_bootif() {
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# handle ksdevice (tell us which device to use for ip= stuff later)
|
|
DistroBaker |
93d277 |
export ksdevice=""
|
|
DistroBaker |
93d277 |
-# TODO: Remove support for ksdevice. It's deprecated a long time already
|
|
DistroBaker |
93d277 |
-# this should be inst.ksdevice however, this is deprecated a long time so we don't have
|
|
DistroBaker |
93d277 |
-# any inst.ksdevice. Let's just ignore this for now.
|
|
DistroBaker |
93d277 |
ksdev_val=$(getarg ksdevice=)
|
|
DistroBaker |
93d277 |
if [ -n "$ksdev_val" ]; then
|
|
DistroBaker |
93d277 |
case "$ksdev_val" in
|
|
DistroBaker |
93d277 |
diff --git a/dracut/parse-anaconda-options.sh b/dracut/parse-anaconda-options.sh
|
|
DistroBaker |
93d277 |
index debe8ac0cb..c2735b0e19 100755
|
|
DistroBaker |
93d277 |
--- a/dracut/parse-anaconda-options.sh
|
|
DistroBaker |
93d277 |
+++ b/dracut/parse-anaconda-options.sh
|
|
DistroBaker |
93d277 |
@@ -58,12 +58,6 @@ check_removed_arg() {
|
|
DistroBaker |
93d277 |
fi
|
|
DistroBaker |
93d277 |
}
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg() {
|
|
DistroBaker |
93d277 |
- local removed_arg="$1" new_arg="$2"
|
|
DistroBaker |
93d277 |
- check_removed_arg "$removed_arg" "All usage of Anaconda boot arguments without 'inst.' prefix \
|
|
DistroBaker |
93d277 |
-was removed. Please use $new_arg instead."
|
|
DistroBaker |
93d277 |
-}
|
|
DistroBaker |
93d277 |
-
|
|
DistroBaker |
93d277 |
check_depr_args "blacklist=" "inst.blacklist=%s"
|
|
DistroBaker |
93d277 |
check_depr_arg "nofirewire" "inst.blacklist=firewire_ohci"
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
@@ -83,32 +77,35 @@ check_removed_arg askmethod "Use an appropriate 'inst.repo=' argument instead."
|
|
DistroBaker |
93d277 |
check_removed_arg asknetwork "Use an appropriate 'ip=' argument instead."
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# lang & keymap
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "lang" "inst.lang"
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "keymap" "inst.keymap"
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "lang" "inst.lang"
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "keymap" "inst.keymap"
|
|
DistroBaker |
93d277 |
+
|
|
DistroBaker |
93d277 |
+# debug
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "debug" "inst.debug"
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# repo
|
|
DistroBaker |
93d277 |
check_depr_arg "method=" "repo=%s"
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "repo" "inst.repo"
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "repo" "inst.repo"
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# stage2
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "stage2" "inst.stage2"
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "stage2" "inst.stage2"
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# kickstart
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "ks" "inst.ks"
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "ksdevice" "inst.ks.device"
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "kssendmac" "inst.ks.sendmac"
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "kssendsn" "inst.ks.sendsn"
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "ks" "inst.ks"
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "ksdevice" "inst.ks.device"
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "kssendmac" "inst.ks.sendmac"
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "kssendsn" "inst.ks.sendsn"
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# Ignore self-signed SSL certs
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "noverifyssl" "inst.noverifyssl"
|
|
DistroBaker |
93d277 |
-if getargbool 0 inst.noverifyssl; then
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "noverifyssl" "inst.noverifyssl"
|
|
DistroBaker |
93d277 |
+if getargbool 0 noverifyssl inst.noverifyssl; then
|
|
DistroBaker |
93d277 |
# Tell dracut to use curl --insecure
|
|
DistroBaker |
93d277 |
echo "rd.noverifyssl" >> /etc/cmdline.d/75-anaconda-options.conf
|
|
DistroBaker |
93d277 |
fi
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# updates
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "updates" "inst.updates"
|
|
DistroBaker |
93d277 |
-if updates=$(getarg inst.updates); then
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "updates=" "inst.updates"
|
|
DistroBaker |
93d277 |
+if updates=$(getarg updates inst.updates); then
|
|
DistroBaker |
93d277 |
if [ -n "$updates" ]; then
|
|
DistroBaker |
93d277 |
export anac_updates=$updates
|
|
DistroBaker |
93d277 |
case $updates in
|
|
DistroBaker |
93d277 |
@@ -122,11 +119,11 @@ if updates=$(getarg inst.updates); then
|
|
DistroBaker |
93d277 |
fi
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# for vnc bring network up in initramfs so that cmdline configuration is used
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "vnc" "inst.vnc"
|
|
DistroBaker |
93d277 |
-getargbool 0 inst.vnc && warn "anaconda requiring network for vnc" && set_neednet
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "vnc" "inst.vnc"
|
|
DistroBaker |
93d277 |
+getargbool 0 vnc inst.vnc && warn "anaconda requiring network for vnc" && set_neednet
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# Driver Update Disk
|
|
DistroBaker |
93d277 |
-check_removed_no_inst_arg "dd" "inst.dd"
|
|
DistroBaker |
93d277 |
+warn_renamed_arg "dd" "inst.dd"
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
# re-read the commandline args
|
|
DistroBaker |
93d277 |
unset CMDLINE
|
|
DistroBaker |
93d277 |
diff --git a/dracut/parse-anaconda-repo.sh b/dracut/parse-anaconda-repo.sh
|
|
DistroBaker |
93d277 |
index fdc937a95a..a1f96b3d98 100755
|
|
DistroBaker |
93d277 |
--- a/dracut/parse-anaconda-repo.sh
|
|
DistroBaker |
93d277 |
+++ b/dracut/parse-anaconda-repo.sh
|
|
DistroBaker |
93d277 |
@@ -4,8 +4,8 @@
|
|
DistroBaker |
93d277 |
# If there's a root= arg, we'll just use that
|
|
DistroBaker |
93d277 |
getarg root= >/dev/null && return
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
-repo="$(getarg inst.repo=)"
|
|
DistroBaker |
93d277 |
-stage2="$(getarg inst.stage2=)"
|
|
DistroBaker |
93d277 |
+repo="$(getarg repo= inst.repo=)"
|
|
DistroBaker |
93d277 |
+stage2="$(getarg stage2= inst.stage2=)"
|
|
DistroBaker |
93d277 |
|
|
DistroBaker |
93d277 |
arg="repo"
|
|
DistroBaker |
93d277 |
# default to using repo, but if we have stage2=, use that
|
|
DistroBaker |
93d277 |
@@ -26,7 +26,7 @@ if [ -n "$repo" ]; then
|
|
DistroBaker |
93d277 |
;;
|
|
DistroBaker |
93d277 |
urls)
|
|
DistroBaker |
93d277 |
root="anaconda-net:urls"
|
|
DistroBaker |
93d277 |
- locations="$(getargs inst.stage2=)"
|
|
DistroBaker |
93d277 |
+ locations="$(getargs stage2= inst.stage2=)"
|
|
DistroBaker |
93d277 |
get_urls "$locations" >/tmp/stage2_urls
|
|
DistroBaker |
93d277 |
set_neednet
|
|
DistroBaker |
93d277 |
;;
|
|
DistroBaker |
93d277 |
--
|
|
DistroBaker |
93d277 |
2.29.2
|
|
DistroBaker |
93d277 |
|