Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Global Lock Failure after Firmware update #102

Open
TProhofsky opened this issue Jul 11, 2020 · 3 comments
Open

Global Lock Failure after Firmware update #102

TProhofsky opened this issue Jul 11, 2020 · 3 comments

Comments

@TProhofsky
Copy link
Collaborator

TProhofsky commented Jul 11, 2020

Currently lvmlockd-idm.c check the drive firmware to validate if the drive can be used. When a firmware download is complete the kernel is not refeshing the FW version as seen by lsscsi. Issuing sg_reset of both target and bus did not trigger a refresh. Neither did partprobe. Currently a server reboot is required after a FW download.

Example
$ ./seachest -s
Vendor Handle Model Number Serial Number FwRev
ATA /dev/sg0 ST240FN0021 Z3X00007 B550
ATA /dev/sg1 ST240FN0001 P3X01226 B560
SEAGATE /dev/sg10 XS7680TE70014 HLN0300A 1759
SEAGATE /dev/sg11 XS7680TE70014 HLN0300E 1759
SEAGATE /dev/sg12 XS7680TE70014 HLN0301C 1759
SEAGATE /dev/sg13 XS7680TE70014 HLN0301X 1759
SEAGATE /dev/sg14 XS7680TE70014 HLN03004 1759
SEAGATE /dev/sg15 XS7680TE70014 HLN0300V 1759
SEAGATE /dev/sg16 XS7680TE70014 HLN0301W 1759
SEAGATE /dev/sg17 XS7680TE70014 HLN0302Z 1759
XYRATEX /dev/sg18 EB-2425-E12EBD SHM1007184RAYA7 4026
SEAGATE /dev/sg2 XS7680TE70014 HLN03026 1759
SEAGATE /dev/sg3 XS7680TE70014 HLN0302F 1759
SEAGATE /dev/sg4 XS7680TE70014 HLN0300S 1759
SEAGATE /dev/sg5 XS7680TE70014 HLN03036 1759
SEAGATE /dev/sg6 XS7680TE70014 HLN0301S 1759
SEAGATE /dev/sg7 XS7680TE70014 HLN03005 1759
SEAGATE /dev/sg8 XS7680TE70014 HLN0310J 1759
SEAGATE /dev/sg9 XS7680TE70014 HLN0301L 1759

$ lsscsi -g
[0:0:0:0] disk ATA ST240FN0021 B550 /dev/sda /dev/sg0
[0:0:1:0] disk ATA ST240FN0001 B560 /dev/sdb /dev/sg1
[1:0:0:0] disk SEAGATE XS7680TE70014 2229 /dev/sdc /dev/sg2
[1:0:1:0] disk SEAGATE XS7680TE70014 2229 /dev/sdd /dev/sg3
[1:0:2:0] disk SEAGATE XS7680TE70014 2229 /dev/sde /dev/sg4
[1:0:3:0] disk SEAGATE XS7680TE70014 2229 /dev/sdf /dev/sg5
[1:0:4:0] disk SEAGATE XS7680TE70014 2229 /dev/sdg /dev/sg6
[1:0:5:0] disk SEAGATE XS7680TE70014 2229 /dev/sdh /dev/sg7
[1:0:6:0] disk SEAGATE XS7680TE70014 2229 /dev/sdi /dev/sg8
[1:0:7:0] disk SEAGATE XS7680TE70014 2229 /dev/sdj /dev/sg9
[1:0:8:0] disk SEAGATE XS7680TE70014 2229 /dev/sdk /dev/sg10
[1:0:9:0] disk SEAGATE XS7680TE70014 2229 /dev/sdl /dev/sg11
[1:0:10:0] disk SEAGATE XS7680TE70014 2229 /dev/sdm /dev/sg12
[1:0:11:0] disk SEAGATE XS7680TE70014 2229 /dev/sdn /dev/sg13
[1:0:12:0] disk SEAGATE XS7680TE70014 2229 /dev/sdo /dev/sg14
[1:0:13:0] disk SEAGATE XS7680TE70014 2229 /dev/sdp /dev/sg15
[1:0:14:0] disk SEAGATE XS7680TE70014 2229 /dev/sdq /dev/sg16
[1:0:15:0] disk SEAGATE XS7680TE70014 2229 /dev/sdr /dev/sg17
[1:0:16:0] enclosu XYRATEX EB-2425-E12EBD 4026 - /dev/sg18

@Leo-Yan
Copy link
Contributor

Leo-Yan commented Jul 13, 2020

I observed for the firmware 1759 I also need to restart the box, but for the other old firmware versions, after updated the firmware, "lsscsi" -g can display the correct version number. It's good to confirm if this is related with firmware rather than Linux kernel?

@xahmad
Copy link
Contributor

xahmad commented Oct 22, 2020

lsscsi uses the sysfs to read it. If you do a trace the process, you will see the following, where rev is the firmware revision:

openat(AT_FDCWD, "/sys/bus/scsi/devices/4:0:0:0/rev", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0444, st_size=4096, ...}) = 0
read(3, "U001\n", 4096)                 = 5
close(3)  

@TProhofsky
Copy link
Collaborator Author

So how does /sys/bus/scsi/devices/4:0:0:0/rev get triggered to re-read the FWrev from the drive?

@TProhofsky TProhofsky changed the title Firmware update not detected Global Lock Failure after Firmware update Dec 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants