Revision 9888b9e6 lib/backend.py

b/lib/backend.py
277 277
      err_msg = "Can't activate master IP: %s" % result.output
278 278
      logging.error(err_msg)
279 279

  
280
    # we ignore the exit code of the following cmds
281
    if ipcls == netutils.IP4Address:
282
      utils.RunCmd(["arping", "-q", "-U", "-c 3", "-I", master_netdev, "-s",
283
                    master_ip, master_ip])
284
    elif ipcls == netutils.IP6Address:
285
      try:
286
        utils.RunCmd(["ndisc6", "-q", "-r 3", master_ip, master_netdev])
287
      except errors.OpExecError:
288
        # TODO: Better error reporting
289
        logging.warning("Can't execute ndisc6, please install if missing")
280
    else:
281
      # we ignore the exit code of the following cmds
282
      if ipcls == netutils.IP4Address:
283
        utils.RunCmd(["arping", "-q", "-U", "-c 3", "-I", master_netdev, "-s",
284
                      master_ip, master_ip])
285
      elif ipcls == netutils.IP6Address:
286
        try:
287
          utils.RunCmd(["ndisc6", "-q", "-r 3", master_ip, master_netdev])
288
        except errors.OpExecError:
289
          # TODO: Better error reporting
290
          logging.warning("Can't execute ndisc6, please install if missing")
290 291

  
291 292
  if err_msg:
292 293
    _Fail(err_msg)

Also available in: Unified diff