From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 31616CCA48C for ; Tue, 26 Jul 2022 08:16:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1658823372; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=8zNZCelfzEmtQ+UFUUbAuVbjxrGLIIazP20OO6oHsCc=; b=KnB7+MjzZtf0ucm9VfFKAHeM7jvsG96aJ157ySF4Kolw6WcUnsO0D3sRXkWE2ZyMZ2x9oG xuTrxLt8acRiEPZnBRBciRHZt578ELygObpKsE3u7CFber5DdPdirAweSfX514abLqVXwz d3yyIdQk35VpxB7RF1BZ4vj9sS/6fCE= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-91-ArBqW69IOIezDrdzyX3mvw-1; Tue, 26 Jul 2022 04:16:09 -0400 X-MC-Unique: ArBqW69IOIezDrdzyX3mvw-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 6D7A9185A7A4; Tue, 26 Jul 2022 08:16:06 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2819D1121319; Tue, 26 Jul 2022 08:16:01 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id C5F1F1945D89; Tue, 26 Jul 2022 08:16:00 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 71E511947040 for ; Thu, 21 Jul 2022 11:40:48 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 63A01909FF; Thu, 21 Jul 2022 11:40:48 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast07.extmail.prod.ext.rdu2.redhat.com [10.11.55.23]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 5E5DC18ECB for ; Thu, 21 Jul 2022 11:40:48 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 392C73C0E20E for ; Thu, 21 Jul 2022 11:40:48 +0000 (UTC) Received: from mx0b-00154904.pphosted.com (mx0b-00154904.pphosted.com [148.163.137.20]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-144-IlSmMMdtMhmRLXUhokDZpw-1; Thu, 21 Jul 2022 07:40:40 -0400 X-MC-Unique: IlSmMMdtMhmRLXUhokDZpw-1 Received: from pps.filterd (m0170394.ppops.net [127.0.0.1]) by mx0b-00154904.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 26L1AmGx019692 for ; Thu, 21 Jul 2022 02:52:13 -0400 Received: from mx0b-00154901.pphosted.com (mx0b-00154901.pphosted.com [67.231.157.37]) by mx0b-00154904.pphosted.com (PPS) with ESMTPS id 3hbqw7upje-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 21 Jul 2022 02:52:13 -0400 Received: from pps.filterd (m0144103.ppops.net [127.0.0.1]) by mx0b-00154901.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 26L6TEG1030402 for ; Thu, 21 Jul 2022 02:52:12 -0400 Received: from nam12-bn8-obe.outbound.protection.outlook.com (mail-bn8nam12lp2175.outbound.protection.outlook.com [104.47.55.175]) by mx0b-00154901.pphosted.com (PPS) with ESMTPS id 3herp7xche-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Thu, 21 Jul 2022 02:52:12 -0400 Received: from DM6PR19MB2491.namprd19.prod.outlook.com (2603:10b6:5:189::11) by DM6PR19MB4107.namprd19.prod.outlook.com (2603:10b6:5:246::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5458.19; Thu, 21 Jul 2022 06:52:10 +0000 Received: from DM6PR19MB2491.namprd19.prod.outlook.com ([fe80::3dff:7d1d:910b:c37e]) by DM6PR19MB2491.namprd19.prod.outlook.com ([fe80::3dff:7d1d:910b:c37e%6]) with mapi id 15.20.5458.019; Thu, 21 Jul 2022 06:52:10 +0000 From: "Marappan, Gopinath" To: "linux-lvm@redhat.com" Thread-Topic: Fix for Bug 2109351 - multipath_component_detection = 0 in lvm.conf does not have any effect Thread-Index: Adicypyy/9MRvKNxS2ywvkLxoLBNNg== Date: Thu, 21 Jul 2022 06:52:09 +0000 Message-ID: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_73dd1fcc-24d7-4f55-9dc2-c1518f171327_Enabled=true; MSIP_Label_73dd1fcc-24d7-4f55-9dc2-c1518f171327_SetDate=2022-07-21T06:52:08Z; MSIP_Label_73dd1fcc-24d7-4f55-9dc2-c1518f171327_Method=Standard; MSIP_Label_73dd1fcc-24d7-4f55-9dc2-c1518f171327_Name=No Protection (Label Only) - Internal Use; MSIP_Label_73dd1fcc-24d7-4f55-9dc2-c1518f171327_SiteId=945c199a-83a2-4e80-9f8c-5a91be5752dd; MSIP_Label_73dd1fcc-24d7-4f55-9dc2-c1518f171327_ActionId=f3420115-3118-4313-b210-70113e47feb9; MSIP_Label_73dd1fcc-24d7-4f55-9dc2-c1518f171327_ContentBits=2 x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: a7d20790-eb4c-432b-16c4-08da6ae5889d x-ms-traffictypediagnostic: DM6PR19MB4107:EE_ x-exotenant: 2khUwGVqB6N9v58KS13ncyUmMJd8q4 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0 x-microsoft-antispam-message-info: TR74duRzqjVua4benMF8nSFZ864Ftg6mKWpJWGHaiMg42tS88+2cCm6ThZ6VJKJ04wSe6k8NlD2BNgVAGAnItxMJSudgi3LahQdcSWlFvwKf+R9ud0I5x7QHfmfRQ6HTzzXeOJQv+vmPEsR7QIby3vBeQaY0GfJdzHuH+KHuxVy7j5fGjyR5m/djHgG5ZWj1cIfEDmg6kUrf7T2VuHt11pC3+fz35x+TtnbAaQYFkqTgD6fC22vNMlWCnYPtEHgr/4p2rdq13qSqTgtaI9QiWHWoOTe5rFLTWvJtL29c0VPL1Tn74QJWoc7JJUBNrREAfDG4p8xmpaWOZ1LYgCbgRvWlzyeHEb1sY5PW+CLvt9C6+yhaaM0mfsjYQ1unREA7L4oEsCGwjivzbTChdthOfKlv/BTGFnp47nXglmv5Jw8Qlzs6+IWeUcg8doJRc1lZI5r04Bc9wrCIB6tctsFvL04KpHFNg6mbsGSh0ojxFlDtM36aM4XMw/74LyojfFYQQHfZlOxZlhE5wgFGF0yZuRxfTOLSpfLafkKdq6eg73Pi07i6lCKf6ekma8+9Qhn/D5uzBW8Z59TMfWcec9pUyqsbhTEuKDRUuAqiEZc//CXlilRrBHF2unQns/rouOyOINhQqCFz3q+KMFVvnlbVj6FfHMC8zy5voz1SBn97oJSscw4yKuYpToOZWbKKLPCqlqGZEI7NFJWTkbAM2bqptTXdpUaF22IWk+Z3gDW8KSLqH3nd/ge2mRB6Z5wPRuGe93s9bhfP2Ryo75B+MydJfXny3lh4TKW1udbGN86VlhNjpKHBf10Pi/TnRIEHkygwrGUwAWhGNMx5lt+r8Ik65g== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR19MB2491.namprd19.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230016)(4636009)(376002)(39860400002)(366004)(396003)(346002)(136003)(478600001)(71200400001)(86362001)(6506007)(7696005)(55236004)(26005)(9686003)(966005)(786003)(41300700001)(122000001)(38100700002)(316002)(55016003)(54906003)(6916009)(38070700005)(166002)(82960400001)(186003)(107886003)(83380400001)(8676002)(64756008)(66446008)(4326008)(5660300002)(8936002)(66946007)(2906002)(52536014)(33656002)(66476007)(66556008)(76116006); DIR:OUT; SFP:1101 x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?YUbPhs436vpE3j+hgELnARWezqtHwC/RD0DMbZiom1E1NZGHYlocJh3AkzxR?= =?us-ascii?Q?xqmkLWaIO0t2jvhlzWsXYZHNSQY4g2Iu57A+4Fi6DKQ2rzlF8UvaErM8eJ+R?= =?us-ascii?Q?Cc2OuV02ZLeO1jbk9hd3fHH8BY1POThE5dqVy2wyr6gLCG6mC56YSQP0YyCs?= =?us-ascii?Q?uRnD9daPBx+GjWI4IPGfwpdDVwmv/Brzl44opq9viIeQDqOf+HgxINW/tXY/?= =?us-ascii?Q?sOmG/KBqsbyh/Nbq2nOX08+077Y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Nj+EueQnjUFXwlCAuvWi4U6k7X44VkMufPJVasQJ5QJZM7YNaTXo?= =?us-ascii?Q?kOmuUn4EQZe9n/Ygej7VvRAEh3jsNioobqvq8FCT+wbQwdNWesDAd34YQckX?= =?us-ascii?Q?MXRnhGibUQWLT6K/w4DcrtN1gwRVThkqR81M6PF+QQQb0RRoJZn4DAuX5SfZ?= =?us-ascii?Q?8PWy5CAfD6m3Rmcb75DDyKM4pI7rlau2izSI93NAm+Y5wB0bK+9OsNXgHCw7?= =?us-ascii?Q?FPIVKFkOxgBeV9s+UnWqXO2voAAcCoznSCmSfw8jhPRe+oPAS6oODNTDmNhO?= =?us-ascii?Q?uQLBCrc8RfsV0dfxLRlEquUfPSeM6KJBozXaAhExpUo3h4VAIwbIoEQ9HjId?= =?us-ascii?Q?T4JYgWCLNwXIOfUYBmyAS73pjN2OHdbb0k+zHS2M11RPSkgq6SO7oAx/G0ln?= =?us-ascii?Q?jUCal/lrdRrIq0AauIqzBV1gE+hclpfwK5j43VuF?= MIME-Version: 1.0 X-OriginatorOrg: Dell.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM6PR19MB2491.namprd19.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: a7d20790-eb4c-432b-16c4-08da6ae5889d X-MS-Exchange-CrossTenant-originalarrivaltime: 21 Jul 2022 06:52:09.7772 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 945c199a-83a2-4e80-9f8c-5a91be5752dd X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: /N/wZBo31Jsvm/VAF9oMpYL2vqMuDpUcMebg1ZmBsJPvbRFB3x7FbLvoyfvAhPc49nH6geU8OV9SoDOWxvJwmFFHIPPwh47r20twE+6Ej74= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR19MB4107 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.883,Hydra:6.0.517,FMLib:17.11.122.1 definitions=2022-07-20_12,2022-07-20_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1011 adultscore=0 lowpriorityscore=0 mlxscore=0 spamscore=0 bulkscore=0 phishscore=0 priorityscore=1501 mlxlogscore=999 impostorscore=0 malwarescore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2206140000 definitions=main-2207210026 X-Proofpoint-GUID: CYM2m3Qa51mdK0gyHg8mj42kQPOS3IBv X-Proofpoint-ORIG-GUID: CYM2m3Qa51mdK0gyHg8mj42kQPOS3IBv X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 adultscore=0 mlxlogscore=999 malwarescore=0 bulkscore=0 spamscore=0 suspectscore=0 mlxscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2206140000 definitions=main-2207210026 X-Mimecast-Impersonation-Protect: Policy=CLT - Impersonation Protection Definition; Similar Internal Domain=false; Similar Monitored External Domain=false; Custom External Domain=false; Mimecast External Domain=false; Newly Observed Domain=false; Internal User Name=false; Custom Display Name List=false; Reply-to Address Mismatch=false; Targeted Threat Dictionary=false; Mimecast Threat Dictionary=false; Custom Threat Dictionary=false X-Scanned-By: MIMEDefang 2.79 on 10.11.54.5 X-Mailman-Approved-At: Tue, 26 Jul 2022 08:15:59 +0000 Subject: [linux-lvm] Fix for Bug 2109351 - multipath_component_detection = 0 in lvm.conf does not have any effect X-BeenThere: linux-lvm@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: LVM general discussion and development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: LVM general discussion and development Cc: "parakunnath, remesh" , "Rajappa, Ajaykumar" , "Tarikere, Madhu" Errors-To: linux-lvm-bounces@redhat.com Sender: "linux-lvm" X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=linux-lvm-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: multipart/mixed; boundary="===============7366507079129999195==" --===============7366507079129999195== Content-Language: en-US Content-Type: multipart/alternative; boundary="_000_DM6PR19MB249191C1C763815BDDFE998588919DM6PR19MB2491namp_" --_000_DM6PR19MB249191C1C763815BDDFE998588919DM6PR19MB2491namp_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Regarding a fix for this bug - https://bugzilla.redhat.com/show_bug.cgi?id= =3D2109351 multipath_component_detection parameter is not considered when lvm scans fo= r PVs. This patch should fix that issue. It ensures that the multipath_component_= detction parameter from lvm.conf is considered before checking for duplicated PVIDs and ignori= ng them if they are multipath components. I have built the patch and verified that it works. diff --git a/lib/cache/lvmcache.c b/lib/cache/lvmcache.c index 22edcfd84..892636aa7 100644 --- a/lib/cache/lvmcache.c +++ b/lib/cache/lvmcache.c @@ -898,7 +898,8 @@ next: /* * Get rid of multipath components based on matching wwids. */ - if (_all_multipath_components(cmd, info, pvid, &altdevs, &dev_mpath= )) { + if ( find_config_tree_bool(cmd, devices_multipath_component_detect= ion_CFG, NULL) && + _all_multipath_components(cmd, info, pvid, &altdevs, &dev_mpa= th) ){ if (info && dev_mpath && (info->dev !=3D dev_mpath)) { /* * info should be dropped from lvmcache and info->d= ev I tried to create a pull request on https://github.com/lvmteam/lvm2, but I = couldn't as I don't have access. If I am granted access to the lvm2 github repo, I can create a PR for this = patch. Kindly let me know how to proceed with this. Thanks, Gopi Internal Use - Confidential --_000_DM6PR19MB249191C1C763815BDDFE998588919DM6PR19MB2491namp_ Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

Regarding a fix for this bug -  https://bugzilla.redhat.com/show_bug.cgi?id=3D2109351

 

multipath_component_detection parameter is not consi= dered when lvm scans for PVs.

 

This patch should fix that issue.  It ensures t= hat the multipath_component_detction parameter

from lvm.conf is considered before checking for dupl= icated PVIDs and ignoring them if they are

multipath components.

 

I have built the patch and verified that it works.

 

diff --git a/lib/cache/lvmcache.c b/lib/cache/lv= mcache.c

index 22edcfd84..892636aa7 100644

--- a/lib/cache/lvmcache.c

+++ b/lib/cache/lvmcache.c

@@ -898,7 +898,8 @@ next:

        /*

        = * Get rid of multipath components based on matching wwids.

        = */

-       if (_all_m= ultipath_components(cmd, info, pvid, &altdevs, &dev_mpath)) {<= /o:p>

+        if (= find_config_tree_bool(cmd, devices_multipath_component_detection_CFG, NULL= ) &&

+        &nbs= p;    _all_multipath_components(cmd, info, pvid, &a= ltdevs, &dev_mpath) ){

        =         if (info && dev_mpath &a= mp;& (info->dev !=3D dev_mpath)) {

        =             &nb= sp;   /*

        =             &nb= sp;    * info should be dropped from lvmcache and info->d= ev

 

I tried to create a pull request on https://github.com/lvmteam/lvm2, but I couldn’t as I don’t = have access.

 

If I am granted access to the lvm2 github repo, I ca= n create a PR for this patch.

 

Kindly let me know how to proceed with this.

 

Thanks,

Gopi

 


Internal Use - Con= fidential

--_000_DM6PR19MB249191C1C763815BDDFE998588919DM6PR19MB2491namp_-- --===============7366507079129999195== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-lvm mailing list linux-lvm@redhat.com https://listman.redhat.com/mailman/listinfo/linux-lvm read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/ --===============7366507079129999195==--