From f3e6bdbe1b174f1350b1862e6da5200cae49a77a Mon Sep 17 00:00:00 2001 From: chove Date: Mon, 11 Apr 2005 23:12:25 +0200 Subject: [PATCH] ajout de la fonctionalit que Vince|| avait mise dans la version originale darcs-hash:20050411211225-4ec08-ade8e196b06775b17ce6acbb913fa613068f97ff.gz --- gestion/tools/locate-mac.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gestion/tools/locate-mac.py b/gestion/tools/locate-mac.py index 75e5ca6f..279204de 100755 --- a/gestion/tools/locate-mac.py +++ b/gestion/tools/locate-mac.py @@ -6,6 +6,7 @@ sys.path.append('/usr/scripts/gestion') from annuaires import reverse, all_switchs from hptools import hpswitch from time import sleep +from os import system import threading mac = ":".join([i.zfill(2) for i in sys.argv[1].split(":")]).lower() @@ -34,3 +35,6 @@ for switch in ['backbone'] + all_switchs(): while len(threading.enumerate()) > 1 : sleep(1) + +print +system('whos mac=%s' % mac)