From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id C70646ACE0 for ; Mon, 25 Jan 2021 09:11:28 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id B34842F46E for ; Mon, 25 Jan 2021 09:10:58 +0100 (CET) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [212.186.127.180]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS id 92A1A2F460 for ; Mon, 25 Jan 2021 09:10:57 +0100 (CET) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 5F3A0446F4 for ; Mon, 25 Jan 2021 09:10:57 +0100 (CET) From: =?UTF-8?q?Fabian=20Gr=C3=BCnbichler?= To: pve-devel@lists.proxmox.com Date: Mon, 25 Jan 2021 09:10:38 +0100 Message-Id: <20210125081038.1833009-1-f.gruenbichler@proxmox.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 0 AWL 0.027 Adjusted score from AWL reputation of From: address KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment 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 Subject: [pve-devel] [PATCH storage] drop absolute udevadm path X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Jan 2021 08:11:28 -0000 the compat symlink from bin to sbin has been dropped with bullseye, and we rely on PATH begin set properly in our daemons/CLI tools anyway.. Signed-off-by: Fabian Grünbichler --- PVE/Diskmanage.pm | 3 +-- PVE/Storage.pm | 5 +---- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/PVE/Diskmanage.pm b/PVE/Diskmanage.pm index 2552add..57d17f1 100644 --- a/PVE/Diskmanage.pm +++ b/PVE/Diskmanage.pm @@ -17,7 +17,6 @@ my $ZPOOL = "/sbin/zpool"; my $SGDISK = "/sbin/sgdisk"; my $PVS = "/sbin/pvs"; my $LVS = "/sbin/lvs"; -my $UDEVADM = "/bin/udevadm"; my $LSBLK = "/bin/lsblk"; sub verify_blockdev_path { @@ -312,7 +311,7 @@ sub get_udev_info { my $info = ""; my $data = {}; eval { - run_command([$UDEVADM, 'info', '-p', $dev, '--query', 'all'], outfunc => sub { + run_command(['udevadm', 'info', '-p', $dev, '--query', 'all'], outfunc => sub { my ($line) = @_; $info .= "$line\n"; }); diff --git a/PVE/Storage.pm b/PVE/Storage.pm index bd6e15e..cf309ad 100755 --- a/PVE/Storage.pm +++ b/PVE/Storage.pm @@ -103,8 +103,6 @@ if ( -d '/usr/share/perl5/PVE/Storage/Custom' ) { # initialize all plugins PVE::Storage::Plugin->init(); -my $UDEVADM = '/sbin/udevadm'; - our $iso_extension_re = qr/\.(?:iso|img)/i; # PVE::Storage utility functions @@ -1031,8 +1029,7 @@ sub activate_storage { # only call udevsettle if there are events if ($newseq > $cache->{uevent_seqnum}) { - my $timeout = 30; - system ("$UDEVADM settle --timeout=$timeout"); # ignore errors + system ("udevadm settle --timeout=30"); # ignore errors $cache->{uevent_seqnum} = $newseq; } -- 2.20.1