From 9e29c4deb8175d47a053b5e24258a1b4b4d9fa50 Mon Sep 17 00:00:00 2001 From: bobijam Date: Tue, 15 Jul 2008 01:40:24 +0000 Subject: [PATCH] Branch HEAD b=16205 i=johann, sheng.yang use a macro defining ldlm timeout value on MDS. --- lustre/include/obd_support.h | 5 +++-- lustre/mdt/mdt_handler.c | 4 +++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/lustre/include/obd_support.h b/lustre/include/obd_support.h index fd4d87f..57d1c33 100644 --- a/lustre/include/obd_support.h +++ b/lustre/include/obd_support.h @@ -75,8 +75,9 @@ int obd_alloc_fail(const void *ptr, const char *name, const char *type, size_t size, const char *file, int line); /* Timeout definitions */ -#define OBD_TIMEOUT_DEFAULT 100 -#define LDLM_TIMEOUT_DEFAULT 20 +#define OBD_TIMEOUT_DEFAULT 100 +#define LDLM_TIMEOUT_DEFAULT 20 +#define MDS_LDLM_TIMEOUT_DEFAULT 6 /* Time to wait for all clients to reconnect during recovery */ /* Should be very conservative; must catch the first reconnect after reboot */ #define OBD_RECOVERY_FACTOR (3) /* times obd_timeout */ diff --git a/lustre/mdt/mdt_handler.c b/lustre/mdt/mdt_handler.c index 67918fe..de3166d 100644 --- a/lustre/mdt/mdt_handler.c +++ b/lustre/mdt/mdt_handler.c @@ -4008,8 +4008,10 @@ static int mdt_init0(const struct lu_env *env, struct mdt_device *m, mdt_init_capa_ctxt(env, m); + /* we use a shorter ldlm_timeout on MDS for keep bumping on + * might-be slow processing OST */ if (ldlm_timeout == LDLM_TIMEOUT_DEFAULT) - ldlm_timeout = 6; + ldlm_timeout = MDS_LDLM_TIMEOUT_DEFAULT; RETURN(0); -- 1.8.3.1