use actal gateway
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
#
|
#
|
||||||
RCSID="$Id: selfcheck,v 1.1 2006/11/08 13:50:28 andreas Exp $"
|
RCSID="$Id: selfcheck,v 1.2 2006/11/08 15:16:41 andreas Exp $"
|
||||||
# check internet connectivity
|
# check internet connectivity
|
||||||
#
|
#
|
||||||
|
|
||||||
@@ -142,8 +142,8 @@ def checkall(IF):
|
|||||||
Res+=".\n<B>PROBLEM: The interfaces has no gateway</B>"
|
Res+=".\n<B>PROBLEM: The interfaces has no gateway</B>"
|
||||||
return(Res)
|
return(Res)
|
||||||
|
|
||||||
ec=os.system("/sbin/ping -n -c 1 %s >/dev/null 2>&1" % "217.237.157.246")
|
# ec=os.system("/sbin/ping -n -c 1 %s >/dev/null 2>&1" % "217.237.157.246")
|
||||||
# ec=os.system("/sbin/ping -n -c 1 %s >/dev/null 2>&1" % IF.ipgw)
|
ec=os.system("/sbin/ping -n -c 1 %s >/dev/null 2>&1" % IF.ipgw)
|
||||||
if ec == 0:
|
if ec == 0:
|
||||||
Res+=".\nThe gateway is reachable."
|
Res+=".\nThe gateway is reachable."
|
||||||
else:
|
else:
|
||||||
|
|||||||
Reference in New Issue
Block a user