'Find ALUA info from xml.'

def _find_alua_info(self, iscsi_info, initiator_name):

    multipath_type = 0
    for ini in iscsi_info:
        if (ini['Name'] == initiator_name):
            if ('ALUA' in ini):
                if ((ini['ALUA'] != '1') and (ini['ALUA'] != '0')):
                    msg = _('Invalid    ALUA    value.    ALUA    value    must    be    1    or    0.')
                    LOG.error(msg)
                    raise exception.InvalidInput(msg)
                else:
                    multipath_type = ini['ALUA']
                    break
    return multipath_type
