All of lore.kernel.org
 help / color / mirror / Atom feed
* latest multipath-tools from git breaks EMC CX
@ 2005-06-02 20:46 Lars Marowsky-Bree
  2005-06-02 21:42 ` christophe varoqui
  0 siblings, 1 reply; 5+ messages in thread
From: Lars Marowsky-Bree @ 2005-06-02 20:46 UTC (permalink / raw)
  To: dm-devel

More specifically, it fails to detect the vendor correctly, and uses the
most basic internal defaults:

...
===== path sdz =====
bus = 0
dev_t = 65:144
size = 280278656
path checker = readsector0 (internal default)
#
# all paths :
#
#:#:#:# sdaa 65:160  []
#:#:#:# sdab 65:176  []
#:#:#:# sdac 65:192  []
#:#:#:# sdad 65:208  []
#:#:#:# sdae 65:224  []
#:#:#:# sdaf 65:240  []
#:#:#:# sdag 66:0    []
#:#:#:# sdah 66:16   []
#:#:#:# sdai 66:32   []
#:#:#:# sdaj 66:48   []

...
params = 0 0 4 2 round-robin 0 1 1 65:240 1000 round-robin 0 1 1 66:224 1000 round-robin 0 1 1 8:16 1000 round-robin 0 1 1 65
:0 1000 
status = 1 0 0 4 2 E 0 1 0 65:240 F 1 A 0 1 0 66:224 A 0 E 0 1 0 8:16 F 1 E 0 1 0 65:0 A 0 
3600601607cf30e00174589a37a31d911
[size=127 GB][features="0"][hwhandler="0"]
\_ round-robin 0 [enabled]
  \_ #:#:#:# sdaf 65:240  [failed]
\_ round-robin 0 [active][best]
  \_ #:#:#:# sdau 66:224  [active]
\_ round-robin 0 [enabled]
  \_ #:#:#:# sdb  8:16    [failed]
\_ round-robin 0 [enabled]
  \_ #:#:#:# sdq  65:0    [active]

...

Just what the heck is going on there? ;-)

I don't get any more output than that, sorry.


Sincerely,
    Lars Marowsky-Brée <lmb@suse.de>

-- 
High Availability & Clustering
SUSE Labs, Research and Development
SUSE LINUX Products GmbH - A Novell Business	 -- Charles Darwin
"Ignorance more frequently begets confidence than does knowledge"

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: latest multipath-tools from git breaks EMC CX
  2005-06-02 20:46 latest multipath-tools from git breaks EMC CX Lars Marowsky-Bree
@ 2005-06-02 21:42 ` christophe varoqui
  2005-06-03  6:54   ` Mike Anderson
  0 siblings, 1 reply; 5+ messages in thread
From: christophe varoqui @ 2005-06-02 21:42 UTC (permalink / raw)
  To: device-mapper development

Most certainly the 8af5a2b1b5e4d3a457f5bb477214356385087eae commit is
the culprit : I did a bit of spliting in path discovery, and introduced
a new fn to get the sysfs bus that I use as a switch to choose a
discovery template.

Reading your output, I would say the bus fetching went wrong.

Well, revert it or debug it :/

Strange it didn't blew on me ...

On jeu, 2005-06-02 at 22:46 +0200, Lars Marowsky-Bree wrote:
> More specifically, it fails to detect the vendor correctly, and uses the
> most basic internal defaults:
> 
> ...
> ===== path sdz =====
> bus = 0
> dev_t = 65:144
> size = 280278656
> path checker = readsector0 (internal default)
> #
> # all paths :
> #
> #:#:#:# sdaa 65:160  []
> #:#:#:# sdab 65:176  []
> #:#:#:# sdac 65:192  []
> #:#:#:# sdad 65:208  []
> #:#:#:# sdae 65:224  []
> #:#:#:# sdaf 65:240  []
> #:#:#:# sdag 66:0    []
> #:#:#:# sdah 66:16   []
> #:#:#:# sdai 66:32   []
> #:#:#:# sdaj 66:48   []
> 
> ...
> params = 0 0 4 2 round-robin 0 1 1 65:240 1000 round-robin 0 1 1 66:224 1000 round-robin 0 1 1 8:16 1000 round-robin 0 1 1 65
> :0 1000 
> status = 1 0 0 4 2 E 0 1 0 65:240 F 1 A 0 1 0 66:224 A 0 E 0 1 0 8:16 F 1 E 0 1 0 65:0 A 0 
> 3600601607cf30e00174589a37a31d911
> [size=127 GB][features="0"][hwhandler="0"]
> \_ round-robin 0 [enabled]
>   \_ #:#:#:# sdaf 65:240  [failed]
> \_ round-robin 0 [active][best]
>   \_ #:#:#:# sdau 66:224  [active]
> \_ round-robin 0 [enabled]
>   \_ #:#:#:# sdb  8:16    [failed]
> \_ round-robin 0 [enabled]
>   \_ #:#:#:# sdq  65:0    [active]
> 
> ...
> 
> Just what the heck is going on there? ;-)
> 
> I don't get any more output than that, sorry.
> 
> 
> Sincerely,
>     Lars Marowsky-Brée <lmb@suse.de>
> 
-- 
christophe varoqui <christophe.varoqui@free.fr>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: latest multipath-tools from git breaks EMC CX
  2005-06-02 21:42 ` christophe varoqui
@ 2005-06-03  6:54   ` Mike Anderson
  2005-06-03  9:43     ` Christophe Varoqui
  0 siblings, 1 reply; 5+ messages in thread
From: Mike Anderson @ 2005-06-03  6:54 UTC (permalink / raw)
  To: device-mapper development

christophe varoqui [christophe.varoqui@free.fr] wrote:
> Most certainly the 8af5a2b1b5e4d3a457f5bb477214356385087eae commit is
> the culprit : I did a bit of spliting in path discovery, and introduced
> a new fn to get the sysfs bus that I use as a switch to choose a
> discovery template.
> 
> Reading your output, I would say the bus fetching went wrong.
> 
> Well, revert it or debug it :/
> 

I was hitting the same problem on my system (the sysfs_get_bus function
leaving bus a none) the hack below fix it for me, but I only tested the
bus code against scsi YMMV.

-andmike
--
Michael Anderson
andmike@us.ibm.com


Hack fix for libmultipath sysfs_get_bus function.

Signed-off-by: Mike Anderson <andmike@us.ibm.com>
---

--- multipath-tools-git/libmultipath/discovery.c	2005-06-03 06:11:15.752789640 -0700
+++ multipath-tools-fix/libmultipath/discovery.c	2005-06-03 06:21:15.913551336 -0700
@@ -337,6 +337,7 @@ get_serial (char * str, int fd)
 static void
 sysfs_get_bus (char * sysfs_path, struct path * curpath)
 {
+	struct sysfs_device *sdev;
 	char attr_path[FILE_NAME_SIZE];
 	char attr_buff[FILE_NAME_SIZE];
 
@@ -352,25 +353,19 @@ sysfs_get_bus (char * sysfs_path, struct
 		condlog(0, "attr_path too small");
 		return;
 	}
-	if (0 > sysfs_get_link(attr_path, attr_buff, sizeof(attr_buff)))
-		return;
-
-	if (strlen(attr_buff) + 4 > FILE_NAME_SIZE) {
-		condlog(0, "attr_path too small");
-		return;
-	}
-	snprintf(attr_path, FILE_NAME_SIZE, "%s/bus", attr_buff);
 
 	if (0 > sysfs_get_link(attr_path, attr_buff, sizeof(attr_buff)))
 		return;
 
-	basename(attr_buff, attr_path);
-	
-	if (!strncmp(attr_path, "scsi", 4))
+	sdev = sysfs_open_device_path(attr_buff);
+
+	if (!strncmp(sdev->bus, "scsi", 4))
 		curpath->bus = SYSFS_BUS_SCSI;
-	else if (!strncmp(attr_path, "ide", 3))
+	else if (!strncmp(sdev->bus, "ide", 3))
 		curpath->bus = SYSFS_BUS_IDE;
 
+	sysfs_close_device(sdev);
+
 	return;
 }
 

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: latest multipath-tools from git breaks EMC CX
  2005-06-03  6:54   ` Mike Anderson
@ 2005-06-03  9:43     ` Christophe Varoqui
  2005-06-03 16:03       ` Lars Marowsky-Bree
  0 siblings, 1 reply; 5+ messages in thread
From: Christophe Varoqui @ 2005-06-03  9:43 UTC (permalink / raw)
  To: device-mapper development

> 
> I was hitting the same problem on my system (the sysfs_get_bus function
> leaving bus a none) the hack below fix it for me, but I only tested the
> bus code against scsi YMMV.
> 
Works for me too with iSCSI (scsi sysfs bus too).

Thanks, commited.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: latest multipath-tools from git breaks EMC CX
  2005-06-03  9:43     ` Christophe Varoqui
@ 2005-06-03 16:03       ` Lars Marowsky-Bree
  0 siblings, 0 replies; 5+ messages in thread
From: Lars Marowsky-Bree @ 2005-06-03 16:03 UTC (permalink / raw)
  To: device-mapper development

On 2005-06-03T11:43:55, Christophe Varoqui <christophe.varoqui@free.fr> wrote:

> > I was hitting the same problem on my system (the sysfs_get_bus function
> > leaving bus a none) the hack below fix it for me, but I only tested the
> > bus code against scsi YMMV.
> Works for me too with iSCSI (scsi sysfs bus too).
> 
> Thanks, commited.

Confirmed, works for me too.


-- 
High Availability & Clustering
SUSE Labs, Research and Development
SUSE LINUX Products GmbH - A Novell Business	 -- Charles Darwin
"Ignorance more frequently begets confidence than does knowledge"

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2005-06-03 16:03 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-06-02 20:46 latest multipath-tools from git breaks EMC CX Lars Marowsky-Bree
2005-06-02 21:42 ` christophe varoqui
2005-06-03  6:54   ` Mike Anderson
2005-06-03  9:43     ` Christophe Varoqui
2005-06-03 16:03       ` Lars Marowsky-Bree

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.