• Kubernetes Submit Queue's avatar
    Merge pull request #63176 from NetApp/bug/59946 · 845a55db
    Kubernetes Submit Queue authored
    Automatic merge from submit-queue (batch tested with PRs 64844, 63176). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.
    
    Fix discovery/deletion of iscsi block devices
    
    This PR modifies the iSCSI attach/detatch codepaths in the following
    ways:
    1) After unmounting a filesystem on an iSCSI block device, always
    flush the multipath device mapper entry (if it exists) and delete
    all block devices so the kernel forgets about them.
    2) When attaching an iSCSI block device, instead of blindly
    attempting to scan for the new LUN, first determine if the target
    is already logged into, and if not, do the login first. Once every
    portal is logged into, the scan is done.
    3) Scans are now done for specific devices, instead of the whole
    bus. This avoids discovering LUNs that kubelet has no interest in.
    4) Additions to the underlying utility interfaces, with new tests
    for the new functionality.
    5) Some existing code was shifted up or down, to make the new logic
    work.
    6) A typo in an existing exec call on the attach path was fixed.
    
    Fixes #59946
    
    ```release-note
    When attaching iSCSI volumes, kubelet now scans only the specific
    LUNs being attached, and also deletes them after detaching. This avoids
    dangling references to LUNs that no longer exist, which used to be the
    cause of random I/O errors/timeouts in kernel logs, slowdowns during
    block-device related operations, and very rare cases of data corruption.
    ```
    845a55db
Name
Last commit
Last update
..
aws_ebs Loading commit data...
azure_dd Loading commit data...
azure_file Loading commit data...
cephfs Loading commit data...
cinder Loading commit data...
configmap Loading commit data...
csi Loading commit data...
downwardapi Loading commit data...
empty_dir Loading commit data...
fc Loading commit data...
flexvolume Loading commit data...
flocker Loading commit data...
gce_pd Loading commit data...
git_repo Loading commit data...
glusterfs Loading commit data...
host_path Loading commit data...
iscsi Loading commit data...
local Loading commit data...
nfs Loading commit data...
photon_pd Loading commit data...
portworx Loading commit data...
projected Loading commit data...
quobyte Loading commit data...
rbd Loading commit data...
scaleio Loading commit data...
secret Loading commit data...
storageos Loading commit data...
testing Loading commit data...
util Loading commit data...
validation Loading commit data...
vsphere_volume Loading commit data...
BUILD Loading commit data...
OWNERS Loading commit data...
doc.go Loading commit data...
metrics_cached.go Loading commit data...
metrics_du.go Loading commit data...
metrics_du_test.go Loading commit data...
metrics_errors.go Loading commit data...
metrics_nil.go Loading commit data...
metrics_nil_test.go Loading commit data...
metrics_statfs.go Loading commit data...
metrics_statfs_test.go Loading commit data...
plugins.go Loading commit data...
plugins_test.go Loading commit data...
volume.go Loading commit data...
volume_linux.go Loading commit data...
volume_unsupported.go Loading commit data...