[sheepdog] [PATCH v2] gateway: use more user friendly outout for poll timeout

MORITA Kazutaka morita.kazutaka at lab.ntt.co.jp
Thu May 23 11:55:55 CEST 2013


At Thu, 23 May 2013 16:48:24 +0800,
Liu Yuan wrote:
> 
> Signed-off-by: Liu Yuan <namei.unix at gmail.com>
> ---
>  - move printf to better place
>  sheep/gateway.c |    4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/sheep/gateway.c b/sheep/gateway.c
> index 1a37ad8..207ef4a 100644
> --- a/sheep/gateway.c
> +++ b/sheep/gateway.c
> @@ -164,13 +164,15 @@ again:
>  
>  		panic("%m");
>  	} else if (pollret == 0) {
> -		sd_eprintf("poll timeout %d", wi->nr_sent);
>  		/*
>  		 * If IO NIC is down, epoch isn't incremented, so we can't retry
>  		 * for ever.
>  		 */
>  		if (sheep_need_retry(req->rq.epoch) && repeat) {
>  			repeat--;
> +			sd_eprintf("poll timeout %d, disks of some nodes or"
> +				   " network is busy. Going to poll-wait again",
> +				   wi->nr_sent);

I wonder if SDOG_ERR is an appropriate log level here.  Even if
timeout happens, sheep doesn't return any errors to a VM.  I think
SDOG_WARNING is better to avoid confusing users.

Thanks,

Kazutaka


More information about the sheepdog mailing list