Skip to content

Commit 93589a1

Browse files
committed
better detection of backstore type - mainly in failed resource state
1 parent 67f2c9b commit 93589a1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

heartbeat/iSCSILogicalUnit.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -501,7 +501,7 @@ iSCSILogicalUnit_stop() {
501501
# gone. Log a warning and still push ahead.
502502

503503
local backstore_type
504-
if targetcli /iscsi/${OCF_RESKEY_target_iqn}/tpg1/luns/lun${OCF_RESKEY_lun} status | grep ' fileio/' >/dev/null; then
504+
if targetcli /backstores/fileio/${OCF_RESOURCE_INSTANCE} status >/dev/null 2>&1 ; then
505505
backstore_type=fileio
506506
else
507507
backstore_type=block

0 commit comments

Comments
 (0)