[sheepdog] [PATCH v3 3/5] tools: add kill_zk_session
MORITA Kazutaka
morita.kazutaka at gmail.com
Mon Jun 17 18:23:20 CEST 2013
At Mon, 17 Jun 2013 05:28:44 -0700,
Kai Zhang wrote:
>
> This is a useful tool for simulating zookeeper session timeout.
>
> Usage:
> ./kill_zk_session [zk_path]
>
> zk_path should contains the clientid_t content.
>
> Signed-off-by: Kai Zhang <kyle at zelin.io>
> ---
> Makefile.am | 2 +-
> configure.ac | 3 ++-
> tools/Makefile.am | 11 +++++++++
> tools/kill_zk_session.c | 58 +++++++++++++++++++++++++++++++++++++++++++++++
> 4 files changed, 72 insertions(+), 2 deletions(-)
> create mode 100644 tools/Makefile.am
> create mode 100644 tools/kill_zk_session.c
>
> diff --git a/Makefile.am b/Makefile.am
> index 16eb532..adc0784 100644
> --- a/Makefile.am
> +++ b/Makefile.am
> @@ -17,7 +17,7 @@ sheepdogsysconfdir = ${SHEEPDOGCONFDIR}
>
> sheepdogsysconf_DATA =
>
> -SUBDIRS = lib collie sheep include script shepherd
> +SUBDIRS = lib collie sheep include script shepherd tools
>
> if BUILD_SHEEPFS
> SUBDIRS += sheepfs
> diff --git a/configure.ac b/configure.ac
> index e06e55c..187fd71 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -134,7 +134,8 @@ AC_CONFIG_FILES([Makefile
> script/Makefile
> lib/Makefile
> man/Makefile
> - shepherd/Makefile])
> + shepherd/Makefile
> + tools/Makefile])
>
> ### Local business
>
> diff --git a/tools/Makefile.am b/tools/Makefile.am
> new file mode 100644
> index 0000000..f07a1cc
> --- /dev/null
> +++ b/tools/Makefile.am
> @@ -0,0 +1,11 @@
> +MAINTAINERCLEANFILES = Makefile.in
> +
> +sbin_PROGRAMS = kill_zk_session
> +
> +if BUILD_ZOOKEEPER
> +kill_zk_session_SOURCES = kill_zk_session.c
> +
> +kill_zk_session_LDADD = -lzookeeper_mt
> +endif
This causes a compile error when --enable-zookeeper is not specified
to configure.
Thanks,
Kazutaka
More information about the sheepdog
mailing list