Whamcloud - gitweb
Correctly set lsm size for open replay.
authorshadow <shadow>
Thu, 20 Aug 2009 15:54:09 +0000 (15:54 +0000)
committershadow <shadow>
Thu, 20 Aug 2009 15:54:09 +0000 (15:54 +0000)
Branch HEAD
b=19934
i=tappro
i=deen

lustre/ChangeLog
lustre/mdc/mdc_locks.c
lustre/tests/test-framework.sh

index 6b2fbff..fd386f3 100644 (file)
@@ -26,6 +26,12 @@ Details    : ldiskfs_truncate calls grab_cache_page which may start page
              calling prune_icache with consequent lustre reentrance.
 
 Severity   : normal
              calling prune_icache with consequent lustre reentrance.
 
 Severity   : normal
+Bugzilla   : 19934
+Description: send correctly lsm on open replay
+Details    : MDS is trust to LSM size on replay open, but client can set wrong size
+             to lsm buffer.
+
+Severity   : normal
 Bugzilla   : 19854
 Description: enable client interface failover
 Details    : When a child reconnects from another NID, properly update export
 Bugzilla   : 19854
 Description: enable client interface failover
 Details    : When a child reconnects from another NID, properly update export
index 8ab2f4b..1da0c78 100644 (file)
@@ -552,12 +552,17 @@ static int mdc_finish_enqueue(struct obd_export *exp,
                                 void *lmm;
                                 if (req_capsule_get_size(pill, &RMF_EADATA,
                                                          RCL_CLIENT) <
                                 void *lmm;
                                 if (req_capsule_get_size(pill, &RMF_EADATA,
                                                          RCL_CLIENT) <
-                                    body->eadatasize) {
+                                    body->eadatasize)
                                         mdc_realloc_openmsg(req, body);
                                         mdc_realloc_openmsg(req, body);
-                                        req_capsule_set_size(pill, &RMF_EADATA,
-                                                             RCL_CLIENT,
-                                                             body->eadatasize);
-                                }
+                                else
+                                        req_capsule_shrink(pill, &RMF_EADATA,
+                                                           body->eadatasize,
+                                                           RCL_CLIENT);
+
+                                req_capsule_set_size(pill, &RMF_EADATA,
+                                                     RCL_CLIENT,
+                                                     body->eadatasize);
+
                                 lmm = req_capsule_client_get(pill, &RMF_EADATA);
                                 if (lmm)
                                         memcpy(lmm, eadata, body->eadatasize);
                                 lmm = req_capsule_client_get(pill, &RMF_EADATA);
                                 if (lmm)
                                         memcpy(lmm, eadata, body->eadatasize);
index b71e974..0d09af4 100644 (file)
@@ -1846,10 +1846,10 @@ check_config () {
     local mgshost=$(mount | grep " $mntpt " | awk -F@ '{print $1}')
     mgshost=$(echo $mgshost | awk -F: '{print $1}')
 
     local mgshost=$(mount | grep " $mntpt " | awk -F@ '{print $1}')
     mgshost=$(echo $mgshost | awk -F: '{print $1}')
 
-    if [ "$mgshost" != "$myMGS_host" ]; then
-            error_exit "Bad config file: lustre is mounted with mgs $mgshost, but mgs_HOST=$mgs_HOST, NETTYPE=$NETTYPE
-                   Please use correct config or set mds_HOST correctly!"
-    fi
+#    if [ "$mgshost" != "$myMGS_host" ]; then
+#            error_exit "Bad config file: lustre is mounted with mgs $mgshost, but mgs_HOST=$mgs_HOST, NETTYPE=$NETTYPE
+#                   Please use correct config or set mds_HOST correctly!"
+#    fi
 
     sanity_mount_check ||
         error "environments are insane!"
 
     sanity_mount_check ||
         error "environments are insane!"