From nobody Tue May 7 23:43:51 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zoho.com; dkim=fail spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1491208597155871.8260851984915; Mon, 3 Apr 2017 01:36:37 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 8212CC04B927; Mon, 3 Apr 2017 08:36:12 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 22926A0A11; Mon, 3 Apr 2017 08:36:12 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 24C4118523CD; Mon, 3 Apr 2017 08:36:09 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v338a7wO002594 for ; Mon, 3 Apr 2017 04:36:07 -0400 Received: by smtp.corp.redhat.com (Postfix) id D49D984DA4; Mon, 3 Apr 2017 08:36:07 +0000 (UTC) Received: from mx1.redhat.com (ext-mx03.extmail.prod.ext.phx2.redhat.com [10.5.110.27]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 997FA84DB2; Mon, 3 Apr 2017 08:36:04 +0000 (UTC) Received: from mail-pg0-f68.google.com (mail-pg0-f68.google.com [74.125.83.68]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 6489483F42; Mon, 3 Apr 2017 08:36:03 +0000 (UTC) Received: by mail-pg0-f68.google.com with SMTP id g2so28279604pge.2; Mon, 03 Apr 2017 01:36:03 -0700 (PDT) Received: from prerna-saxena.dev.eng.nutanix.com. (206-15-90-246.static.twtelecom.net. [206.15.90.246]) by smtp.gmail.com with ESMTPSA id e76sm24218555pfk.75.2017.04.03.01.36.01 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 03 Apr 2017 01:36:01 -0700 (PDT) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 8212CC04B927 Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 8212CC04B927 Authentication-Results: mx1.redhat.com; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="REqu7HUJ" DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 6489483F42 Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=saxenap.ltc@gmail.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 6489483F42 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=i2/wI7g4XfXpqvxDYkmzV2wd3wJavcGJYecWZcefY/U=; b=REqu7HUJ4RRG8hTGygR/eVThNqeE7AtpF/sPDeGAWZQIqZ3vOGBvsIfxvsETaaeiai 8LECECkVnL6WYDQjEE7csfniOaZldP1RbavLeIz2M6zgWqJjnHgN1AQX/VEz3pkwxhiw ChfaA+g5cG7wtsOLAI/bhKELLJ67rJdiwgx6LEXfjCbHeC494rc6QE6pS/v/KBhp/29S ATvb7RNkotbclxEcNqomA47EaixUPeJPXpGGhfn90yvPFHFlfVoE50cqNnGlkkY+VUnq +0+yibYDF+57zIasnZUAH4V4w8yUL6t40ZQ7+nw8oxIEW8HdANkkHxqKbvemn2Vp37ol 6YOg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=i2/wI7g4XfXpqvxDYkmzV2wd3wJavcGJYecWZcefY/U=; b=PWwPbADh73G8OaIX0r+yQpM4DB/vwI8hpo6pVVvFJ+gj/CVcMF+zIlVOHR2BfJF83N k3JYCbzYwEPU+E5yTAkehBl9icd/LpHHFNiST8Ez+ZbJIT9EYqNQ6yOQo4yIQw4t4iuc 3JEFraFnIG8wac3u8v/6pf92A/f4Gj6/oKlIWNSxp1KyCK8kvD8ZR3C8uRLgLkR6QkfY 7howZU4QzjjH4jAgHAff6i742biNoa/R2ziExEJGzDLFej+Krw+Qs0+euCtwwKWThpsx S3ffuHAeocM/F338oAI3GS4jT0jPH6lnN/J/3P2Dbkmr2ZrG5ErlJxdTpuHLPKHo17M4 NxoA== X-Gm-Message-State: AFeK/H1MjbaCbY3mba+de2Qy1F1DmzWZLTsnV/dmK6xvbKDtMi+ixv0hG88JhoyXU+YPLQ== X-Received: by 10.99.108.74 with SMTP id h71mr16669419pgc.18.1491208562573; Mon, 03 Apr 2017 01:36:02 -0700 (PDT) From: Prerna Saxena To: libvir-list@redhat.com Date: Mon, 3 Apr 2017 01:35:53 -0700 Message-Id: <1491208554-20716-2-git-send-email-saxenap.ltc@gmail.com> In-Reply-To: <1491208554-20716-1-git-send-email-saxenap.ltc@gmail.com> References: <1491208554-20716-1-git-send-email-saxenap.ltc@gmail.com> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Mon, 03 Apr 2017 08:36:03 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Mon, 03 Apr 2017 08:36:03 +0000 (UTC) for IP:'74.125.83.68' DOMAIN:'mail-pg0-f68.google.com' HELO:'mail-pg0-f68.google.com' FROM:'saxenap.ltc@gmail.com' RCPT:'' X-RedHat-Spam-Score: 1.17 * (BAYES_50, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, RCVD_IN_SORBS_SPAM, SPF_PASS) 74.125.83.68 mail-pg0-f68.google.com 74.125.83.68 mail-pg0-f68.google.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.27 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-loop: libvir-list@redhat.com Cc: pkrempa@redhat.com Subject: [libvirt] [PATCH v2 1/2] Debug: Add DEBUG messages for when a client has opened/closed connection. X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Mon, 03 Apr 2017 08:36:34 +0000 (UTC) X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" While tracing connections from a remote client, it helps to keep track of the connection lifecycle. Messages such as the following : error : virNetSocketReadWire:1574 : End of file while reading data: Input/o= utput error are rather unhelpful. They do not indicate if the client had earlier asked = for connection closure via libvirt API. This patch introduces messages to annotate when a client connected/disconne= cted. Signed-off-by: Prerna Saxena --- src/rpc/virnetserverclient.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/rpc/virnetserverclient.c b/src/rpc/virnetserverclient.c index 85857bc..24c9c33 100644 --- a/src/rpc/virnetserverclient.c +++ b/src/rpc/virnetserverclient.c @@ -964,8 +964,11 @@ void virNetServerClientClose(virNetServerClientPtr cli= ent) virNetServerClientCloseFunc cf; virKeepAlivePtr ka; =20 + VIR_DEBUG("Free'ing up resources for client=3D%p sock=3D%d", client, + virNetServerClientGetFD(client)); + virObjectLock(client); - VIR_DEBUG("client=3D%p", client); + if (!client->sock) { virObjectUnlock(client); return; @@ -1039,10 +1042,14 @@ void virNetServerClientDelayedClose(virNetServerCli= entPtr client) virObjectLock(client); client->delayedClose =3D true; virObjectUnlock(client); + VIR_DEBUG("Client=3D%p sock=3D%d requested closure of connection.", + client, virNetServerClientGetFD(client)); } =20 void virNetServerClientImmediateClose(virNetServerClientPtr client) { + VIR_DEBUG("Client %p sock %d closed the connection", client, + virNetServerClientGetFD(client)); virObjectLock(client); client->wantClose =3D true; virObjectUnlock(client); @@ -1151,6 +1158,7 @@ static void virNetServerClientDispatchRead(virNetServ= erClientPtr client) if (client->rx->nfds =3D=3D 0) { if (virNetServerClientRead(client) < 0) { client->wantClose =3D true; + VIR_WARN("Client=3D%p sock=3D%p closed connection", client, cl= ient->sock); return; /* Error */ } } --=20 1.8.1.2 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Tue May 7 23:43:51 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zoho.com; dkim=fail spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 14912086343982.0399601351773526; Mon, 3 Apr 2017 01:37:14 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 3121661D02; Mon, 3 Apr 2017 08:37:13 +0000 (UTC) Received: from colo-mx.corp.redhat.com (unknown [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id F028A5C887; Mon, 3 Apr 2017 08:37:12 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id A5F9E5EC60; Mon, 3 Apr 2017 08:37:12 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v338aBBZ002616 for ; Mon, 3 Apr 2017 04:36:11 -0400 Received: by smtp.corp.redhat.com (Postfix) id 5A4917E2E5; Mon, 3 Apr 2017 08:36:11 +0000 (UTC) Received: from mx1.redhat.com (ext-mx03.extmail.prod.ext.phx2.redhat.com [10.5.110.27]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 4F11B77EC9; Mon, 3 Apr 2017 08:36:05 +0000 (UTC) Received: from mail-pg0-f67.google.com (mail-pg0-f67.google.com [74.125.83.67]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 921EA81F01; Mon, 3 Apr 2017 08:36:04 +0000 (UTC) Received: by mail-pg0-f67.google.com with SMTP id g2so28279685pge.2; Mon, 03 Apr 2017 01:36:04 -0700 (PDT) Received: from prerna-saxena.dev.eng.nutanix.com. (206-15-90-246.static.twtelecom.net. [206.15.90.246]) by smtp.gmail.com with ESMTPSA id e76sm24218555pfk.75.2017.04.03.01.36.02 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 03 Apr 2017 01:36:02 -0700 (PDT) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 3121661D02 Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 3121661D02 Authentication-Results: mx1.redhat.com; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Hksa78Fp" DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 921EA81F01 Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=saxenap.ltc@gmail.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 921EA81F01 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=iEaw1C681bKrfQgMPGTWByVebGJR/K1wSPs0LYDgCJo=; b=Hksa78FptslOTbYvrvm51nY09wK7G0PzM2OmxJ/llYiIc1Q/S9z/luhQBpWIgwEGxH N/AgFEPwyCx+eZ0rIG9rJ9LAN/Z+JrrEhyPPVRwQDTRad2BUBJkdvThDioOoAECdmbo7 98ytWhLGbYHJlHzaHFoLM9QNGkbgYvJCRiP3lJVBkeYNkvARS9zuy9MUb5QB569ey5WL 2JlKkvAs2qHOSXzPGWV8bBTA4pXenQe86WvH/t+B2f2/8KdiTFjunFrrVdVqCVEMNQTs vYoIWF0796tMmXiSaX/6F6uTjeVBqTycw96OIAEQNhzD8lRoJ8w+BH6E2ZO8HZqsD/sG Zrgw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=iEaw1C681bKrfQgMPGTWByVebGJR/K1wSPs0LYDgCJo=; b=PTDmseDwO2HsbJvEzjQb89/DhgzUpWLtzpdXdXgVIYMBUz/+YaakF2okcle/THFI5d XtN0cGVRxFPtNlzfSQPuOsdYlNPbY+Xt9kUVqe9cHPBB0IOeU7cXV0YViOBzTBuhpNQr i8HzLXgFMlG6jT8QpuFdLNsFLAbHYPKMjZ7yoWcZaEZjiklhrbyL/+If+A4oM51afYL+ 44hNFii3Kvz/2cYEfo17yQJg0YWthoQmip+ZKEWjrPUdpNFPtJF4Xq17t27yOgrepcP3 HT/ZAchC6kiPSyFWUMVk/fX+ny4QWzxhwalpQKSnm8CJcrgcWRrMHrG4vJUKOdpCKTMl fSbw== X-Gm-Message-State: AFeK/H2B507qqmBBGAgXudxHKontVLmrtoVibeYsCgH66/P7nZAcuYGqquJ9+IUt0WRlaw== X-Received: by 10.84.241.14 with SMTP id a14mr19797660pll.117.1491208563812; Mon, 03 Apr 2017 01:36:03 -0700 (PDT) From: Prerna Saxena To: libvir-list@redhat.com Date: Mon, 3 Apr 2017 01:35:54 -0700 Message-Id: <1491208554-20716-3-git-send-email-saxenap.ltc@gmail.com> In-Reply-To: <1491208554-20716-1-git-send-email-saxenap.ltc@gmail.com> References: <1491208554-20716-1-git-send-email-saxenap.ltc@gmail.com> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Mon, 03 Apr 2017 08:36:04 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Mon, 03 Apr 2017 08:36:04 +0000 (UTC) for IP:'74.125.83.67' DOMAIN:'mail-pg0-f67.google.com' HELO:'mail-pg0-f67.google.com' FROM:'saxenap.ltc@gmail.com' RCPT:'' X-RedHat-Spam-Score: 1.17 * (BAYES_50, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, RCVD_IN_SORBS_SPAM, SPF_PASS) 74.125.83.67 mail-pg0-f67.google.com 74.125.83.67 mail-pg0-f67.google.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.27 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-loop: libvir-list@redhat.com Cc: pkrempa@redhat.com Subject: [libvirt] [PATCH v2 2/2] Debug: Report VM errors more concisely. X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Mon, 03 Apr 2017 08:37:13 +0000 (UTC) X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Current logs: error : qemuProcessFindDomainDiskByAlias:411 : internal error: no disk foun= d with alias ide0-0-0 There is no way to find which VM was seeing this error. Makes debugging very hard, and the message itself is no good. Signed-off-by: Prerna Saxena --- src/qemu/qemu_process.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c index e450d06..0a052e8 100644 --- a/src/qemu/qemu_process.c +++ b/src/qemu/qemu_process.c @@ -367,8 +367,8 @@ qemuProcessFindDomainDiskByAlias(virDomainObjPtr vm, } =20 virReportError(VIR_ERR_INTERNAL_ERROR, - _("no disk found with alias %s"), - alias); + _("VM %s: no disk found with alias %s"), + vm->def->name, alias); return NULL; } =20 --=20 1.8.1.2 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list