Revision 35c0c8da lib/cmdlib.py

b/lib/cmdlib.py
610 610
            if params[constants.NIC_MODE] == constants.NIC_MODE_BRIDGED]
611 611
  if brlist:
612 612
    result = lu.rpc.call_bridges_exist(target_node, brlist)
613
    result.Raise()
614
    if not result.data:
615
      raise errors.OpPrereqError("One or more target bridges %s does not"
616
                                 " exist on destination node '%s'" %
617
                                 (brlist, target_node))
613
    msg = result.RemoteFailMsg()
614
    if msg:
615
      raise errors.OpPrereqError("Error checking bridges on destination node"
616
                                 " '%s': %s" % (target_node, msg))
618 617

  
619 618

  
620 619
def _CheckInstanceBridgesExist(lu, instance, node=None):
......
6166 6165
      if new_nic_mode == constants.NIC_MODE_BRIDGED:
6167 6166
        nic_bridge = new_filled_nic_params[constants.NIC_LINK]
6168 6167
        result = self.rpc.call_bridges_exist(pnode, [nic_bridge])
6169
        result.Raise()
6170
        if not result.data:
6171
          msg = ("Bridge '%s' doesn't exist on one of"
6172
                 " the instance nodes" % nic_bridge)
6168
        msg = result.RemoteFailMsg()
6169
        if msg:
6170
          msg = "Error checking bridges on node %s: %s" % (pnode, msg)
6173 6171
          if self.force:
6174 6172
            self.warn.append(msg)
6175 6173
          else:

Also available in: Unified diff