예제 #1
0
파일: quagga.py 프로젝트: Benocs/core
 def routerid(node):
     ''' Helper to return the first IPv4 address of a node as its router ID.
     '''
     # Use IPv4 loopback address of this node as the routerID.
     # Don't get v4-loopback-addr directly from node as the node might has
     # IPv4 disabled. Instead, directly query the central 'database' for the
     # IPv4 address that would be the nodes IPv4 loopback.
     return str(Loopback.getLoopbackIPv4(node))
예제 #2
0
파일: bird.py 프로젝트: Benocs/core
 def routerid(node):
     ''' Helper to return the first IPv4 address of a node as its router ID.
     '''
     return str(Loopback.getLoopbackIPv4(node))