From 6585969f62b580504637bef09990e49c03d50f6a Mon Sep 17 00:00:00 2001 From: William Brown Date: Wed, 11 May 2016 13:40:31 +1000 Subject: [PATCH] Ticket 48830 - Convert lib389 to ip route tools Bug Description: lib389 is using the deprecated ifconfig for a check. Fix Description: replace this with the correct call to ip route tools instead https://fedorahosted.org/389/ticket/48830 Author: wibrown Review by: ??? --- lib389/utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib389/utils.py b/lib389/utils.py index 1ede4e3..17aff84 100644 --- a/lib389/utils.py +++ b/lib389/utils.py @@ -371,9 +371,9 @@ def isLocalHost(host_name): # next, see if this IP addr is one of our # local addresses - p = my_popen(['/sbin/ifconfig', '-a'], stdout=PIPE) + p = my_popen(['/sbin/ip', 'addr'], stdout=PIPE) child_stdout = p.stdout.read() - found = ('inet addr:' + ip_addr) in child_stdout + found = ('inet ' + ip_addr) in child_stdout p.wait() return found -- 2.5.5