ifdown: Introduce _UnconfigureNIC() helper method
authorDimitris Aragiorgis <dimara@grnet.gr>
Tue, 4 Feb 2014 13:33:09 +0000 (15:33 +0200)
committerDimitris Aragiorgis <dimara@grnet.gr>
Thu, 27 Mar 2014 08:01:15 +0000 (10:01 +0200)
commit5f3219f90ea7eaac96a15171799f6703412b1390
treed6d2c8ec27f0668be5435f8d5e96c965df0fba54
parent02985c42044217333d8c6ba7491df73899c71242
ifdown: Introduce _UnconfigureNIC() helper method

This method takes a NIC object, creates the proper invironment
and invokes ifdown script.

It takes an extra boolean argument only_local which is passed
to ifdown script as the second positional argument. It states
if the external script should wipe out every configuration
related to the NIC or should only clean up local thinks, e.g.
during a successful migration we are going to invoke ifdown
on the source node but we do not want to purge any DDNS
configuration related to instance's NICs.

Signed-off-by: Dimitris Aragiorgis <dimara@grnet.gr>
lib/hypervisor/hv_kvm.py