From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [45.144.208.40]) by lore.proxmox.com (Postfix) with ESMTPS id 1297C1FF0DF for ; Fri, 28 Aug 2026 15:32:43 +0200 (CEST) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id 1D9A12157E; Fri, 28 Aug 2026 15:31:15 +0200 (CEST) From: Shannon Sterz To: pve-devel@lists.proxmox.com Subject: [PATCH installer 19/21] unconfigured: add restore mode to unconfigured.sh Date: Fri, 28 Aug 2026 15:30:28 +0200 Message-ID: <20260828133030.351140-20-s.sterz@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20260828133030.351140-1-s.sterz@proxmox.com> References: <20260828133030.351140-1-s.sterz@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1787923825207 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.859 Adjusted score from AWL reputation of From: address DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment (newer systems) RCVD_IN_DNSWL_MED -2.3 Sender listed at https://www.dnswl.org/, medium trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: ZA67HGKHDH6O27AJRALJ5Z4MWL6CH4QX X-Message-ID-Hash: ZA67HGKHDH6O27AJRALJ5Z4MWL6CH4QX X-MailFrom: s.sterz@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Signed-off-by: Shannon Sterz --- Proxmox/Install/Config.pm | 2 +- unconfigured.sh | 18 +++++++++++++++--- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/Proxmox/Install/Config.pm b/Proxmox/Install/Config.pm index 00b713f..299bab1 100644 --- a/Proxmox/Install/Config.pm +++ b/Proxmox/Install/Config.pm @@ -46,7 +46,7 @@ sub parse_kernel_cmdline { my @filtered = grep { $_ !~ m/^(BOOT_IMAGE|root|ramdisk_size|splash|vga)=\S+$/ && $_ !~ m/^(ro|rw|quiet)$/ - && $_ !~ m/^(prox(debug|tui|auto)|proxmox-\S+)$/ + && $_ !~ m/^(prox(debug|tui|auto|restore)|proxmox-\S+)$/ } split(/\s+/, $cmdline); $cfg->{target_cmdline} = join(' ', @filtered); diff --git a/unconfigured.sh b/unconfigured.sh index 6af29e8..8e4300d 100755 --- a/unconfigured.sh +++ b/unconfigured.sh @@ -12,6 +12,7 @@ parse_cmdline() { proxdebug=0 proxtui=0 serial=0 + proxrestore=0 # shellcheck disable=SC2013 # per word splitting is wanted here for par in $(cat /proc/cmdline); do case $par in @@ -27,6 +28,9 @@ parse_cmdline() { console=ttyS*|console=ttyAMA*) serial=1 ;; + proxrestore|proxmox-restore-mode) + proxrestore=1 + ;; esac done; } @@ -349,9 +353,17 @@ sysctl -w kernel.printk='4 4 1 7' /usr/bin/proxmox-low-level-installer dump-env -if [ $proxtui -ne 0 ]; then - echo "Starting the TUI installer" - /usr/bin/proxmox-tui-installer 2>/dev/tty2 +if [ $proxtui -ne 0 ] || [ $proxrestore -ne 0 ]; then + if [ $proxrestore -ne 0 ]; then + echo "Caching device info from udev" + /usr/bin/proxmox-low-level-installer dump-udev + + echo "Starting the TUI installer in restore mode" + /usr/bin/proxmox-tui-installer -r 2>/dev/tty2 + else + echo "Starting the TUI installer" + /usr/bin/proxmox-tui-installer 2>/dev/tty2 + fi elif [ $start_auto_installer -ne 0 ]; then echo "Caching device info from udev" /usr/bin/proxmox-low-level-installer dump-udev -- 2.47.3