Пример #1
0
        // Whether the vSwitch Controller appears to be configured.
        // (Note that we can't tell whether it's actually working properly through the API).
        public bool vSwitchController()
        {
            if (string.IsNullOrEmpty(vswitch_controller))
            {
                return(false);
            }

            foreach (Host h in Connection.Cache.Hosts)
            {
                if (Host.RestrictVSwitchController(h) ||
                    !h.software_version.ContainsKey("network_backend") ||
                    h.software_version["network_backend"] != "openvswitch")
                {
                    return(false);
                }
            }

            return(true);
        }