Whamcloud - gitweb
fs/lustre-release.git
3 years agoLU-7986 hsm: update actions llog in place 47/19447/2
John L. Hammond [Fri, 5 Jun 2015 21:39:23 +0000 (16:39 -0500)]
LU-7986 hsm: update actions llog in place

Update HSM actions llog entries in place rather than doing an append
and cancel.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I5c5282d199e43fbc6709d5dc9bc050e0b98fb889
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/19447
Tested-by: Jenkins
Reviewed-by: Frank Zago <fzago@cray.com>
Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Tested-by: Maloo <hpdd-maloo@intel.com>
3 years agoLU-7992 hsm: close KUC pipe before unregistering 42/19442/2
John L. Hammond [Thu, 4 Jun 2015 14:48:44 +0000 (09:48 -0500)]
LU-7992 hsm: close KUC pipe before unregistering

In llapi_hsm_copytool_unregister() close the read side of the KUC pipe
before unregistering the copytool to avoid deadlocking with a ldlm_cb
thread.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I844086b32a3b2958ecaec391accded0ca06f60a2
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Faccini Bruno <bruno.faccini@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/19442
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Frank Zago <fzago@cray.com>
3 years agoLU-7998 utils: fix fd lost 08/19408/4
Dmitry Eremin [Fri, 8 Apr 2016 15:20:01 +0000 (18:20 +0300)]
LU-7998 utils: fix fd lost

A file descriptor for "/dev/loop-control" was never closed.

Change-Id: I0dc1cb2453f49322315f00266308c829c04b4792
Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-on: http://review.whamcloud.com/19408
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7835 checkpatch: Update gerrit_checkpatch for new features. 48/18748/4
Ashley Pittman [Wed, 2 Mar 2016 12:24:12 +0000 (12:24 +0000)]
LU-7835 checkpatch: Update gerrit_checkpatch for new features.

Allow checking of a single patch per invocation rather than running as
daemon. Update wiki URL for coding standards. Supply --notree option
allowing upstream checkpatch.pl to be used. Add linebreaks to output
when reporting multiple errors per line of source

Signed-off-by: Ashley Pittman <ashley.m.pittman@intel.com>
Change-Id: I3823db55073b606fb84b84f520e598e8427b22e7
Signed-off-by: Ashley Pittman <ashley.m.pittman@intel.com>
Reviewed-on: http://review.whamcloud.com/18748
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
3 years agoLU-7791 ldlm: signal vs CP callback race 98/18498/5
Andriy Skulysh [Tue, 1 Mar 2016 22:15:55 +0000 (00:15 +0200)]
LU-7791 ldlm: signal vs CP callback race

a lock isn't canceled on the server on reception
of a signal on the client when it is blocked waiting
for a lock to be granted, thus client is evicted for
not responding to LDLM_FL_AST_SENT.

Seagate-bug-id: MRP-3314
Change-Id: Ie025bb58b13fb2d741119f74c87439f917983268
Signed-off-by: Andriy Skulysh <andriy.skulysh@seagate.com>
Reviewed-on: http://review.whamcloud.com/18498
Tested-by: Jenkins
Reviewed-by: Vitaly Fertman <vitaly.fertman@seagate.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Chris Horn <hornc@cray.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7434 ptlrpc: lost bulk leads to a hang 21/17221/10
Vitaly Fertman [Tue, 1 Mar 2016 23:46:31 +0000 (02:46 +0300)]
LU-7434 ptlrpc: lost bulk leads to a hang

The reverse order of request_out_callback() and reply_in_callback()
puts the RPC into UNREGISTERING state, which is waiting for RPC &
bulk md unlink, whereas only RPC md unlink has been called so far.
If bulk is lost, even expired_set does not check for UNREGISTERING
state.

The same for write if server returns an error.

This phase is ambiguous, split to UNREG_RPC and UNREG_BULK.

Signed-off-by: Vitaly Fertman <vitaly.fertman@seagate.com>
Change-Id: Ib1eeb1777ad1ab4c7ea1c83fe95dc9ae82c1894c
Seagate-bug-id:  MRP-2953, MRP-3206
Reviewed-by: Andriy Skulysh <andriy.skulysh@seagate.com>
Reviewed-by: Alexey Leonidovich Lyashkov <alexey.lyashkov@seagate.com>
Tested-by: Elena V. Gryaznova <elena.gryaznova@seagate.com>
Reviewed-on: http://review.whamcloud.com/17221
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Chris Horn <hornc@cray.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7323 test: Unknown symbol mb_cache_create (err 0)" on RHEL7 00/16900/7
Parinay Kondekar [Wed, 6 Apr 2016 04:43:45 +0000 (10:13 +0530)]
LU-7323 test: Unknown symbol mb_cache_create (err 0)" on RHEL7

The error message is seen if mbcache module isn't loaded.

Before RHEL7 it was part of ext4, but EL7 have mbcache as
separate module and needs an extra `modprobe mbcache` command
before tests are run from local build dir.

This fixes the function load_modules_local() in test-framework.sh

Seagate-bug-id: MRP-3018
Change-Id: I7f1317355785c191287788bcb177d78b12231c97
Signed-off-by: Alexey Lyashkov <alexey.lyashkov@seagate.com>
Signed-off-by: Parinay Kondekar <parinay.kondekar@seagate.com>
Reviewed-on: http://review.whamcloud.com/16900
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7130 test: sanity/162 doesn't handle DIR values properly 58/16358/4
Kyrylo Shatskyy [Wed, 13 Apr 2016 06:29:32 +0000 (11:59 +0530)]
LU-7130 test: sanity/162 doesn't handle DIR values properly

The test fails when path values have trailing slash,
e.g. DIR=/mnt/lustre/

The patch adds validation which at the moment processes
these parameters-DIR, DIR1, DIR2, MOUNT, MOUNT1, MOUNT2.

Change-Id: Ief85e8798911cb67b4dafce985a9e4ef56cc26a4
Signed-off-by: Kyrylo Shatskyy <kyrylo.shatskyy@seagate.com>
Signed-off-by: Parinay Kondekar <parinay.kondekar@seagate.com>
Seagate-bug-id: MRP-334
Reviewed-on: http://es-gerrit.xyus.xyratex.com:8080/#/c/269
Tested-by: Jenkins
Reviewed-by: Andrew Perepechko <Andrew_Perepechko@xyratex.com>
Reviewed-by: Alexander Lezhoev <Alexander_Lezhoev@xyratex.com>
Tested-by: Alexander Lezhoev <Alexander_Lezhoev@xyratex.com>
Reviewed-by: Vitaly Fertman <Vitaly_Fertman@xyratex.com>
Reviewed-on: http://review.whamcloud.com/16358
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7121 tests: Extra items shown in the stack trace in t-f 38/16338/4
Parinay Kondekar [Wed, 9 Sep 2015 12:09:39 +0000 (17:39 +0530)]
LU-7121 tests: Extra items shown in the stack trace in t-f

The call to functions error_exit(), error_noexit(), error()
in turn call function log_trace_dump().

This call along with important information about where the
particular test failed shows some extra information in the
dump trace.

This changes fix the problem noticed and dumps only the relevant
information instead.

Signed-off-by: Parinay Kondekar <parinay.kondekar@seagate.com>
Change-Id: I5fba23f6e296e77feb0339c5e20815c288b8b751
Seagate-Bug-Id: MRP-891
Reviewed-on: http://es-gerrit.xyus.xyratex.com:8080/721/
Tested-by: Jenkins
Reviewed-by: Elena V. Gryaznova <elena.gryaznova@seagate.com>
Tested-by: Elena V. Gryaznova <elena.gryaznova@seagate.com>
Reviewed-by: Kyrylo Shatskyy <kyrylo_shatskyy@xyratex.com>
Signed-off-by: Kyrylo Shatskyy <kyrylo_shatskyy@xyratex.com>
Reviewed-on: http://review.whamcloud.com/16338
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Wei Liu <wei3.liu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6245 libcfs: replace CFS_MODULE_PARAM with linux kernel module api 83/19383/6
James Simmons [Mon, 11 Apr 2016 20:01:00 +0000 (16:01 -0400)]
LU-6245 libcfs: replace CFS_MODULE_PARAM with linux kernel module api

Remove the CFS_MODULE_PARM wrapper and use the linux macros
module_param and MODULE_PARM_DESC instead.

Change-Id: If551518b34195caf92435189f98b01895a0b0d24
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: http://review.whamcloud.com/19383
Reviewed-by: Frank Zago <fzago@cray.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7435 test: managing OST pools properly 26/17326/5
Elena Gryaznova [Sat, 16 Jan 2016 22:57:01 +0000 (00:57 +0200)]
LU-7435 test: managing OST pools properly

ost-pools tests fail on configuration MGS/MDS not combined,
different nodes, configured as failover pair.

Patch fixes ost-pools to execute commands on mgs instead of
$SINGLEMDS.

Seagate-bug-id: MRP-2733
Signed-off-by: Elena Gryaznova <elena.gryaznova@seagate.com>
Change-Id: I8dfe4cc38a30af59f6cf5f4dcd144588b499c3c3
Reviewed-on: http://review.whamcloud.com/17326
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Wei Liu <wei3.liu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7699 build: Convert lustre_ver.h.in into a static .h file 11/18111/13
Christopher J. Morrone [Sun, 24 Jan 2016 00:44:48 +0000 (16:44 -0800)]
LU-7699 build: Convert lustre_ver.h.in into a static .h file

The AC_LUSTRE_{MAJOR,MINOR,PATCH,FIX} autoconf output values are
no longer necessary.  We can instead use AC_DEFINE to set the
LUSTRE_{MAJOR,MINOR,PATCH,FIX} CPP macros directly.  As a result,
the lustre_ver.h file no longer needs to be generated by autoconf
and it can be made into a static file.

At the same time we set LUSTRE_VERSION_STRING, even though it
is not strictly needed, to avoid additional divergence from
the client code in the upstream Linux kernel staging area.

Change-Id: I6b0364a7af1869beb6acedc63c034565af00ef06
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/18111
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7110 tests: sanity-hsm.sh can erase all files on filesystem 91/16291/7
Parinay Kondekar [Tue, 12 Apr 2016 06:44:03 +0000 (12:14 +0530)]
LU-7110 tests: sanity-hsm.sh can erase all files on filesystem

For SINGLEAGT=client, $HSM_ARCHIVE & $hsm_root is empty.
Thus purging of archive in copytool_setup() will result
in execution of "rm -rf /*", resulting in permanent loss
of files as well as cluster node.

This change fixes it by checking the respective variables
like HSM_ARCHIVE or hsm_root to be non-empty.

Change-Id: I73cdc08a58409ae1f3ba85a9d12077062a38b321
Seagate-Bug-Id: MRP-2659
Signed-off-by: Parinay Kondekar <parinay.kondekar@seagate.com>
Reviewed-on: http://es-gerrit.xyus.xyratex.com:8080/6471
Tested-by:Jenkins
Reviewed-by: Elena V. Gryaznova <elena.gryaznova@seagate.com>
Reviewed-by: Alexander Lezhoev <alexander.lezhoev@seagate.com>
Reviewed-on: http://review.whamcloud.com/16291
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoNew version 2.8.52 2.8.52 v2_8_52 v2_8_52_0
Oleg Drokin [Thu, 21 Apr 2016 01:41:39 +0000 (21:41 -0400)]
New version 2.8.52

Change-Id: I7c5d288c7d2a1290bac5a4c3e179977672813194
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7220 llog: fix fd lost and correct error reporting 07/19407/3
Dmitry Eremin [Fri, 8 Apr 2016 15:09:23 +0000 (18:09 +0300)]
LU-7220 llog: fix fd lost and correct error reporting

A file descriptor acquired to 'fd' may be lost in case of
error in is_fstype_ext() function.

Fix error code of is_fstype_ext() propagation.

Change-Id: I0894cfad83854c503e2cdcfff78d44f6f2746ef3
Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-on: http://review.whamcloud.com/19407
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Jenkins
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7990 rpc: increase bulk size 66/19366/3
Jinshan Xiong [Fri, 9 May 2014 00:13:19 +0000 (17:13 -0700)]
LU-7990 rpc: increase bulk size

To make the ptlrpc be able to size 16MB IO

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Signed-off-by: Gu Zheng <gzheng@ddn.com>
Change-Id: I32727beaed08cb0e9048e7fe0e27489e330fce60
Reviewed-on: http://review.whamcloud.com/19366
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7967 kernel: kernel update RHEL7.2 [3.10.0-327.13.1.el7] 89/19289/4
Bob Glossman [Thu, 31 Mar 2016 15:49:39 +0000 (08:49 -0700)]
LU-7967 kernel: kernel update RHEL7.2 [3.10.0-327.13.1.el7]

Update RHEL7.2 kernel to 3.10.0-327.13.1.el7

Test-Parameters: clientdistro=el7 mdsdistro=el7 ossdistro=el7 \
  mdsfilesystemtype=ldiskfs mdtfilesystemtype=ldiskfs \
  ostfilesystemtype=ldiskfs testgroup=review-ldiskfs

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I341473cfef85a687aa2218f457e757186ac923f0
Reviewed-on: http://review.whamcloud.com/19289
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-4182 tests: enable sanity-scrub test_15 under DNE mode 40/18440/2
Fan Yong [Tue, 1 Dec 2015 15:13:32 +0000 (23:13 +0800)]
LU-4182 tests: enable sanity-scrub test_15 under DNE mode

Drop unnecessary condition check.

Test-Parameters: mdsfilesystemtype=ldiskfs mdtfilesystemtype=ldiskfs ostfilesystemtype=ldiskfs mdtcount=4 mdscount=2 envdefinitions=ONLY=15 testlist=sanity-scrub,sanity-scrub,sanity-scrub
Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: Ic355218b2c449a9979bec22f613e6f6646601870
Reviewed-on: http://review.whamcloud.com/18440
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
3 years agoLU-28 fileset: add fileset mount support 07/5007/39
Lai Siyao [Tue, 3 Mar 2015 12:36:31 +0000 (20:36 +0800)]
LU-28 fileset: add fileset mount support

This patch enables client to mount subdirectory as fileset.

usage: mount -t lustre mgsname:/fsname/subdir /mount/point

* mdt lookup fileset fid and return to client during mount.
* `lfs fid2path` support for fileset.

Test-Parameters: envdefinitions=FILESET=/somedir testlist=sanity
Signed-off-by: Lai Siyao <lai.siyao@intel.com>
Signed-off-by: Kit Westneat <kwestneat@ddn.com>
Signed-off-by: Wang Shilong <wshilong@ddn.com>
Change-Id: I947785de3b053907600d1090c80e8f57396e1e93
Reviewed-on: http://review.whamcloud.com/5007
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Li Xi <lixi@ddn.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-4931 ladvise: Add feature of giving file access advices 29/10029/52
Li Xi [Tue, 22 Mar 2016 00:12:55 +0000 (08:12 +0800)]
LU-4931 ladvise: Add feature of giving file access advices

The fadvise() system call provided by Linux kernel enables
applications to give advices or hints about how a file will be
accessed. However, It is only a client side mechanism which is
not enough for distributed file systems like Lustre, because in
order to tune system-wide cache or read-ahead policies, servers
need to understand the advices too.

This patch adds a new feature named ladvise which provides new
APIs and utils to give advices about the access pattern of Lustre
files with the purpose of performance improvement. It is similar
to Linux fadvise() system call, except it forwards the advices
directly from Lustre client to server. The server side codes will
apply appropriate read-ahead and caching techniques for the
corresponding files.

A typical workload for ladvise is e.g. a bunch of different
clients are doing small random reads of a file, so prefetching
pages into OSS cache with big linear reads before the random IO
is a net benefit. Fetching all that data into each client cache
with fadvise() may not be, due to much more data being sent to
the client.

Signed-off-by: Li Xi <lixi@ddn.com>
Change-Id: I6de14ed87199949963360d393897ff79826c9819
Reviewed-on: http://review.whamcloud.com/10029
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Wang Shilong <wshilong@ddn.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7699 build: Eliminate lustre_build_version.h 08/18108/11
Christopher J. Morrone [Wed, 23 Mar 2016 23:35:50 +0000 (19:35 -0400)]
LU-7699 build: Eliminate lustre_build_version.h

The lustre_build_version.h is no longer necessary.  With the new
versioning system the lustre version can now be retrieved from
standard autotools defines and/or lustre_ver.h.

To make compatibility easier for the upstream lustre client in
the linux kernel, we use LUSTRE_VERSION_STRING from lustre_ver.h.

Change-Id: I08233d8547bc4af7bf2fb0c15bee8e306f6fa0f0
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/18108
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6601 osp: update obd status while osp status changed 02/19402/2
Yang Sheng [Fri, 8 Apr 2016 04:10:43 +0000 (12:10 +0800)]
LU-6601 osp: update obd status while osp status changed

We should update OBD status when osp import status is
changed. Else the status change will not reflect in
'lctl dl'.

Signed-off-by: Yang Sheng <yang.sheng@intel.com>
Change-Id: Ice10802028b569470027db33a5e5e5e2bcc9dfc0
Reviewed-on: http://review.whamcloud.com/19402
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7925 llite: avoid clearing i_nlink for inodes in use 64/19164/4
Andrew Perepechko [Sat, 26 Mar 2016 14:48:25 +0000 (17:48 +0300)]
LU-7925 llite: avoid clearing i_nlink for inodes in use

The patch removes find_cbdata callbacks and clear_nlink
from dentry_iput path, since this piece of code makes
a few races possible.

The test case reproduces one of the possible races
described in LU-7925:

1) two hard links are created for the same file
2) the test calls stat(2) for link #1
3) in the middle of 2) the test opens and closes link #2
4) in the middle of 2) the test drops the ldlm locks and
   forces dentry reclaim via vm.drop_caches=2
5) in the middle of 2) ll_d_iput() clears i_nlink for
   the inode
6) the initial stat(2) continues and copies the wrong
   i_nlink value into st_nlink

Signed-off-by: Andrew Perepechko <andrew.perepechko@seagate.com>
Seagate-bug-id: MRP-3271
Change-Id: I185bed4b875a4fbf66df835cf9161912a6ade415
Reviewed-on: http://review.whamcloud.com/19164
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Wally Wang <wang@cray.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7979 o2iblnd: fix free of IS_ERR pointer 11/19311/2
Dmitry Eremin [Mon, 4 Apr 2016 10:21:18 +0000 (13:21 +0300)]
LU-7979 o2iblnd: fix free of IS_ERR pointer

Explicitly nullify pointers is case of error.

Change-Id: Ic25ef3323b8ef4e8bf1da442b2328e6801b3d252
Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-on: http://review.whamcloud.com/19311
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
3 years agoLU-7965 utils: fix stack corruption in mkfs.lustre 60/19260/3
Gregoire Pichon [Thu, 31 Mar 2016 11:05:20 +0000 (13:05 +0200)]
LU-7965 utils: fix stack corruption in mkfs.lustre

This patch fixes a stack corruption that randomly happens when
formating a Lustre target. A call to append_unique() routine
was done with a wrong maxbuflen value.

Signed-off-by: Gregoire Pichon <gregoire.pichon@bull.net>
Change-Id: I8838b90a1dcda7c27457c0be0246e216856e7d5d
Reviewed-on: http://review.whamcloud.com/19260
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: lokesh.jaliminche <lokesh.jaliminche@seagate.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
3 years agoLU-7962 build: Support builds w/ weak module ZFS 49/19249/4
Christopher J. Morrone [Tue, 4 Aug 2015 01:37:47 +0000 (18:37 -0700)]
LU-7962 build: Support builds w/ weak module ZFS

Now that ZFS supports weak module updates, ZFS does will not
always be built for every specific kernel that is installed.
Unfortunately, some directories that Lustre needs from ZFS and
SPL have a kernel string embedded in them, and now that kernel
string will potentially be different than the kernel that
Lustre is building against.

As a work around we can update the Lustre build scripts to just
select the last subdirectory (after all other methods fail) that
has a kernel name from the ZFS and SPL build directories as a
directory that Lustre should use in its build. Its as reasonable
a guess as I can figure we can easily make.

Change-Id: Id17940b78b99ddb8b589d1f46f85c3282c71a3ad
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/19249
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Reviewed-by: Faccini Bruno <bruno.faccini@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7936 utils: fix resource lost 93/19193/5
Dmitry Eremin [Tue, 29 Mar 2016 14:33:48 +0000 (17:33 +0300)]
LU-7936 utils: fix resource lost

Close file handle before return from function.

Change-Id: I1cea4c1d60672b945cd524367e91fb27df185c87
Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-on: http://review.whamcloud.com/19193
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6401 headers: move seq_range.h to correct directory 63/18863/4
Ben Evans [Thu, 10 Mar 2016 22:09:47 +0000 (16:09 -0600)]
LU-6401 headers: move seq_range.h to correct directory

in change http://review.whamcloud.com/#/c/16339/ seq_range.h
was put in the wrong directory, and was requested to move it
up a level.

Signed-off-by: Ben Evans <bevans@cray.com>
Change-Id: I461273c4d216714eddc7d4d5c7cdb8ac9f8c8678
Reviewed-on: http://review.whamcloud.com/18863
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
3 years agoLU-7772 llog: do not destroy llog twice 62/18362/3
Alex Zhuravlev [Tue, 9 Feb 2016 13:00:04 +0000 (16:00 +0300)]
LU-7772 llog: do not destroy llog twice

if llog_process_thread() finds a llog corrupted, then it cancels
all remaining records which in turn causes destroy of this llog.
but it's still referenced by the catalog's in-code structures
(chd_head list) and llog_cat_close() at umount tries to destroy
this llog again. we can reset LLOG_F_ZAP_WHEN_EMPTY at destroy,
so it never repeats.

Change-Id: I8173d9dd2971fa5cce613e71555ca04e96b5512b
Signed-off-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-on: http://review.whamcloud.com/18362
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: wangdi <di.wang@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7055 osd: move dput() out of osd_ost_fini()'s rwlock 89/19189/2
Emoly Liu [Tue, 29 Mar 2016 07:04:44 +0000 (15:04 +0800)]
LU-7055 osd: move dput() out of osd_ost_fini()'s rwlock

osd_ost_fini() calls into osd_seq_free() under write lock, which
in turn calls into dput() that might sleep and cause "BUG: rwlock
wrong CPU on CPU#x, umount/xxx" sort of messages.
To fix this issue, this patch only keeps list_del_init() under
write lock, and moves sleeping function out of there.

Signed-off-by: Emoly Liu <emoly.liu@intel.com>
Change-Id: Ie1eef345d1735bb88aeb016a2409ea649cd20fe5
Reviewed-on: http://review.whamcloud.com/19189
Tested-by: Jenkins
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
3 years agoLU-6245 libcfs: remove libcfs userland time abstraction 13/19113/3
James Simmons [Tue, 29 Mar 2016 00:30:55 +0000 (20:30 -0400)]
LU-6245 libcfs: remove libcfs userland time abstraction

Instead of creating a time abstraction layer in libcfs
for userland lets just use the userland time APIs
directly.

Change-Id: I5c91b23d4ae6c4f75f7712c28572818f26fe57e2
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: http://review.whamcloud.com/19113
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Frank Zago <fzago@cray.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
3 years agoLU-7759 utils: build mount.lustre with libmount 20/18820/5
Yang Sheng [Tue, 8 Mar 2016 17:21:14 +0000 (01:21 +0800)]
LU-7759 utils: build mount.lustre with libmount

Newer distro, like RHEL7, SLES12 will invoke statfs when
umount. It will block while some OST unavailable. So we
write a entry in utab file to avoid invoke statfs() before
issuing the unmount call.

Signed-off-by: Yang Sheng <yang.sheng@intel.com>
Change-Id: I3930ac3454a568908f0872f4a0d83ab264742f3c
Reviewed-on: http://review.whamcloud.com/18820
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
3 years agoLU-4423 lnet: remove LNET_MUTEX_LOCK macro 85/18985/3
Mike Shuey [Thu, 17 Mar 2016 17:20:18 +0000 (13:20 -0400)]
LU-4423 lnet: remove LNET_MUTEX_LOCK macro

LNET_MUTEX_LOCK and LNET_MUTEX_UNLOCK are verbose wrappers to mutex_lock and
mutex_unlock.  Get rid of these.

Change-Id: Icdb029441d57ce080ce4b1e7990d38d4ff0edf26
Signed-off-by: Mike Shuey <shuey@purdue.edu>
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Reviewed-on: http://review.whamcloud.com/18985
Tested-by: Jenkins
Reviewed-by: Frank Zago <fzago@cray.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7101 lnet: per NI map-on-demand value 67/16367/18
Amir Shehata [Tue, 15 Mar 2016 19:39:54 +0000 (15:39 -0400)]
LU-7101 lnet: per NI map-on-demand value

Enables support of different map-on-demand values per NI.  This is
required to support OPA coexistence with MLX5 cards.  MLX5 does not
support FMR, which is enabled via map-on-demand.  However OPA's
performance is greatly enahanced when FMR is enabled.  In order
to enable coexistence of both of these two types of cards we
need to be able to set different map-on-demand values for both
NIs.

This patch also lays the ground work for other per NI tunables to
be added in future patches.

Signed-off-by: Amir Shehata <amir.shehata@intel.com>
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Change-Id: Ic7617d3d5846e58f83e7c67bb9eb7173700be8d7
Reviewed-on: http://review.whamcloud.com/16367
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Reviewed-by: Olaf Weber <olaf@sgi.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7355 osd: supress useless warning about many credits 85/16985/14
Alex Zhuravlev [Thu, 29 Oct 2015 15:26:43 +0000 (18:26 +0300)]
LU-7355 osd: supress useless warning about many credits

on tiny systems (like we used to debug Lustre) journals are
tiny as max.transaction too. it doesn't help to warn about
this. we've got another precise mechanism to catch credits
misuse so it should be OK to suppress these messages.

Change-Id: I9599ae856bedb0a08a8dac01821e2c9a72377cac
Signed-off-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-on: http://review.whamcloud.com/16985
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7060 ldev: Added MGS NID substitution to ldev 29/16129/11
Giuseppe Di Natale [Fri, 28 Aug 2015 23:17:24 +0000 (16:17 -0700)]
LU-7060 ldev: Added MGS NID substitution to ldev

For automation purposes, it would be nice to have a
command substitution for the MGS NID of a node.
The ldev perl script now has a %m flag to sub in
the MGS NID. The MGS associated with a node is
determined by which file system the node is a part
of. The NID is obtained by using the current
NID file parsing. Also, MGS is now an acceptable
type to have specified in a label.

Signed-off-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Change-Id: Ifcfad7664ac028e2074030e4b3ba5995ddb5358d
Reviewed-on: http://review.whamcloud.com/16129
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7907 kernel: kernel update RHEL 6.7 [2.6.32-573.22.1.el6] 18/19118/2
Bob Glossman [Tue, 22 Mar 2016 22:38:40 +0000 (15:38 -0700)]
LU-7907 kernel: kernel update RHEL 6.7 [2.6.32-573.22.1.el6]

Update RHEL 6.7 kernel to 2.6.32-573.22.1.el6

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I2736a6390607d552ea171bdf53dd071a8575a4fa
Reviewed-on: http://review.whamcloud.com/19118
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-4423 lnet: Drop unnecessary wrapper function srpc_post_active_rqtbuf 57/18957/7
Shivani Bhardwaj [Tue, 29 Mar 2016 00:27:24 +0000 (20:27 -0400)]
LU-4423 lnet: Drop unnecessary wrapper function srpc_post_active_rqtbuf

Remove the function srpc_post_active_rqtbuf() and replace its only call
with the function srpc_post_active_rdma() by adding appropriate parameters.

Change-Id: I0fcbfa6bc07f04ae218abac7d25264af7072b902
Signed-off-by: Shivani Bhardwaj <shivanib134@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: http://review.whamcloud.com/18957
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Tested-by: Jenkins
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Frank Zago <fzago@cray.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-4423 lnet: remove memset(0) after LIBCFS_ALLOC 54/18954/7
Vitaly Osipov [Tue, 29 Mar 2016 00:25:12 +0000 (20:25 -0400)]
LU-4423 lnet: remove memset(0) after LIBCFS_ALLOC

Joe Perches mentioned on driverdev-devel that memset after LIBCFS_ALLOC
is not necessary as it is already done during LIBCFS_ALLOC_POST. This
commit removes these unnecessary memsets. Based on the results of running
a cocci patch along the lines of:

@@
expression E1, E2;
@@

LIBCFS_ALLOC (E1,E2);
...
- memset(E1,0,E2);

Linux-commit : cab80d98f50bbacb7df79bd267d0b2b008b2d84f

Change-Id: I49b48539d7b99e59e3bb56f9ad74efed101d8a4e
Signed-off-by: Vitaly Osipov <vitaly.osipov@gmail.com>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: http://review.whamcloud.com/18954
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Tested-by: Jenkins
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Frank Zago <fzago@cray.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6163 kernel: use do_div64() for 64 bit divides 19/18819/8
Bob Glossman [Wed, 23 Mar 2016 22:35:16 +0000 (18:35 -0400)]
LU-6163 kernel: use do_div64() for 64 bit divides

For 32 bit platforms to perform 64 bit divides or modulo
operations the do_div64() macro has to used to avoid the
__umoddi missing errors. Those errors prevent lustre from
working properly on 32 bit machines. The fix for o2iblnd
is a backport of upstream kernel commit:

Linux-commit: 5f43264c5320624f3b458c5794f37220c4fc2934

Change-Id: Iee44fb707ef11be5e484989f0455951e2c84ceb5
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: http://review.whamcloud.com/18819
Tested-by: Jenkins
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7796 utils: print error with valueless lctl set_param 03/18703/4
Ryan Haasken [Fri, 26 Feb 2016 19:52:39 +0000 (13:52 -0600)]
LU-7796 utils: print error with valueless lctl set_param

If lctl set_param is called with space-separated arguments, and there
is a trailing parameter without a value, print an error instead of
returning silently.  Also, allow values which contain equal signs when
lctl set_param is given space-separated arguments.

Print a warning message for both formats whenever the value contains
an '=' character because it is likely that the user made an error.

Also fix the return values of jt_lcfg_setparam, so they are always
negative on error.

Add tests for "lctl set_param" to verify that it returns an error when
a value is omitted in either format and to check that "lctl set_param"
accepts values which contain the '=' character in either format.

Signed-off-by: Ryan Haasken <haasken@cray.com>
Change-Id: Ie9d709c5aa533f778cc83f4b58f40fe4b084c754
Reviewed-on: http://review.whamcloud.com/18703
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Emoly Liu <emoly.liu@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7408 target: comment as per inspection 78/17578/5
Alex Zhuravlev [Mon, 14 Dec 2015 15:53:10 +0000 (18:53 +0300)]
LU-7408 target: comment as per inspection

add a comment as per the original patch's inspection.

Change-Id: I391e5cefa6384f5c2c1c29efc958c9a873a5e7bc
Signed-off-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-on: http://review.whamcloud.com/17578
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
3 years agoLU-7156 mdd: add changelog_size to procfs 16/16416/11
Alexander Boyko [Mon, 14 Sep 2015 19:32:46 +0000 (22:32 +0300)]
LU-7156 mdd: add changelog_size to procfs

It is hard to get size of changelogs. This patch adds new procfs file
changelog_size. It shows the current size of all changelog files.

Signed-off-by: Alexander Boyko <alexander.boyko@seagate.com>
Seagate-bug-id: MRP-2383
Change-Id: Ia2905bbf965256b18708fb79c9e5e07b4ffd2b10
Reviewed-on: http://review.whamcloud.com/16416
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
3 years agoLU-7928 mdd: wrong params order at mdd_declare_rename 66/19166/2
Alexander Boyko [Mon, 28 Mar 2016 13:11:02 +0000 (16:11 +0300)]
LU-7928 mdd: wrong params order at mdd_declare_rename

Patch changes ltname and lsname order.

Seagate-bug-id: MRP-3385
Signed-off-by: Alexander Boyko <alexander.boyko@seagate.com>
Change-Id: I26695a8fa2adb48864bbe3d0952f32dcbb81f1db
Reviewed-on: http://review.whamcloud.com/19166
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andrew Perepechko <andrew.perepechko@seagate.com>
3 years agoLU-6245 libcfs: fix racey module handling 64/18964/5
James Simmons [Wed, 23 Mar 2016 23:22:40 +0000 (19:22 -0400)]
LU-6245 libcfs: fix racey module handling

While working on the upstream client Greg pointed out the
current why we handle libcfs module loading with psdev is
very racy. This patch removes the possible race.

Change-Id: Ic86aa9b0d426cc53a239ae81fc92db2d5a2b5c60
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: http://review.whamcloud.com/18964
Reviewed-by: Frank Zago <fzago@cray.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7428 test: commit the label change to disk 71/18871/2
Hongchao Zhang [Thu, 10 Dec 2015 13:20:55 +0000 (21:20 +0800)]
LU-7428 test: commit the label change to disk

when mounting some Lustre target (MDT or OST), the device label
will be changed if it is mounted for the first time, and it's
better to commit the change to disk.

Change-Id: I36125356bf19f0aedcb1a6939e7461911c1a749d
Signed-off-by: Hongchao Zhang <hongchao.zhang@intel.com>
Reviewed-on: http://review.whamcloud.com/18871
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6215 lprocfs: handle seq_printf api change 33/16933/17
James Simmons [Wed, 23 Mar 2016 22:37:27 +0000 (18:37 -0400)]
LU-6215 lprocfs: handle seq_printf api change

Starting with the 4.3 linux kernel seq_printf is a void
function not returning the character count. This work
updates lustre to treat seq_printf as a void function.
Fixed alignment issues and ran this patch against the
Linux kernels checkpatch to make it compliant to
upstream standards.

Change-Id: I0cfd71252322038c1b54da624fce48b37a6f30b6
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: http://review.whamcloud.com/16933
Tested-by: Jenkins
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7968 lbuild: Fix reuse signature calculation 62/19262/3
Dmitry Eremin [Thu, 31 Mar 2016 12:37:30 +0000 (15:37 +0300)]
LU-7968 lbuild: Fix reuse signature calculation

Don't use an information about Lustre commits from target file content
that is not directly related to kernel build which should be cached.
In other words make signature independent from git commits hash.

Change-Id: I3dbeb5f3a94cb947221aaa92659f14d4ea65e30a
Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-on: http://review.whamcloud.com/19262
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
Tested-by: Jenkins
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7887 lbuild: use "make rpms" for building Lustre RPMs 37/19037/2
Dmitry Eremin [Mon, 21 Mar 2016 12:44:27 +0000 (15:44 +0300)]
LU-7887 lbuild: use "make rpms" for building Lustre RPMs

The fact that "make rpms" and lbuild give different results is very
concerning. This patch switch to use common "make rpms" for building
Lustre RPMs in lbuild as well.

Change-Id: Idb27a08f18c4cc45eb658781ecff176628ef22db
Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-on: http://review.whamcloud.com/19037
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoNew tag 2.8.51 2.8.51 v2_8_51
Oleg Drokin [Thu, 31 Mar 2016 02:28:59 +0000 (22:28 -0400)]
New tag 2.8.51

Change-Id: If839cc33ce210982f7e1d5c3d04e6a8005d0d535
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7931 tests: Allow per-subtest setup/cleanup 71/19171/1
Oleg Drokin [Mon, 28 Mar 2016 18:54:12 +0000 (14:54 -0400)]
LU-7931 tests: Allow per-subtest setup/cleanup

This brings back ability to have per-subtest setup/cleanup
logic.
Most frequently used in the past as:
SETUP=setup CLEANUP=cleanup sh sanity.sh
to do unmount/remount of the whole stack after every test
to better pinpoint memory/lock leacks and other
accumulated behavior only visible at unmount.

Change-Id: I13bf42ce56a6c1873c034a357ad3bdfbee5c6c1f
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7893 osd-zfs: calls dmu_objset_disown() with NULL 52/19052/2
Olaf Faaland [Mon, 21 Mar 2016 20:32:23 +0000 (13:32 -0700)]
LU-7893 osd-zfs: calls dmu_objset_disown() with NULL

When a ZFS-backed target is mounted, and dmu_objset_own() fails,
osd_mount() follows a goto err: and calls dmu_objset_disown(NULL).
This triggers a kernel panic due to NULL pointer dereference.

Call dmu_objset_disown() only if objset_t o->od_os is non-NULL.

Signed-off-by: Olaf Faaland <faaland1@llnl.gov>
Change-Id: I04ce39fbf97a87978c5819731ee1eba9debe6db2
Reviewed-on: http://review.whamcloud.com/19052
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-5704 utils: stop open hangs on fifo files 39/19039/4
Bob Glossman [Mon, 21 Mar 2016 13:30:14 +0000 (06:30 -0700)]
LU-5704 utils: stop open hangs on fifo files

Use O_NONBLOCK in open calls to prevent hangs on operations
to special files, fifo files in particular.

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I20aa8425efa6ac545c3e2b970bd88e4c57c086da
Reviewed-on: http://review.whamcloud.com/19039
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7227 tests: check dmesg for errors after test 65/16665/2
Sergey Cheremencev [Thu, 25 Jun 2015 09:52:11 +0000 (12:52 +0300)]
LU-7227 tests: check dmesg for errors after test

Add a check to t-f that dmesg doesn't have critical messages
after test execution. The list of error  messages in
"check_dmesg_for_erros" should be updated by developers.

Change-Id: If33ab73865121a56b9a21afd10fa1635f30dcbbe
Xyratex-bug-id: MRP-2713
Signed-off-by: Sergey Cheremencev <sergey.cheremencev@seagate.com>
Reviewed-by: Elena V. Gryaznova <elena.gryaznova@seagate.com>
Tested-by: Elena V. Gryaznova <elena.gryaznova@seagate.com>
Reviewed-by: Alexander Zarochentsev <alexander.zarochentsev@seagate.com>
Reviewed-on: http://review.whamcloud.com/16665
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6862 build: Make dist of contrib's contents consistent 29/15629/5
Christopher J. Morrone [Thu, 16 Jul 2015 23:09:34 +0000 (16:09 -0700)]
LU-6862 build: Make dist of contrib's contents consistent

Authors and reviewers of patches adding things to the contrib
subdirectory have been inconsistent with the inclusion of the
contrib tree's contents in the distribution tarball.

This patch fixes that by removing all of the Makefiles from the
contrib tree, and instead just listing contrib in EXTRA_DIST
at the top level.  That will recursively include the entire
contrib directory in the distribution tarball.  This way
there is little oportunity for inclusion of files under
contrib being inconsistent.

Change-Id: If6b92ed069a3fbeb1d0a8c8c0488180ee69597f3
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/15629
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Brian J. Murrell <brian.murrell@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7883 llog: Flush out journal callback data 05/19005/3
Yang Sheng [Fri, 18 Mar 2016 13:53:12 +0000 (21:53 +0800)]
LU-7883 llog: Flush out journal callback data

As LU-7329, llog_test_10 trigger OOM again. So add
dt_sync on subtest beginning to flush out journal
callback data accumulated by previous subtest.

Test-Parameters: envdefinitions=ONLY=60a testlist=sanity,sanity,sanity,sanity,sanity,sanity

Signed-off-by: Yang Sheng <yang.sheng@intel.com>
Change-Id: I25c3a5d5a6184b4f51f29948af9c3c0dff1abfaa
Reviewed-on: http://review.whamcloud.com/19005
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Faccini Bruno <bruno.faccini@intel.com>
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6527 ldiskfs: Journal commit callback optimization 35/18835/5
Yang Sheng [Wed, 9 Mar 2016 15:01:14 +0000 (23:01 +0800)]
LU-6527 ldiskfs: Journal commit callback optimization

Porting patch for RHEL7, SLES11 & SLES12

This is a porting patch from:
Lustre-change: http://review.whamcloud.com/14611/
Lustre-commit: 55afbf5934e145e48a31193de601abd58e605a42

    Don't take spinlock in tgt_cb_last_committed, if
    exp_last_committed was updated with higher trasno.
    Also change list_add_tail to list_add. It gives
    advantages to ldiskfs in tgt_cb_last_committed.
    In the beginning of list will be placed thandles
    with the highest transaction numbers. So at the
    first iterations we will have the highest transno.
    It will save from extra call of
    ptlrpc_commit_replies.

Signed-off-by: Sergey Cheremencev <sergey.cheremencev@seagate.com>
Xyratex-bug-id: MRP-2575
Reviewed-by: Alexander Zarochentsev <alexander.zarochentsev@seagate.com>
Reviewed-by: Alexander Boyko <alexander.boyko@seagate.com>
Tested-by: Alexander Lezhoev <alexander.lezhoev@seagate.com>
Reviewed-by: Alexey Leonidovich Lyashkov <alexey.lyashkov@seagate.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Yang Sheng <yang.sheng@intel.com>
Change-Id: I3e7f28e5386cf77f3139ff0d330afadf8864c293
Reviewed-on: http://review.whamcloud.com/18835
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
3 years agoLU-7828 statahead: set sai_index_wait with lli_sa_lock held 99/18499/6
Fan Yong [Tue, 23 Feb 2016 20:41:27 +0000 (04:41 +0800)]
LU-7828 statahead: set sai_index_wait with lli_sa_lock held

It is the sponsor thread of the statahead thread to update the
sai::sai_index_wait. Originally, it didn't hold the lli_sa_lock
when did that. Becuase of out-of-order execution others may miss
to wakeup such thread.

On the other hand, if the statahead RPC gets failure, it should
wakeup the sponsor thread, not the statahead thread.

Signed-off-by: Li Xi <lixi@ddn.com>
Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: Icc7937794ff62c2aa6f7d456defffdfc5ba53b61
Reviewed-on: http://review.whamcloud.com/18499
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoRevert "LU-6245 libcfs: remove cfs_fs_time handling" 94/19094/3
Oleg Drokin [Wed, 23 Mar 2016 14:37:37 +0000 (14:37 +0000)]
Revert "LU-6245 libcfs: remove cfs_fs_time handling"

This seems to be causing build failures on EL7:
cc1: all warnings being treated as errors
In file included from libcfs/include/libcfs/linux/libcfs.h:51:0,
                from libcfs/include/libcfs/libcfs.h:45,
                from lnet/include/lnet/lib-lnet.h:48,
                from lnet/lnet/api-ni.c:39:
libcfs/include/libcfs/linux/linux-time.h:111:0: error: "ktime_get_real_ts64" redefined [-Werror]
#define ktime_get_real_ts64 ktime_get_real_ts
^
In file included from include/linux/timer.h:5:0,
                from include/linux/workqueue.h:8,
                from include/linux/pm.h:25,
                from include/linux/device.h:25,
                from include/linux/node.h:17,
                from include/linux/cpu.h:17,
                from libcfs/include/libcfs/linux/linux-cpu.h:50,
                from libcfs/include/libcfs/linux/libcfs.h:50,
                from libcfs/include/libcfs/libcfs.h:45,
                from lnet/include/lnet/lib-lnet.h:48,
                from lnet/lnet/api-ni.c:39:
include/linux/ktime.h:455:0: note: this is the location of the previous definition
#define ktime_get_real_ts64(ts) getnstimeofday64(ts)
^
make[7]: *** [lnet/klnds/o2iblnd/o2iblnd.o] Error 1
make[6]: *** [lnet/klnds/o2iblnd] Error 2
make[5]: *** [lnet/klnds] Error 2
make[5]: *** Waiting for unfinished jobs....
cc1: all warnings being treated as errors
make[6]: *** [lnet/lnet/api-ni.o] Error 1
make[6]: *** Waiting for unfinished jobs....

This reverts commit c3ddfae1b795385aa14db61df1a416ab57bfc066.

Change-Id: I629bd51d27206db7c6b6251ca7089707d33287b8
Reviewed-on: http://review.whamcloud.com/19094
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-4423 lnet: Don't ignore error code for lst_group_info_ioctl 52/18952/2
Cristina Moraru [Wed, 16 Mar 2016 15:43:27 +0000 (11:43 -0400)]
LU-4423 lnet: Don't ignore error code for lst_group_info_ioctl

Error stored in rc was never reported, so directly return it here.

Linux-commit : 2a96be0d46825689ac9b6078056e523ba96acec4

Change-Id: I0535d0a101c1142f035e6dfba240e95fc9040eb2
Signed-off-by: Cristina Moraru <cristina.moraru09@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: http://review.whamcloud.com/18952
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Frank Zago <fzago@cray.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-4423 lnet: Drop unnecessary wrapper function in lnetselftest console.c 51/18951/2
Shraddha Barke [Wed, 16 Mar 2016 15:41:12 +0000 (11:41 -0400)]
LU-4423 lnet: Drop unnecessary wrapper function in lnetselftest console.c

Remove the function lstcon_group_put() and replace all its calls with the
function lstcon_group_decref() because the former function just
performs the job of calling the latter.

Linux-commit : 33db686a22e502ba127138912814e8468ac51ed6

Change-Id: Id12aee41286fd46beb5f96f09dcc50b7e636e93e
Signed-off-by: Shivani Bhardwaj <shivanib134@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: http://review.whamcloud.com/18951
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Frank Zago <fzago@cray.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7812 tests: print more stats for sanity 120e failure 26/18826/3
Andreas Dilger [Wed, 9 Mar 2016 02:48:44 +0000 (21:48 -0500)]
LU-7812 tests: print more stats for sanity 120e failure

Print more info for sanity.sh test_120e failures to help debug
intermittent failures of this test.

Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: Ib4288ce9440a787cb34a9b276858d720d48a6256
Reviewed-on: http://review.whamcloud.com/18826
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7829 osc: glimpse lock should match only with granted locks 38/18738/2
Andriy Skulysh [Tue, 16 Feb 2016 17:24:32 +0000 (19:24 +0200)]
LU-7829 osc: glimpse lock should match only with granted locks

A deadlock is possible during ccc_prep_size()->ldlm_lock_match() vs
cl_io_lock() which is waiting for a matched lock and conflicts with
already taken lock before ccc_prep_size().

It is better to send an aditional lock request to avoid deadlock.

Seagate-bug-id: MRP-3312
Change-Id: I2eed05da4d587500cfc14350d9cc1b33547df4fe
Signed-off-by: Andriy Skulysh <andriy.skulysh@seagate.com>
Reviewed-on: http://review.whamcloud.com/18738
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Bobi Jam <bobijam@hotmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7707 quota: put qqi reference after all things done 42/18142/2
Niu Yawei [Tue, 26 Jan 2016 02:52:43 +0000 (21:52 -0500)]
LU-7707 quota: put qqi reference after all things done

In qsd_reint_main(), we should put qqi reference when all things
done, otherwise, the qqi could be used after free in some race
condition.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I363efd8be22a6ea5b9589c6b152bf924e1f1abae
Reviewed-on: http://review.whamcloud.com/18142
Tested-by: Jenkins
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@hotmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6401 headers: Create a header for obdo related functions 17/16917/8
Ben Evans [Thu, 22 Oct 2015 17:01:30 +0000 (12:01 -0500)]
LU-6401 headers:  Create a header for obdo related functions

Remove all obdo related functions from lustre_idl.h
Create lustre_odbo.h
Include where appropriate, reorganize #include blocks

Signed-off-by: Ben Evans <bevans@cray.com>
Change-Id: I35646ba27a0903bbb64281ad49fd650b10f71d7b
Reviewed-on: http://review.whamcloud.com/16917
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6966 test: Dash in FSNAME causes warning in testframework 25/15925/5
Lokesh Nagappa Jaliminche [Thu, 6 Aug 2015 10:48:44 +0000 (16:18 +0530)]
LU-6966 test: Dash in FSNAME causes warning in testframework

The FSNAME with dash was causing warning in test-framework.sh. These
are specifically due to use of FSNAME with dash in l-value of the
export statement. So export statement has been modified such that it
will not to include dash in its l-value.

Seagate-bug-id: MRP-2171
Signed-off-by: Lokesh Nagappa Jaliminche <lokesh.jaliminche@seagate.com>
Signed-off-by: Bhagyesh Dudhediya <bhagyesh.dudhediya@seagate.com>
Change-Id: Ia4d690c6529b287bb008f11a57e8131a2facfba4
Reviewed-on: http://review.whamcloud.com/15925
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6215 llite: make_request_fn returns blk_qc_t in kernel 4.4 30/18730/3
Li Dongyang [Tue, 1 Mar 2016 05:53:49 +0000 (16:53 +1100)]
LU-6215 llite: make_request_fn returns blk_qc_t in kernel 4.4

For the 4.4 kernel request_queue.make_request_fn is defined as
a function returns blk_qc_t. loop_make_request() should return
BLK_QC_T_NONE in this case.

Linux-commit: dece16353ef47d8d33f5302bc158072a9d65e26f

Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au>
Change-Id: I20a796caf6d8e6411f084db2392683c12307a0bf
Reviewed-on: http://review.whamcloud.com/18730
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6215 llite: handle locks API change in 4.4+ kernels 29/18729/3
Li Dongyang [Tue, 1 Mar 2016 05:36:49 +0000 (16:36 +1100)]
LU-6215 llite: handle locks API change in 4.4+ kernels

Since 4.4 linux kernel replaced both posix_lock_file_wait() and
flock_lock_file_wait() by introducing locks_lock_file_wait().
This patch handles the API change.

Linux-commit: 4f6563677ae833baad8003e14353241bc25da4fc

Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au>
Change-Id: I1b9c98c2afcad9da3fb377c3e788b12f20261e9e
Reviewed-on: http://review.whamcloud.com/18729
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6215 gss: cache_head is now on a hlist in 4.3+ kernels 28/18728/3
Li Dongyang [Tue, 1 Mar 2016 05:10:48 +0000 (16:10 +1100)]
LU-6215 gss: cache_head is now on a hlist in 4.3+ kernels

Since kernel 4.3 struct cache_head switched from a single
list to a hlist. This patch handles the change.

Linux-commit: 129e5824cd96d9289679973f0ff7c48e88d569bb

Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au>
Change-Id: Iec4c7d0acf106a8f7b60d72eb2038b6d9e12f422
Reviewed-on: http://review.whamcloud.com/18728
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7084 mem: code cleanup for memory allocation 73/17673/10
Yang Sheng [Fri, 18 Dec 2015 18:22:07 +0000 (02:22 +0800)]
LU-7084 mem: code cleanup for memory allocation

This patch just want fix some memory allocation issues.

Signed-off-by: Yang Sheng <yang.sheng@intel.com>
Change-Id: I53d622d5c4e71ce42488a6cfce17a10063cf4f4d
Reviewed-on: http://review.whamcloud.com/17673
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6245 libcfs: remove cfs_fs_time handling 76/17376/2
James Simmons [Fri, 27 Nov 2015 17:29:03 +0000 (12:29 -0500)]
LU-6245 libcfs: remove cfs_fs_time handling

Only the mdd layer uses cfs_fs_time handling and since
it is kernel side code we can easily convert it to the
standard linux kernel time keeping api.

Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Change-Id: I212e0098a847e01e2ddc201a78a790097ba8b0f9
Reviewed-on: http://review.whamcloud.com/17376
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Frank Zago <fzago@cray.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-4423 libcfs: remove some unused code and wrappers in libcfs 75/17375/7
Shraddha Barke [Wed, 16 Mar 2016 16:40:20 +0000 (12:40 -0400)]
LU-4423 libcfs: remove some unused code and wrappers in libcfs

Remove code that is not used by anyone anymore in the
libcfs module. Also simplify the code by removing
several one line wrappers. This is a collection of work
done upstream by Shraddha Barke. The linux commits are:

Linux-commit : 8eefa1c028f5b16f33ce1b3c7bbabdf74efc63b1
Linux-commit : d11f8cc4bb7ff4ee8cc89d2799cdda206da0f434
Linux-commit : 7fb6f46b14d01a185dfe563a8ba20cda514d4f9a
Linux-commit : 7cbf673d8b4a68916fe362fe9a9c3a55a604700e
Linux-commit : e4ce7f7779313ff23f958049b91cc7ac1b24d8e8
Linux-commit : 5a2f464af23bc90a77df6b9b30815e602efb99af
Linux-commit : 87af1d2e0c29ce4f025da0cdbb9c74a3958fd71d
Linux-commit : 9561c25c590afdcb27002dc168bcecbf5a757308
Linux-commit : 7d6e398ca61427e903246f1c11853f6f967bbb5e
Linux-commit : 90f8b4643023b23061a15229c0c0b8ee747438a8
Linux-commit : a2aadf23d1437ddcce86fa0673a6ecb5f932d3ec

Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Change-Id: I667f98b3c73d4ac9e884d6ada6fed0733a3f6451
Reviewed-on: http://review.whamcloud.com/17375
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7699 build: Replace version_tag.pl with LUSTRE-VERSION-GEN 07/18107/17
Christopher J. Morrone [Fri, 22 Jan 2016 02:36:01 +0000 (21:36 -0500)]
LU-7699 build: Replace version_tag.pl with LUSTRE-VERSION-GEN

This patch overhauls how version numbers are handled.

The biggest change is removing the two independent
places where versions were being generated (LB_BUILDID and
lustre_tag*.pl) with a single script named LUSTRE-VERSION-GEN
at the top level of the tree.  LUSTRE-VERSION-GEN is based
on the GIT-VERSION-GEN script that git's own source code build
system uses.

LUSTRE-VERSION-GEN generates the lustre version string from
either git, or if git is not available from the LUSTRE-VERSION-FILE
file, or if _that_ is not available, its own internal DEFAULT_VERSION
default version number.  This allows building the lustre code under
all reasonable conditions.

The new method uses LUSTRE-VERSION-GEN to supply the correct
full lustre version (which may contain git --describe information)
to AC_INIT.  This means that the autotools actually know the
correct version number.  Some benefits of this are:

* We can use standard {AC_}PACKAGE_VERSION macros and variables
  instead of inventing our own
* ./configure --version and other commands will list the correct
  version of Lustre
* The lustre tarball created by "make dist" will contain the full
  version number

The lustre/autoconf/lustre-version.ac file was replaced with
a new config/lustre-version.m4 file.  We no longer need to work
with m4-only macros prefore AC_INIT is called, so the new
file defines a LUSTRE_VERSION_VARIABLES function for us to call
from configure.ac.  The new lustre-version.m4 derives the
derive LUSTRE_{MAJOR,MINOR,PATCH,FIX} from AC_PACKAGE_VERSION
rather than being yet another source of version numbers.

The LUSTRE_VER_ALLOWED_OFFSET and LUSTRE_CLI_VER_OFFSET_WARN
m4 macros were dropped, and the OBD_OCD_VERSION strings stored
directly in lustre_ver.h.in instead.

LB_CHECK_VERSION was removed (no longer necessary).

AC_LUSTRE_VERSION_STRING was drop.  It is no longer necessary
now that we can set LUSTRE_VERSION_STRING directly to
@PACKAGE_VERSION@ in lustre_ver.h.in.

The DOWNSTREAM_RELEASE configure argument is deprecated and all
related code removed.

The lustre/doc/VERSIONING documenation is relocated to
Documentation/versioning.txt and updated to reflect the new versioning
method and practices.

The META file and BUILDID variables and related code are removed
since they are no longer used under the new versioning method.

Note that this patch makes lustre only look at the dotted version
tags in git, so we can finally stop using three to five tags for
every release.  Now we can just use one clear tag.  The tags
with underscores are obsolete.

Change-Id: I7196f92ed4975776cc8e73fd3ebf436b5921f83e
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/18107
Tested-by: Jenkins
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6304 ldlm: crash on umount in cleanup_resource 08/13908/10
Andriy Skulysh [Fri, 27 Feb 2015 12:15:15 +0000 (14:15 +0200)]
LU-6304 ldlm: crash on umount in cleanup_resource

cfs_hash_for_each_relax() assumes that cfs_hash_put_locked()
doesn't release bd lock, but it isn't true for
ldlm_res_hop_put_locked().

Add recfcount on next hnode in cfs_hash_for_each_relax() and
remove ldlm_res_hop_put_locked()

Change-Id: I275c0d29737119d084205e604c336a42e489bfe7
Xyratex-bug-id: MRP-2352
Signed-off-by: Andriy Skulysh <andriy.skulysh@seagate.com>
Reviewed-by: Vitaly Fertman <vitaly.fertman@seagate.com>
Reviewed-by: Alexander Boyko <alexander.boyko@seagate.com>
Tested-by: Alexander Lezhoev <alexander.lezhoev@seagate.com>
Reviewed-on: http://review.whamcloud.com/13908
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7841 doc: stop using python-docutils 92/18792/4
Bob Glossman [Fri, 4 Mar 2016 17:45:22 +0000 (09:45 -0800)]
LU-7841 doc: stop using python-docutils

Since python-docutils is a problem in some Linux distibutions
don't use it.  Convert the few manpage sources kept in .rst
format to the more traditional nroff style so no conversion
is needed at build time.

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: If64b4b504ee5bcacb688a721f479f181c53d99e0
Reviewed-on: http://review.whamcloud.com/18792
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7518 build: Remove the Phi accelerator-specific packaging 88/17488/5
Christopher J. Morrone [Sat, 5 Dec 2015 00:28:18 +0000 (19:28 -0500)]
LU-7518 build: Remove the Phi accelerator-specific packaging

Intel needed to build Lustre for its non-self-hosted accelerator version
of the Phi processor. It turns out that the OS for that is packaged in some
weird non-standard way. Intel added support into Lustre to rpm package it.
While those additions use words like "cross_build", making it sound like it
might be generic, it really isn't.

All of that is really messy and non-standard, and it is making far too
difficult to package Lustre for normal rpm-based distributions.

Hopefully this won't be too much of a problem for Intel, because Phi
processors are now self-hosting.

This is in large part a revert of commit
  426194de03ad47497e99d281d86b5cdfc5142148:
"LU-2784 build: Provide RPMs build for Xeon Phi(TM) card"

Change-Id: Ie5d655f1da3e17eae6edebb5f4d6fd6e7d58811f
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/17488
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoRevert "LU-4640 mdt: implement Remove Archive on Last Unlink policy" 25/18925/2
Oleg Drokin [Tue, 15 Mar 2016 17:52:06 +0000 (17:52 +0000)]
Revert "LU-4640 mdt: implement Remove Archive on Last Unlink policy"

This causes massive testing failures tracked in LU-7881

This reverts commit 74d92933108dc64b110a843352cf3336dca249d0.

Change-Id: Ie7f6d3b217b82bc0be02b8e418acf83f6b83b5cb
Reviewed-on: http://review.whamcloud.com/18925
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Tested-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7850 gnilnd: Fix niov calculation with offset kiov 93/18793/2
Chuck Fossen [Thu, 3 Mar 2016 20:14:26 +0000 (20:14 +0000)]
LU-7850 gnilnd: Fix niov calculation with offset kiov

The niov calculation in kgnilnd_setup_immediate_buffer() did not take
into account an offset kiov which can cause it to map one less page
than needed.
Add in the kiov_offset to the calculation.
Ran patched lnet_selftest that allows specifying an offset and
observed correct behavior.

Signed-off-by: Chris Horn <hornc@cray.com>
Change-Id: Id3d500d178841aa803c35bcbb7b56fd13b3fc1b0
Reviewed-on: http://review.whamcloud.com/18793
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7818 kernel: kernel update [SLES12 SP1 3.12.53-60.30] 08/18708/2
Bob Glossman [Thu, 25 Feb 2016 21:44:57 +0000 (13:44 -0800)]
LU-7818 kernel: kernel update [SLES12 SP1 3.12.53-60.30]

Update target and kernel_config files for new version

Test-Parameters: clientdistro=sles12 testgroup=review-ldiskfs \
  mdsdistro=sles12 ossdistro=sles12 mdsfilesystemtype=ldiskfs \
  mdtfilesystemtype=ldiskfs ostfilesystemtype=ldiskfs

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I88acf88a3c9418afa2c86b2dc9bdfb2d65192e20
Reviewed-on: http://review.whamcloud.com/18708
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7799 hsm: use correct record start index for actions 25/18525/2
John L. Hammond [Fri, 19 Feb 2016 19:09:55 +0000 (13:09 -0600)]
LU-7799 hsm: use correct record start index for actions

In mdt_hsm_actions_proc_show() pass index of the last printed record
to the startidx of llog_cat_process(). This avoids an issue where the
next record to be printed would have been skipped.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: Ic8516d6a9429a21bf1f8d435d60bc9e8801982a5
Reviewed-on: http://review.whamcloud.com/18525
Tested-by: Jenkins
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Henri Doreau <henri.doreau@cea.fr>
Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7782 osp: save env for update callback 93/18493/4
Di Wang [Wed, 17 Feb 2016 03:03:22 +0000 (22:03 -0500)]
LU-7782 osp: save env for update callback

Because the ptlrpc_queue_wait might reset
the env to NULL, let's save the current
environment for update callback of
synchronous request.

Signed-off-by: Di Wang <di.wang@intel.com>
Change-Id: I16f0be1d1e44b5dec3253c4a0dc55af398f49de5
Reviewed-on: http://review.whamcloud.com/18493
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7768 fld: Do not retry fld request 82/18382/2
Di Wang [Mon, 8 Feb 2016 00:04:25 +0000 (19:04 -0500)]
LU-7768 fld: Do not retry fld request

Do not retry fld request if the remote target does
not support FLD_READ request.

Signed-off-by: Di Wang <di.wang@intel.com>
Change-Id: I02c6185cceb4aed6a9cd6b4853eb7423296bb1d2
Reviewed-on: http://review.whamcloud.com/18382
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7756 oss: allow larger number of OSS service threads 50/18350/2
Gregoire Pichon [Mon, 8 Feb 2016 16:07:24 +0000 (17:07 +0100)]
LU-7756 oss: allow larger number of OSS service threads

The current static limit on the maximum number of OSS service threads
is sometimes not large enough to have enough requests sent to the
OST devices.

This patch makes this limit tunable with a new module parameter
oss_max_threads, so that it can be adapted to the underlying
storage hardware.

Signed-off-by: Gregoire Pichon <gregoire.pichon@bull.net>
Change-Id: I182d1dc0a35b42b85b9c0e2a5413e3a852a4e5c3
Reviewed-on: http://review.whamcloud.com/18350
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7124 o2iblnd: limit cap.max_send_wr for MLX5 47/18347/9
Dmitry Eremin [Mon, 8 Feb 2016 12:54:06 +0000 (15:54 +0300)]
LU-7124 o2iblnd: limit cap.max_send_wr for MLX5

Decrease cap.max_send_wr until it is accepted by rdma_create_qp()

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: Ib76f07d997ea579f86fca467329ad357ed26b36f
Reviewed-on: http://review.whamcloud.com/18347
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Olaf Weber <olaf@sgi.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7003 utils: must quote the value of the context option 94/18294/5
Frederic Saunier [Tue, 2 Feb 2016 08:46:43 +0000 (09:46 +0100)]
LU-7003 utils: must quote the value of the context option

As per mount(8) notes, the context value might contain commas,
in which case the  value has to be properly quoted, otherwise
mount(8) will interpret the comma as a separator between mount
options.

Signed-off-by: Frederic Saunier <frederic.saunier@atos.net>
Change-Id: I75e958da26273fe2a15ccae01a1176c3549821b8
Reviewed-on: http://review.whamcloud.com/18294
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Sebastien Buisson <sbuisson@ddn.com>
Reviewed-by: Henri Doreau <henri.doreau@cea.fr>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7002 utils: SELinux context repeated in mount opts 19/18319/4
Frederic Saunier [Fri, 5 Feb 2016 10:11:36 +0000 (11:11 +0100)]
LU-7002 utils: SELinux context repeated in mount opts

SELinux context can only be specified once in mount options,
thus append_context_for_mount() should not apply once again
when called at mount time.

Signed-off-by: Frederic Saunier <frederic.saunier@atos.net>
Change-Id: I350b67ec42691b875aab085224185f2a7582d41d
Reviewed-on: http://review.whamcloud.com/18319
Tested-by: Jenkins
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Grégoire Pichon <gregoire.pichon@bull.net>
Reviewed-by: Sebastien Buisson <sbuisson@ddn.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7736 scripts: ensure lustre_rmmod unload all modules 79/18279/2
Gregoire Pichon [Wed, 3 Feb 2016 15:07:38 +0000 (16:07 +0100)]
LU-7736 scripts: ensure lustre_rmmod unload all modules

The luste_rmmod script unloads the lustre modules recursively from
libcfs, unloading each dependent module first.

If the module dependency order makes an LND module to be unloaded
before the ptlrpc module, the LND unload fails and it results in
lnet and libcfs modules still loaded at the end.

# modprobe lustre
# lctl list_nids
10.1.0.64@o2ib
# lustre_rmmod
Modules still loaded:
lnet/lnet/lnet.o libcfs/libcfs/libcfs.o

This patch ensures modules are all unloaded by the lustre_rmmod
script.

Signed-off-by: Gregoire Pichon <gregoire.pichon@bull.net>
Change-Id: Id94308332a4f5f95f4617f0d5882a9e2857ee20d
Reviewed-on: http://review.whamcloud.com/18279
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Frederic Saunier <frederic.saunier@atos.net>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7727 mdt: fail FMODE_WRITE open if the client is read only 42/18242/2
Li Dongyang [Mon, 1 Feb 2016 04:31:03 +0000 (15:31 +1100)]
LU-7727 mdt: fail FMODE_WRITE open if the client is read only

O_WRONLY/O_RDWR open on a file will get EROFS on a read only client,
but the rpc gets sent to the mdt anyway.
mdt will increase the mot_write_count of the mdt object, blocking
subsequent FMODE_EXEC open to the same file.

This patch makes sure we fail the FMODE_WRITE open with EROFS on mdt
if the open request is from a read only client.
We also do a similar check on the client so we can fail with EROFS
straight away without sending the rpc to mdt.

Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au>
Change-Id: I8b08e9d100a1ab8edf2fa47d4e2ebc5170f36df5
Reviewed-on: http://review.whamcloud.com/18242
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Ian Costello <icostello@ddn.com>
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7689 obdclass: limit lu_site hash table size on clients 48/18048/4
Li Dongyang [Wed, 20 Jan 2016 01:17:28 +0000 (12:17 +1100)]
LU-7689 obdclass: limit lu_site hash table size on clients

Allocating a big hash table using the formula for osd
does not really work for clients. We will create new
hash table for each mount on a single client which is
a lot of memory more than expected.

This patch limits the hash table up to 8M on clients,
which has 524288 entries.

Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au>
Change-Id: I908fda102ec5fd46c1325e0e41f5fe291aaa3378
Reviewed-on: http://review.whamcloud.com/18048
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7608 kernel: kernel upgrade [SLES12 SP1 3.12.51-60.25] 57/17857/10
Bob Glossman [Tue, 16 Jun 2015 20:35:42 +0000 (13:35 -0700)]
LU-7608 kernel: kernel upgrade [SLES12 SP1 3.12.51-60.25]

change supported version from base SLES12 to SLES12 SP1
Update target file for new version
Add kernel config for server build
Revise one of the ldiskfs patches for sles12,
as the rhel7 version it was sharing no longer applies.
Revise lbuild for sles12 server builds.

Test-Parameters: clientdistro=sles12 testgroup=review-ldiskfs \
  mdsdistro=sles12 ossdistro=sles12 mdsfilesystemtype=ldiskfs \
  mdtfilesystemtype=ldiskfs ostfilesystemtype=ldiskfs

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I72a6964615356a2dfa0a9b4dae49a9457ed617b0
Reviewed-on: http://review.whamcloud.com/17857
Tested-by: Jenkins
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7781 kernel: kernel update RHEL7.2 [3.10.0-327.10.1.el7] 78/18478/4
Bob Glossman [Tue, 5 Jan 2016 16:54:33 +0000 (08:54 -0800)]
LU-7781 kernel: kernel update RHEL7.2 [3.10.0-327.10.1.el7]

Update RHEL7.2 kernel to 3.10.0-327.10.1.el7

Test-Parameters: clientdistro=el7 mdsdistro=el7 ossdistro=el7 \
  mdsfilesystemtype=ldiskfs mdtfilesystemtype=ldiskfs \
  ostfilesystemtype=ldiskfs testgroup=review-ldiskfs

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: Ic4b375e61cb069697c289c665484090787a93fe3
Reviewed-on: http://review.whamcloud.com/18478
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7024 tests: Skip squash_id if server version is older than 2.5.53 99/17799/4
Wei Liu [Mon, 4 Jan 2016 21:37:36 +0000 (13:37 -0800)]
LU-7024 tests: Skip squash_id if server version is older than 2.5.53

Add server version check in squash_id to skip if older than 2.5.53

Change-Id: I5e725a03873b4c776a9d90e003071ef777343901
Signed-off-by: Wei Liu <wei3.liu@intel.com>
Reviewed-on: http://review.whamcloud.com/17799
Tested-by: Jenkins
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7524 fld: fld_clientlookup retries next target 83/17683/4
Noopur Maheshwari [Thu, 28 Jan 2016 17:28:49 +0000 (22:58 +0530)]
LU-7524 fld: fld_clientlookup retries next target

fld_client_lookup() retries for another target, if the remote
target is deactive. This was introduced in
http://review.whamcloud.com/#/c/14313/ For getting the
next export target from the list, we use:
target = list_entry(target->ft_chain.next, struct
lu_fld_target,ft_chain);

Now for tests that deactivate the last target,
&(target->ft_chain) is the last entry in the list, and the
next of the last entry(target->ft_chain.next) is the list_head.
Using the macro list_entry maps the list_head pointer back into
a pointer to the structure that contains the list_head. Thus,
it turns the head of the list into its containing
structure(lu_fld_target).
Hence, since the head of the list does not have any data
associated with it, the containing structure(i.e.target)
formed from the head of the list also does not have any data.
Therefore, an export target with no obd device data is generated.
This corrupted export target(generated from the head of the
list) causes the assertion.

The fix is: While fld_client_lookup retries for another target,
if the next entry in the export target list is the head of the
list(&fld->lcf_targets), move to the next entry after the
head(target->ft_chain.next->next) and retrieve the target.
Else retrieve the next target entry(target->ft_chain.next).

Seagate-bug-id: MRP-3200
Signed-off-by: Noopur Maheshwari <noopur.maheshwari@seagate.com>
Change-Id: Ia353437a315de0f1bb44d8822e836ac969b0567f
Reviewed-on: http://review.whamcloud.com/17683
Tested-by: Jenkins
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-4423 libcfs: Merge linux-proc.c into module.c 01/17201/6
Matthew Tyler [Tue, 5 Jan 2016 01:15:21 +0000 (20:15 -0500)]
LU-4423 libcfs: Merge linux-proc.c into module.c

module.c was previously the sole exporter of symbols from linux-proc.c
This patch removes the global symbols by merging the two files

Linux-commit: 87643abf92484074937594897145bb53efc0e77e

Signed-off-by: Matthew Tyler <matt.tyler@flashics.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Change-Id: I557efbfd37b5a23d2fdd8cd5a2aa399a7a494bc6
Reviewed-on: http://review.whamcloud.com/17201
Tested-by: Jenkins
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Frank Zago <fzago@cray.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-3782 test: Fix for faliure when no file are created. 39/16939/9
Kirtankumar Krishna Shetty [Mon, 26 Oct 2015 12:01:27 +0000 (17:31 +0530)]
LU-3782 test: Fix for faliure when no file are created.

The test_18 of ost-pools.sh failed when the createmany
function returns zero and test showed a divide by zero
error. Fixed the issue by adding a check for the return
value and also fixed incorrect average calculation.

Seagate-bug-id: MRP-1117
Signed-off-by: Kirtankumar Krishna Shetty <kirtan.shetty@seagate.com>
Change-Id: I13ea0c1aeb974b5e74dfc7d92fe4e3b744a1fba6
Reviewed-on: http://review.whamcloud.com/16939
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Emoly Liu <emoly.liu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-4640 mdt: implement Remove Archive on Last Unlink policy 84/14384/31
Bruno Faccini [Thu, 9 Apr 2015 08:31:54 +0000 (10:31 +0200)]
LU-4640 mdt: implement Remove Archive on Last Unlink policy

This patch introduces RAoLU policy where an implicit remove
request will be sent to archive/Agent upon last close of an
unlinked file.
Policy can be enabled/disabled using an lprocfs tunable.
If CDT not running, requests will be queued.

test_26[a-c] related tests have been also added in sanity-hsm.

This patch also contains a small fix to prevent unnecessary
progress infos to be gathered for REMOVE requests.

Patch now also handles cases where unlinked file is closed
from mdt_export_cleanup() after Client eviction. And
specific test_26d has been added in sanity-hsm.

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: I7affb20b2834bcd0618412349fc3adc7f6744de0
Reviewed-on: http://review.whamcloud.com/14384
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Aurelien Degremont <aurelien.degremont@cea.fr>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-6391 llite: Add client mount opt to ignore suppress_pings 27/14127/5
Wally Wang [Tue, 8 Sep 2015 16:56:48 +0000 (09:56 -0700)]
LU-6391 llite: Add client mount opt to ignore suppress_pings

When Lustre servers enable 'suppress_pings', all clients will stop
pinging. However, some clients may not have external mechanism
to notify Lustre servers for node death and therefore need to
preserve the Lustre ping.

This patch provides a mount option 'always_ping' so that the
client will not stop pinging even if the server has enabled
'suppress_pings'.

Signed-off-by: Wally Wang <wang@cray.com>
Change-Id: Ia7b45e8d2dbb53f02157ef2ab1d327d9483c2455
Reviewed-on: http://review.whamcloud.com/14127
Tested-by: Jenkins
Reviewed-by: Li Wei <wei.g.li@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Chris Horn <hornc@cray.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-5505 clio: revise read ahead algorithm 28/11528/7
Jinshan Xiong [Tue, 13 Jan 2015 18:59:42 +0000 (10:59 -0800)]
LU-5505 clio: revise read ahead algorithm

ras_window_len should only be updated in ras_update() by read
pattern and it can't be adjusted in ll_readahead() at all;
ras_consecutive_pages is used to detect read pattern from
mmap. It will be used to increase read ahead window length
gradually.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: I78b41646ccd8d9d1c810196a8cbcf58adbcb9319
Reviewed-on: http://review.whamcloud.com/11528
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Bobi Jam <bobijam@hotmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7786 tests: improve racer cleanup 75/18475/2
Lokesh Nagappa Jaliminche [Wed, 17 Feb 2016 07:36:30 +0000 (13:06 +0530)]
LU-7786 tests: improve racer cleanup

On cleanup racer terminates child scripts: file_create.sh,
dir_create.sh, etc. Children of those srcipts do not get terminated
that way. Long running commands, like dd, causes annoying warnings:
     /mnt/lustre2 is still busy, wait one second
on attempt to umount $DIR2.

Add trap to all child scripts to have then to cleanup on exiting.

Seagate-bug-id: MRP-2106
Change-Id: Ie9453449ceea3657881ebc0ce1edeb9e259c848e
Signed-off-by: Lokesh Nagappa Jaliminche <lokesh.jaliminche@seagate.com>
Reviewed-on: http://review.whamcloud.com/18475
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
3 years agoLU-7718 utils: lfs getstripe does not work on bind mount 95/18195/3
vinayakswami hariharmath [Thu, 28 Jan 2016 08:08:04 +0000 (13:38 +0530)]
LU-7718 utils: lfs getstripe does not work on bind mount

As /etc/mtab does not list original mount type and fsname
of bind mount point, using /prc/mounts to list out the
properties of the original mount point of bind mount.

Signed-off-by: vinayakswami hariharmath <vinayakswami.hariharmath@seagate.com>
Change-Id: Icf3644303552d56ad4e336decc5fadca581ff358
Reviewed-on: http://review.whamcloud.com/18195
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>