Skip to content

Commit

Permalink
Merge pull request #526 from MarkSymsCtx/CA-349188
Browse files Browse the repository at this point in the history
CA-349188: only the initiatorname is critical
  • Loading branch information
MarkSymsCtx authored Nov 24, 2020
2 parents fb3c65f + 5b14047 commit acc7d1f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/set-iscsi-initiator
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@ INITIATORALIAS=$2
flock -s 200

CURRENT_INITATOR=$(awk 'BEGIN { FS = "=" } /InitiatorName/ {print $2}' $INITIATORFILE)
CURRENT_ALIAS=$(awk 'BEGIN { FS = "=" } /InitiatorAlias/ {print $2}' $INITIATORFILE)

if [ "$CURRENT_INITATOR" == "$INITIATORNAME" -a "$CURRENT_ALIAS" == "$INITIATORALIAS" ]
# Only care that the initiator name is the name, alias may be missing
if [ "$CURRENT_INITATOR" == "$INITIATORNAME" ]
then
exit 0
fi
Expand Down

0 comments on commit acc7d1f

Please sign in to comment.