On Wed, 2026-11-11 at 09:42 -0800, Brian Bunker wrote: > On Tue, 2026-11-10, Martin Wilck wrote: > > > > IMO, if we can't trust the reply of the storage array, all bets are > > off. Why would the reply that multipathd obtains directly be more > > trustworthy than what scsi_id had got? > > It isn't more trustworthy, it's newer. The sequence on the host was:
Right, but "newer" doesn't mean "more accurate". You write below that there is no indication that anything actually changed, so time shouldn't be a factor. If a wrong VPD reply is possible once, it can also occur multiple times. If it's just an unlikely failure, a purely stochastical thing, it would help to simply repeat the same request; if the probability for error is 1e-4, the probability for two errors in succession would be 1e-8. However we don't know if it's stochastical. > > 09:26:34.808 udev change event for sdq; ID_SERIAL is verify1's > WWID > 09:26:34.833 uev_update_path() sees the change and calls > ev_remove_path(); the reload of verify3's map then > blocks in the resume until in-flight I/O drains > 09:26:39.221 the reload completes; sdq is freed > 09:26:39.235 uev_update_path() calls uev_add_path() with the same > uevent, and sdq goes into verify1's map > 09:26:39.379 next change event for sdq; ID_SERIAL is verify3's > WWID again > > So the add acted on an answer that was 4.4 seconds old. An INQUIRY at > the time of the add would have reflected what the device said then, > and the one 140 ms later was correct. The check doesn't help against > storage that keeps giving the wrong answer. It stops multipathd from > moving a path into another LUN's map on an old answer. Well you keep telling me that newer == better. Maybe you are right. We can neither prove nor disprove that with the material we have. > > One possible case for a WWID change is that a > > a Linux SCSI disk is removed, and another disk is added later, > > taking > > over the previous device's dev_t. > [...] > > This sounds as if the WWID of sdq was that of "verify3", then > > "verify1", and then "verify3" again. > > That's what happened, and it wasn't a remove and add. The kernel log > shows no SCSI device removed or added in that window, and sdq stayed > 2:0:0:8 (65:0) throughout. Only that one udev event carried the wrong > WWID. Weird. Gamma radiation maybe? ;-) > > Question about your test: Apparently the problem is reproducible, > > otherwise you wouldn't be able to verify your patch. But you said > > "we > > have no packet capture". > > I should have been clearer: we've seen it once. We haven't reproduced > it. We've been running a v1-style patch on our test initiators since, If it was my choice, I'd prefer repeating the test with the unpatched code, but additional debugging instrumentation, in the hope to obtain more insight into what actually happened. > and it hasn't recurred, but at this rate that doesn't tell us much. I'd go one step further and say that it tells us nothing at all. You would need to be able to reproduce the issue in a well-defined time frame in order to do a test that gives at least some confidence that your patch fixed it. However from the time line you provided, it makes sense that your patch would have been effective in the error case. Regards, Martin > We've also changed our test tool to open the devices read-only, which > removes the flood of change events that made the window likely in the > first place. I'd like to get a capture, but I can't promise we'll > reproduce it. > > > With this in mind, I suggest that you go back to v2 and SG_IO. > [...] > > I further suggest that you make this code > > path conditional on "recheck_wwid". > > Will do; Ben suggested the same. v4 does the SG_IO check only on > PATH_ADD_REINIT, only when recheck_wwid is set, and drops the > uev_update_path() check from v2. > > > In the long run, we may want to redesign our WWID detection. We do > > have > > a general framework for asynchronous jobs now. Thus we actually > > could > > run asynchronous VPD inquries. > > That sounds like the right direction, and I'd be glad to help with > it. > > Brian -- Dr. Martin Wilck <[email protected]> SUSE Software Solutions Germany GmbH, Frankenstr. 146, 90461 Nürnberg, Germany Geschäftsführer: Stefan Gaiser, Jochen Jaser, Abhinav Puri (HRB 36809,AG Nürnberg)
