]> git.proxmox.com Git - pve-installer.git/commitdiff
serial install: fix console parameter parsing
authorStoiko Ivanov <s.ivanov@proxmox.com>
Tue, 14 Nov 2023 17:31:48 +0000 (18:31 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Tue, 14 Nov 2023 17:34:11 +0000 (18:34 +0100)
The regex matching in Proxmox::Install::Config was blindly copied from
above - so the other parameters are also likely to not get recognized
if they are the last on the cmdline

Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
Proxmox/Install.pm
Proxmox/Install/Config.pm

index a289037e804af6896d46f2803fb9473cbf9c5824..66adb2dc5f262faac895c17c6da693d928e59c84 100644 (file)
@@ -1154,7 +1154,7 @@ _EOD
        update_progress(0.8, 0.95, 1, "make system bootable");
        my $console_param='';
        if (my $console = Proxmox::Install::Config::get_console()) {
-           my $console_param="console=$console";;
+           $console_param="console=$console";
            my $console_snippet = "GRUB_CMDLINE_LINUX=\"\$GRUB_CMDLINE_LINUX $console_param\"";
            file_write_all("$targetdir/etc/default/grub.d/console.cfg", $console_snippet);
        }
index 55e53c7e78d8d22e1f801c105b7dac08faea5fd1..5e8025542d3c71a9e8be8cb586e5a6c019546f43 100644 (file)
@@ -43,7 +43,7 @@ my sub parse_kernel_cmdline {
        }
     }
 
-    if ($cmdline =~ m/console=(\S+)[\s\n]/i) {
+    if ($cmdline =~ m/console=(\S+)[\s\n]?/i) {
            $cfg->{console} = $1;
     }