Revision 96e0d5cc lib/backend.py

b/lib/backend.py
375 375

  
376 376
@RunLocalHooks(constants.FAKE_OP_MASTER_TURNDOWN, "master-ip-turndown",
377 377
               _BuildMasterIpHookEnv)
378
def DeactivateMasterIp():
378
def DeactivateMasterIp(master_ip, master_netmask, master_netdev):
379 379
  """Deactivate the master IP on this node.
380 380

  
381
  @param master_ip: the master IP
382
  @param master_netmask: the master IP netmask
383
  @param master_netdev: the master network device
384

  
381 385
  """
382 386
  # TODO: log and report back to the caller the error failures; we
383 387
  # need to decide in which case we fail the RPC for this
384 388

  
385
  # GetMasterInfo will raise an exception if not able to return data
386
  master_netdev, master_ip, _, _, master_netmask = GetMasterInfo()
387

  
388 389
  result = utils.RunCmd([constants.IP_COMMAND_PATH, "address", "del",
389 390
                         "%s/%s" % (master_ip, master_netmask),
390 391
                         "dev", master_netdev])

Also available in: Unified diff