feat: read and validate unit serial number after login
this patch adds a read of VPD page 0x80 (unit serial number) after successful login. The serial is then validated on secutive reconnects to avoid the accidental mismatch of LUN ids if some kind of remapping appears between loss of connection and a later reconnect. An additional url parameter force_usn is added to enforce the usn right from the beginning. If not set via url or the new iscsi_set_unit_serial_number function the usn is learned at the first successful login. Signed-off-by: Peter Lieven <pl@dlhnet.de>
This commit is contained in:
@@ -116,6 +116,7 @@ struct iscsi_context {
|
||||
char portal[MAX_STRING_SIZE+1];
|
||||
char alias[MAX_STRING_SIZE+1];
|
||||
char bind_interfaces[MAX_STRING_SIZE+1];
|
||||
char unit_serial_number[MAX_STRING_SIZE+1];
|
||||
|
||||
enum iscsi_chap_auth chap_auth;
|
||||
char user[MAX_STRING_SIZE+1];
|
||||
|
||||
Reference in New Issue
Block a user