From nobody Sun Feb 8 22:08:05 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) client-ip=8.43.85.245; envelope-from=devel-bounces@lists.libvirt.org; helo=lists.libvirt.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass(p=reject dis=none) header.from=lists.libvirt.org ARC-Seal: i=1; a=rsa-sha256; t=1770289519; cv=none; d=zohomail.com; s=zohoarc; b=jtGomMq1VY3XmqCJSRePCiP81tW6/FNaINcERPFO6nKNKQonvKJrm8gdToqSAoJxKZEiOluRKjvlDaQWtDPJ2ndlSFLW6fGOBcJ0x4O3GEDtOvTp+LBbJieHrfI9vZcjKmgSub3qd7lEnVdYK+Dohqac/GorUwS/m7KvjPMQlcg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1770289519; h=Content-Type:Content-Transfer-Encoding:Date:Date:From:From:List-Subscribe:List-Post:List-Owner:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:Reply-To:Subject:Subject:To:To:Message-Id:Cc; bh=695wgwVErZcUpTAP/0RjvSerYEmGBH+vRLpoxCP2JBw=; b=GWl4SP8sSVoZUk6i/JMdv1ip/+5J6aGuN7fnakvLV2tmrk7L9u/UKE71YYqD6mz0P64roJFGAbwjx9aOmX7mt7Hz3Oc8D73OZRues+N8FqUbziAYRVCpI/a+GMeCkTrzCP93fdUpaM4lXvdtkIX/aWSaQ0xqU0YD+LfGrkec/bs= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 17702895197341000.718984967797; Thu, 5 Feb 2026 03:05:19 -0800 (PST) Received: by lists.libvirt.org (Postfix, from userid 993) id 6F059418E2; Thu, 5 Feb 2026 06:05:18 -0500 (EST) Received: from [172.19.199.6] (lists.libvirt.org [8.43.85.245]) by lists.libvirt.org (Postfix) with ESMTP id 8B6FC41AEE; Thu, 5 Feb 2026 06:04:37 -0500 (EST) Received: by lists.libvirt.org (Postfix, from userid 993) id B1E374185E; Thu, 5 Feb 2026 06:04:34 -0500 (EST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (3072 bits) server-digest SHA256) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id E5EE13FABD for ; Thu, 5 Feb 2026 06:04:33 -0500 (EST) Received: from mx-prod-mc-06.mail-002.prod.us-west-2.aws.redhat.com (ec2-35-165-154-97.us-west-2.compute.amazonaws.com [35.165.154.97]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-402-SmVub1hmPbyhQVh4cpjK3Q-1; Thu, 05 Feb 2026 06:04:32 -0500 Received: from mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.17]) (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 mx-prod-mc-06.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 598C8180025A for ; Thu, 5 Feb 2026 11:04:31 +0000 (UTC) Received: from dosh.home.annexia.org.com (unknown [10.45.227.50]) by mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 88B3F19373D8 for ; Thu, 5 Feb 2026 11:04:30 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-5.0 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED,RCVD_IN_VALIDITY_RPBL_BLOCKED, RCVD_IN_VALIDITY_SAFE_BLOCKED,SPF_PASS autolearn=unavailable autolearn_force=no version=4.0.1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1770289473; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=695wgwVErZcUpTAP/0RjvSerYEmGBH+vRLpoxCP2JBw=; b=b3s5iljCIVxrdWlL+Rb8KMMPXB1l5eqMlEpRK1NAU1rTQfJstuYYYg1OKGEyVxg675TH03 Sdb/7uQYeIK1cnSLEQ7OzRCm6gjofsIH8Sscmtu+MMp4nK3kzX61RGdhIpyvrVf6WJuZc5 9wabYtTb3dNAjlRNkzwTJ7943oTw+3E= X-MC-Unique: SmVub1hmPbyhQVh4cpjK3Q-1 X-Mimecast-MFC-AGG-ID: SmVub1hmPbyhQVh4cpjK3Q_1770289471 To: devel@lists.libvirt.org Subject: [PATCH] src/esx/esx_vi.c: Debug path element comparisons Date: Thu, 5 Feb 2026 11:04:24 +0000 Message-ID: <20260205110427.1538580-1-rjones@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.17 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: SQvs1su4NLMXJhMQSY0cS74n9TnA1TW23u4oIzueltY_1770289471 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Message-ID-Hash: VJSKSDY32325SLOYGFZ4LM5A4TMYLOIV X-Message-ID-Hash: VJSKSDY32325SLOYGFZ4LM5A4TMYLOIV X-MailFrom: rjones@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; header-match-devel.lists.libvirt.org-0; 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: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: "Richard W.M. Jones via Devel" Reply-To: "Richard W.M. Jones" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZM-MESSAGEID: 1770289521396154100 Content-Type: text/plain; charset="utf-8"; x-default="true" Libvirt vpx:// and esx:// URIs are quite obscure. In particular it is very difficult to construct a correct path to a VMware resource. Basically you are iterating over VMware structures blindly with no way to know what your choices are at each level in the path. This commit doesn't directly address this. It's still difficult. But at least let's add the true path choices to the debug output so someone could in theory use 'LIBVIRT_DEBUG=3D1' to find out what possible choices exist at a path level. For example this command fails because the label (which looks like an IPv6 address, but is really a label) should use "::" instead of ":0:": LIBVIRT_DEBUG=3D1 virsh -c 'vpx://root@.../data/aaaa:52:0:49e0:2eea:7fff:= fee6:eca0/?no_verify=3D1' In the debugging output we now print: 2026-02-05 10:58:25.421+0000: 1528876: debug : esxVI_LookupManagedObjectH= elper:4956 : comparing path element 'aaaa:52:0:49e0:2eea:7fff:fee6:eca0' wi= th candidate name 'aaaa:52::49e0:2eea:7fff:fee6:eca0' 2026-02-05 10:58:25.421+0000: 1528876: error : esxVI_Context_LookupManage= dObjectsByPath:1098 : internal error: Could not find compute resource speci= fied in '/data/aaaa:52:0:49e0:2eea:7fff:fee6:eca0/' In an ideal world we should improve the error message to show the possible choices, but the way the code is structured makes that prohibitive. Related: https://issues.redhat.com/browse/RHEL-145080 Reviewed-by: Peter Krempa --- src/esx/esx_vi.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/esx/esx_vi.c b/src/esx/esx_vi.c index 8d2ffb3f8f..cfd783622d 100644 --- a/src/esx/esx_vi.c +++ b/src/esx/esx_vi.c @@ -4953,6 +4953,8 @@ esxVI_LookupManagedObjectHelper(esxVI_Context *ctx, goto cleanup; } =20 + VIR_DEBUG("comparing path element '%s' with candidate name '%s= '", + name, name_candidate); if (STREQ(name_candidate, name)) { /* Found item with matching name */ break; --=20 2.52.0