From patchwork Tue Jun 7 21:05:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Terry Wilson X-Patchwork-Id: 1640139 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=icWT7jDv; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.138; helo=smtp1.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (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 bilbo.ozlabs.org (Postfix) with ESMTPS id 4LHjZD31wBz9sFx for ; Wed, 8 Jun 2022 07:05:56 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 89BF3841DB; Tue, 7 Jun 2022 21:05:54 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ASLi1f50TDDV; Tue, 7 Jun 2022 21:05:53 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [IPv6:2605:bc80:3010:104::8cd3:938]) by smtp1.osuosl.org (Postfix) with ESMTPS id E1C03841BC; Tue, 7 Jun 2022 21:05:52 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id AD119C007A; Tue, 7 Jun 2022 21:05:52 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133]) by lists.linuxfoundation.org (Postfix) with ESMTP id EC785C002D for ; Tue, 7 Jun 2022 21:05:51 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id DB8BE40332 for ; Tue, 7 Jun 2022 21:05:51 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp2.osuosl.org (amavisd-new); dkim=pass (1024-bit key) header.d=redhat.com Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aR_t6b_EhHv1 for ; Tue, 7 Jun 2022 21:05:51 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by smtp2.osuosl.org (Postfix) with ESMTPS id 5098640017 for ; Tue, 7 Jun 2022 21:05:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1654635949; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=VKiX34bipnlictwVUmuW1bpzBHbWhnAoYN+zRkajaKM=; b=icWT7jDvV2jf+XbFbahDypzUCXhlihmaASIU/MMAewtxtIps9snj9bkWbu4ovz0ji3wjIe 89muO2/z3q2sdxbe9OoYhrrN30vbicsmg7or+qUe8bafk7w31bru34uuX45HVyhSYODHc7 nbzfIvRQ+1knTor/l6z+WwQQPkPBEPA= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-264-tN_gzmpKNzeZH2wPZsdJJQ-1; Tue, 07 Jun 2022 17:05:46 -0400 X-MC-Unique: tN_gzmpKNzeZH2wPZsdJJQ-1 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 5C3713C0F720; Tue, 7 Jun 2022 21:05:46 +0000 (UTC) Received: from fedora.redhat.com (unknown [10.22.33.61]) by smtp.corp.redhat.com (Postfix) with ESMTP id 25539492C3B; Tue, 7 Jun 2022 21:05:46 +0000 (UTC) From: Terry Wilson To: dev@openvswitch.org Date: Tue, 7 Jun 2022 16:05:43 -0500 Message-Id: <20220607210543.3075469-2-twilson@redhat.com> In-Reply-To: <20220607210543.3075469-1-twilson@redhat.com> References: <20220607210543.3075469-1-twilson@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.85 on 10.11.54.9 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=twilson@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Cc: dceara@openvswitch.org Subject: [ovs-dev] [PATCH v3 2/2] Ensure pid belongs to ovsdb-server in ovn-ctl X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" When checking if ovsdb-server is running, ensure that the binary we are going to run matches the one actually running with the the pid that was in our pidfile. Signed-off-by: Terry Wilson --- utilities/ovn-ctl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utilities/ovn-ctl b/utilities/ovn-ctl index 14d37a3d6..e2f05915b 100755 --- a/utilities/ovn-ctl +++ b/utilities/ovn-ctl @@ -200,7 +200,7 @@ start_ovsdb__() { ovn_install_dir "$ovn_etcdir" # Check and eventually start ovsdb-server for DB - if pidfile_is_running $db_pid_file; then + if pidfile_is_running $db_pid_file ovsdb-server; then return fi