Hi Dan,Is there an easy way to tell condor 6.7.18 to prefer private addresses instead of public addresses? Or is there some wildcard that we can set to avoid having to set NETWORK_INTERFACE for each machine individually?
something like: NETWORK_INTERFACE=192.168.0.* or NETWORK_INTERFACE=192.168.0.0/24 or NETWORK_INTERFACE=eth0 --Mike Dan Bradley wrote:
Stuart,The algorithm for picking an interface turns out to be a little more complicated than just picking the "first one found". I will correct that in the manual.The algorithm (as of my reading in 6.7.19 source code) is this:Loop through DNS host records returned by gethostbyname() for the current host. Pick one of the IP addresses from this list. The first preference is an IP address other than anything matching the following addresses 10.*, 172.16.*, 192.168.*, 127.0.0.1. The second choice is anything not matching 127.0.0.1. The third choice is 127.0.0.1. If there are multiple options of equal preference, the first one returned by gethostbyname() is used. (However, I just discovered that the reverse is true for the private addresses 10.*, 172.16.*, etc. In that case the _last_ one in the list is returned. This is probably not intentional, so we'll review that.)The new behavior added in 6.7.18 is that if you specify BIND_ALL_INTERFACES=True, then the choice of IP address to advertise is dynamic, depending on what network interface is actually used when communicating with the collector. This allows, for example, a multi-homed schedd to flock jobs to two different sites in separate networks. It also allows glidein startds that land on a multi-homed machine to more dependably choose the correct network interface to advertise so that they are reachable from the outside.--Dan
Description: S/MIME Cryptographic Signature