From f401c6047f205cc2df8e0887fdf1010c4d5e47de Mon Sep 17 00:00:00 2001 From: Rob Hoes Date: Wed, 26 Jun 2013 15:04:24 +0100 Subject: [PATCH] Do signal xapi when an IP address is removed BobB pointed out that when a DHCP lease expires, the IP address may go away. Therefore, a signal to xapi for it to update its DB makes sense. Signed-off-by: Rob Hoes --- networkd/network_monitor_thread.ml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/networkd/network_monitor_thread.ml b/networkd/network_monitor_thread.ml index dca87847a..1037a16ba 100644 --- a/networkd/network_monitor_thread.ml +++ b/networkd/network_monitor_thread.ml @@ -263,8 +263,7 @@ let ip_watcher () = let rec loop () = let line = input_line in_channel in (* Do not send events for link-local IPv6 addresses, and removed IPs *) - if String.has_substr line "inet" && not (String.has_substr line "inet6 fe80") && - not (String.has_substr line "Deleted") then begin + if String.has_substr line "inet" && not (String.has_substr line "inet6 fe80") then begin (* Ignore changes for the next second, since they usually come in bursts, * and signal only once. *) Thread.delay 1.;