X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=xenserver%2Fopt_xensource_libexec_InterfaceReconfigureVswitch.py;h=a4b9da751e4626e1ce527cc4cbe7d1563b72ba20;hb=769c32b0b3e9795f1dd5ed04ade3f51ca2b3e113;hp=b102886e0cabb89850dcabd18e1a7ee9881d6ceb;hpb=16f2ae571fc7d21f13c9ddbe4e948d8f35552ae5;p=openvswitch diff --git a/xenserver/opt_xensource_libexec_InterfaceReconfigureVswitch.py b/xenserver/opt_xensource_libexec_InterfaceReconfigureVswitch.py index b102886e..a4b9da75 100644 --- a/xenserver/opt_xensource_libexec_InterfaceReconfigureVswitch.py +++ b/xenserver/opt_xensource_libexec_InterfaceReconfigureVswitch.py @@ -358,6 +358,17 @@ class DatapathVswitch(Datapath): log("Configured for Vswitch datapath") + @classmethod + def rewrite(cls): + vsctl_argv = [] + for pif in db().get_all_pifs(): + pifrec = db().get_pif_record(pif) + if not pif_is_vlan(pif) and pifrec['currently_attached']: + vsctl_argv += set_br_external_ids(pif) + + if vsctl_argv != []: + datapath_modify_config(vsctl_argv) + def configure_ipdev(self, cfg): cfg.write("TYPE=Ethernet\n")