Whamcloud - gitweb
fs/lustre-release.git
11 years agoLU-1486 tests: fix sanityn test_45g() to add error check
Yu Jian [Thu, 30 Aug 2012 06:50:10 +0000 (14:50 +0800)]
LU-1486 tests: fix sanityn test_45g() to add error check

This patch fixes sanityn test_45g() to add error check for
"stat must fail".

Signed-off-by: Yu Jian <yujian@whamcloud.com>
Change-Id: Iff65f2684244ab58e0d0cab68db0795f5604187e
Reviewed-on: http://review.whamcloud.com/3826
Tested-by: Hudson
Reviewed-by: Wei Liu <wei3.liu@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-661 tests: don't check file-2 in replay-dual 0b
Mikhail Pershin [Tue, 22 Nov 2011 06:59:26 +0000 (10:59 +0400)]
LU-661 tests: don't check file-2 in replay-dual 0b

It is uncertain was it replayed on not yet, so it might exist
and test will fail. Remove wrong check from test

Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Change-Id: I724f389f0504f3c8c388b2b271b3a64cb61339ab
Reviewed-on: http://review.whamcloud.com/4999
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
11 years agoLU-2416 test: Some test using wrong lctl params
James Simmons [Mon, 7 Jan 2013 17:55:42 +0000 (12:55 -0500)]
LU-2416 test: Some test using wrong lctl params

With the move of obdfilter to ofd some of the lctl
parameters got moved around. For the test suite a function
{get,set}_obdfilter_param was written to handle this change so
this patch updates a few more test to use this api.

Signed-off-by: James Simmons <uja.ornl@gmail.com>
Change-Id: I05ca4711b198061de1378b79d2f7f35d5a1c75af
Reviewed-on: http://review.whamcloud.com/4726
Reviewed-by: Li Wei <wei.g.li@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2158 fsfilt: Remove bits from fsfilt_ext3.c/lustre_fsfilt.h
Prakash Surya [Tue, 18 Dec 2012 22:15:38 +0000 (14:15 -0800)]
LU-2158 fsfilt: Remove bits from fsfilt_ext3.c/lustre_fsfilt.h

The only remaining dependency needed from the fsfilt_ext3.c for use in
osd-ldiskfs is the fsfilt_ext3_map_inode_pages function. Thus much of
the fsfilt_ext3.c contents have been removed by this commit because
they are no longer used.

Also, since much of the fsfilt_operations structure is not used anymore,
that structure was trimmed to the bare essentials needed by the
osd-ldiskfs layer. The related inline helper functions were also removed.

Change-Id: Ie0f7d428d15862b1b17df140b7152cb0b56ce3be
Signed-off-by: Prakash Surya <surya1@llnl.gov>
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/4863
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2158 lvfs: Remove cruft from lvfs_linux.h
Prakash Surya [Wed, 19 Oct 2011 19:01:08 +0000 (12:01 -0700)]
LU-2158 lvfs: Remove cruft from lvfs_linux.h

Various bits from the lvfs_linux.h file were removed as they are no
longer used. Specifically, the following was removed:

 * l_inode
 * lvfs_sbdev_sync
 * lvfs_set_rdonly
 * lvfs_clear_rdonly
 * lvfs_dentry_params

Change-Id: I993a1416bb548746ca717904a483c0cd6245768e
Signed-off-by: Prakash Surya <surya1@llnl.gov>
Reviewed-on: http://review.whamcloud.com/4862
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
11 years agoLU-2158 lvfs: Remove ll_sleep from linux/lvfs.h
Prakash Surya [Wed, 19 Oct 2011 17:55:37 +0000 (10:55 -0700)]
LU-2158 lvfs: Remove ll_sleep from linux/lvfs.h

The ll_sleep function was removed because it is not used anywhere.

Change-Id: Ic22552c69635f3da5b2cdd3dd67b9930d63a48d1
Signed-off-by: Prakash Surya <surya1@llnl.gov>
Reviewed-on: http://review.whamcloud.com/4861
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
11 years agoLU-2158 lvfs: Remove ll_fid2str from lvfs.h
Prakash Surya [Wed, 19 Oct 2011 17:47:41 +0000 (10:47 -0700)]
LU-2158 lvfs: Remove ll_fid2str from lvfs.h

The ll_fid2str function was removed because it is not used anywhere.

Change-Id: I7e16b3d5e2fa10af0d5763909a42871a8c86a3ff
Signed-off-by: Prakash Surya <surya1@llnl.gov>
Reviewed-on: http://review.whamcloud.com/4860
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
11 years agoLU-2618 test: recovery-small test_24b dumps dmesg
Kyrylo Shatskyy [Tue, 15 Jan 2013 22:22:45 +0000 (00:22 +0200)]
LU-2618 test: recovery-small test_24b dumps dmesg

Redirected output of 'dmesg -c' to null device

Signed-off-by: Kyrylo Shatskyy <kyrylo_shatskyy@xyratex.com>
Change-Id: I6b06122e4c9600aac6da476f7083c1e051d92c98
Reviewed-on: http://review.whamcloud.com/5033
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Keith Mannthey <keith.mannthey@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2590 lod: magic changed after swab
Bobi Jam [Fri, 11 Jan 2013 04:08:30 +0000 (12:08 +0800)]
LU-2590 lod: magic changed after swab

In lod_qos_parse_config(), the stack magic variable should be changed
to native endianness as well.

Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Change-Id: I940c40f20f1ec55d7b55eeffe8d61404a1badfdb
Reviewed-on: http://review.whamcloud.com/4996
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
11 years agoLU-2558 test: recovery-small 19a FAIL no eviction
yangsheng [Thu, 10 Jan 2013 13:15:39 +0000 (21:15 +0800)]
LU-2558 test: recovery-small 19a FAIL no eviction

Use stat instead of mcreate since latter cannot
ensure enqueue a lock.

Signed-off-by: yang sheng <ys@whamcloud.com>
Change-Id: Ifb63f679305e707df64457c4de599ca1b5fb0f00
Reviewed-on: http://review.whamcloud.com/4987
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Hudson
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1270 utils: properly initialize traverse param
James Simmons [Wed, 12 Dec 2012 15:57:41 +0000 (10:57 -0500)]
LU-1270 utils: properly initialize traverse param

The find_param::mdtindex intialization was neglected.

Signed-off-by: James Simmons <uja.ornl@gmail.com>
Signed-off-by: Bobi Jam <bobijam@whamcloud.com>
Change-Id: I3018c346a4bbab0d7da7c7efdeeb201098ac1e53
Reviewed-on: http://review.whamcloud.com/2411
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-2309 config: ignore unknown configuration param
Jian Yu [Wed, 16 Jan 2013 06:37:35 +0000 (14:37 +0800)]
LU-2309 config: ignore unknown configuration param

Client or server should not fail to mount if it hits
a configuration parameter that it doesn't understand.
This patch fixes class_process_config() to meet
the above requirement.

The patch also improves conf-sanity test 42 to verify
that invalid sys config param should not prevent client
or server from mounting.

Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I33a6eb3c2beb3dd7425a097e8e7b5a2766852a96
Reviewed-on: http://review.whamcloud.com/5037
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2336 llog: hide the harmless log message
Hongchao Zhang [Sun, 13 Jan 2013 13:15:49 +0000 (21:15 +0800)]
LU-2336 llog: hide the harmless log message

in llog_cat_add_rec, the llog_write_rec could return -ENOSPC
if the current log is full, and it will move to the next log
file, then it should not be treated as an error.

Change-Id: Ie2e203dc01572e170e9a383c63dcc670db093355
Signed-off-by: Hongchao Zhang <hongchao.zhang@whamcloud.com>
Reviewed-on: http://review.whamcloud.com/5146
Tested-by: Hudson
Reviewed-by: Prakash Surya <surya1@llnl.gov>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-2158 lvfs: Remove functions from lvfs_linux.c
Prakash Surya [Tue, 18 Dec 2012 21:19:02 +0000 (13:19 -0800)]
LU-2158 lvfs: Remove functions from lvfs_linux.c

The following functions were removed from the lvfs_linux.c file as they
are no longer used:

 * simple_mknod
 * lustre_fread
 * lustre_fwrite
 * lustre_fsync
 * l_filldir
 * l_readdir
 * l_notify_change
 * simple_truncate
 * lvfs_check_io_health

Change-Id: I6684815c85e87974277295e6906fd6d7c8dfe1be
Signed-off-by: Prakash Surya <surya1@llnl.gov>
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/4859
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-2644 build: fix 'resource leak' errors
Sebastien Buisson [Fri, 18 Jan 2013 15:00:40 +0000 (16:00 +0100)]
LU-2644 build: fix 'resource leak' errors

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

Signed-off-by: Sebastien Buisson <sebastien.buisson@bull.net>
Change-Id: I9fae1905848a83393b7258449bfafd1fc0a342a7
Reviewed-on: http://review.whamcloud.com/5131
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Keith Mannthey <keith.mannthey@intel.com>
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-744 clio: save memory allocations for cl_page
Jinshan Xiong [Thu, 20 Dec 2012 02:07:45 +0000 (18:07 -0800)]
LU-744 clio: save memory allocations for cl_page

It used to allocate 6 piece of memory to create a page:
 - top cl_page, llite & lov page slice;
 - subpage, lovsub_page & osc_page.

This patch will allocate top cl_page, llite and lov page slice in
the same piece of memory, similar to sub pages, so that only 2
memory allocations will be needed for each page.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: I1c4dd0541bda23e7d739131f73bcd895b8dd2c13
Reviewed-on: http://review.whamcloud.com/4943
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-1199 build: Assume that ldiskfs PDO is now standard
Christopher J. Morrone [Fri, 11 Jan 2013 23:35:00 +0000 (15:35 -0800)]
LU-1199 build: Assume that ldiskfs PDO is now standard

PDO (Parallel Directory Operations) is now a standard ldiskfs feature.
The old patch series files that lacked PDO support have been removed
from the tree, so now we can drop all of the places that conditionally
use PDO, and just assume that PDO is standard.

Also remove support for rhel5 series file in ldiskfs, since that
no longer exists in the tree.

Change-Id: I76b5b31a4614c1ade3b4b5890a111cdabc4afa63
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/5004
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Liang Zhen <liang.zhen@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
11 years agoLU-1095 debug: Quiet/cleanup various common console messages
Brian Behlendorf [Fri, 19 Feb 2010 22:39:40 +0000 (14:39 -0800)]
LU-1095 debug: Quiet/cleanup various common console messages

Turn off several common message we always observe when restarting
servers assuming they are for the expected return code.  Simply
move others which are not helpful to an administrator to the
internal debug kernel log.  Less noise means you are more likely
to spot the important error messages.

Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Signed-off-by: Prakash Surya <surya1@llnl.gov>
Change-Id: I523eacfe3c72480d62c915537427aa6c99428647
Reviewed-on: http://review.whamcloud.com/2201
Tested-by: Hudson
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1199 build: Remove autoMakefile.am.toplevel
Christopher J. Morrone [Tue, 18 Dec 2012 19:31:28 +0000 (11:31 -0800)]
LU-1199 build: Remove autoMakefile.am.toplevel

Now that ldiskfs no longer shares lustre's build system,
there is no need for the added complication of
the autoMakefile.am.toplevel file.  We move its contents
into the actual top level autoMakefile.am file.

Change-Id: Ie2787465f1b60146dd44c2e4564e236782de1afa
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/4975
Tested-by: Hudson
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
11 years agoLU-2361 quota: quiet warning when acct isn't enabled
Johann Lombardi [Tue, 8 Jan 2013 09:34:32 +0000 (10:34 +0100)]
LU-2361 quota: quiet warning when acct isn't enabled

Don't print a warning to the console on every mount when space
accounting is disabled.

Signed-off-by: Johann Lombardi <johann.lombardi@intel.com>
Change-Id: I7e1855c21f509b755c0452824eefe1084a1c33f1
Reviewed-on: http://review.whamcloud.com/4968
Tested-by: Hudson
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-1199 build: Simplify autotools version checks
Christopher J. Morrone [Wed, 28 Nov 2012 04:55:57 +0000 (20:55 -0800)]
LU-1199 build: Simplify autotools version checks

Simplify the check for minumum autoconf and automake
versions by using standard macros in configure.ac
rather than using shell functions in autogen.sh.

Note that I am bumping the minimum automake version
from 1.9 to 1.10.

Change-Id: I009c316a54d8d517abea0d1808dc244e2353b2aa
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/4693
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Brian J. Murrell <brian.murrell@intel.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
11 years agoLU-2602 tests: add missing bug number to error_ignore call
Bob Glossman [Fri, 11 Jan 2013 01:07:40 +0000 (17:07 -0800)]
LU-2602 tests: add missing bug number to error_ignore call

error_ignore called with the wrong number of arguments
led to a corrupted and hard to interpret test log

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: I6d2150eaa3c1b8cf044ddafd40d66cd64bb25314
Reviewed-on: http://review.whamcloud.com/4995
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
Reviewed-by: Keith Mannthey <keith.mannthey@intel.com>
11 years agoLU-1812 mgs: assign PTR_ERR() to prevent warnings
chas williams - CONTRACTOR [Tue, 8 Jan 2013 15:06:18 +0000 (10:06 -0500)]
LU-1812 mgs: assign PTR_ERR() to prevent warnings

Some newer kernels fail with the "error: ignoring return value of
'PTR_ERR', declared with attribute warn_unused_result".

Signed-off-by: chas williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Change-Id: I94ff7d8371e2daf7440dd5fb295c209ed671bc74
Reviewed-on: http://review.whamcloud.com/4971
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Peng Tao <bergwolf@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-2607 mdd: preserve input arguments in mdd_create()
Alex Zhuravlev [Thu, 17 Jan 2013 07:43:08 +0000 (11:43 +0400)]
LU-2607 mdd: preserve input arguments in mdd_create()

all input arguments are supposed to stay as is so that
the caller can re-use them again.

Signed-off-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Change-Id: Ie2be78e702bfa9b7febafe7d106f09beccbf48d3
Reviewed-on: http://review.whamcloud.com/5048
Reviewed-by: wangdi <di.wang@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2563 tests: Print correct names in mgsdevname()
Li Wei [Fri, 4 Jan 2013 03:55:18 +0000 (11:55 +0800)]
LU-2563 tests: Print correct names in mgsdevname()

Current mgsdevname() prints names of block devices (or files for loop
devices) regardless of MGS back end types.  This is plainly a
violation of what the function is expected to do.  If an MGS is
ZFS-based, mgsdevname() should print the dataset name instead of the
VDev names.  This patch fixes the regression and makes sure that
mgsdevname() and mgsvdevname() work for both standalone and
MDT-combined MGSs.

Signed-off-by: Li Wei <wei.g.li@intel.com>
Change-Id: I5885af48e811fcd98aa00c5d901db30e5837b505
Signed-off-by: Li Wei <wei.g.li@intel.com>
Reviewed-on: http://review.whamcloud.com/4950
Tested-by: Hudson
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: wangdi <di.wang@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2587 quota: bump version after migration
Niu Yawei [Tue, 8 Jan 2013 10:39:56 +0000 (05:39 -0500)]
LU-2587 quota: bump version after migration

The global index version should be bumped to 2 if migration
happened, otherwise, the global index copy version on slave will
be same as the global index's (both equal to 1 after creation),
and the migrated limits will fail to be reintegrated.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: I2d596a33e2eb4495dfbb7bd63d37199297a9b214
Reviewed-on: http://review.whamcloud.com/4969
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
Tested-by: Hudson
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2072 ldiskfs: Leak of s_mb_prealloc_table in ldiskfs
Bruno Faccini [Thu, 10 Jan 2013 14:27:25 +0000 (15:27 +0100)]
LU-2072 ldiskfs: Leak of s_mb_prealloc_table in ldiskfs

ext4-prealloc-rhel[5,6] patches adds kmalloc'ed
sbi->s_mb_prealloc_table field which is never freed
in [ldiskfs,ext4]_mb_release()/ext4-vmalloc-rhel[5,6].patch

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: I0ca3ff1e7ae8daa0260cd070c5ac52c843248a1b
Reviewed-on: http://review.whamcloud.com/4683
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2321 debug: Quiet uninitialized target connects
Prakash Surya [Tue, 20 Nov 2012 21:04:03 +0000 (13:04 -0800)]
LU-2321 debug: Quiet uninitialized target connects

When a target is not fully initialized and receives a connection
attempt, it will refuse the connection and print a message to the
console stating this fact. This is "normal operation", so rather
than using LCONSOLE_WARN to convey this information, this patch
modifies it to use CDEBUG.

Signed-off-by: Prakash Surya <surya1@llnl.gov>
Change-Id: Ia5d098fcfe2ad9ae2a1406166087db8181496a7d
Reviewed-on: http://review.whamcloud.com/4640
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1665 libcfs: alignment of hsb_head[0] can be suboptimal
chas williams - CONTRACTOR [Fri, 10 Aug 2012 19:21:10 +0000 (15:21 -0400)]
LU-1665 libcfs: alignment of hsb_head[0] can be suboptimal

On ia64, hsb_head[0] of struct cfs_hash_bucket could be aligned to a
4-byte boundary.  However, after allocating the hash bucket and
casting, the first member of the struct pointed to by hsb_head[0]
might prefer an 8-byte alignment.  This causes a constant stream
of unaligned access warnings from the kernel.

For other cpus this might waste some small amount of space, but
potentially produces more natural alignments (8 byte objects on 8
byte boundaries).

Signed-off-by: chas williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Change-Id: I4561ab3e6553b5dcef840b8e4e9aa3023b7c3586
Reviewed-on: http://review.whamcloud.com/4965
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Hudson
Reviewed-by: Keith Mannthey <keith.mannthey@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-1961 build: fix 'dereference before null check' errors
Sebastien Buisson [Tue, 18 Sep 2012 07:13:41 +0000 (09:13 +0200)]
LU-1961 build: fix 'dereference before null check' errors

Fix 'dereference before null check' defects found by Coverity version
6.0.3:
Dereference before null check (REVERSE_INULL)
Null-checking variable suggests that it may be null, but it has
already been dereferenced on all paths leading to the check.

Signed-off-by: Sebastien Buisson <sebastien.buisson@bull.net>
Change-Id: I0c1be27ea443865fcb7640976839d95d0dc07b9a
Reviewed-on: http://review.whamcloud.com/4023
Tested-by: Hudson
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Keith Mannthey <keith.mannthey@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1187 lmv: allocate lmv tgts array by index
wangdi [Fri, 1 Nov 2013 12:50:24 +0000 (05:50 -0700)]
LU-1187 lmv: allocate lmv tgts array by index

Allocate lmv tgts array by MDT index, which is similar as lov
tgts arrary, so the index of tgts will be decided by MDT index,
instead of mount sequence in current implementation.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: If4903553251e1dba653aa79fb02bce581580629f
Reviewed-on: http://review.whamcloud.com/4936
Tested-by: Hudson
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-1187 lod: Fix config log and setup process for DNE
wangdi [Fri, 8 Nov 2013 11:43:32 +0000 (03:43 -0800)]
LU-1187 lod: Fix config log and setup process for DNE

OSP will be used for local proxy client for remote MDT,
and LOD will be used to manage these OSPs.

1. Add DNE config log in mgs.
2. Lod_add_device will reorganize MD OSP and add them.
3. In osp_init0 and remove some unnecessary init stuff
for MD OSP.
4. Check whether osp is on OST or on MDT during client
setup.
5. Only stop MDT0--osp--MDT0 in lustre_disconnect_osp,
and other OSPs on MDT will be stoped in mdt stack
cleanup.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I1c8e24edbb95d638500dacd2f9a4e423f1007170
Reviewed-on: http://review.whamcloud.com/4922
Tested-by: Hudson
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-1187 lod: reorganize lod_ost
wangdi [Fri, 8 Nov 2013 11:42:23 +0000 (03:42 -0800)]
LU-1187 lod: reorganize lod_ost

Move lod_ost to lod_tgt_desc, so LOD can be used
to manage OSP for both MDT and OST.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I01c8033ba53e6729bfb62588306f48073f505b17
Reviewed-on: http://review.whamcloud.com/4921
Tested-by: Hudson
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2433 lnet: enable asymmetric router failure detection
Emoly Liu [Fri, 7 Dec 2012 01:56:34 +0000 (09:56 +0800)]
LU-2433 lnet: enable asymmetric router failure detection

Asynmmetric router failure detection is disabled by default,
it's helpful to enable it by default.
The original change is at https://github.com/chaos/lustre/
commit/872bfc41cc858a6c01cae3648e0ca329a414a436

Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Signed-off-by: Emoly Liu <emoly.liu@intel.com>
Change-Id: I259e00911cdf3d7caecb98c9832d40a91b571596
Reviewed-on: http://review.whamcloud.com/4753
Reviewed-by: Isaac Huang <he.huang@intel.com>
Reviewed-by: Liang Zhen <liang.zhen@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2555 fsfilt: fix race in ldiskfs_ext_new_extent_cb
Niu Yawei [Sat, 5 Jan 2013 09:00:27 +0000 (04:00 -0500)]
LU-2555 fsfilt: fix race in ldiskfs_ext_new_extent_cb

In ldiskfs_ext_calc_credits_for_insert(), we should use the 'depth'
stored in the 'path' instead from inode, because the extent tree
could have been changed when ldiskfs_ext_calc_credits_for_insert()
is called (by ldiskfs_ext_new_extent_cb()).

Signed-off-by: Niu Yawei <niu@whamcloud.com>
Change-Id: I04dada849a71228980501ab7eb1cc9ab71ca3782
Reviewed-on: http://review.whamcloud.com/4957
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-709 build: remove old BGL support option
Christopher J. Morrone [Mon, 17 Dec 2012 19:39:21 +0000 (11:39 -0800)]
LU-709 build: remove old BGL support option

Remove the old and obsolete --enable-bgl configure option.
Lustre no longer supports the old kernel that BG/L systems
use, and we do not use this opton on the later BG/P and
BG/Q systems.

Change-Id: Iea0b893fd67fe5242fa65ebc8993c1f2b0863ae6
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/4841
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
11 years agoLU-1018 tests: reduce runtime value for compilebench
Minh Diep [Thu, 17 Jan 2013 15:57:41 +0000 (07:57 -0800)]
LU-1018 tests: reduce runtime value for compilebench

We are reducing the cbench_IDIRS and cbench_RUNS to 2.
These variables can be adjusted to other runs beside
sanity check.

Test-Parameters: envdefinitions=SLOW=yes,ENABLE_QUOTA=yes testlist=parallel-scale
Signed-off-by: Minh Diep <minh.diep@intel.com>
Change-Id: If03f7b5a71eb8a4b4b380638af872a012f9cdac5
Reviewed-on: http://review.whamcloud.com/5052
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1722 llite: LTP fcntl14 test fails on a SMP host
Andriy Skulysh [Fri, 3 Aug 2012 08:51:44 +0000 (11:51 +0300)]
LU-1722 llite: LTP fcntl14 test fails on a SMP host

Release Lustre flock in case of local locking failure

Xyratex-bug-id: MRP-447
Reviewed-by: Vitaly Fertman <vitaly_fertman@xyratex.com>
Reviewed-by: Andrew Perepechko <andrew_perepechko@xyratex.com>
Signed-off-by: Andriy Skulysh <Andriy_Skulysh@xyratex.com>
Change-Id: I27e4627461756442713077344bcefeb3841d594a
Reviewed-on: http://review.whamcloud.com/3565
Reviewed-by: Keith Mannthey <keith.mannthey@intel.com>
Tested-by: Hudson
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2511 procfs: Disallow secretly (un)writable proc entries
John L. Hammond [Wed, 19 Dec 2012 22:54:31 +0000 (16:54 -0600)]
LU-2511 procfs: Disallow secretly (un)writable proc entries

Add an assert to lprocfs_seq_create() to ensure that proc entries
implementing write have user writable modes.  Fix a few callers to
pass this assertion.

Signed-off-by: John L. Hammond <jhammond@tacc.utexas.edu>
Change-Id: I95d08106f7d9be478c29d7331cdf5ab607435889
Reviewed-on: http://review.whamcloud.com/4871
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Keith Mannthey <keith.mannthey@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1445 lod: Add FLD lookup to LOD
wangdi [Thu, 26 Sep 2013 01:35:37 +0000 (18:35 -0700)]
LU-1445 lod: Add FLD lookup to LOD

1. Adding FLD in LOD can make it getting the OST index
of the real FID when setting stripEA(l_ost_index) to
the file. Then the client can still use l_ost_index
in stripeEA to locate OST, by which the old client can
still access OST after FID_on_OST is landed.

2. Init sequence client for OSP.

Signed-off-by: Wang Di <di.wang@intel.com>
Change-Id: I559edfd02feb08f32156c7237ec75fe6dde681e3
Reviewed-on: http://review.whamcloud.com/5047
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoNew tag 2.3.59 2.3.59 v2_3_59 v2_3_59_0
Oleg Drokin [Sat, 19 Jan 2013 02:10:49 +0000 (21:10 -0500)]
New tag 2.3.59

Change-Id: I66aeac610981cafd226fe77386044f04d3b65b8c
Signed-off-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1187 tests: Add mntfmt/mntcount/mdtcount to mdsrate
wangdi [Mon, 19 Nov 2012 13:38:26 +0000 (05:38 -0800)]
LU-1187 tests: Add mntfmt/mntcount/mdtcount to mdsrate

Add mntfmt, mntcount and mdtcount to parameters of mdsrate, so
it can do multiple mount or DNE tests.

Signed-off-by: wang di <di.wang@whamcloud.com>
Change-Id: Ie3859ab13ef1ed680e645883611c5f8c9ea4e4a5
Reviewed-on: http://review.whamcloud.com/4614
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1187 dne: add remote dir check in replay-vbr.
wangdi [Sun, 18 Nov 2012 21:37:44 +0000 (13:37 -0800)]
LU-1187 dne: add remote dir check in replay-vbr.

Add remote dir check in replay-vbr.

Change-Id: Ia955703a45c1fe63439d0cbe893b73bb12a77305
Signed-off-by: Wang Di <di.wang@whamcloud.com>
Reviewed-on: http://review.whamcloud.com/4321
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
11 years agoLU-1187 lmv: Locate right MDT in lmv.
wangdi [Fri, 1 Nov 2013 12:27:11 +0000 (05:27 -0700)]
LU-1187 lmv: Locate right MDT in lmv.

1.Add fid in md_revalidate_lock for locate mdt in
do_statahead_interpret.
2.locate right mdc for FID2PATH.
3.Only validating MDT0 connection for statfsi during Mount,
so even some MDTs are not avaible, the system can still be
setup.

Signed-off-by: Wang Di <di.wang@intel.com>
Change-Id: I40a3dcbe1f87cd38386ea360547dd2b4528645d1
Reviewed-on: http://review.whamcloud.com/4356
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
11 years agoLU-2509 quota: various code cleanups
Johann Lombardi [Tue, 18 Dec 2012 21:54:54 +0000 (22:54 +0100)]
LU-2509 quota: various code cleanups

Address some cleanups that were mentioned during code inspection.

Signed-off-by: Johann Lombardi <johann.lombardi@intel.com>
Change-Id: I3cab9c0e6bfefef0d717e542f6620cc167075937
Reviewed-on: http://review.whamcloud.com/4855
Tested-by: Hudson
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2470 procfs: Remove unused lu_time code.
John L. Hammond [Tue, 11 Dec 2012 19:47:00 +0000 (13:47 -0600)]
LU-2470 procfs: Remove unused lu_time code.

Remove lu_time.{c,h}, the unused wrappers for the functions defined
therein, and the stats file /proc/fs/lustre/mdt/*/site_time.

Signed-off-by: John L. Hammond <jhammond@tacc.utexas.edu>
Change-Id: Id45b12efd06134048a96f4b0ba92eaa4fce0b55d
Reviewed-on: http://review.whamcloud.com/4802
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Keith Mannthey <keith.mannthey@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2349 osp: Move log ops init to module init.
wangdi [Fri, 16 Nov 2012 19:16:29 +0000 (11:16 -0800)]
LU-2349 osp: Move log ops init to module init.

Because osp_mds_ost_orig_logops and changelog_orig_logops
will be shared by all of the llog ctxt for all OSPs/MDDs
on one node, if we keep changing that during obd_setup
process, the loc_logops might be changed, i.e. lop_add
and lop_declare_add might become zero for a while. So if
other healthy device(like another osp) tried to delcare_add
or add record during the time, it will get ENOTSUPP.(especially
for DNE). So the ops initialization should move to module init.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I1e46d2163c2431c43c369adb7b3c16e664260a4e
Reviewed-on: http://review.whamcloud.com/4608
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1187 mdt: enqueue rename lock locally for phase I.
wangdi [Mon, 12 Nov 2012 14:39:25 +0000 (06:39 -0800)]
LU-1187 mdt: enqueue rename lock locally for phase I.

Because cross-rename is not permitted in phase I, it only
needs to enqueue rename lock locally for phase I.

Change-Id: I954a6c7c5ab914df4b756c6eae4fc0bfddad8e6b
Signed-off-by: wang di <di.wang@intel.com>
Reviewed-on: http://review.whamcloud.com/4355
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
11 years agoLU-2397 recovery: check queue_len > 0 in check_for_next_transno
Mikhail Pershin [Fri, 11 Jan 2013 07:21:10 +0000 (11:21 +0400)]
LU-2397 recovery: check queue_len > 0 in check_for_next_transno

The check_for_next_transno rely on obd_req_replay_clients is unable
to change during that function call, it is not true.

Patch makes sure that case with zero queue_len is excluded and
check for obd_req_replay_clients is 0 after comparing with queue_len

Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Change-Id: I0b81e0f8e6a4f2cbfd51b6a049ee273cec4732a2
Reviewed-on: http://review.whamcloud.com/4998
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1716 test: Test holder for b2_1 only test.
Keith Mannthey [Wed, 28 Nov 2012 01:05:13 +0000 (17:05 -0800)]
LU-1716 test: Test holder for b2_1 only test.

A b2_1 only test is needed. Add it as a comment so as not to
reuse it in the future.

Signed-off-by: Keith Mannthey <keith.mannthey@intel.com>
Change-Id: I3caf15d1369e73b8104194561b73929561d2dfe9
Reviewed-on: http://review.whamcloud.com/4690
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
11 years agoLU-1756 kernel: cleanup lustre_compat25.h
Peng Tao [Thu, 16 Aug 2012 07:59:21 +0000 (15:59 +0800)]
LU-1756 kernel: cleanup lustre_compat25.h

1. unused functions:
   ll_bdi_wb_cnt()
2. call bdi_init/bdi_destroy directly
3. call add_to_page_cache_lru directly
4. fix a typo of ll_pagevec_init

Signed-off-by: Peng Tao <tao.peng@emc.com>
Change-Id: I0ce799bc5aad70279a652cf911b9880abcc74194
Reviewed-on: http://review.whamcloud.com/4656
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
11 years agoLU-2158 lvfs: Remove cruft from lvfs directory
Prakash Surya [Tue, 18 Dec 2012 19:44:39 +0000 (11:44 -0800)]
LU-2158 lvfs: Remove cruft from lvfs directory

Some of the unnecessary cruft from within the lvfs directory was
removed by this change. Specifically, the following changes were
made:

 * Removed files:
    * Info.plist
    * lvfs_darwin.c
    * lvfs_internal.h
    * lvfs_userfs.c
 * Cleaned up the autoMakefile.am and Makefile.in files to reflect the
   removed files.

Change-Id: Icc7189912415e96b81dde384491c1948fa4ef06a
Signed-off-by: Prakash Surya <surya1@llnl.gov>
Signed-off-by: Christopher J. Morrone <morrone2@llnl.gov>
Reviewed-on: http://review.whamcloud.com/4858
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
11 years agoLU-1434 utils: Add better handling for normal lustre packets
Nathaniel Clark [Tue, 18 Dec 2012 17:08:04 +0000 (12:08 -0500)]
LU-1434 utils: Add better handling for normal lustre packets

This fixes handling for Lustre packets (lustre 2.1) for more packet
types and fixes some packet types that were being mis-interpreted.

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: Ib6fcf99a93efc41a0cad3457da8009522c68d248
Reviewed-on: http://review.whamcloud.com/4852
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Doug Oucharek <doug.s.oucharek@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2183 quota: quota tests for DNE
Niu Yawei [Fri, 4 Jan 2013 10:16:47 +0000 (05:16 -0500)]
LU-2183 quota: quota tests for DNE

Added two quota tests for DNE:
- test_7e: inode limits reintegration;
- test_12b: inode quota rebalancing;

Signed-off-by: Niu Yawei <niu@whamcloud.com>
Change-Id: I1a262496bde318da062ef1f4558f4160737dd12b
Reviewed-on: http://review.whamcloud.com/4952
Tested-by: Hudson
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
11 years agoLU-1445 fid: start ptlrpc service for OST FID
wangdi [Tue, 24 Sep 2013 19:32:05 +0000 (12:32 -0700)]
LU-1445 fid: start ptlrpc service for OST FID

Start FID service on OST for FID on OST.

Change-Id: I58b36e052a2f09fc6707107f805176dcdca7e86a
Signed-off-by: Wang Di <di.wang@whamcloud.com>
Reviewed-on: http://review.whamcloud.com/4328
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Tested-by: Hudson
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
11 years agoLU-1430 mgs: "replace_nids" lctl command added
Artem Blagodarenko [Thu, 30 Aug 2012 12:35:57 +0000 (16:35 +0400)]
LU-1430 mgs: "replace_nids" lctl command added

Currently after device address is changed tunefs
should be started with "writeconf" options. This
erase configuration logs for the filesystem that
this server is part of, and regenerate them. This
is very dangerous. All clients must be unmounted
and servers  for  this filesystem should be stopped.
All targets (OSTs/MDTs) must then be restarted to
regenerate the logs.  No clients should be started
until all targets have restarted. The targets start
order is also important. Wrong order can be cause
of failure.

This patch adds "replace_nids" command to lctl
that should be executed when only MGS server
started. This command replace nids and uuid for
given device. Command can be used to change
OST or MDT nids.

Xyratex-bug-id: MRP-397
Reviewed-by: Alexey Lyashkov <alexey_lyashkov@xyratex.com>
Reviewed-by: Nathan Rutman <nathan.rutman@xyratex.com>
Signed-off-by: Artem Blagodarenko <artem_blagodarenko@xyratex.com>
Change-Id: I74b72281ce3b5e48188735035e58250596a16bf7
Reviewed-on: http://review.whamcloud.com/2896
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2531 osc: evict extents in trunc whatever happens
Jinshan Xiong [Thu, 27 Dec 2012 20:47:38 +0000 (12:47 -0800)]
LU-2531 osc: evict extents in trunc whatever happens

In osc_cache_truncate_start(), we should ignore the return code
of osc_extent_wait() because initiator will handle it and truncate
should continue in anyways.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: Iaae1228d0f1c488c5deaf938761715ee3984ac3d
Reviewed-on: http://review.whamcloud.com/4896
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
Tested-by: Oleg Drokin <green@whamcloud.com>
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-676 tests: machinefile option for mpirun via a variable
Jay J. Lan [Tue, 18 Oct 2011 19:04:07 +0000 (12:04 -0700)]
LU-676 tests: machinefile option for mpirun via a variable

Not all MPI implementations pass the host file to mpirun via the same
option. Common options are -machinefile and -hostfile.

This problem can be resolved by using a variable MACHINEFILE_OPTION
instead. A default value is assigned if the variable not defined.

Signed-off-by: Jay J Lan <jay.j.lan@nasa.gov>
Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Change-Id: I3362a6e62a27318cff733aea2f99b1356b3ff02e
Reviewed-on: http://review.whamcloud.com/3873
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1187 lmv: remove obsolete lmv object.
wangdi [Thu, 31 Oct 2013 06:33:38 +0000 (23:33 -0700)]
LU-1187 lmv: remove obsolete lmv object.

lmv object is intended to handle spliting directory, which
is obsolete for current DNE infrastructure.

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I5337d497451f6869bc67474b0cd7d74bde01a172
Reviewed-on: http://review.whamcloud.com/5011
Tested-by: Hudson
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1445 fid: Add DATA fid type in fid_request.
wangdi [Thu, 26 Sep 2013 02:11:47 +0000 (19:11 -0700)]
LU-1445 fid: Add DATA fid type in fid_request.

1. Add data fid type in fid request on client side.
2. When MDT request fids to the OST, if it is not
ready for fid allocation yet. i.e. not being connected
to MDT0 yet, it will return -EINPROGRESS, and MDT will
try again.
3. Remove obsolete obd_fid_init/fini in llite.

Signed-off-by: wang di <di.wang@whamcloud.com>
Change-Id: I54d97d5c84a5b38ebeae77522bd8666206ef2701
Reviewed-on: http://review.whamcloud.com/4787
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
11 years agoLU-1876 hsm: layout lock implementation on server side
Jinshan Xiong [Thu, 6 Dec 2012 17:34:15 +0000 (09:34 -0800)]
LU-1876 hsm: layout lock implementation on server side

* enabled OBD_CONNECT_LAYOUTLOCK both on client and mdt
* mdt_object_lock_try() is implemented to try layout lock
* dlm flag LDLM_FL_BLOCK_NOWAIT is added to implement nonblock mode
  dlm lock enqueue
* try layout lock for IT_GETATTR and IT_OPEN
* make layout lock work
* add layout intent support.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: I84a6dfca83ded2344240fa5430c9922b7cfc7bcf
Reviewed-on: http://review.whamcloud.com/4417
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: wangdi <di.wang@intel.com>
Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2263 ptlrpc: deadlock of obd_import::imp_lock
Liang Zhen [Fri, 21 Dec 2012 06:27:57 +0000 (14:27 +0800)]
LU-2263 ptlrpc: deadlock of obd_import::imp_lock

ptlrpc_at_recv_early_reply() calls ptlrpc_at_set_req_timeout() with
hold of ptlrpc_request::rq_lock, and
ptlrpc_at_set_req_timeout()->import_at_get_index() requires imp_lock,
it violates locking-order rule of Lustre, which assumes rq_lock can
nest in imp_lock.

Signed-off-by: Liang Zhen <liang@whamcloud.com>
Change-Id: I924839b59ca1fa1cdf01568872de867ce3985f8b
Reviewed-on: http://review.whamcloud.com/4880
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
11 years agoLU-1187 tests: Add parallel sanity tests to dne
wangdi [Fri, 7 Dec 2012 16:38:35 +0000 (08:38 -0800)]
LU-1187 tests: Add parallel sanity tests to dne

1. Add parallel sanity tests(dne_sanity) to run sanity
tests on different directories at the same time.

2. Add PARALLEL check line in sanity to skip some tests which
are unable to run parallel.

3. Do not check multiop in run_one when multiple sanity
is running.

4. In test_105, replace DIR with MOUNT to check flock option.

Test-Parameters: envdefinitions=SLOW=yes testlist=sanity,dne_sanity
Signed-off-by: Wang Di <di.wang@whamcloud.com>
Change-Id: If2386e5465c2067059fb72c5fc95ac690ddd3fa4
Reviewed-on: http://review.whamcloud.com/4318
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
11 years agoLU-1187 tests: Add dne specific tests to sanityN
wangdi [Sun, 18 Nov 2012 21:30:16 +0000 (13:30 -0800)]
LU-1187 tests: Add dne specific tests to sanityN

1. Change mkdir to test_mkdir for DNE.
2. 2f: Check attr and ownder update under remote dir.
3. 25b: Acl checking under remote dir.
4. 33b: commit on share under remote dir.
5. 4[0-7]: Check remote dir with pdir lock.
6. 70: cd dir and rm -rf dir.

Change-Id: I9b752d8663287db55bd07a5ce132c397749ade4d
Signed-off-by: Wang Di <di.wang@whamcloud.com>
Reviewed-on: http://review.whamcloud.com/4366
Tested-by: Hudson
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-1445 ofd: Add fid support on OFD
wangdi [Tue, 24 Sep 2013 09:59:57 +0000 (02:59 -0700)]
LU-1445 ofd: Add fid support on OFD

1. Init fid server related structure in OFD, which will
become a sequence metaserver, i.e. MDT will request sequence
from OST(OFD), OFD will request super sequence from MDT0

2. OST FID sequence width will be 4 billion, which is different
with MDS FID.

Change-Id: If861cf5814ea77ce72464525a8de71ac182d742c
Signed-off-by: Wang Di <di.wang@whamcloud.com>
Reviewed-on: http://review.whamcloud.com/4326
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-1445 ofd: set index during server_data_init
wangdi [Tue, 15 Oct 2013 04:40:21 +0000 (21:40 -0700)]
LU-1445 ofd: set index during server_data_init

Get mdt/ost index from obd_name, and set it in
server_data_init.

Signed-off-by: wang di <di.wang@whamcloud.com>
Change-Id: I62466f3bcadb738b4182db90773e83361d6963e9
Reviewed-on: http://review.whamcloud.com/4918
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Hudson
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-1445 fld: change md_site to seq_server_site
wangdi [Fri, 27 Sep 2013 15:14:10 +0000 (08:14 -0700)]
LU-1445 fld: change md_site to seq_server_site

Change md_site to seq_server_site, so both Metadata and data
stack will use this structure for sequence service.

Signed-off-by: wang di <di.wang@whamcloud.com>
Change-Id: I1f9c835d7006c4d336153c9bf8cac7d6fc729def
Reviewed-on: http://review.whamcloud.com/4805
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-1445 ofd: remove ofd_seq_count and add ocd_seq
wangdi [Tue, 24 Sep 2013 09:47:06 +0000 (02:47 -0700)]
LU-1445 ofd: remove ofd_seq_count and add ocd_seq

Remove ofd_seq_count from the disk, so ofd_seq will
not be initialized during setup,  only be created during
connection or reconnection.

Change-Id: I6dad9aa960897f46afb0a5ea96d8330a227f36e4
Signed-off-by: Wang Di <di.wang@whamcloud.com>
Reviewed-on: http://review.whamcloud.com/4325
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-1445 osd: replace OFD_GROUP0_LAST_OID with [seq, 0]
wangdi [Tue, 24 Sep 2013 09:45:31 +0000 (02:45 -0700)]
LU-1445 osd: replace OFD_GROUP0_LAST_OID with [seq, 0]

Replace OFD_GROUP0_LAST_OID with [seq, 0], so LAST_ID of each
sequence will be identified by [seq,0].

Change-Id: Ieca4eb0cf367e59b6fca044367e4c7e223f79025
Signed-off-by: Wang Di <di.wang@whamcloud.com>
Reviewed-on: http://review.whamcloud.com/4324
Tested-by: Hudson
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2367 osc: unplug IO queue for writeback anyway
Jinshan Xiong [Thu, 22 Nov 2012 22:31:36 +0000 (14:31 -0800)]
LU-2367 osc: unplug IO queue for writeback anyway

osc_io_unplug_async() in osc_extent_release() may not unplug IO
queue due to a race in ptlrpc_queue_work(). As a fix, we should
unplug it when the page is being flushed or fsync calls.

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: Ied1d6ad12b79a28229cdae83a9db9ad9b3189462
Reviewed-on: http://review.whamcloud.com/4659
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Prakash Surya <surya1@llnl.gov>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2543 llite: wait osc cleanup when put super
Niu Yawei [Fri, 4 Jan 2013 09:35:07 +0000 (04:35 -0500)]
LU-2543 llite: wait osc cleanup when put super

Since osc is now accessing sbi->ll_cache, we'd wait till all OSCs
are gone when put super.

Signed-off-by: Niu Yawei <niu@whamcloud.com>
Change-Id: I5d09b29cda28d4b596f67bdf8da2ce5e7082a38e
Reviewed-on: http://review.whamcloud.com/4951
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2494 tests: obdfilter/*/mds_sync: Found no match
Bob Glossman [Fri, 21 Dec 2012 19:34:33 +0000 (11:34 -0800)]
LU-2494 tests: obdfilter/*/mds_sync: Found no match

Revise test-framework to look for new variable *osp*/old_sync_processed
instead of obsolete variable */mds_sync.

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: Ie219f17fae3b49caf52394aff16a6b7d58840ade
Reviewed-on: http://review.whamcloud.com/4885
Reviewed-by: Minh Diep <minh.diep@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
11 years agoLU-2109 llog: introduce llog handle refcounter
Mikhail Pershin [Wed, 5 Dec 2012 11:57:20 +0000 (15:57 +0400)]
LU-2109 llog: introduce llog handle refcounter

llog handle is allocated by llog_open and freed by llog_close,
meawhile there is 'backdoor' to get already opened handle - it is
llog_cat_id2handle() function, it can find handle in the list. That
leads to possible use-after-free.

llog_refcount was introduced to solve this.
- llog_alloc_handle() set refcount to 1
- llog_handle_put() drops refcount and free handle if refcount == 0
- llog_cat_i2handle() takes extra reference
- llog_handle_put() must be called if handle was taken by
  llog_cat_id2handle()
- llog_free_handle() calls llog_handle_put() at the end.

Additional changes in patch:
- llog_cat_init_and_process() processes llogs without fork, making
  sure that server will not start until all old llogs are cancelled.
- llog_cat_cancel_records() doesn't break cycle if handle is not
  found but continue to check other handles
- wrong GOTO() parameter in llog_close. Should be 'rc = -EOPNOTSUPP'
  but not just '-EOPNOTSUPP'.
- indentation fixes.

Signed-off-by: Mikhail Pershin <tappro@whamcloud.com>
Change-Id: I0dd0a934eb79c63c6726902540132ad877183d10
Reviewed-on: http://review.whamcloud.com/4745
Tested-by: Hudson
Reviewed-by: Li Wei <wei.g.li@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Prakash Surya <surya1@llnl.gov>
11 years agoLU-941 hsm: Manage dirty flag for hsm-archived files
Aurelien Degremont [Mon, 19 Dec 2011 13:55:05 +0000 (14:55 +0100)]
LU-941 hsm: Manage dirty flag for hsm-archived files

clio manages a LLIF_DATA_MODIFIED flag when file data are modified
which is sent to MDT. It now has a way to know file data was modified
and can update HS_DIRTY flag in LMA which is mandatory for Lustre/HSM
binding.
When HS_DIRTY is set, a changelog event is raised.

Signed-off-by: Aurelien Degremont <aurelien.degremont@cea.fr>
Change-Id: I074c8db0d6c10341aaabc55441fe746497259e84
Reviewed-on: http://review.whamcloud.com/1891
Tested-by: Hudson
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoRevert "LU-2469 tests: use MDS/OSTDEV and MDS/OSTDEVBASE with zfs"
Oleg Drokin [Thu, 10 Jan 2013 15:42:44 +0000 (10:42 -0500)]
Revert "LU-2469 tests: use MDS/OSTDEV and MDS/OSTDEVBASE with zfs"

This broke zfs completely apparently

This reverts commit d25e7654f798060f6b671c3b65949a70b8c67f58.

11 years agoLU-657 test: limit the write size in run_dd
Hongchao Zhang [Mon, 31 Dec 2012 19:32:25 +0000 (03:32 +0800)]
LU-657 test: limit the write size in run_dd

1, in run_dd.sh, limit the write size of dd according to
   the free disk space currently intead of using fixed value.

2, fix a bug in ofd_tnx_stop_cb, which cleared the 'thandle->th_sync'

Test-Parameters: envdefinitions=SLOW=yes clientcount=4 osscount=2 mdscount=2 austeroptions=-R failover=true useiscsi=true testlist=recovery-mds-scale
Signed-off-by: Hongchao Zhang <hongchao.zhang@whamcloud.com>
Change-Id: I8b9cc2fc8b9831e5ad79b521ba7af4ae9160143f
Reviewed-on: http://review.whamcloud.com/4599
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-1187 osd: allocate osd_compat_objid_seq dynamically
wangdi [Tue, 24 Sep 2013 09:16:38 +0000 (02:16 -0700)]
LU-1187 osd: allocate osd_compat_objid_seq dynamically

1. Allocate osd_compat_objid_seq dynamically, so osd can load
as many as seq it wants.
2. Change group to seq.
3. remove the compat from name, because we will still use
the same disk-layout for FID on OST.

Change-Id: I52d40ecd805aa44074838496e44ed2b71fd39f92
Signed-off-by: Wang Di <di.wang@whamcloud.com>
Reviewed-on: http://review.whamcloud.com/4323
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Hudson
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
11 years agoLU-2275 mdt: Avoid setting positive dispositions too early
Oleg Drokin [Mon, 5 Nov 2012 05:21:06 +0000 (00:21 -0500)]
LU-2275 mdt: Avoid setting positive dispositions too early

mdt_finish_open and mdt_open_by_fid_lock set DISP_LOOKUP_POS
and DISP_OPEN_OPEN a bit too eagerly only to have later code add
negative disposition and a lookup error, confusing a client
with such self-contradicting replies in the end.

This patch only sets positive dispositions when we are sure
not to get them overruled.

Change-Id: I3389f1d59b21f4a9e4c16ca75b398785ea6e130c
Signed-off-by: Oleg Drokin <green@whamcloud.com
Reviewed-on: http://review.whamcloud.com/4459
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: wangdi <di.wang@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-1187 ofd: Allocate ofd group dynamically.
wangdi [Tue, 24 Sep 2013 08:06:42 +0000 (01:06 -0700)]
LU-1187 ofd: Allocate ofd group dynamically.

Allocate the OFD sequence maps dynamically, so that the OST can
handle an arbitrary number of MDTs or WBC clients, and potentially
multiple streams of object allocations from each MDT.

Signed-off-by: Wang Di <di.wang@whamcloud.com>
Change-Id: Id5f8e5bf4f3dcbe3ba228144c7542bdd3cfef20c
Reviewed-on: http://review.whamcloud.com/4322
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Hudson
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
11 years agoLU-2332 osc: solve a race in client obd list lock
Jinshan Xiong [Thu, 15 Nov 2012 05:07:02 +0000 (21:07 -0800)]
LU-2332 osc: solve a race in client obd list lock

In __client_obd_list_lock(), the lock may have been released before
printing the debug information.

Also, avoid calling osc_wake_cache_waiters() recrusively in
__osc_unreserve_grant().

Signed-off-by: Jinshan Xiong <jinshan.xiong@intel.com>
Change-Id: I4ada1f02feb56b7b25f2f87384551cee7265679e
Reviewed-on: http://review.whamcloud.com/4587
Reviewed-by: Prakash Surya <surya1@llnl.gov>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2279 osp: do not spin awaiting for connection
Alex Zhuravlev [Tue, 18 Dec 2012 05:23:46 +0000 (09:23 +0400)]
LU-2279 osp: do not spin awaiting for connection

modify ready condition for osp_precreate_reserve() so that
it ignores -ENODEV and instead rely on expiration mechanism.

Signed-off-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Change-Id: Id59e75bb17c603140616f34e08c98a6f31f10a8d
Reviewed-on: http://review.whamcloud.com/4847
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: wangdi <di.wang@intel.com>
Reviewed-by: Li Wei <wei.g.li@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2508 build: make ldev.conf not overwritten after upgrade
Minh Diep [Wed, 26 Dec 2012 18:18:24 +0000 (10:18 -0800)]
LU-2508 build: make ldev.conf not overwritten after upgrade

Include %config(noreplace) in the spec file so we don't lose
changes after upgrade for ldev.conf

Signed-off-by: Minh Diep <minh.diep@intel.com>
Change-Id: I9e3f892c494a6f8e3f0da27691cb5f8ac7dfe31e
Reviewed-on: http://review.whamcloud.com/4890
Tested-by: Hudson
Reviewed-by: Prakash Surya <surya1@llnl.gov>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-709 build: remove old userspace-OSS configure
Andreas Dilger [Tue, 6 Nov 2012 22:47:13 +0000 (15:47 -0700)]
LU-709 build: remove old userspace-OSS configure

Remove the old and obsolete userspace-OSS configure options.  These
are not used anywhere in the code, and are not intended to be needed
any time in the near future.

Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: I9b50dbd4f22ad07696be7b3a39cbf87ab5500c1e
Reviewed-on: http://review.whamcloud.com/4828
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Christopher J. Morrone <chris.morrone.llnl@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-992 kernel: deprecate RHEL5 server support for master
yangsheng [Fri, 21 Dec 2012 04:46:29 +0000 (12:46 +0800)]
LU-992 kernel: deprecate RHEL5 server support for master

Remove patches relate to RHEL5 server support.

Signed-off-by: yang sheng <ys@whamcloud.com>
Change-Id: I694c9bbe0b6713119501392540c9cf5c6f8e53f3
Reviewed-on: http://review.whamcloud.com/4865
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
11 years agoLU-2337 scripts: init script to not use -d with zpool import
Ned Bass [Tue, 27 Nov 2012 19:06:43 +0000 (11:06 -0800)]
LU-2337 scripts: init script to not use -d with zpool import

The zpool import command shipped with ZFS on Linux now searches the
following directories for devices (in order), eliminating the need for
the zpool import -d option in the lustre init script.

  /dev/disk/by-vdev   - Custom rules, use first if they exist
  /dev/disk/zpool     - Custom rules, use first if they exist
  /dev/mapper         - Use multipath devices before components
  /dev/disk/by-uuid   - Single unique entry and persistent
  /dev/disk/by-id     - May be multiple entries and persistent
  /dev/disk/by-path   - Encodes physical location and persistent
  /dev/disk/by-label  - Custom persistent labels
  /dev                - UNSAFE device names will change

The command formerly only searched /dev by default, so the init script
used the -d option to give precedence to preferred locations such as
/dev/mapper.  However this approach is error-prone on systems where
/dev/mapper exists but doesn't contain the zpool member devices.  With
this change the default script behavior should work on systems using
any of the above directories.

Also print an error message if zpool import fails, and remove an
unused variable from an unrelated function.

Signed-off-by: Ned Bass <bass6@llnl.gov>
Change-Id: I257da17328bec84aa568a61a40cdb374535aa935
Reviewed-on: http://review.whamcloud.com/4686
Tested-by: Hudson
Reviewed-by: Prakash Surya <surya1@llnl.gov>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2361 quota: allow upgraded fs to start w/o spc accounting
Johann Lombardi [Wed, 21 Nov 2012 09:56:46 +0000 (10:56 +0100)]
LU-2361 quota: allow upgraded fs to start w/o spc accounting

All filesystems upgraded to 2.4 should run tunefs.lustre --quota to
have functional space accounting. If not done, we still allow the
filesystem to be started, but print an error on the console if the
administrator tries to enable quota.

Signed-off-by: Johann Lombardi <johann.lombardi@intel.com>
Change-Id: I98ff2cf5e5c381353b219679b935bc0584b033cc
Reviewed-on: http://review.whamcloud.com/4642
Tested-by: Hudson
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2164 utils: mkfs.lustre segfaults if no "/" in dataset name
Ned Bass [Wed, 7 Nov 2012 20:46:13 +0000 (12:46 -0800)]
LU-2164 utils: mkfs.lustre segfaults if no "/" in dataset name

mkfs.lustre incorrectly assumes that the libzfs function
zfs_name_valid() disallows filesystem names without a "/", and so uses
the result of strrchr(pool, '/') without a NULL check.  In fact
dataset names without a / are permitted, as in the case of commands
like

   zfs get all tank

where a pool tank is treated like a dataset.  The leads to a segfault
if mkfs.lustre is given a dataset name without a /.  Since lustre
datasets are always created as children of a pool, add a separate
check for a missing slash and print an error if it's missing.

Signed-off-by: Ned Bass <bass6@llnl.gov>
Change-Id: Ic7bede9ca19d646f64d2f166f189fa6822a70fe3
Reviewed-on: http://review.whamcloud.com/4490
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-2395 ofd: Maintain per-export {read,write}_bytes counters
John L. Hammond [Tue, 27 Nov 2012 20:28:20 +0000 (14:28 -0600)]
LU-2395 ofd: Maintain per-export {read,write}_bytes counters

Add handling of these counters to ofd_counter_incr() and add a test to
sanity to ensure that they work as intended.

Signed-off-by: John L. Hammond <jhammond@tacc.utexas.edu>
Change-Id: I49e237a6387b8ece1aecd63987ad4a75897b430b
Reviewed-on: http://review.whamcloud.com/4687
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Emoly Liu <emoly.liu@intel.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2317 mgs: both callbacks are to be fixed
Vitaly Fertman [Mon, 17 Dec 2012 19:48:44 +0000 (23:48 +0400)]
LU-2317 mgs: both callbacks are to be fixed

The commit ORNL-27 introduced a new lock enqueue which drops a
reference on it in the blocking callbacks. however, it turned out
to be racy as if a lock is taken quickly, callback is called twice,
from enqueue completion and from conflicting lock cancel, and lock
reference is decremented twice.  LU-1259 tried to fix it, but only
for 1 callback.

Fix it for mgs_completion_ast_config as well.

Signed-off-by: Vitaly Fertman <vitaly_fertman@xyratex.com>
Xyratex-bug-id: MRP-792
Change-Id: I49207cfae230318da3b6dcbe3a63c14d8d94a244
Reviewed-on: http://review.whamcloud.com/4744
Tested-by: Hudson
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2469 tests: use MDS/OSTDEV and MDS/OSTDEVBASE with zfs
Nathaniel Clark [Tue, 18 Dec 2012 19:05:55 +0000 (14:05 -0500)]
LU-2469 tests: use MDS/OSTDEV and MDS/OSTDEVBASE with zfs

Add support for using MDSDEVn, OSTDEVn, MDSDEVBASE and OSTDEVBASE
variables when testing with zfs.

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: I89115ce935294cdbbd6620fec3f9dc3eb76f8960
Reviewed-on: http://review.whamcloud.com/4854
Tested-by: Hudson
Reviewed-by: Cliff White <cliff.white@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-1756 kernel: cleanup lustre_compat25.h
Peng Tao [Tue, 30 Oct 2012 09:15:02 +0000 (17:15 +0800)]
LU-1756 kernel: cleanup lustre_compat25.h

Use cpumask_of_node() rather than node_to_cpumask().
cpumask_of_node() is availabe in latest kernel, while
node_to_cpumask() isn't.

Also fix how cpumask_of_node() is detected. Some OFED
backports cpumask_of_node() and put it in private
include/linux/cpumask.h.

Signed-off-by: Peng Tao <tao.peng@emc.com>
Change-Id: I770fcb549c354c2c925c821d2a8920d867274d7a
Reviewed-on: http://review.whamcloud.com/4588
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Yang Sheng <yang.sheng@intel.com>
11 years agoLU-2414 tests: fix job # substitution in replay_barrier
Nathaniel Clark [Fri, 30 Nov 2012 16:56:51 +0000 (11:56 -0500)]
LU-2414 tests: fix job # substitution in replay_barrier

The extra % in front of ${!svc} can cause erronious substitution by
bash, as in If ${!svc} resolves to something like nlc then the %n
becomes job number 0 so the filesystem is 0lc and that fails.

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: I4a0b0db86e960a33dab95b2e7ca4aed7fce4a55d
Reviewed-on: http://review.whamcloud.com/4725
Tested-by: Hudson
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2056 mdd: create transaction before locking object
Hongchao Zhang [Sun, 30 Dec 2012 12:37:41 +0000 (20:37 +0800)]
LU-2056 mdd: create transaction before locking object

OSD requires transactions to be created before locking the object.
however, mdd_close has a rare call path violating this rule.

Signed-off-by: Liang Zhan <liang@whamcloud.com>
Signed-off-by: Hongchao Zhang <hongchao.zhang@whamcloud.com>
Change-Id: Ibf7930338c3d1216b6ec1e0c51403ab4b8f3b940
Reviewed-on: http://review.whamcloud.com/4461
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
11 years agoLU-2526 quota: writer proper size in test_9
Niu Yawei [Thu, 27 Dec 2012 03:05:28 +0000 (22:05 -0500)]
LU-2526 quota: writer proper size in test_9

Write proper size (4.5G) in test_9 of s-q.

Signed-off-by: Niu Yawei <niu@whamcloud.com>
Change-Id: I5233368bbfb47e926c852baf413791ee043acded
Reviewed-on: http://review.whamcloud.com/4892
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
11 years agoLU-2446 build: Update Whamcloud copyright messages to Intel
Keith Mannthey [Fri, 4 Jan 2013 03:34:24 +0000 (19:34 -0800)]
LU-2446 build: Update Whamcloud copyright messages to Intel

Update script to assign all Whamcloud copyrights to Intel and add
copyrights to files that have been edited by Whamcloud since
2010-06-01.

Changes to the script include:
  Ability to exclude some previous commits.
  Intel Authors now reconized
  Ability to deal with a few common forms in the Intel Copyright
  Xyratex Copyright aware
  Updated user messages
  Detects Git non-linear year issues.

Signed-off-by: Keith Mannthey <keith@whamcloud.com>
Change-Id: I8c817e6564ea51b88223f954af8b838d713c9a44
Reviewed-on: http://review.whamcloud.com/4811
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
11 years agoLU-2446 build: Update Whamcloud copyright messages for Intel
Keith Mannthey [Fri, 4 Jan 2013 02:48:41 +0000 (18:48 -0800)]
LU-2446 build: Update Whamcloud copyright messages for Intel

Update the copyright messages for master branch for Intel.

This is the result of the updatecw.sh script.

Signed-off-by: Keith Mannthey <keith.mannthey@intel.com>
Change-Id: Id8dc454e7a5b6dffef64aa6efefeaaaea966d780
Reviewed-on: http://review.whamcloud.com/4812
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
11 years agoLU-2446 build: Update Whamcloud copyright messages for Intel
Keith Mannthey [Fri, 4 Jan 2013 01:56:25 +0000 (17:56 -0800)]
LU-2446 build: Update Whamcloud copyright messages for Intel

Update the copyright messages for master branch for Intel.

These are the manual changes required.
Issues addressed:
  The addition of the GPL to two header files
  Updating the Man page copyrights
  Dealing with nonlinear year issues in git
  Removal of a double copyright
  Careful addition of Intel copyrights in a tricky spots

Signed-off-by: Keith Mannthey <keith.mannthey@intel.com>
Change-Id: Iaf8bd9f2a7e38c265c86c477fdf51607c1590b86
Reviewed-on: http://review.whamcloud.com/4948
Tested-by: Hudson
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
11 years agoLU-2504 procfs: Call put_cpu() if stats alloc fails
John L. Hammond [Mon, 17 Dec 2012 23:34:57 +0000 (17:34 -0600)]
LU-2504 procfs: Call put_cpu() if stats alloc fails

Call put_cpu() if lprocfs_stats_alloc_one() fails in
lprocfs_stats_lock().

Signed-off-by: John L. Hammond <jhammond@tacc.utexas.edu>
Change-Id: I12c3eb9ecbbef3086493d63c300ddb853d86dd98
Reviewed-on: http://review.whamcloud.com/4845
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Keith Mannthey <keith.mannthey@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
11 years agoLU-2503 libcfs: Call lbug_with_loc() in LASSERT()
John L. Hammond [Mon, 17 Dec 2012 23:07:27 +0000 (17:07 -0600)]
LU-2503 libcfs: Call lbug_with_loc() in LASSERT()

LASSERT() declares a msgdata which can be passed to lbug_with_loc()
instead of calling LBUG() thereby saving /millions/ of bytes.  Also
remove unused libcfs_assertion_failed().

Signed-off-by: John L. Hammond <jhammond@tacc.utexas.edu>
Change-Id: Iac267c7804b5e18f687f47b2eea585c655e7bb21
Reviewed-on: http://review.whamcloud.com/4844
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Keith Mannthey <keith.mannthey@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
11 years agoLU-2351 tests: remote_node works wrong
Kyrylo Shatskyy [Thu, 8 Nov 2012 10:55:33 +0000 (12:55 +0200)]
LU-2351 tests: remote_node works wrong

The test-framework's remote_node works wrong for host names with any
suffixes.

To resolve this the host identification has been switch to IP address.
Target node address is compared with address on each interface
of the local host. Assume host remote if it is unable to resolve
its IP address. Results of comparison are cached in global variables
in order to suppress host resolution overhead.

Signed-off-by: Kyrylo Shatskyy <kyrylo_shatskyy@xyratex.com>
Xyratex-bug-id: MRP-629
Reviewed-by: Alexander Lezhoev <Alexander_Lezhoev@xyratex.com>
Reviewed-by: Roman Grigoryev <Roman_Grigoryev@xyratex.com>
Reviewed-by: Bruce Korb <Bruce_Korb@xyratex.com>
Change-Id: I6128650ac8c5cc2759f9ff53856b5ffdf3222aa4
Reviewed-on: http://review.whamcloud.com/4609
Reviewed-by: Bruce Korb <bruce_korb@xyratex.com>
Reviewed-by: Alexander Lezhoev <alexander_lezhoev@xyratex.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>