|
|
8c1676 |
From 9bcb30c91723e63c16c8a2cdbcd94f61f370a6a9 Mon Sep 17 00:00:00 2001
|
|
|
8c1676 |
From: Greg Hudson <ghudson@mit.edu>
|
|
|
8c1676 |
Date: Wed, 10 Feb 2016 11:50:54 -0500
|
|
|
8c1676 |
Subject: [PATCH 1/3] Fix and adjust t_kprop.py
|
|
|
8c1676 |
|
|
|
8c1676 |
The listprincs check was at the wrong indentation level and had the
|
|
|
8c1676 |
wrong argument grouping; fix it so we actually verify the propagation.
|
|
|
8c1676 |
|
|
|
8c1676 |
Stop using the -t (runonce) flag to kpropd, so that kpropd continues
|
|
|
8c1676 |
to run until k5test.py terminates it. Quit out of the read loop when
|
|
|
8c1676 |
we see that the load process is completed, instead of looking for end
|
|
|
8c1676 |
of input. This change is needed in order to add hooks in k5test.py
|
|
|
8c1676 |
for checking daemons for memory leaks before terminating them.
|
|
|
8c1676 |
---
|
|
|
8c1676 |
src/tests/t_kprop.py | 10 +++++-----
|
|
|
8c1676 |
1 file changed, 5 insertions(+), 5 deletions(-)
|
|
|
8c1676 |
|
|
|
8c1676 |
diff --git a/src/tests/t_kprop.py b/src/tests/t_kprop.py
|
|
|
8c1676 |
index e2026c8..d625627 100755
|
|
|
8c1676 |
--- a/src/tests/t_kprop.py
|
|
|
8c1676 |
+++ b/src/tests/t_kprop.py
|
|
|
8c1676 |
@@ -24,21 +24,21 @@ for realm in multipass_realms(create_user=False):
|
|
|
8c1676 |
realm.addprinc('wakawaka')
|
|
|
8c1676 |
|
|
|
8c1676 |
# Start kpropd.
|
|
|
8c1676 |
- kpropd = realm.start_kpropd(slave, ['-d', '-t'])
|
|
|
8c1676 |
+ kpropd = realm.start_kpropd(slave, ['-d'])
|
|
|
8c1676 |
|
|
|
8c1676 |
realm.run([kdb5_util, 'dump', dumpfile])
|
|
|
8c1676 |
realm.run([kprop, '-f', dumpfile, '-P', str(realm.kprop_port()), hostname])
|
|
|
8c1676 |
output('*** kpropd output follows\n')
|
|
|
8c1676 |
while True:
|
|
|
8c1676 |
line = kpropd.stdout.readline()
|
|
|
8c1676 |
- if line == '':
|
|
|
8c1676 |
+ if 'Database load process for full propagation completed' in line:
|
|
|
8c1676 |
break
|
|
|
8c1676 |
output('kpropd: ' + line)
|
|
|
8c1676 |
if 'Rejected connection' in line:
|
|
|
8c1676 |
fail('kpropd rejected connection from kprop')
|
|
|
8c1676 |
|
|
|
8c1676 |
- out = realm.run([kadminl, 'listprincs', slave])
|
|
|
8c1676 |
- if 'wakawaka' not in out:
|
|
|
8c1676 |
- fail('Slave does not have all principals from master')
|
|
|
8c1676 |
+ out = realm.run([kadminl, 'listprincs'], slave)
|
|
|
8c1676 |
+ if 'wakawaka' not in out:
|
|
|
8c1676 |
+ fail('Slave does not have all principals from master')
|
|
|
8c1676 |
|
|
|
8c1676 |
success('kprop tests')
|
|
|
8c1676 |
--
|
|
|
8c1676 |
2.8.1
|
|
|
8c1676 |
|