[krbdev.mit.edu #8611] test programs should dynamically select an free port #

Will Fiveash via RT rt-comment at krbdev.mit.edu
Tue Aug 29 15:24:45 EDT 2017


Today, running src/tests/gssapi/t_ccselect.py, I encountered a "port in
use" error when the krb5kdc was started as a result of this statement:

r2 = K5Realm(create_user=False, realm='KRBTEST2.COM', portbase=62000,
             testdir=os.path.join(r1.testdir, 'r2'))

The problem is that on the test system UDP port 62000 was in use by
mountd.  It would be better if ports for the KDC daemons were first
determined to be free.  If that is too much hassle choosing a random
starting port # above 60000 would make test runs more reliable.


More information about the krb5-bugs mailing list