[sheepdog] [PATCH v2 0/3] sheepkeeper: a new cluster manager specialized for sheepdog
Hitoshi Mitake
h.mitake at gmail.com
Mon Nov 12 12:55:56 CET 2012
On Mon, Nov 12, 2012 at 6:42 PM, Liu Yuan <namei.unix at gmail.com> wrote:
> On 11/12/2012 04:58 PM, Hitoshi Mitake wrote:
>> This patchset adds sheepkeeper: a new cluster manager specialized for sheepdog.
>> The 3rd patch actually adds sheepkeeper, 1st and 2nd do preparation for it.
>>
Thanks for your review.
>
> get GCC warning:
> ...
> sheepkeeper.c: In function ‘main’:
> sheepkeeper.c:444:9: warning: ignoring return value of ‘daemon’,
> declared with attribute warn_unused_result [-Wunused-result]
> sheepkeeper.c:480:9: warning: ignoring return value of ‘daemon’,
> declared with attribute warn_unused_result [-Wunused-result]
> In file included from /usr/include/string.h:642:0,
> from sheepkeeper.c:14:
> In function ‘memcpy’,
> inlined from ‘main’ at sheepkeeper.c:462:8:
> /usr/include/x86_64-linux-gnu/bits/string3.h:52:3: warning: call to
> __builtin___memcpy_chk will always overflow destination buffer [enabled
> by default]
> ...
It seems that -Wunused-result is not passed to gcc in the Makefile of sheepdog.
Will it be added to CFLAGS?
>
>
>> Hitoshi Mitake (3):
>> move node_to_str() and str_to_node() from sheep/cluster.h to
>> include/internal_proto.h
>> logger: use syslog() when outfile == NULL
>
> Why sheepkeeper need syslog() instead of a plain file?
Because I couldn't find suitable single file for log from sheepkeeper.
The relation between sheep and sheepkeeper is not 1:1. sheepkeeper can be
executed on hosts which doesn't have sheep. So sheepkeeper shouldn't assume
directories of sheep (e.g. /store/sheep).
So I decided to use syslog() for logging by sheepkeeper. But if you want,
we can use a single dedicated file for logging.
It seems that it is better if we can choose syslog() or a plain file
for logging by
command line option. How do you think?
Thanks,
Hitoshi
More information about the sheepdog
mailing list