Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
volume/fc: fix FibreChannel volume plugin matching wrong disks
Before: findDisk() fcPathExp := "^(pci-.*-fc|fc)-0x" + wwn + "-lun-" + lun After: findDisk() fcPathExp := "^(pci-.*-fc|fc)-0x" + wwn + "-lun-" + lun + "$" fc path may have the same wwns but different luns.for example: pci-0000:41:00.0-fc-0x500a0981891b8dc5-lun-1 pci-0000:41:00.0-fc-0x500a0981891b8dc5-lun-12 Function findDisk() may mismatch the fc path, return the wrong device and wrong associated devicemapper parent. This may cause a disater that pods attach wrong disks. Accutally it happended in my testing environment before.
- Loading branch information
Showing
2 changed files
with
40 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters