File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -103,7 +103,8 @@ def create_iscsi_sessions(self, sr_uuid):
103
103
self .iscsiSRs = []
104
104
self .iscsiSRs .append (iscsi )
105
105
saved_exc = None
106
- if self .dconf ['target' ].find (',' ) == 0 or self .dconf ['targetIQN' ] == "*" :
106
+ targets = self .dconf ['target' ].split (',' )
107
+ if len (targets ) > 1 or self .dconf ['targetIQN' ] == "*" :
107
108
# Instantiate multiple sessions
108
109
self .iscsiSRs = []
109
110
if self .dconf ['targetIQN' ] == "*" :
@@ -129,7 +130,7 @@ def create_iscsi_sessions(self, sr_uuid):
129
130
# IQNstring cannot be built with a dictionary iteration because of this
130
131
IQNstring = self .dconf ['multiSession' ]
131
132
else :
132
- for tgt in self . dconf [ 'target' ]. split ( ',' ) :
133
+ for tgt in targets :
133
134
try :
134
135
tgt_ip = util ._convertDNS (tgt )
135
136
except :
You can’t perform that action at this time.
0 commit comments