'Ensure that the flags are set properly.'

def check_for_setup_error(self):

    LOG.debug('enter:    check_for_setup_error')
    if (self._system_name is None):
        msg = _('check_for_setup_error:    Unable    to    determine    system    name.')
        raise exception.VolumeBackendAPIException(data=msg)
    if (self._system_id is None):
        msg = _('check_for_setup_error:    Unable    to    determine    system    id.')
        raise exception.VolumeBackendAPIException(data=msg)
    required_flags = ['san_ip', 'san_ssh_port', 'san_login']
    for flag in required_flags:
        if (not self.configuration.safe_get(flag)):
            msg = (_('%s    is    not    set.') % flag)
            raise exception.InvalidInput(reason=msg)
    if (not (self.configuration.san_password or self.configuration.san_private_key)):
        msg = _('check_for_setup_error:    Password    or    SSH    private    key    is    required    for    authentication:    set    either    san_password    or    san_private_key    option.')
        raise exception.InvalidInput(reason=msg)
    params = self._build_default_params()
    self._check_vdisk_params(params)
    LOG.debug('leave:    check_for_setup_error')
