From patchwork Wed Apr 27 22:46:01 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Benjamin Marzinski X-Patchwork-Id: 8963841 Return-Path: X-Original-To: patchwork-dm-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 2237B9F457 for ; Wed, 27 Apr 2016 22:51:50 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2267620272 for ; Wed, 27 Apr 2016 22:51:49 +0000 (UTC) Received: from mx4-phx2.redhat.com (mx4-phx2.redhat.com [209.132.183.25]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id D9F1120268 for ; Wed, 27 Apr 2016 22:51:47 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by mx4-phx2.redhat.com (8.13.8/8.13.8) with ESMTP id u3RMk5MN001179; Wed, 27 Apr 2016 18:46:06 -0400 Received: from int-mx13.intmail.prod.int.phx2.redhat.com (int-mx13.intmail.prod.int.phx2.redhat.com [10.5.11.26]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id u3RMk4ah000392 for ; Wed, 27 Apr 2016 18:46:04 -0400 Received: from redhat.com (octiron.msp.redhat.com [10.15.80.209]) by int-mx13.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with SMTP id u3RMk2ak016124; Wed, 27 Apr 2016 18:46:02 -0400 Received: by redhat.com (sSMTP sendmail emulation); Wed, 27 Apr 2016 17:46:01 -0500 From: "Benjamin Marzinski" Date: Wed, 27 Apr 2016 17:46:01 -0500 To: Hannes Reinecke Message-ID: <20160427224601.GG26117@octiron.msp.redhat.com> References: <571DF852.6030604@redhat.com> <571E0E7A.4050703@redhat.com> <1986ca6b-d281-4faf-2b50-11c3dc132463@gmail.com> <571F026C.5040102@suse.de> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <571F026C.5040102@suse.de> User-Agent: Mutt/1.5.23 (2014-03-12) X-Scanned-By: MIMEDefang 2.68 on 10.5.11.26 X-loop: dm-devel@redhat.com Cc: Peter Volkov , device-mapper development , Xose Vazquez Perez , Zdenek Kabelac Subject: Re: [dm-devel] multipath-0.5.0 still provides broken udev rules X-BeenThere: dm-devel@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: device-mapper development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dm-devel-bounces@redhat.com Errors-To: dm-devel-bounces@redhat.com X-Spam-Status: No, score=-7.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Tue, Apr 26, 2016 at 07:53:48AM +0200, Hannes Reinecke wrote: > On 04/25/2016 10:14 PM, Xose Vazquez Perez wrote: > > On 04/25/2016 02:56 PM, Christophe Varoqui wrote: > > > >> Those example udev rules are indeed unmaintained and should be > >> removed not to confuse distributors. > >> > >> Distributors can't be asked to agree on a common udev ruleset. > >> Ben, Hannes, Xosé, Peter are you ok with my deleting the udev rules example ? > > > > Fine with me. > > > > Btw, are these relevant ? For all that I didn't comment on, I feel the same way as Hannes. > > getuid/usb_id > Huh? What is that doing there? > It should really have been moved to the udev package ... > > > kpartx/kpartx_id > > kpartx/kpartx.rules > See above. Yes, they are relevant (at least for us) Like I said, Red Hat doesn't use them. I'll post our multipath.rules shortly. > > multipath/01_udev > > multipath/02_multipath > Not used anymore with systemd/dracut > > > multipath/11-dm-mpath.rules > Yep. Absolutely required. > > > multipath.conf.annotated > > multipath.conf.defaults > > multipath.conf.synthetic > Actually, I never saw the need for those. > Can we at least have them merged? I don't think they are being kept up to date anymore. The 'defaults' information can be gotten from a running system, and it includes the changes from the config files, so it's much more useful. I have no idea what people would use 'synthetic' for besides an example of what a config would look like. And the 'annotated' information is all in the multipath.conf manpage. Red Hat doesn't ship these files anymore. I'd be happy to see them go. > > multipathd/multipathd.init.debian > > multipathd/multipathd.init.redhat > > multipathd/multipathd.init.suse > Old init scripts; doubtful value. > > > multipathd/multipathd.service > > multipathd/multipathd.socket > systemd service definitions. Yes, required. Red Hat has a slightly different multipathd.service file, and we don't ship the socket file. Since multipathd should always be running, I don't really see the need. Also, if you start multipathd manually (instead of through udev) this causes problems with multipathd not getting messages. For those interested, here's a diff of our multipath.service Aside from dropping the socket, it checks that /etc/multipath.conf exists, and that the kernel wasn't started with "nompath". Also it runs "multipath -A" this reads the kernel commandline from /proc/cmdline, and adds any wwids listed as part of any mpath.wwid= parameters. Hannes NACKed this patch, so the option isn't present upsteam. > > multipath/multipath.init.suse > Old init script; not used anymore. > > > multipath/multipath.rules > Yep. used for udev. > > > multipath-tools.spec.in > > > Well; due to our buildservice we have to keep a separate spec file > anyway. So ATM we don't use it. > > Cheers, > > Hannes > -- > Dr. Hannes Reinecke Teamlead Storage & Networking > hare@suse.de +49 911 74053 688 > SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg > GF: F. Imendörffer, J. Smithard, J. Guild, D. Upmanyu, G. Norton > HRB 21284 (AG Nürnberg) --- dm-devel mailing list dm-devel@redhat.com https://www.redhat.com/mailman/listinfo/dm-devel diff --git a/multipathd/multipathd.service b/multipathd/multipathd.service index d5f8606..1e5dfab 100644 --- a/multipathd/multipathd.service +++ b/multipathd/multipathd.service @@ -2,9 +2,10 @@ Description=Device-Mapper Multipath Device Controller Before=iscsi.service iscsid.service lvm2-activation-early.service Before=local-fs-pre.target -After=multipathd.socket +ConditionPathExists=/etc/multipath.conf +ConditionKernelCommandLine=!nompath DefaultDependencies=no -Wants=local-fs-pre.target multipathd.socket blk-availability.service +Wants=local-fs-pre.target blk-availability.service Conflicts=shutdown.target [Service] @@ -12,9 +13,9 @@ Type=notify NotifyAccess=main LimitCORE=infinity ExecStartPre=/sbin/modprobe dm-multipath +ExecStartPre=-/sbin/multipath -A ExecStart=/sbin/multipathd -d -s ExecReload=/sbin/multipathd reconfigure [Install] WantedBy=sysinit.target -Also=multipathd.socket