Whamcloud - gitweb
fs/lustre-release.git
9 years agoLU-5474 tests: sanity-hsm test_90 use local HSM_ARCHIVE 63/12963/3
James Nunez [Fri, 5 Dec 2014 20:28:01 +0000 (12:28 -0800)]
LU-5474 tests: sanity-hsm test_90 use local HSM_ARCHIVE

sanity-hsm test 90 suffers from frequent failures due to
slow archive speeds. If the existing archive is not
local, test 90 now uses a local disk archive to speed
the archive process.

sanity-hsm test 40 was modified to query the SINGLEAGT
node to check if the archive is a local disk for
HSM_ARCHIVE.

copytool_cleanup was modified to match copytool_setup;
remove the contents of $hsm_root and not $hsm_root itself.

This patch is back-ported from the following one:
Lustre-commit: 8641822bdb248a034bf4065c7e2e60cdb7a47041
Lustre-change: http://review.whamcloud.com/12069

Signed-off-by: James Nunez <james.a.nunez@intel.com>
Change-Id: I3aeaedf21d4b6a1316a9510f8e6f3d19662ccdec
Reviewed-on: http://review.whamcloud.com/12963
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Faccini Bruno <bruno.faccini@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5622 tests: check/wait for copytool death 67/12967/2
Bruno Faccini [Fri, 5 Dec 2014 20:23:51 +0000 (12:23 -0800)]
LU-5622 tests: check/wait for copytool death

Seems that copytool death/kill may take more time so
this condition must be handled in sanity-hsm copytool_cleanup()
function to avoid situations where copytool will then not be
restarted, but only signaled, in next copytool_setup().

This patch is back-ported from the following one:
Lustre-commit: 6facf3953b170832200ca9c111398da8feecd281
Lustre-change: http://review.whamcloud.com/11922

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: Ia817936eb030386dbe539ec8d5297812f4b6fff2
Reviewed-on: http://review.whamcloud.com/12967
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Henri Doreau <henri.doreau@cea.fr>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4864 tests: cleanup shared files in sanity-hsm 62/12962/2
Minh Diep [Fri, 5 Dec 2014 20:03:25 +0000 (12:03 -0800)]
LU-4864 tests: cleanup shared files in sanity-hsm

Test creates shared files need to remove them completely

This patch is back-ported from the following one:
Lustre-commit: 9c096264c14c70e88e38ee1de9b05b494491fd28
Lustre-change: http://review.whamcloud.com/10073

Signed-off-by: Minh Diep <minh.diep@intel.com>
Change-Id: I94e5de73f867f87a6e63b2ea213637a5d0cad488
Reviewed-on: http://review.whamcloud.com/12962
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-6091 llite: glimpse the inode before doing fiemap 39/13439/2
Li Dongyang [Thu, 8 Jan 2015 00:02:24 +0000 (11:02 +1100)]
LU-6091 llite: glimpse the inode before doing fiemap

For a new inode, the i_size is 0 until a stat, which will yield
an empty fiemap result.
Fix the issue by glimpsing the size before doing fiemap.

Lustre-commit: 4b983ad104310d6e67d22e42b057085cc9122604
Lustre-change: http://review.whamcloud.com/13280

Signed-off-by: Li Dongyang <dongyang.li@anu.edu.au>
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: I072fd1f5e13c7fd127199a10b44366aed145b8e1
Reviewed-on: http://review.whamcloud.com/13439
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5726 ldiskfs: missed brelse() in large EA patch 64/13464/2
Niu Yawei [Tue, 20 Jan 2015 09:51:54 +0000 (04:51 -0500)]
LU-5726 ldiskfs: missed brelse() in large EA patch

brelse() is missed in ldiskfs_xattr_delete_inode(), this
defect is introduced by the ldiskfs large EA patch.

Lustre-commit: 09ab9d084884d8624e10ce49eeb0ed9f41451cea
Lustre-change: http://review.whamcloud.com/#/c/13452/

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I506dd93dd8a5e62b233be71083a392d4f35dac8e
Reviewed-on: http://review.whamcloud.com/13464
Tested-by: Jenkins
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-1453 tests: scrub interoperability issues with master 21/13021/4
Fan Yong [Fri, 3 Oct 2014 17:27:50 +0000 (01:27 +0800)]
LU-1453 tests: scrub interoperability issues with master

Since b2_7, we introduced new OSD parameter od_full_scrub_ratio
to control how to trigger OI scrub on the whole device if found
inconsistent OI mapping(s) during normal RPC services. When the
old sanity-scrub runs on (old) b2_5 client that talks with b2_7
or newer MDT, then it should properly handle such parameter.

Lustre-2.x (x <= 5) used "-n off" to disable dryrun which does
not work under Lustre-2.y (y >= 6), the test script should be
fixed as "-noff" or "--dryrun=off" or nothing by default.

Test-Parameters: alwaysuploadlogs ossjob=lustre-reviews mdsjob=lustre-reviews ossbuildno=28913 mdsbuildno=28913 testlist=sanity-scrub
Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: I95614f4441e219af94d5f9dfdae35fa25e38f903
Reviewed-on: http://review.whamcloud.com/13021
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4458 test: take fail_val into account for pause_bulk() 05/13205/2
Mikhail Pershin [Tue, 30 Dec 2014 08:05:17 +0000 (11:05 +0300)]
LU-4458 test: take fail_val into account for pause_bulk()

pause_bulk(), set_nodes_failloc() and reset_fail_loc() should
care about fail_val as well for compatibility with master

Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Change-Id: I283a23c67a633a5db479e421c96c164e1e07d05c
Reviewed-on: http://review.whamcloud.com/13205
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Li Wei <wei.g.li@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5651: ptlrpc: fix import state during replay 63/12163/8
Andriy Skulysh [Thu, 11 Dec 2014 18:29:10 +0000 (13:29 -0500)]
LU-5651: ptlrpc: fix import state during replay

Client doesn't restore import state correctly
on reconnect during replay. It resends lock replay
when final ping was queued by server.
Server fails with "target_queue_recovery_request())
ASSERTION( req->rq_export->exp_lock_replay_needed ) failed"

Add imp_replay_state to store last replay state.
imp_state is restored from imp_replay_state
during reconnect.

Lustre-commit: f61cec84e61e4be07ab741dd0fbeac3b4a388eef
Lustre-change: http://review.whamcloud.com/#/c/12015

The new test for replay-single will only work for lustre
versions that contain commit f61cec84. This patch does
lustre version checking to over failing on platforms that
are not fixed.

Lustre-commit: afde9f17260650d0cb80d53613fb5afda0a39384
Lustre-change: http://review.whamcloud.com/#/c/12942

Xyratex-bug-id: MRP-2022
Signed-off-by: Andriy Skulysh <Andriy_Skulysh@xyratex.com>
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: Iaa14fe968cc31f266b605785df4fa676083fbca4
Reviewed-on: http://review.whamcloud.com/12163
Tested-by: Jenkins
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5830 scripts: use lustre_rmmod in lnet start/stop script 87/12587/2
Bruno Faccini [Wed, 5 Nov 2014 19:38:04 +0000 (11:38 -0800)]
LU-5830 scripts: use lustre_rmmod in lnet start/stop script

In lnet's start/stop script stop phase, use lustre_rmmod instead
to try to unload a static list/sequence of modules.

This patch is back-ported from the following one:
Lustre-commit: f882ceaa28d5c0fb2f018102468656d9b7adc637
Lustre-change: http://review.whamcloud.com/12513

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: Ida7093e10b198c73a4cd8ca539f4b803dd998e00
Reviewed-on: http://review.whamcloud.com/12587
Reviewed-by: Brian J. Murrell <brian.murrell@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-5674 test: print spl debug info 90/12590/2
Minh Diep [Wed, 5 Nov 2014 19:53:55 +0000 (11:53 -0800)]
LU-5674 test: print spl debug info

Print /proc/spl files in case of tests fail

This patch is back-ported from the following one:
Lustre-commit: acdaca8426a4ca21dab6f6b39365befb3a8f5ffc
Lustre-change: http://review.whamcloud.com/11580

Signed-off-by: Minh Diep <minh.diep@intel.com>
Change-Id: Ia255347e2ad47732e6f86f9d8cd7bfa883bcde9b
Reviewed-on: http://review.whamcloud.com/12590
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Isaac Huang <he.huang@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5932 tests: load sunrpc module before insmod ptlrpc_gss 17/13017/3
Jian Yu [Fri, 12 Dec 2014 08:03:18 +0000 (00:03 -0800)]
LU-5932 tests: load sunrpc module before insmod ptlrpc_gss

Lustre ptlrpc_gss module depends on Linux kernel sunrpc module.
This patch fixes load_module() in test-framework.sh to load the
sunrpc module before loading ptlrpc_gss module by using insmod.

This patch is back-ported from the following one:
Lustre-commit: 92479eca2ed5e1871b2660af280917e4d61bdba8
Lustre-change: http://review.whamcloud.com/12790

Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I105608d37c5889def0fab938a249c2f2a8f2186f
Reviewed-on: http://review.whamcloud.com/13017
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Wei Liu <wei3.liu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-3676 llite: to configure max_cached_mb correctly 24/12924/2
Jinshan Xiong [Wed, 3 Dec 2014 22:59:04 +0000 (14:59 -0800)]
LU-3676 llite: to configure max_cached_mb correctly

If there exists MGS conf_param to reduce the memory cache
max_cached_mb it will fail because dt_exp is not initialized
yet.

It should just go ahead and configure it because certainly it
have enough free LRU slot to deduct ccc_lru_left.

This patch is back-ported from the following one:
Lustre-commit: b0135d72b783eed4d9b86532be6244ebc57b1f39
Lustre-change: http://review.whamcloud.com/11783

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: If837f178592dd487775ddcb15115964fba6429bf
Reviewed-on: http://review.whamcloud.com/12924
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5905 tests: add version check codes to conf-sanity test 56 46/13046/3
Jian Yu [Sun, 14 Dec 2014 07:25:37 +0000 (23:25 -0800)]
LU-5905 tests: add version check codes to conf-sanity test 56

This patch adds Lustre version check codes into conf-sanity test
56 to make the test interoperate with servers that do not have
the following changes:

Lustre-commit: 3dc232918c7c9b95398ac6a0dc4c2130adc2851d
Lustre-change: http://review.whamcloud.com/12145
or
Lustre-commit: e6745116cc372647f785c4063389734620c92e91
Lustre-change: http://review.whamcloud.com/12319

Test-Parameters: alwaysuploadlogs envdefinitions=ONLY=56 \
ossjob=lustre-b2_4 mdsjob=lustre-b2_4 ossbuildno=73 mdsbuildno=73 \
testlist=conf-sanity

Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I903d9d5779cedd5b73a903b3b0d46c102ab038fd
Reviewed-on: http://review.whamcloud.com/13046
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Li Wei <wei.g.li@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-6000 tests: avoid test failure on b2_4 server 00/13000/7
Fan Yong [Sun, 28 Sep 2014 17:33:58 +0000 (01:33 +0800)]
LU-6000 tests: avoid test failure on b2_4 server

The injection failure stub OBD_FAIL_FID_LOOKUP on old MDT
(version < 2.5.4) will cause sanity-lfsck test_4 failure
when traversal the directory. Since we will not land more
patch on b2_4, then skip related test(s) in new version
test scripts.

Test-Parameters: alwaysuploadlogs ossjob=lustre-b2_4 mdsjob=lustre-b2_4 ossbuildno=73 mdsbuildno=73 testlist=sanity-lfsck
Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: I9866707a336865e7e30ba587bd9847c1dae7ea58
Reviewed-on: http://review.whamcloud.com/13000
Tested-by: Jenkins
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Emoly Liu <emoly.liu@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-3455 mdt: sync when evicting client 31/13231/2
Hongchao Zhang [Sun, 4 Jan 2015 05:55:03 +0000 (21:55 -0800)]
LU-3455 mdt: sync when evicting client

If some client is evicted from the MDT, then the underlying OSD
should be synchronized, otherwise the recovery will be failed
for the replay requests were dropped alongside with the client.

in test_20b in replay-single.sh, the occupied disk space will be
released only after DMUs are committed for ZFS, then it should
wait some more time before calling 'df' to get the disk usage info.

This patch is back-ported from the following one:
Lustre-commit: fabd01968d0fac83e4855da5a5dfe8f68c038ceb
Lustre-change: http://review.whamcloud.com/11767

Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes,ONLY=20b \
mdtfilesystemtype=zfs mdsfilesystemtype=zfs ostfilesystemtype=zfs \
clientcount=4 osscount=2 mdscount=2 \
mdssizegb=10 ostsizegb=10 austeroptions=-R failover=true iscsi=1 \
testlist=replay-single,replay-single,replay-single,replay-single,replay-single

Signed-off-by: Hongchao Zhang <hongchao.zhang@intel.com>
Change-Id: Ia0416e57d009f2fa00c880c6ea41f9d0bd60fef0
Reviewed-on: http://review.whamcloud.com/13231
Tested-by: Jenkins
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@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>
9 years agoLU-6016 tests: do not need start MDS in sanity-lfsck test 20a 25/13025/3
Jian Yu [Wed, 10 Dec 2014 19:56:03 +0000 (11:56 -0800)]
LU-6016 tests: do not need start MDS in sanity-lfsck test 20a

This patch removes "start $SINGLEMDS" and "mount_client $MOUNT"
from sanity-lfsck test_20a() because these operations are already
done in lfsck_prep().

Test-Parameters: alwaysuploadlogs envdefinitions=SLOW=yes,ENABLE_QUOTA=yes mdtfilesystemtype=ldiskfs mdsfilesystemtype=ldiskfs ostfilesystemtype=ldiskfs mdtcount=1 testlist=sanity-lfsck
Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I75c77519c306c0f74db3441936935252cdedb774
Reviewed-on: http://review.whamcloud.com/13025
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4958 lov: don't crash accessing LOV object with FID{0,0} 40/12740/6
Yang Sheng [Sat, 15 Nov 2014 15:42:23 +0000 (23:42 +0800)]
LU-4958 lov: don't crash accessing LOV object with FID{0,0}

Some object maybe has a corrupted LOV EA or a hole in
LOV EA. We should not crash client in such case.

This is a back-port patch from master:
Lustre-change: http://review.whamcloud.com/10042
Lustre-commit: 754bf71c650c427acfb0fe35017e8f9c1eb9fa7d

Signed-off-by: Fan Yong <fan.yong@intel.com>
Signed-off-by: Yang Sheng <yang.sheng@intel.com>
Change-Id: I08cdd770c369eb51aa92b04a838fbb6784d36bad
Reviewed-on: http://review.whamcloud.com/12740
Tested-by: Jenkins
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-5626 ldiskfs: update non-htree dotdot in rename 27/12927/2
Bob Glossman [Wed, 3 Dec 2014 23:33:49 +0000 (15:33 -0800)]
LU-5626 ldiskfs: update non-htree dotdot in rename

This mod duplicates changes previously committed only for el6
for sles11sp3.

In 2.4+, when renaming a directory, its old dotdot entry will
be removed firstly, then the new dotdot entry is inserted, and
ldiskfs tries to append FID-in-dirent to the new entry.
But the space for dotdot entry may not be enough to hold
the new dotdot with FID-in-dirent, such as an MDT device
restored from file-level backup, or a device upgraded from 1.8.

In that case, for non-HTree directories, the ".." entry
will be written in the next available space in the directory
block.  This is invalid, as the ".." entry must be the
second entry in the block.

The same bug was fixed for HTree directories in LU-2638.
As Fan Yong said then: we do not want to introduce
complex logic to handle directory data moving, instead, in
such case, ignore the FID-in-dirent for the new dotdot entry,
and just insert the new dotdot entry.

There is one known flaw: This patch, like the one for
LU-2638, skips the entire data section rather than just
the FID.  This could cause trouble if something else ever
uses this section with ".." entries.

This patch is back-ported from the following one:
Lustre-commit: 4f8edadbbd3ba70d9236e98518182b4d3ff5acdb
Lustre-change: http://review.whamcloud.com/12585

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I1a51e85654837b9ce720ed925ccc4b90645f6e24
Reviewed-on: http://review.whamcloud.com/12927
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>
9 years agoLU-5626 ldiskfs: update non-htree dotdot in rename 26/12926/2
Patrick Farrell [Wed, 3 Dec 2014 23:26:59 +0000 (15:26 -0800)]
LU-5626 ldiskfs: update non-htree dotdot in rename

In 2.4+, when renaming a directory, its old dotdot entry will
be removed firstly, then the new dotdot entry is inserted, and
ldiskfs tries to append FID-in-dirent to the new entry.
But the space for dotdot entry may not be enough to hold
the new dotdot with FID-in-dirent, such as an MDT device
restored from file-level backup, or a device upgraded from 1.8.

In that case, for non-HTree directories, the ".." entry
will be written in the next available space in the directory
block.  This is invalid, as the ".." entry must be the
second entry in the block.

The same bug was fixed for HTree directories in LU-2638.
As Fan Yong said then: we do not want to introduce
complex logic to handle directory data moving, instead, in
such case, ignore the FID-in-dirent for the new dotdot entry,
and just insert the new dotdot entry.

There is one known flaw: This patch, like the one for
LU-2638, skips the entire data section rather than just
the FID.  This could cause trouble if something else ever
uses this section with ".." entries.

This patch is back-ported from the following one:
Lustre-commit: 38ec486aeee20345a86dbbd2022d7976337c49b8
Lustre-change: http://review.whamcloud.com/11939

Signed-off-by: Patrick Farrell <paf@cray.com>
Change-Id: I509b960b111d12d6375c967163f50199cb8f76bf
Reviewed-on: http://review.whamcloud.com/12926
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>
9 years agoLU-5044 mdd: do not return .lustre from readdir
John L. Hammond [Tue, 22 Jul 2014 21:30:08 +0000 (16:30 -0500)]
LU-5044 mdd: do not return .lustre from readdir

In mdd_dir_page_build() skip dirents with the FID of .lustre
preventing that directory from being return by readdir on Lustre
clients. Add a sanity tets to this effect.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: Ieecb77a286748c4bf4df4dee68d7f33670a0c286
Reviewed-on: http://review.whamcloud.com/11186
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: wangdi <di.wang@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
9 years agoLU-4604 obdclass: handle ldt_device_nr/ldt_linkage properly 31/12531/4
Fan Yong [Wed, 3 Sep 2014 16:29:41 +0000 (00:29 +0800)]
LU-4604 obdclass: handle ldt_device_nr/ldt_linkage properly

It is partly back-ported the patch from master:
"LU-4604 lfsck: LFSCK async updates RPC flow control"
But this only contains the part related with lu_device fixes,
not the lfsck async RPC changes.

There was no protection when inc/dec lu_device_type::ldt_device_nr,
which may caused the ldt_device_nr to be wrong and trigger assert.
This patch redefine lu_device_type::ldt_device_nr as atomic type.

There was no protection when add/del lu_device_type::ldt_linkage
into/from the global lu_device_types list, which may caused bad
address accessing. This patch uses the existing obd_types_lock
to protect related operations.

We do NOT need lu_types_stop() any longer. Such function scans
the global lu_device_types list, and for each type item on it
which has zerod lu_device_type::ldt_device_nr, call its stop()
method. In fact, the lu_device_type::ldt_device_nr only will be
zero when the last lu_device_fini() is called, and at that time,
inside the lu_device_fini(), its stop() method will be called.
So it is unnecessary to call the stop() again via lu_types_stop().

Lustre-commit: caef708d4040fd13499a11a42507ba56f9454298
Lustre-change: http://review.whamcloud.com/8694

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: Ibea9e8f51191de76dbd2e199e01b1d2adff35c75
Reviewed-on: http://review.whamcloud.com/12531
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>
9 years agoLU-5241 tests: speed up sanity-lfsck and sanity-scrub tests 18/10818/6
Emoly Liu [Sat, 20 Sep 2014 06:10:30 +0000 (23:10 -0700)]
LU-5241 tests: speed up sanity-lfsck and sanity-scrub tests

1) drop unnecessary devices reformat.
2) drop unnecessary system stop/re-start.
3) replace 'sleep' with wait_update_facet to avoid idle wait.
4) drop unnecessary "-p" option for some "mkdir" cases.
5) replace "touch" with "createmany -m".
6) other code style changes and cleanup.

This patch is back-ported from the following one:
Lustre-commit: 1dbba329174e6c7f7712f01fc4e44c44400fbc92
Lustre-change: http://review.whamcloud.com/9704

LU-4803 ofd: skip orphan cleanup when inject OI error

When inject OI error for simulating some failure cases, the object
may be mapped to invalid local target (inode for ldiskfs), so skip
the orphan cleanup in OSP to avoid unexpected warning or destroy.

Lustre-commit: 0bafbd7d8f652997d83b3cc2419894f48833f424
Lustre-change: http://review.whamcloud.com/9759

Test-Parameters: alwaysuploadlogs envdefinitions=SLOW=yes \
testlist=lfsck-performance,sanity-scrub,sanity-lfsck

Signed-off-by: Fan Yong <fan.yong@intel.com>
Signed-off-by: Emoly Liu <emoly.liu@intel.com>
Change-Id: Iacae0047a502e3baa778b86536220d70c717f6f5
Reviewed-on: http://review.whamcloud.com/10818
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5248 osd: NOT inject OBD_FAIL_FID_LOOKUP on dotdot 06/11006/4
Fan Yong [Sat, 20 Sep 2014 05:44:06 +0000 (22:44 -0700)]
LU-5248 osd: NOT inject OBD_FAIL_FID_LOOKUP on dotdot

The namespace LFSCK may cannot rebuild the FID-in-dirent for dotdot
entry after the MDT restored from file-level backup, because there
is not enough space in the directory head area.

Lustre-change: http://review.whamcloud.com/9748
Lustre-commit: 7dec22d474faa50e1a7fb6b377ceb1310b76a8e8

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: Iedf3b140a1dcc9fd77b40dbdf3dee52a44b5814b
Reviewed-on: http://review.whamcloud.com/11006
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>
9 years agoLU-5827 mdt: do not crash server upon unsupported opc 97/12497/2
Bobi Jam [Thu, 30 Oct 2014 12:29:47 +0000 (20:29 +0800)]
LU-5827 mdt: do not crash server upon unsupported opc

mdt_handler_find() needs to check opc as well as whether we've defined
its handler to decide that the operation is supported.

Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Change-Id: Iefc2629cd4ad2d9df1b19ada7aa620282c5dab19
Reviewed-on: http://review.whamcloud.com/12497
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>
9 years agoLU-5807 qos: enable QOS_DEBUG() 51/12651/2
Niu Yawei [Mon, 27 Oct 2014 12:43:07 +0000 (08:43 -0400)]
LU-5807 qos: enable QOS_DEBUG()

Enable QOS_DEBUG() by default.

Lustre-commit: 24f49b88cfefcd748902a6056dfd8ce20bdd6b7f
Lustre-change: http://review.whamcloud.com/12434

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: If2b0e1388a5f12edd5b03ffc1081709b9efb1c13
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-on: http://review.whamcloud.com/12651
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5781 osc: osc_lock_weight endless loop fix 59/12859/2
Jinshan Xiong [Thu, 6 Nov 2014 18:00:32 +0000 (10:00 -0800)]
LU-5781 osc: osc_lock_weight endless loop fix

With huge number of pages to scan by osc_lock_weight() it is likely
CLP_GANG_RESCHED is returned from osc_page_gang_lookup() and the scan
will be repeated again from the start. To be sure that the scan is
progressing across those restarts, next scan should be started from
the last scanned page index plus one.

Xyratex-bug-id: MRP-2145
Change-Id: I60775f2d8f688029d97ad4fe64f9b2698ed278c8
Signed-off-by: Alexander Zarochentsev <alexander.zarochentsev@seagate.com>
Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-on: http://review.whamcloud.com/12859
Tested-by: Jenkins
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5778 lod: Fix lod_qos_statfs_update() 85/12685/3
Aurelien Degremont [Wed, 12 Nov 2014 13:00:59 +0000 (14:00 +0100)]
LU-5778 lod: Fix lod_qos_statfs_update()

When an OST is sick, or unactivate, lod cannot fetch its statfs
information. In lod_qos_statfs_update() this was preventing lod
to get information for other OST because refresh was stopped at
first error.
This patch fixes this behaviour.

Patch backported from master:
Lustre-change: http://review.whamcloud.com/12617
Lustre-commit: b50a6ccf9fe32c2fae1e6225f8e1a5b420b45d56

Signed-off-by: Aurelien Degremont <aurelien.degremont@cea.fr>
Change-Id: I26ea91e54275f9e1accf51b779edf1b6e6a796a0
Reviewed-on: http://review.whamcloud.com/12685
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5727 ldlm: revert the changes for lock canceling policy 65/12565/5
Jinshan Xiong [Tue, 28 Oct 2014 02:20:07 +0000 (22:20 -0400)]
LU-5727 ldlm: revert the changes for lock canceling policy

The changes for LRU lock policy was introduced by commit 0a6c6fcd4,
where I was trying to revise the policy to pick locks for canceling.

However, this caused two problems as mentioned in LU-5727. The first
problem is that the lock can only be picked for canceling only if
the number of LRU locks is over preset LRU number AND it's aged; the
second problem is that mdc_cancel_weight() tends to not cancel OPEN
locks, therefore open locks can be kept forever and finally exhausts
memory on the MDT side.

This patch will revert the changes related to LRU policy revision.

This is backported from master:
Lustre-change: http://review.whamcloud.com/12733

LU-5727 ldlm: revert changes to ldlm_cancel_aged_policy()

The changes to ldlm_cancel_aged_policy() intrdouced from LU-4300
(bfae5a) was incorrect. This patch revert this part of changes.

This is backported from master:
Lustre-change: http://review.whamcloud.com/12448
Lustre-commit: e8812867e8c6c9eb62174b370cb818985e3d2180

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: Ic04f894c8bf54dbbdfb0e3bada5f6e4a367711a5
Reviewed-on: http://review.whamcloud.com/12565
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5707 lfsck: recreate LFSCK trace file for load failure 78/12278/3
Fan Yong [Mon, 8 Sep 2014 21:11:02 +0000 (05:11 +0800)]
LU-5707 lfsck: recreate LFSCK trace file for load failure

The extended attribute XATTR_NAME_LFSCK_NAMESPACE for namespace
LFSCK trace file is enlarged since Lustre-2.7. When downgrade
from Lustre-2.7, the old MDS will get -ERANGE when loads the
XATTR_NAME_LFSCK_NAMESPACE extended attribute from the new
formatted on-disk namespace LFSCK trace file. Under such case,
the LFSCK should not return failure, instead, it can recreate the
XATTR_NAME_LFSCK_NAMESPACE EA as initialization case.

More further, if the LFSCK failed to load trace file, it is
unncessary to fail the whole LFSCK, instead, just recreate the
trace file.

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: Icc2c7087f9f4a20d57664eaaf5a92f6c6260c3aa
Reviewed-on: http://review.whamcloud.com/12278
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Patrick Farrell <paf@cray.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
9 years agoLU-5142 tests: add version check codes to conf-sanity test 43 11/12911/2
Jian Yu [Wed, 3 Dec 2014 00:40:08 +0000 (16:40 -0800)]
LU-5142 tests: add version check codes to conf-sanity test 43

This patch adds Lustre version check codes into conf-sanity test
43 to make the test interoperate with servers that do not have
the following changes:

Lustre-commit: 3064318df90ce7019b83c8a7f80e93a9634c00fa
Lustre-change: http://review.whamcloud.com/5700
Lustre-commit: 917b0a17d4e50db9f966763925a2dc860d932a3b
Lustre-change: http://review.whamcloud.com/9221

Test-Parameters: alwaysuploadlogs envdefinitions=ONLY=43 \
ossjob=lustre-b2_4 mdsjob=lustre-b2_4 ossbuildno=73 mdsbuildno=73 \
testlist=conf-sanity

Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I7e12038cc8f77d3a9dbe19806133c21580bfd484
Reviewed-on: http://review.whamcloud.com/12911
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4943 obdclass: detach MGC dev on error 65/11765/5
Bobi Jam [Mon, 28 Apr 2014 15:40:27 +0000 (23:40 +0800)]
LU-4943 obdclass: detach MGC dev on error

lustre_start_mgc() creates MGC device, if error happens later on
ll_fill_super(), this device is still attached, and later mount
fails by keep complaining that the MGC device's already in the
client node.

It turns out that the device was referenced by mgc config llog data
which is arranged in the mgc lock requeue thread re-trying to get its
mgc lock, and in normal case, this llog reference only released in
mgc_blocking_ast() when the system is umount.

This patch make mgc_precleanup() to wake up requeue thread to handle
the config llog data.

This patch also makes mgc_setup() wait for mgc_requeue_thread() start
before moving on.

Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Change-Id: I83df8c68c1dbe4ef4ee879e04ab20df46fea9062
Reviewed-on: http://review.whamcloud.com/11765
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Ryan Haasken <haasken@cray.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4441 test: improve run-llog.sh to print more information 73/11573/2
Emoly Liu [Mon, 25 Aug 2014 05:30:45 +0000 (13:30 +0800)]
LU-4441 test: improve run-llog.sh to print more information

Improve run-llog.sh script so that it can print more useful
information when "Module llog_test is in use" happens again.

This is a backport to b2_5.
Lustre-change: http://review.whamcloud.com/9966
Lustre-commit: 5d8de1fabf740eda724ad2e9eb40c3b57322b9e4

Signed-off-by: Emoly Liu <emoly.liu@intel.com>
Change-Id: I15594f34f26550204b525d8f532fd064f30d00a4
Reviewed-on: http://review.whamcloud.com/11573
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-4839 tests: Give copytool more time to start 23/12823/2
Nathaniel Clark [Sun, 23 Nov 2014 07:48:10 +0000 (23:48 -0800)]
LU-4839 tests: Give copytool more time to start

Copytool can take some time to start, and if the HSM archive directory
is on a busy NFS server, it can take a bit of time for the initial
opens to occur.  This allows those actions more time to complete which
should give this test a better chance of passing correctly.

Test-Parameters: alwaysuploadlogs envdefinitions=SLOW=yes \
mdtfilesystemtype=zfs mdsfilesystemtype=zfs ostfilesystemtype=zfs \
testlist=sanity-hsm,sanity-hsm,sanity-hsm,sanity-hsm

Test-Parameters: alwaysuploadlogs envdefinitions=SLOW=yes,ONLY=60 \
mdtfilesystemtype=ldiskfs mdsfilesystemtype=ldiskfs ostfilesystemtype=ldiskfs \
mdtcount=4 testlist=sanity-hsm,sanity-hsm,sanity-hsm,sanity-hsm

This patch is back-ported from the following one:
Lustre-commit: 6948e80bc149aa689e09334a70941340143fa2ce
Lustre-change: http://review.whamcloud.com/12682

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: Ib8828805f52c1f86bf01388606b78ad2c4085acb
Reviewed-on: http://review.whamcloud.com/12823
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Jenkins
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5822 osd-ldiskfs: Correctly return OS_STATE_READONLY 63/12463/2
Matt Ezell [Tue, 28 Oct 2014 20:49:23 +0000 (16:49 -0400)]
LU-5822 osd-ldiskfs: Correctly return OS_STATE_READONLY

Ensure that read-only devices correctly return their state so that
the health_check file will be accurate

Signed-off-by: Matt Ezell <ezellma@ornl.gov>
Change-Id: Iea38c924ca0d8cb543b77599019fc88fd8b58105
Reviewed-on: http://review.whamcloud.com/12463
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-5650 mgc: check the import stat for lprocfs 96/12896/2
Hongchao Zhang [Mon, 1 Dec 2014 22:47:05 +0000 (14:47 -0800)]
LU-5650 mgc: check the import stat for lprocfs

in lprocfs_mgc_rd_ir_state, the import state should be checked
the validity before doing further work.

This patch is back-ported from the following one:
Lustre-commit: 4295402585605e1ba210ad96c12e3820fa523f7b
Lustre-change: http://review.whamcloud.com/12327

Signed-off-by: Hongchao Zhang <hongchao.zhang@intel.com>
Change-Id: I41a5f7547d24bf61ce83dd488aef699409be209b
Reviewed-on: http://review.whamcloud.com/12896
Tested-by: Jenkins
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5545 ptlrpc: false alarm in AT network latency measuring 55/12855/2
Liang Zhen [Tue, 25 Nov 2014 19:21:34 +0000 (11:21 -0800)]
LU-5545 ptlrpc: false alarm in AT network latency measuring

If early reply of client RPC is lost and client RPC is expired and
resent, server will drop the resent RPC because it's already in
processing, server may also send reply or early reply to client,
which can still match reply buffer of the original request.
In this case, client is measuring time from resent time, but server
is reporting service time of original RPC, which is longer than
the time measured by client.

This patch is back-ported from the following one:
Lustre-commit: c238be0bd02367b634c1061a30bbe161dfd9d8e9
Lustre-change: http://review.whamcloud.com/12018

Signed-off-by: Liang Zhen <liang.zhen@intel.com>
Change-Id: I5bdcdee9dd6b439d5d650fa812ea65527458c590
Reviewed-on: http://review.whamcloud.com/12855
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Li Wei <wei.g.li@intel.com>
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
9 years agoLU-4810 utils: print messages when set tunables 53/12553/3
Niu Yawei [Mon, 28 Apr 2014 04:39:38 +0000 (00:39 -0400)]
LU-4810 utils: print messages when set tunables

When set scheduler and max_sectors_kb on mount, error messages should
be printed to notify user that these tunables are changed by lustre.

Lustre-commit: 9813961151e8f6e19eac9cf5a8db676f7aa70f50
Lustre-change: http://review.whamcloud.com/9865

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I6a3618b7e5eb0127e9aea18631397cd4dcbde546
Reviewed-on: http://review.whamcloud.com/9865
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Blake Caldwell <blakec@ornl.gov>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/12553
Reviewed-by: James Nunez <james.a.nunez@intel.com>
9 years agoLU-4627 llite: deed taking lli_trunc_sem during file write 68/12268/3
Bobi Jam [Thu, 13 Feb 2014 15:27:41 +0000 (23:27 +0800)]
LU-4627 llite: deed taking lli_trunc_sem during file write

File write before io loop will take lli_trun_sem read semaphore to
protect osc_extent, while after generic_file_aio_write() done, it
could possible need to kill suid or sgid, which will call
ll_setattr_raw() to change the inode's attribute, and it does not
involve size.

So the ll_truc_sem write semaphore should be constrained
around ll_setattr_ost() to not come across the lli_trunc_sem read
semaphore get from the normal file write path.

Backported from master:
Lustre-change: http://review.whamcloud.com/9267
Lustre-commit: 1601e8591c1334ee7879bb6daac09342caa4a542

Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Change-Id: Ic7f9cfb6d76dcf7ad08635efab154e7cdc392ce8
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/12268
Tested-by: Jenkins
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
9 years agoLU-5639 lnet: portal spreading rotor should be unsigned 99/11999/2
Liang Zhen [Tue, 16 Sep 2014 03:49:40 +0000 (11:49 +0800)]
LU-5639 lnet: portal spreading rotor should be unsigned

Portal spreading rotor should be unsigned, otherwise lnet may get
negative CPT number and access invalid addresses.

Lustre-commit: ed5c72e96f7f951ad29284fccd1f878963a817cf
Lustre-change: http://review.whamcloud.com/11936

Signed-off-by: Liang Zhen <liang.zhen@intel.com>
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: Id7f40da241af3b01483fdedd366b09329f530163
Reviewed-on: http://review.whamcloud.com/11999
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Isaac Huang <he.huang@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5631 obdclass: Proper swabbing of llog_rec_tail. 53/11953/2
Henri Doreau [Tue, 16 Sep 2014 10:34:07 +0000 (12:34 +0200)]
LU-5631 obdclass: Proper swabbing of llog_rec_tail.

A variable-length structure preceeds llog_rec_tail within an llog
block. Thus cr_tail shouldn't be accessed directly as a structure
member but its actual location should be computed dynamically.

Signed-off-by: Henri Doreau <henri.doreau@cea.fr>
Change-Id: I2d244797d107cf52f647e19b2db780138e910925
Reviewed-on: http://review.whamcloud.com/11953
Tested-by: Jenkins
Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-5606 tests: add version check codes to conf-sanity test 41c 75/12375/3
Jian Yu [Wed, 22 Oct 2014 06:34:04 +0000 (23:34 -0700)]
LU-5606 tests: add version check codes to conf-sanity test 41c

This patch adds Lustre version check codes into conf-sanity test
41c to make the test interoperate with servers that do not have
commit 166c5ba95cb2a4771317e030a3649e4480c8cbad.

Test-Parameters: alwaysuploadlogs envdefinitions=ONLY=41c \
ossjob=lustre-b2_4 mdsjob=lustre-b2_4 ossbuildno=73 mdsbuildno=73 \
testlist=conf-sanity

Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I605e43954ba7015002dabcaee1cd587c898fa6cb
Reviewed-on: http://review.whamcloud.com/12375
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-5573 obdclass: strengthen against concurrent server mounts 53/12353/4
Bruno Faccini [Tue, 21 Oct 2014 01:33:50 +0000 (18:33 -0700)]
LU-5573 obdclass: strengthen against concurrent server mounts

This patch is an add-on to previous fix for LU-5299, against same
issues/races scenarios during concurrent server devices mounts.

This patch is back-ported from the following one:
Lustre-commit: 91b68bc4f4d8f25e88a252ca0918f0a422fec27b
Lustre-change: http://review.whamcloud.com/12114

Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes,CONF_SANITY_EXCEPT=45 \
mdtfilesystemtype=zfs mdsfilesystemtype=zfs ostfilesystemtype=zfs \
ostcount=2 ostsizegb=8 testlist=conf-sanity,conf-sanity,conf-sanity

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: I121ee3f14d4bee7973cd968d561e8fc03acb6386
Reviewed-on: http://review.whamcloud.com/12353
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5556 target: limit bulk transfer time 42/12242/3
Johann Lombardi [Mon, 1 Sep 2014 13:03:51 +0000 (15:03 +0200)]
LU-5556 target: limit bulk transfer time

Messages lost during bulk transfer are not resent, so there is no
point in waiting for a very long time (up to at_max/600s has been
seen). This patch adds a new static timeout for the bulk transfer
(100s by default).

Signed-off-by: Johann Lombardi <johann.lombardi@intel.com>
Change-Id: I3926a7a8f2bce4cbd00b8fe54094a8e9cbec1508
Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Reviewed-on: http://review.whamcloud.com/12242
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5548 ptlrpc: avoid list scan in ptlrpcd_check 65/12265/3
Liang Zhen [Tue, 19 Aug 2014 02:55:04 +0000 (10:55 +0800)]
LU-5548 ptlrpc: avoid list scan in ptlrpcd_check

ptlrpcd_check() always scan all requests on ptlrpc_request_set
and try to finish completed requests, this is low efficiency.
Even worse, l_wait_event() always checks condition for twice
before sleeping and one more time after waking up, which means
it will call ptlrpcd_check() for three times in each loop.

This patch will move completed requests at the head of list
in ptlrpc_check_set(), with this change ptlrpcd_check doesn't
need to scan all requests anymore.

Signed-off-by: Liang Zhen <liang.zhen@intel.com>
Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Change-Id: I770016d4a2bcd51603b390b41427eb64ff52f71c
Reviewed-on: http://review.whamcloud.com/12265
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5062 llite: Solve a race to access lli_has_smd in read case 39/12139/3
Jinshan Xiong [Tue, 30 Sep 2014 18:44:54 +0000 (11:44 -0700)]
LU-5062 llite: Solve a race to access lli_has_smd in read case

In vvp_io_read_lock(), it used to decide if to add read lock by
checking lli_has_smd. Accessing lli_has_smd is racy when an empty
file is turned into raid0, therefore, it may result in read requests
are issued without corresponding lock.

Patch on master: http://review.whamcloud.com/10760

Test-Parameters: alwaysuploadlogs testlist=metadata-updates

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: I70cb1888b42e0e9928f8346359e2b1f554fe4e8f
Reviewed-on: http://review.whamcloud.com/12139
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4904 test: write_append_truncate failed with divide error 58/12358/3
Andriy Skulysh [Tue, 21 Oct 2014 07:06:43 +0000 (00:06 -0700)]
LU-4904 test: write_append_truncate failed with divide error

fix trunc_size calculation in case of append_size == 1
Don't allow to specify write_max and append_max < 2.

This patch is back-ported from the following one:
Lustre-commit: 85b037f5da6a022919783ef9a87ed6d2a4d102d2
Lustre-change: http://review.whamcloud.com/9948

Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes,ONLY=write_append_truncate \
mdtfilesystemtype=ldiskfs mdsfilesystemtype=ldiskfs ostfilesystemtype=ldiskfs \
mdtcount=4 mdssizegb=2 ostcount=7 ostsizegb=2 \
testlist=parallel-scale

Xyratex-bug-id: MRP-1779

Signed-off-by: Andriy Skulysh <Andriy_Skulysh@xyratex.com>
Change-Id: Ia2cf141b3cc78e4f1488a96fc602b78b16869678
Reviewed-on: http://review.whamcloud.com/12358
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Emoly Liu <emoly.liu@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4839 utils: fix bandwidth ctl in lhsmtool 05/12405/3
Nathaniel Clark [Sat, 27 Sep 2014 18:22:55 +0000 (14:22 -0400)]
LU-4839 utils: fix bandwidth ctl in lhsmtool

Use nanosleep for bandwidth control because usleep fails
for times of a second or longer (usleep(2) EINVAL return value). Add
loop in case sleep is woken by signal.

This is a backport to b2_5 of
Lustre-change: http://review.whamcloud.com/#/c/12093/
Lustre-commit: f74ace3919d60dc05664caa32f5a79abc3a2fe91

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: Ib58676b878678eb399bf58bb9873d8fb411b3316
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/12405
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
9 years agoLU-5659 hsm: add timestamps to lhsmtool log messages 68/12368/5
John L. Hammond [Wed, 24 Sep 2014 17:33:10 +0000 (12:33 -0500)]
LU-5659 hsm: add timestamps to lhsmtool log messages

Add epoch timestamps (secs.usecs) to the log messages emitted by
lhsmtool_posix. Change the single use of CT_DEBUG() to
CT_TRACE(). Remove the unused macro CT_PRINTF().

This is a backport to b2_5 of
Lustre-change: http://review.whamcloud.com/#/c/12042/3
Lustre-commit: b23357064aba6022237dd146c33725529069770d

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I227d00c97f93a09ac9322213d255102b8a3cf612
Reviewed-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Faccini Bruno <bruno.faccini@intel.com>
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/12368
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
9 years agoLU-4044 build: fix 'resource leak' errors 94/12394/3
Sebastien Buisson [Wed, 2 Oct 2013 06:43:08 +0000 (08:43 +0200)]
LU-4044 build: fix 'resource leak' errors

Fix 'resource leak' defects found by Coverity version 6.6.1:
Resource leak (RESOURCE_LEAK)
Variable going out of scope leaks the storage it points to.

Signed-off-by: Sebastien Buisson <sebastien.buisson@bull.net>
Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: I1039fa8bd5e82acab0ffcb082d35fca28dfb694c
Reviewed-on: http://review.whamcloud.com/7820
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/12394

9 years agoLU-3696 mdd: decref volatile object after creation 76/12076/2
James Nunez [Fri, 26 Sep 2014 20:24:09 +0000 (14:24 -0600)]
LU-3696 mdd: decref volatile object after creation

Drop the nlink count on a volatile file after it is created.
It is created with a single reference and then added to the PENDING
directory, which adds a second reference to the inode.  When it is
closed it is left with an nlink count=1 and not unlinked as it should
be.

Do not insert volatile files into the ChangeLog, since they are
intended to be temporary files that cannot be accessed after creation
and should not be synched to a backup filesystem.

If llapi_create_volatile_idx() is used on a non-Lustre filesystem then
it should also unlink the temporary filename after opening it, so that
the behaviour is the same.  Improve the comments for this function.

Minor cleanups of related functions found during investigation.

This patch is based on Andreas Dilger's patch:
Lustre-change: http://review.whamcloud.com/#/c/10179
Lustre-commit: 1ebc8dc473dd9f948837b9d5b258194637d46525

Signed-off-by: James Nunez <james.a.nunez@intel.com>
Change-Id: Ief906362ab2f6f92342c8eabcb9b090a340a5003
Reviewed-on: http://review.whamcloud.com/12076
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
9 years agoLU-1778 llite: fix inconsistencies of root squash feature 44/10744/4
Gregoire Pichon [Wed, 18 Jun 2014 09:18:00 +0000 (11:18 +0200)]
LU-1778 llite: fix inconsistencies of root squash feature

Root squash exhibits inconsistent behaviour on a client when
enabled. If a file is not cached on the client, then root will get
a permission denied error when accessing the file. When
the file has recently been accessed by a regular user and is
still in cache, root will be able to access the file without error
because the permission check is only done by the client that
isn't aware of root squash.

While the only real security benefit from root squash is to deny
clients access to files owned by root itself, it also makes sense
to treat file access on the client in a consistent manner
regardless of whether the file is in cache or not.

This patch adds root squash settings to llite so that client is able
to apply root squashing when it is relevant.

Configuration of MDT root squash settings will automatically be
applied to llite config log as well.

Update cfs_str2num_check() routine by removing any modification
of the specified string parameter. Since string can come from ls_str
field of a lstr structure, this avoids inconsistent ls_len field.

Lustre-change: http://review.whamcloud.com/5700
Lustre-commit: 3064318df90ce7019b83c8a7f80e93a9634c00fa

Signed-off-by: Gregoire Pichon <gregoire.pichon@bull.net>
Change-Id: Ib94a1a4a63c62c434a76bb935faad0fbdfddfec3
Reviewed-on: http://review.whamcloud.com/10744
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-1778 libcfs: add a service that prints a nidlist 43/10743/4
Gregoire Pichon [Tue, 17 Jun 2014 14:10:40 +0000 (16:10 +0200)]
LU-1778 libcfs: add a service that prints a nidlist

The libcfs already provides services to parse a string into a nidlist
and to match a nid into a nidlist. This patch implements a service
that prints a nidlist into a buffer.

This is required for instance to print the nosquash_nids parameter
of the MDT procfs component.

Additionally, this patch fixes a bug in return code of
parse_addrange() routine, so that parsing of nids including
a * character works fine ('*@elan' for instance).

Lustre-change: http://review.whamcloud.com/9221
Lustre-commit: 917b0a17d4e50db9f966763925a2dc860d932a3b

Signed-off-by: Gregoire Pichon <gregoire.pichon@bull.net>
Change-Id: Ifd5a9c224d43c815104eb170c5b854a1951ab47a
Reviewed-on: http://review.whamcloud.com/10743
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-5079 tests: fix service_time in max_recovery_time() 14/12714/5
Jian Yu [Fri, 14 Nov 2014 03:29:00 +0000 (19:29 -0800)]
LU-5079 tests: fix service_time in max_recovery_time()

This patch fixes the calculation of service_time in
max_recovery_time() to use the new method in
check_and_start_recovery_timer() and new values of
CONNECTION_SWITCH_MAX and CONNECTION_SWITCH_INC.

The patch also fixes replay-dual sub-tests:
- to call wait_clients_import_state() instead of sleeping
  uncertain time in test_11()
- to add some margin into the recovery time comparison
  in test_20()

Backport to b2_5 from master
Lustre-change: http://review.whamcloud.com/12724

Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes \
mdtfilesystemtype=ldiskfs mdsfilesystemtype=ldiskfs \
ostfilesystemtype=ldiskfs mdtcount=1 \
testlist=replay-dual,replay-dual

Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes \
mdtfilesystemtype=zfs mdsfilesystemtype=zfs \
ostfilesystemtype=zfs mdtcount=1 \
testlist=replay-dual,replay-dual

Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes \
mdtfilesystemtype=ldiskfs mdsfilesystemtype=ldiskfs \
ostfilesystemtype=ldiskfs mdtcount=4 \
testlist=replay-dual,replay-dual

Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I8ff0385c508dc4aea883f4159f3f9e55a216527c
Reviewed-on: http://review.whamcloud.com/12714
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>
9 years agoLU-5654 osd-ldiskfs: Handle holes in osd_ldiskfs_read() 19/12319/3
Li Wei [Wed, 24 Sep 2014 04:12:37 +0000 (12:12 +0800)]
LU-5654 osd-ldiskfs: Handle holes in osd_ldiskfs_read()

Current osd_ldiskfs_read() incorrectly returns zero and leaves the
corresponding portion of the buffer untouched when a block to be read
is not allocated.

Test-Parameters: testlist=conf-sanity,conf-sanity,conf-sanity mdsfilesystemtype=zfs mdtfilesystemtype=zfs ostfilesystemtype=zfs
Test-Parameters: testlist=conf-sanity,conf-sanity,conf-sanity mdsfilesystemtype=ldiskfs mdtfilesystemtype=ldiskfs ostfilesystemtype=ldiskfs
Change-Id: I51c5fcc5d9e258b536e5d2f070eb9ca6cd67d5aa
Signed-off-by: Li Wei <wei.g.li@intel.com>
Reviewed-on: http://review.whamcloud.com/12319
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Liang Zhen <liang.zhen@intel.com>
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
9 years agoLU-4588 code: replace semaphores with mutexes 58/12258/2
Dmitry Eremin [Thu, 9 Oct 2014 20:59:06 +0000 (00:59 +0400)]
LU-4588 code: replace semaphores with mutexes

It's just optimization. The mutex subsystem is slightly faster
and has better scalability for contended workloads.

Remove the lustre_lock and it's accessor functions l_lock(),
l_unlock(), l_lock_init(), and l_has_lock() since they have
not been used by the code since Lustre 1.6.

Lustre-Commit: 34b9fe2f703d91e7ad5b315aaac696d3a314cf0b
Lustre-Review: http://review.whamcloud.com/9294

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>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: Iea30c0853faf1ff18821b1facd2020ef91df1764
Reviewed-on: http://review.whamcloud.com/12258
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4669 type: change "%llx" to "LPX64” 32/12432/2
Jian Yu [Mon, 27 Oct 2014 07:44:44 +0000 (00:44 -0700)]
LU-4669 type: change "%llx" to "LPX64”

This patch fixes the following compile errors by using "LPX64”:
error: format '%llx' expects type 'long long unsigned int',
       but argument 5 has type '__u64'
error: format '%#llx' expects type 'long long unsigned int',
       but argument 3 has type '__u64'

This patch is back-ported from the following one:
Lustre-commit: f1eaf5e99aa9093b7a0fac7ae11e741560f64c31
Lustre-change: http://review.whamcloud.com/9811

Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I0637f2c0a1e57cf8ab89d8fe9c905145724fded3
Reviewed-on: http://review.whamcloud.com/12432
Tested-by: Jenkins
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-4669 ldiskfs: do not export static inline functions 31/12431/2
Jian Yu [Mon, 27 Oct 2014 07:33:46 +0000 (00:33 -0700)]
LU-4669 ldiskfs: do not export static inline functions

In ldiskfs/ldiskfs_extents.h, both ldiskfs_ext_store_pblock()
and ldiskfs_ext_pblock() are defined as static inline functions.
However, commit 49b06fba39e (http://review.whamcloud.com/4804)
exported these two functions in ldiskfs/extents.c, which is not
allowed by gcc and causes the following compile errors:

error: __ksymtab_ldiskfs_ext_pblock causes a section type conflict
error: __ksymtab_ldiskfs_ext_store_pblock causes a section type conflict

This patch fixes the above errors by not exporting the two functions.

This patch is back-ported from the following one:
Lustre-commit: e387b0e21c093ebbfb7571cd9e65a98d8e7e5718
Lustre-change: http://review.whamcloud.com/9401

Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I9ba2aa39d9d9dc97e74bd29b8513b86eed7fe175
Reviewed-on: http://review.whamcloud.com/12431
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-4749 mgs: Recognize colons in failover.node values 96/12196/3
Li Wei [Wed, 17 Sep 2014 05:55:33 +0000 (13:55 +0800)]
LU-4749 mgs: Recognize colons in failover.node values

Current mgs assumes that all the NIDs in a single failover.node
parameter belong to one node.  This is not the case, even prior to
http://review.whamcloud.com/11161, because mkfs.lustre options like

  --servicenode=<nid1>,<nid2>:<nid3>,<nid4>

are allowed.

Lustre-commit: bbe5f8ec92c63cc4fcb9ab0b316e92fb2a3d9683
Lustre-change: http://review.whamcloud.com/11956

Change-Id: If3e2ebc0e81093e9c8304e496afdca24edf456ef
Signed-off-by: Li Wei <wei.g.li@intel.com>
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
Reviewed-by: Liang Zhen <liang.zhen@intel.com>
Reviewed-on: http://review.whamcloud.com/12196
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
9 years agoLU-4298 utils: do not create file with no striping info 35/12335/3
James Nunez [Fri, 18 Jul 2014 15:06:36 +0000 (09:06 -0600)]
LU-4298 utils: do not create file with no striping info

'lfs setstripe' should not create a file with no striping
information if bad values are given. The input parameter
check in llapi_file_open_pool is moved before the file open
to catch bad parameters before the file is created.

A check is added to sanity test 27f to make sure
'lfs setstripe -s' does not create a file with no
striping information.

Lustre-commit: 823147fa760752c8c2ff11a5bd74f71f819f9e4e
Lustre-change: http://review.whamcloud.com/8375

Signed-off-by: Sebastien Buisson <sebastien.buisson@bull.net>
Signed-off-by: James Nunez <james.a.nunez@intel.com>
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I19beef973dc3a62bf2cb443e02195896772702fc
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-on: http://review.whamcloud.com/12335
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5795 kernel: kernel update [SLES11 SP3 3.0.101-0.40] 02/12402/3
Bob Glossman [Thu, 23 Oct 2014 16:35:01 +0000 (09:35 -0700)]
LU-5795 kernel: kernel update [SLES11 SP3 3.0.101-0.40]

Update target and config files for new version

Test-Parameters: mdsdistro=sles11sp3 ossdistro=sles11sp3\
 clientdistro=sles11sp3 mdsfilesystemtype=ldiskfs\
 mdtfilesystemtype=ldiskfs ostfilesystemtype=ldiskfs

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: Iac6e9dc76a6d2bdeb5615bffaeaa5e69652f31ba
Reviewed-on: http://review.whamcloud.com/12402
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-2059 mgs: fix a bug in mgs_llog_open 28/12428/2
Mikhail Pershin [Sat, 25 Oct 2014 05:23:41 +0000 (22:23 -0700)]
LU-2059 mgs: fix a bug in mgs_llog_open

- don't calculate len for NULL ptr
- check the logname is PARAMS_FILENAME inside 'if (ptr == NULL ...)
clause so all cases with NULL ptr will end there.

This patch is back-ported from the following one:
Lustre-commit: 8c21986e79f50131b0f381e5fe0311294328d660
Lustre-change: http://review.whamcloud.com/10589

Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Change-Id: Ic69866e91acad7920085848faf12c69bf3d17f12
Reviewed-on: http://review.whamcloud.com/12428
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Hongchao Zhang <hongchao.zhang@intel.com>
9 years agoLU-2059 mgs: don't fail on missing params log 27/12427/2
Mikhail Pershin [Sat, 25 Oct 2014 04:58:05 +0000 (21:58 -0700)]
LU-2059 mgs: don't fail on missing params log

The mgc_process_cfg_log() fails if 'params' log is not
accessinble and has no local copy. In fact that log is
optional and may be just empty.

Patch allows 'params' log to be empty and checks also for
'params' log in other places to avoid wrong error messages.
There was also deprecated code in mgs_write_log_direct_all()
which creates lustre-params log which is not used by anyone now.
Third change is removal of exceptions in conf-sanity.sh and
insanity.sh related to LU-2059

The only exception is insanity test_1 which is still failed due
to other reason.

This patch is back-ported from the following one:
Lustre-commit: 864fc9daac267819f5e3bdebef6cdac4c6325626
Lustre-change: http://review.whamcloud.com/10311

Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Change-Id: I081ca3920f3c2d05d4e966ed5234369ddc0eaac0
Reviewed-on: http://review.whamcloud.com/12427
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Hongchao Zhang <hongchao.zhang@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5079 ptlrpc: fix early reply timeout for recovery 65/12365/4
Alexander Boyko [Wed, 29 Oct 2014 21:59:12 +0000 (14:59 -0700)]
LU-5079 ptlrpc: fix early reply timeout for recovery

Commit 8b2f9c0e408 http://review.whamcloud.com/9100 changed
the deadline calculation from current time to request arrival.
During recovery, the new deadline could be less than calculated
at request arrival time. And even worse, the deadline may be
in past. For the first case unneeded early reply would be sent
to client. For the second, client requests would be dropped by
timeout and client reconnect happend.

Do at_measured() for recovery in the same way like general early
reply base on the current time. And set new timeout to the end
of recovery.

Test to check recovery deadline bug.

The patch also speeds up replay-vbr test 7* by decreasing the
at_max value in test_7_cycle().

This patch is back-ported from the following one:
Lustre-commit: 1d889090f2e2902d861d1fab0227c4343127cc42
Lustre-change: http://review.whamcloud.com/11213

Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes \
mdtfilesystemtype=ldiskfs mdsfilesystemtype=ldiskfs ostfilesystemtype=ldiskfs \
clientdistro=el6 ossdistro=el6 mdsdistro=el6 \
mdtcount=1 mdssizegb=2 ostcount=7 ostsizegb=2 \
testlist=replay-vbr,replay-vbr

Xyratex-bug-id: MRP-1988

Change-Id: I7a5d60ca8e52a805546cc9934eb42bddeaf8ff4e
Signed-off-by: Alexander Boyko <alexander_boyko@xyratex.com>
Signed-off-by: Jian Yu <jian.yu@intel.com>
Reviewed-on: http://review.whamcloud.com/12365
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5287 export: hold exp_lock when modify exp_flags 62/12162/2
Niu Yawei [Thu, 11 Sep 2014 10:57:52 +0000 (06:57 -0400)]
LU-5287 export: hold exp_lock when modify exp_flags

There are few places that changing the exp_flags without holding
exp_lock, that could overwrite other concurrent exp_flags updating.

Lustre-commit: 999fedbd5c18a021064b23933e84e4c92a7f48ac
Lustre-change: http://review.whamcloud.com/11871

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I9c0421ffeacd6bf6feaa31dca9f9fc0e7963bc8b
Reviewed-on: http://review.whamcloud.com/12162
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5150 mdc: Handle empty but non-zero acl xattr 89/11989/3
Christopher J. Morrone [Fri, 19 Sep 2014 01:51:59 +0000 (18:51 -0700)]
LU-5150 mdc: Handle empty but non-zero acl xattr

We have found that posix_acl_access can have a value
of \002\000\000\000.  In that case body->aclsize is
non-zero, but the there are no actuall acls stored
in the xattr.

In mdc_unpack_acl(), it only checks IS_ERR() on the
pointer returned by posix_acl_from_xattr(), it does not
check for NULL.  Because of the above situation, the
xattr aclsize can be non-zero, but posic_acl_from_xattr()
still returns NULL.  Passing NULL to posix_acl_valid()
crashes the kernel.

We add a check to properly handle the NULL return value.

This patch is back-ported from the following one:
Lustre-commit: 867e301972278e397b57094810821ff884092fd8
Lustre-change: http://review.whamcloud.com/10620

Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Change-Id: I76fb2198e7233261ee65c6527d4f2b78f27022bc
Reviewed-on: http://review.whamcloud.com/11989
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5018 libcfs: don't depend on configure for lustre_user.h 40/11840/2
Andreas Dilger [Tue, 9 Sep 2014 23:24:54 +0000 (17:24 -0600)]
LU-5018 libcfs: don't depend on configure for lustre_user.h

Don't depend on configure to detect the presence of <linux/types.h>
in order to define the __u8, __u16, __u32, and __u64 types.  Instead,
just define these types directly if <linux/types.h> is not included
already.

The <linux/types.h> header is available on Linux systems with GCC
installed, which is required to build Lustre anyway.  On non-Linux
systems they should create an appropriate <linux/types.h> compat
header in the include path.

Lustre-change: http://review.whamcloud.com/10258
Lustre-commit: 241cdb8ba008d47fd96f0b6529797ce922e2b635

Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: Ida0915fe1b5829f3378e459c782844cf9df060e6
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/11840
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
9 years agoLU-4629 osd-ldiskfs: Fix use after free 96/12096/2
Niu Yawei [Sun, 28 Sep 2014 08:18:15 +0000 (04:18 -0400)]
LU-4629 osd-ldiskfs: Fix use after free

Object 'dir' was dereferenced at line 3343 after being freed
by calling 'kfree' at line 3332.

Lustre-commit: f4842b027ee57969fa1b01b90d5f23aed18b5eb5
Lustre-change: http://review.whamcloud.com/10609

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I5e27f4555bda6144be5e5fcb9d0f00916512020a
Reviewed-on: http://review.whamcloud.com/12096
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4768 tests: Update ost-survey script 40/12240/5
James Nunez [Wed, 8 Oct 2014 23:46:28 +0000 (17:46 -0600)]
LU-4768 tests: Update ost-survey script

Currently, ost-survey hangs due to calling
'lfs setstripe' in an old (positional) style and
setting max_cached_mb to zero.

The call to 'lfs setstripe' is updated to use the
'-S', '-i' and '-c' flags. max_cached_mb is now
set to pagesize * 256 (in MB). The patch also gets
parameters for the correct file system if more
than one Lustre file system is mounted, and
corrects a few typos in comments.

In ll_max_cached_mb_seq_write(), the number of
pages requested is set to the max of pages requested
or PTLRPC_MAX_BRW_PAGES to allow the client to make
well formed RPCs.

This is a backport to b2_5
Lustre-change: http://review.whamcloud.com/#/c/11971/4
Lustre-commit: 46bec835ac726aa2d06024b197002be7b112e192

with some changes to ost-survey from
Lustre-change: http://review.whamcloud.com/#/c/10534/8
Lustre-commit: fe3ddff77475dd487873e2f873835455aab7aa38

Signed-off-by: James Nunez <james.a.nunez@intel.com>
Change-Id: Ia9f22c19f95b85d14687bdaf70cad05ca3a3f455
Reviewed-on: http://review.whamcloud.com/12240
Tested-by: Jenkins
Reviewed-by: Cliff White <cliff.white@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-5768 target: Revert the test part of the LU-5579 fix 90/12390/2
Li Wei [Wed, 22 Oct 2014 13:31:33 +0000 (21:31 +0800)]
LU-5768 target: Revert the test part of the LU-5579 fix

This patch reverts the test part, including the tgt_enqueue() fault
injection, of the LU-5579 fix (d29c0438).  These changes cause
replay-single 52 and 73b to fail frequently.

Change-Id: I63c9210ddd4165cf587272e4216cd39dc608f976
Signed-off-by: Li Wei <wei.g.li@intel.com>
Reviewed-on: http://review.whamcloud.com/12390
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4624 llite: Avoid statahead thread start/stop deadlocks 82/12182/2
Christopher J. Morrone [Fri, 21 Feb 2014 22:46:47 +0000 (14:46 -0800)]
LU-4624 llite: Avoid statahead thread start/stop deadlocks

The statahead and statahead agl threads blindly set their
thread state to SVC_RUNNING without checking the state first.  If, for
instance, another thread sets the state to SVC_STOPPING that
stop signal will now have been lost.  Deadlock ensues.

We also partly improve the sai reference counting, because a race exists
where the ll_stop_statahead thread can drop the default reference, and
the statahead thread can exit and drop its reference as well.  With no
references on the sai, the final put will poison and free the buffer.  The
original do_statahead_enter() function may then continue to access
the buffer after it is freed because it did not take a reference of its
own.  We add a local reference to address that.

Lustre-commit: 373d937086e5cede6fc1a3b3f859622c0173c1de
Lustre-change: http://review.whamcloud.com/9358

Change-Id: I531f17966d49ba1e6ebd99abe9cb8b128eeac4f9
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/12182
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
9 years agoLU-3188 osc: shorten IO calling path 12/11612/3
Bobi Jam [Mon, 12 May 2014 14:04:23 +0000 (22:04 +0800)]
LU-3188 osc: shorten IO calling path

By using osc_io_unplug_aync() for osc_queue_sync_pages() to shorten
the IO calling path, to reduce the chance of stack overflow.

This is revive of git commit 83ae17df2bdce837e62473aec27c03d67312c8ea.

Lustre-commit: 5bc6be85c7b5434917791f97a199b16f6c8bf533
Lustre-change: http://review.whamcloud.com/10292

Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I2ac32866f7adbc4701370704612c849a18a5d1ac
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/11612
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
9 years agoLU-5240 obdclass: Increase minimum LU Cache for ZFS 02/12002/3
Nathaniel Clark [Sat, 20 Sep 2014 06:50:48 +0000 (23:50 -0700)]
LU-5240 obdclass: Increase minimum LU Cache for ZFS

If the lu cache is too small threads will thrash for data including
the OI tables and other important metadata.

This patch is back-ported from the following one:
Lustre-commit: a9c51c03eaecb5234ba754b738877323a35bed51
Lustre-change: http://review.whamcloud.com/10802

Test-Parameters: alwaysuploadlogs \
mdtfilesystemtype=zfs mdsfilesystemtype=zfs ostfilesystemtype=zfs \
testgroup=review-zfs

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: Ia6c85f523219706b5d41054c869e73ed5bf3c2f5
Reviewed-on: http://review.whamcloud.com/12002
Tested-by: Jenkins
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Tested-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5164 osd: Limit lu_object cache 01/12001/3
Brian Behlendorf [Sat, 20 Sep 2014 06:43:56 +0000 (23:43 -0700)]
LU-5164 osd: Limit lu_object cache

For OSDs like ZFS to perform optimally it's import that they be allowed
to manage their own cache.  This maximizes the likelyhood that the ARC
will prefetch and cache the right buffers.  In the existing ZFS OSD
code a cached LU object pins buffers in the ARC preventing them from
being dropped.  As the LU cache grows it can consume the entire ARC
preventing buffers for other objects, such as the OIs, from being
cached and severely impacting the performance for FID lookups.

By default this patch will only limit the LU cache for ZFS OSDs.

NOTES:

* Setting LU_CACHE_NR_ZFS_LIMIT to 0 results in an LBUG on the MDS.
  This may be because an object is being used without a reference.
  Setting a minimum value of 256 was arbitrary, ideally we would
  set this value to 0.

* In order to be able to quickly determine the number of objects in
  the hash table the CFS_HASH_COUNTER flag is added.  This adds an
  atomic_inc/dec to the hash insert/remove paths but is not expected
  to have any measurable impact of performance.

This patch is back-ported from the following one:
Lustre-commit: 0123baecc4e2050447f8c4f48f5b33a6d3c524a8
Lustre-change: http://review.whamcloud.com/10237

Test-Parameters: alwaysuploadlogs \
mdtfilesystemtype=zfs mdsfilesystemtype=zfs ostfilesystemtype=zfs \
testgroup=review-zfs

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Change-Id: If573f02175a02abeeb100ed74f3109e629d4c392
Reviewed-on: http://review.whamcloud.com/12001
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Isaac Huang <he.huang@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4349 target: count disconnected exports as stale
Mikhail Pershin [Thu, 9 Jan 2014 16:01:19 +0000 (20:01 +0400)]
LU-4349 target: count disconnected exports as stale

If export is disconnected during recovery then stale client
counter need to be increased.

Test-Parameters: envdefinitions=SLOW=yes testlist=conf-sanity,conf-sanity,conf-sanity,conf-sanity,conf-sanity
Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Change-Id: Id4f2a668dbe8d5cd2fa3d392b7df7b4d67a4265a
Reviewed-on: http://review.whamcloud.com/8785
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: wangdi <di.wang@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5579 ldlm: re-sent enqueue vs lock destroy race
Vitaly Fertman [Mon, 29 Sep 2014 23:42:32 +0000 (19:42 -0400)]
LU-5579 ldlm: re-sent enqueue vs lock destroy race

upon lock enqueue re-send, lock is pinned by ldlm_handle_enqueue0,
however it may race with client eviction or even lcok cancel (if
a reply for the original RPC finally reached the client) and the
lock cann be found by cookie anymore:

 ASSERTION( lock != NULL ) failed: Invalid lock handle

Signed-off-by: Vitaly Fertman <vitaly_fertman@xyratex.com>
Change-Id: I9d8156bf78a1b83ac22ffaa1148feb43bef37b1a
Xyratex-bug-id: MRP-2094

9 years agoLU-5530 mdt: Properly match open lock and unlock
Oleg Drokin [Mon, 29 Sep 2014 23:42:02 +0000 (19:42 -0400)]
LU-5530 mdt: Properly match open lock and unlock

It seems that when request resend with a corresponding lock match is
in play (thanks to large striping + llnl patch for the client to send
small requests only), after all the suffering and fixing coming from
LU-2827, here is another casualty in in open/lease locking.
mdt_reint_open() and mdt_open_by_fid_lock() might match the lock
on resend and not call mdt_object_open_lock(), yet call
mdt_object_open_unlock() before exit.
Since mdt_object_open_lock/unlock also plays with a semaphore,
hilarity ensues usually most visible as a rw_sem lockup
in mdt_object_open_lock.

This patch adds tracking whenever we actually called mdt_object_open_lock
or not and only calls mdt_object_open_unlock if we did.

Change-Id: I73c529229acec98cac4ad73f7b487e759ad9a763
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5496 ldlm: reconstruct proper flags on enqueue resend 86/12186/4
Vitaly Fertman [Mon, 29 Sep 2014 23:25:47 +0000 (19:25 -0400)]
LU-5496 ldlm: reconstruct proper flags on enqueue resend

otherwise, waiting lock may get granted as no BLOCKED_GRANTED
flag is returned

Lustre-commit: 175ce732b881e99d77d3f5c11fd1d0d5f604218a
Lustre-change: http://review.whamcloud.com/11644

Signed-off-by: Vitaly Fertman <vitaly_fertman@xyratex.com>
Xyratex-bug-id: MRP-1944
Change-Id: I5e938ff0454d5e8694b09f9fff3c1f82d746360d
Reviewed-on: http://review.whamcloud.com/11644
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5266 ldlm: granting the same lock twice on recovery
Vitaly Fertman [Mon, 29 Sep 2014 23:21:21 +0000 (19:21 -0400)]
LU-5266 ldlm: granting the same lock twice on recovery

ASSERTION( lock->l_granted_mode != lock->l_req_mode ) is hit
when resending LDLM_FL_REPLAY.

Don't add lock to waiting list as it is already added or granted.

Lustre-commit : 63851b5816bb30687fbf3750380d6b448e9400f1
Lustre-change: http://review.whamcloud.com/10903

Change-Id: Ib8e5d2c7588f6cacd1723529e70d29f63742caad
Xyratex-bug-id: MRP-1944
Signed-off-by: Andriy Skulysh <Andriy_Skulysh@xyratex.com>
Signed-off-by: Vitaly Fertman <vitaly_fertman@xyratex.com>
Reviewed-on: http://review.whamcloud.com/10903
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Tested-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
9 years agoLU-2827 ldlm: wrong handling of ldlm resends 92/10492/4
Vitaly Fertman [Mon, 29 Sep 2014 23:13:25 +0000 (19:13 -0400)]
LU-2827 ldlm: wrong handling of ldlm resends

If a successful reply is lost for an intent
lock request, MDS will not correctly recover
from this situation on resend. Instead, a new
lock is created.

Lustre-commit: I9a23c13313d5168d0c232fdc0acbdab330089356
Lustre-change: http://review.whamcloud.com/5978

This patch also adds handling of resend during layout-lock

Lustre-commit: Ideb551779a884d77ded8036c513f62557b2dfcde
Lustre-change: http://review.whamcloud.com/#/c/10378

Change-Id: I6745461b2a1370837be7bcbff12dc021cd1021cf
Signed-off-by: Vitaly Fertman <vitaly_fertman@xyratex.com>
Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Signed-off-by: James Simmons <uja.ornl@gmail.com>
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5051 hsm: do not reallocate hsm receive buffer 16/10716/3
Frank Zago [Thu, 22 May 2014 18:27:56 +0000 (13:27 -0500)]
LU-5051 hsm: do not reallocate hsm receive buffer

Instead of allocating 1MB for every call to
llapi_hsm_copytool_recv, allocate that buffer once in
llapi_hsm_copytool_register. The application must not call
llapi_hsm_copytool_recv until it has cleared the data from
the previous call, which lhsmtool_posix already does. This
also make llapi_hsm_action_list_free unnecessary.

Lustre-change: http://review.whamcloud.com/10299
Lustre-commit: 76dca841869d87df2b625cb9d186d531c406fc9b

Signed-off-by: Patrick Farrell <paf@cray.com>
Signed-off-by: Frank Zago <fzago@cray.com>
Change-Id: Ie9e15a5cb4e3ba6d3fe23d40ee2bb47330280abf
Reviewed-on: http://review.whamcloud.com/10299
Tested-by: Jenkins
Reviewed-by: Faccini Bruno <bruno.faccini@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>
(cherry picked from commit 76dca841869d87df2b625cb9d186d531c406fc9b)
Reviewed-on: http://review.whamcloud.com/10716
Tested-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5385: HSM: do not call the JSON log function if no log is open 17/11617/2
Frank Zago [Sat, 19 Jul 2014 14:21:10 +0000 (09:21 -0500)]
LU-5385: HSM: do not call the JSON log function if no log is open

llapi_hsm_log_ct_registration() and llapi_hsm_log_ct_progress() are
very expensive (fid2path+allocations). Do not let them do anything
if llapi_hsm_write_json_event() is going to discard the JSON record.

Make llapi_hsm_log_ct_registration() and llapi_hsm_log_ct_progress()
static too.

This is a backport to b2_5.

Lustre-change: http://review.whamcloud.com/11164
Lustre-commit: 35d122fd99c961b0b9fd500b3a78bdc0f5334a97

Signed-off-by: frank zago <fzago@cray.com>
Change-Id: Ib10023968a1bd021694bca6338c0a962f58da19a
Reviewed-on: http://review.whamcloud.com/11164
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Reviewed-by: Patrick Farrell <paf@cray.com>
Reviewed-by: Faccini Bruno <bruno.faccini@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
(cherry picked from commit 35d122fd99c961b0b9fd500b3a78bdc0f5334a97)
Reviewed-on: http://review.whamcloud.com/11617
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-4086 tests: strengthen sanity-hsm/test_33 12/10712/2
Bruno Faccini [Wed, 12 Mar 2014 13:12:33 +0000 (14:12 +0100)]
LU-4086 tests: strengthen sanity-hsm/test_33

Instead of waiting+checking both Restore and Cancel HSM operations
sequentially, wait for both to be finished and then check each
results. This will allow to handle conditions where Restore
terminates before the Cancel is started.

Also added to wait_all_done() the capability to only work on
requests for a specific fid.

Lustre-change: http://review.whamcloud.com/9600
Lustre-commit: adc6a5e76348d9bb1c8355103f419405a14decca

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: I480ce074513d6829ecb3078c273bac1fdffa6256
Reviewed-on: http://review.whamcloud.com/9600
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Aurelien Degremont <aurelien.degremont@cea.fr>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
(cherry picked from commit adc6a5e76348d9bb1c8355103f419405a14decca)
Reviewed-on: http://review.whamcloud.com/10712

9 years agoLU-5195: hsm: delete HSM records not found on disk 19/11619/2
Frank Zago [Mon, 11 Aug 2014 23:24:07 +0000 (18:24 -0500)]
LU-5195: hsm: delete HSM records not found on disk

After a MDS crash, it is possible the file containing an hsm record is
not present anymore. When the MDS restarts, we get traces like this:

(mdt_hsm_cdt_actions.c:104:cdt_llog_process()) tas01-MDT0000:
    failed to process HSM_ACTIONS llog (rc=-2)
(mdt_hsm_cdt_actions.c:104:cdt_llog_process())
    Skipped 600 previous similar messages
(llog_cat.c:192:llog_cat_id2handle()) tas01-MDD0000:
    error opening log id 0x1c:1:0: rc = -2
(llog_cat.c:192:llog_cat_id2handle()) Skipped 600 previous similar messages
(llog_cat.c:556:llog_cat_process_cb()) tas01-MDD0000:
    cannot find handle for llog 0x1c:1: -2
(llog_cat.c:556:llog_cat_process_cb()) Skipped 600 previous similar messages
(mdt_hsm_cdt_actions.c:104:cdt_llog_process()) tas01-MDT0000:
    failed to process HSM_ACTIONS llog (rc=-2)
(mdt_hsm_cdt_actions.c:104:cdt_llog_process())
    Skipped 600 previous similar messages
(llog_cat.c:192:llog_cat_id2handle()) tas01-MDD0000:
    error opening log id 0x1c:1:0: rc = -2
(llog_cat.c:192:llog_cat_id2handle()) Skipped 600 previous similar messages

No HSM operation can happen, and the only way to clean is to unmount
the MDT and delete hsm_actions.

If the record can't be found, let the MDS delete it instead.

This is a backport to b2_5.

Lustre-change: http://review.whamcloud.com/11419
Lustre-commit: 3a83b4b93373db46a4ee60a7388775fa0be2eb9a

Change-Id: I61f625d4c18750c8044909ff56d53042cf0b6d86
Signed-off-by: frank zago <fzago@cray.com>
Reviewed-on: http://review.whamcloud.com/11419
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Ryan Haasken <haasken@cray.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
(cherry picked from commit 3a83b4b93373db46a4ee60a7388775fa0be2eb9a)
Reviewed-on: http://review.whamcloud.com/11619
Reviewed-by: Patrick Farrell <paf@cray.com>
9 years agoLU-5299 obdclass: avoid race during Server device start
Bruno Faccini [Fri, 18 Jul 2014 11:34:33 +0000 (13:34 +0200)]
LU-5299 obdclass: avoid race during Server device start

Handle concurrent starts for same device (multiple mounts, ...).
But allows for separate nosvc and nomgs case.
Also add a specific test of concurent MDT/OST start with an
artificial delay to verify.

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: I442819a5b865ed3e98477f9d2602efc4d09d7860
Reviewed-on: http://review.whamcloud.com/11139
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-1279 kernel: Fix concurrent module loading deadlocks
Li Wei [Fri, 25 Jul 2014 16:14:51 +0000 (00:14 +0800)]
LU-1279 kernel: Fix concurrent module loading deadlocks

Concurrently starting multiple OSTs on a single OSS frequently
triggers 30s deadlocks on module_mutex.  This RHEL 6 kernel bug
applies to any module that results in additional request_module()
calls in its init callback.  In Lustre, at least ptlrpc and libcfs are
affected.  (RHEL 7 should have enough fixes in this area, but testing
needs to be done.)  This patch adds a fix adapted from a number of
upstream commits to the RHEL 6 kernel patch series.

Change-Id: Ibdd384fd7622a0b4fcbf4cb5fdb864de87fcc25e
Signed-off-by: Li Wei <wei.g.li@intel.com>
Reviewed-on: http://review.whamcloud.com/11229
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
9 years agoLU-5428 libcfs: false alarm of libcfs watchdog
Liang Zhen [Tue, 12 Aug 2014 14:36:42 +0000 (22:36 +0800)]
LU-5428 libcfs: false alarm of libcfs watchdog

lc_watchdog_disable will not delete kernel timer, benefit of this
is no overhead of del_timer in each serivce loop, however, there
is a corner case that lc_watchdog_touch can race with lcw_cb when
service thread is actually idle:

1. service thread armed a timer before processing request, after
   it handled request, it called lc_watchdog_disable() and set
   lc_watchdog as disabled, but kernel timer is still outstanding.
2. service thread slept for many seconds because there is no
   request to handle
3. it's waken up by incoming request
4. it called lc_watchdog_touch and set watchdog status to enabled.
   now because timer is still alive, if timer is expired right
   before cfs_timer_arm(), then lcw_cb will set a disabled watchdog
   as "expired", which is wrong.
5. the next call of lc_watchdog_disable will complain for expired
   watchdog.

There are two options to fix this issue:
1. always del_timer in lc_watchdog_disable, however, it may increase
   system overhead when service threads are busy.
2. set watchdog as "enabled" after cfs_timer_arm, so there is no
   window for lcw_cb to see false status of watchdog.

This patch chooses the second approach to fix the problem

Signed-off-by: Liang Zhen <liang.zhen@intel.com>
Change-Id: Iac24082e2d63de8330285cf243ed585da6524ab9
Reviewed-on: http://review.whamcloud.com/11415
Tested-by: Jenkins
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5405 llog: add newly opened llog at tail of handle list
Li Xi [Mon, 25 Aug 2014 08:56:29 +0000 (16:56 +0800)]
LU-5405 llog: add newly opened llog at tail of handle list

Add newly opened llog handle at the tail of handle list to increase
lookup speed, especially for cancel operation, because the canceled
log will be removed from the list, and lookup is from the beginning.

Signed-off-by: Lai Siyao <lai.siyao@intel.com>
Signed-off-by: Li Xi <lixi@ddn.com>
Change-Id: I4c5c22901ea5818a8ee50ef97d6dabe4839b9a74
Reviewed-on: http://review.whamcloud.com/11575
Tested-by: Jenkins
Reviewed-by: Ian Costello <costello.ian@gmail.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Conflicts:
lustre/obdclass/llog_cat.c

9 years agoLU-4933 osc: Automatically increase the max_dirty_mb 37/10937/2
Li Xi [Wed, 2 Jul 2014 03:07:20 +0000 (11:07 +0800)]
LU-4933 osc: Automatically increase the max_dirty_mb

When RPC size or the max RPCs in flight is increased, the actual
limit might be max_dirty_mb. This patch automatically increases
the max_dirty_mb value at connection time and when the related
values are tuned manually by proc file system.

This patch also changes the unit of "cl_dirty" and "cl_dirty_max"
in client_obd from byte to page.

Lustre-change: http://review.whamcloud.com/10446/
Lustre-commit: bdc5bb52c55470cf8020933f80e327c397810603

Signed-off-by: Li Xi <lixi@ddn.com>
Signed-off-by: Hongchao Zhang <hongchao.zhang@intel.com>
Change-Id: I8480122b7370247b17de81d731c2f2b5f67892ce
Reviewed-on: http://review.whamcloud.com/10937
Tested-by: Jenkins
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
9 years agoLU-4855 fld: refer to MDT0 for fld lookup in some cases 80/11780/2
wang di [Wed, 2 Apr 2014 16:57:00 +0000 (09:57 -0700)]
LU-4855 fld: refer to MDT0 for fld lookup in some cases

It is possible that when fld client is trying to lookup seq
on one of MDT, but the connection between the client and the MDT
is not being initialized yet, especially during striped dir creation,
because client will only send create req to the master MDT, then
master MDT will distribute the operation to all of other MDT, instead
of client distributing these requests, which will usually trigger
the connection.

In this case, we will send the fld request to MDT0, since it has
all of location information.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I577ada2a782ecbdc863d05e8d007c0914a1e7837
Reviewed-on: http://review.whamcloud.com/9877
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/11780

9 years agoLU-5144 mdt: rename vs link deadlock 18/10918/6
Rahul Deshmukh [Sat, 30 Aug 2014 00:21:59 +0000 (17:21 -0700)]
LU-5144 mdt: rename vs link deadlock

it may happen that tgt child for rename is a directory, which is used
as tgt dir for link in parallel, as the result rename locks src child,
tgt child what may deadlock with tgt dir, src file locking of link.

As not dir cannot replace dir, check it before locking the tgt child.

Lustre-commit: b2c2cfc24fa461b3e54cd204a697eeee9a89d49c
Lustre-change: http://review.whamcloud.com/10570/

Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes,ONLY=55 \
ossjob=lustre-b2_4 mdsjob=lustre-b2_4 ossbuildno=73 mdsbuildno=73 \
testlist=sanityn

Signed-off-by: Vitaly Fertman <vitaly_fertman@xyratex.com>
Signed-off-by: Rahul Deshmukh <rahul_deshmukh@xyratex.com>
Change-Id: I09e96b132d9069d4818e8dc2628c903eff38e53d
Reviewed-on: http://review.whamcloud.com/10918
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-4725 mdt: child-parent lock ordering in rename 15/11615/3
Rahul Deshmukh [Sat, 30 Aug 2014 00:11:07 +0000 (17:11 -0700)]
LU-4725 mdt: child-parent lock ordering in rename

change rename so that it always has parent-child lock ordering,
otherwise it may deadlock with other operations.

Lustre-commit: 4e308ef74f271ec7e19917e3c0f88586537582c3
Lustre-change: http://review.whamcloud.com/9538/

LU-4725 obd: lu_object_find_at hung

lu_object_find_at hungs if called 2 times and object is removed
in between. It makes mdt_rename_sanity not workable for rename.
Change mdt_rename_sanity to work on existing object.

Lustre-commit: b7c72ec1ddeda2cf94ea151f974d3f94e3a7d1ed
Lustre-change: http://review.whamcloud.com/10484/

Test-Parameters: alwaysuploadlogs \
envdefinitions=SLOW=yes,ENABLE_QUOTA=yes,ONLY=54 \
ossjob=lustre-b2_4 mdsjob=lustre-b2_4 ossbuildno=73 mdsbuildno=73 \
testlist=sanityn

Signed-off-by: Rahul Deshmukh <rahul_deshmukh@xyratex.com>
Signed-off-by: Vitaly Fertman <vitaly_fertman@xyratex.com>
Change-Id: Ic9ce52bfcd8788834347fba155cc8c6be674dcd8
Reviewed-on: http://review.whamcloud.com/11615
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5114 utils: Fix autoconf warning 05/12005/2
Nathaniel Clark [Mon, 22 Sep 2014 12:58:55 +0000 (08:58 -0400)]
LU-5114 utils: Fix autoconf warning

Fix mount_osd_ldiskfs_LDADD autoconf warning.  This corrects a fix
left out of commit 0d77156572c2b77581f01d960c0e5738b369de6a.

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: I2815f093951c215a8c92678348444cbd18297e25
Reviewed-on: http://review.whamcloud.com/12005
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5040 osd: fix osd declare credit for quota 97/11097/7
Bobi Jam [Mon, 14 Jul 2014 05:51:05 +0000 (13:51 +0800)]
LU-5040 osd: fix osd declare credit for quota

osd_attr_set() always calls ll_vfs_dq_init() to initialize dquot for
the inode, while in some cases osd_declare_attr_set() does not reserve
credit for it.

This patch fixes this issue. This patch also corrects the quota credit
accounting in osd_declare_qid() by judging whether the inode's
i_dquot[quota_type] has been allocated, while old code judgement is
based on the file uid/gid existence, which is not correct.

Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Change-Id: I16555cb1097e1a3e75cdcb4852a2c5e1772ddd88
Reviewed-on: http://review.whamcloud.com/11097
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoRevert "LU-3489 osd-zfs: varsize index support"
Oleg Drokin [Fri, 26 Sep 2014 01:02:55 +0000 (21:02 -0400)]
Revert "LU-3489 osd-zfs: varsize index support"

This seems to be causing LU-5649

This reverts commit d9e627c09ccc5c22aa10704020fb9f45bcf26ed0.

9 years agoLU-5349 include: use __vmalloc() to avoid __GFP_FS default 39/11739/2
Bruno Faccini [Wed, 3 Sep 2014 09:09:34 +0000 (11:09 +0200)]
LU-5349 include: use __vmalloc() to avoid __GFP_FS default

When possible, try to Direct use of __vmalloc() which allows
for protection flag specification, and particularly to not
set __GFP_FS, which can cause some deadlock situations in our
code.

This patch is the b2_5 back-port of :
Lustre-commit: 635421641bfa8a412edebd4ffbbdf05fd0c47410
Lustre-change: http://review.whamcloud.com/11190/

Also corrects a typo in __OBD_VMALLOC_VERBOSE name.

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: I588ebf27d1ff7538745b732d174696c379107ea3
Reviewed-on: http://review.whamcloud.com/11739
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5610 tests: Handle quoted module options 07/11907/2
Stephen Champion [Sat, 13 Sep 2014 03:23:45 +0000 (20:23 -0700)]
LU-5610 tests: Handle quoted module options

When test-framework.sh translates module options to environment
variables for remote nodes, quotes should be escaped to the subshell.

This patch is back-ported from the following one:
Lustre-commit: 4597789df0b6b9fcc7bcbe5529adab3522f0e6ac
Lustre-change: http://review.whamcloud.com/11887

Signed-off-by: Stephen Champion <schamp@sgi.com>
Change-Id: I02daf5ca36170ea901f6b0e4e5152cf4835945dc
Signed-off-by: Jian Yu <jian.yu@intel.com>
Reviewed-on: http://review.whamcloud.com/11907
Tested-by: Jenkins
Reviewed-by: Stephen Champion <that.schamp@gmail.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5600 kernel: kernel update RHEL6.5 [2.6.32-431.29.2.el6] 38/11838/2
Bob Glossman [Tue, 9 Sep 2014 19:59:10 +0000 (12:59 -0700)]
LU-5600 kernel: kernel update RHEL6.5 [2.6.32-431.29.2.el6]

Update RHEL6.5 kernel to 2.6.32-431.29.2.el6

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I4832cf12cb49eebd1c81fc4e07a53d0a1315500d
Reviewed-on: http://review.whamcloud.com/11838
Tested-by: Jenkins
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5612 osd: typo in osd_declare_write() 89/11889/2
Niu Yawei [Fri, 12 Sep 2014 03:30:05 +0000 (23:30 -0400)]
LU-5612 osd: typo in osd_declare_write()

Some bits are lost when porting the fix of LU-4611
3902ff4c54925b2f1fcb732a32ed7ee5428e9f77

That could result in insufficient credits in certain situation.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I828a75c674978278b5adaf210586baa177ea0dc9
Reviewed-on: http://review.whamcloud.com/11889
Tested-by: Jenkins
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@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>
9 years agoLU-5434 mdd: disregard empty POSIX ACLs
Ned Bass [Thu, 31 Jul 2014 22:07:32 +0000 (15:07 -0700)]
LU-5434 mdd: disregard empty POSIX ACLs

Some files may have a POSIX ACL consisting of only a struct
posix_acl_xattr_header, resulting in unexpected permission errors.
Update mdd_check_acl() to return -EAGAIN when such ACLs are
encountered so the caller falls back to standard UNIX
permissions.

These empty ACLs originate from tools like cp. In some cases (e.g.
'cp -rp') just POSIX_ACL_XATTR_VERSION is given as the value of the
system.posix_acl_default extended attribute.  Lustre accepts and
stores this value on disk, and the bad default ACL then propagates
from directories to newly created directory entries.  Separate
patches will prevent the storage of these bad ACLs.  This patch
mitigates problems caused by the ones already stored.

Other minor updates:
- Use the kernel function posix_acl_xattr_count() to count the
  number of ACL entries.
- Convert remainder of mdd_check_acl() to TAB indentation.

Signed-off-by: Ned Bass <bass6@llnl.gov>
Change-Id: Ib4f7b3874696b7645b9de3f1f10ef45dc4105646
Reviewed-on: http://review.whamcloud.com/11300
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
9 years agoLU-5150 acl: 'cp -rp' set empty default ACL
Lai Siyao [Mon, 30 Jun 2014 13:33:25 +0000 (21:33 +0800)]
LU-5150 acl: 'cp -rp' set empty default ACL

'cp -rp' will set an empty default ACL on target, MDD should treat
this as removing specified ACL.

add sanity 103c to verify this.

Signed-off-by: Lai Siayo <lai.siyao@intel.com>
Change-Id: I2b6947e241675c291a43999e6324bbb295d3c88d
Reviewed-on: http://review.whamcloud.com/11158
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Li Wei <wei.g.li@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>