code: def check_ports_on_br(self, bridge='br-ex', ports=['eth3']):
          
          LOG.info("RPC: check_ports_on_br bridge: %s, ports: %s" %
                   (bridge, ports))
          cmd = ['ovs-vsctl', 'list-ports', bridge]
          stdcode, stdout = agent_utils.execute(cmd, root=True)
          data = dict()
          if stdcode == 0:
              for port in ports:
                  if port in stdout:
                      data[port] = True
                      stdout.remove(port)
                  else:
                      data[port] = False
              return agent_utils.make_response(code=stdcode, data=data)
          # execute failed.
          message = stdout.pop(0)
          return agent_utils.make_response(code=stdcode,
                                           message=message)
docs: Check ports exist on bridge.
  
          ovs-vsctl list-ports bridge