krb5 commit: Document kpropd -t and fix it in iprop mode
Greg Hudson
ghudson at mit.edu
Mon Apr 13 17:59:50 EDT 2015
https://github.com/krb5/krb5/commit/334f761ba485e4af6d5fb8822e276d4590b97bf5
commit 334f761ba485e4af6d5fb8822e276d4590b97bf5
Author: Greg Hudson <ghudson at mit.edu>
Date: Wed Apr 8 17:35:56 2015 -0400
Document kpropd -t and fix it in iprop mode
If kpropd is asked to run just once, don't exit after starting a full
resync; we want to wait for the fullprop child to process the request,
and then request incremental updates afterwards. Also don't exit from
do_standalone() in the fullprop child, in case multiple full resyncs
are required to get the database up to date.
Document the -t flag in kpropd.rst.
ticket: 8161
doc/admin/admin_commands/kpropd.rst | 7 +++++++
src/slave/kpropd.c | 4 ++--
2 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/doc/admin/admin_commands/kpropd.rst b/doc/admin/admin_commands/kpropd.rst
index 465d4f5..5e01e2f 100644
--- a/doc/admin/admin_commands/kpropd.rst
+++ b/doc/admin/admin_commands/kpropd.rst
@@ -15,6 +15,7 @@ SYNOPSIS
[**-p** *kdb5_util_prog*]
[**-P** *port*]
[**-d**]
+[**-t**]
DESCRIPTION
-----------
@@ -89,6 +90,12 @@ OPTIONS
it will run in the foreground and print out debugging messages
during the database propagation.
+**-t**
+ In standalone mode without incremental propagation, exit after one
+ dump file is received. In incremental propagation mode, exit as
+ soon as the database is up to date, or if the master returns an
+ error.
+
**-P**
Allow for an alternate port number for kpropd to listen on. This
is only useful in combination with the **-S** option.
diff --git a/src/slave/kpropd.c b/src/slave/kpropd.c
index 1bac58e..1383156 100644
--- a/src/slave/kpropd.c
+++ b/src/slave/kpropd.c
@@ -444,7 +444,7 @@ do_standalone()
* process that it should poll for incremental updates. */
if (fullprop_child == 0)
kill(getppid(), SIGUSR1);
- if (runonce)
+ else if (runonce)
exit(0);
}
}
@@ -963,7 +963,7 @@ reinit:
break;
}
- if (runonce == 1)
+ if (runonce == 1 && incr_ret->ret != UPDATE_FULL_RESYNC_NEEDED)
goto done;
/*
More information about the cvs-krb5
mailing list