Revision 0e67cdbe lib/cmdlib.py

b/lib/cmdlib.py
1547 1547
    "pinst_list", "sinst_list",
1548 1548
    "pip", "sip", "tags",
1549 1549
    "serial_no",
1550
    "master_candidate",
1551
    "master",
1550 1552
    )
1551 1553

  
1552 1554
  def ExpandNames(self):
......
1635 1637
          if secnode in node_to_secondary:
1636 1638
            node_to_secondary[secnode].add(inst.name)
1637 1639

  
1640
    master_node = self.cfg.GetMasterNode()
1641

  
1638 1642
    # end data gathering
1639 1643

  
1640 1644
    output = []
......
1659 1663
          val = list(node.GetTags())
1660 1664
        elif field == "serial_no":
1661 1665
          val = node.serial_no
1666
        elif field == "master_candidate":
1667
          val = node.master_candidate
1668
        elif field == "master":
1669
          val = node.name == master_node
1662 1670
        elif self._FIELDS_DYNAMIC.Matches(field):
1663 1671
          val = live_data[node.name].get(field, None)
1664 1672
        else:

Also available in: Unified diff