- 07 Aug, 2020 1 commit
-
-
Lai Siyao authored
Pack parent FID in getattr request if OBD_CONNECT2_GETATTR_PFID is enabled, otherwise fill it with target FID for backward compatibility. Fixes: f9a2da63 ("LU-13437 mdt: don't fetch LOOKUP lock for remot...") Test-Parameters: clientversion=2.12 testlist=sanity env=SANITY_EXCEPT="27M 151 156" Test-Parameters: serverversion=2.12 testlist=sanity env=SANITY_EXCEPT="56 165 205b" Signed-off-by:
Lai Siyao <lai.siyao@whamcloud.com> Change-Id: Idcf8388b65dee1f0a09a53b240ce8303f3c6ff75 Reviewed-on: https://review.whamcloud.com/39290 Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
Neil Brown <neilb@suse.de> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 20 Jul, 2020 2 commits
-
-
Lai Siyao authored
Add OBD_CONNECT2_GETATTR_PFID connect flag to pack parent FID in getattr request, which will be used to check whether target is remote object, if so, don't take LOOKUP lock, otherwise client may see stale directory entries. Test-parameters: trivial Signed-off-by:
Lai Siyao <lai.siyao@whamcloud.com> Change-Id: Ibdf880934456f255f83cd4bac9d61ab5e1ed7330 Reviewed-on: https://review.whamcloud.com/39289 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Neil Brown <neilb@suse.de> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
Sebastien Buisson authored
Encryption layer needs to set an encryption context on files and dirs that are encrypted. This context is stored as an extended attribute, that then needs to be fetched upon metadata ops like lookup, getattr, open, truncate, and layout. With this patch we send encryption context to the MDT along with create RPCs. This closes the insecure window between creation and setting of the encryption context, and saves a setxattr request. This patch also introduces a way to have the MDT return encryption context upon granted lock reply, making the encryption context retrieval atomic, and sparing the client an additional getxattr request. Test-Parameters: testlist=sanity-sec envdefinitions=ONLY="36 37 38 39 40 41 42 43 44 45 46 47 48 49" clientdistro=el8.1 fstype=ldiskfs mdscount=2 mdtcount=4 Test-Parameters: testlist=sanity-sec envdefinitions=ONLY="36 37 38 39 40 41 42 43 44 45 46 47 48 49" clientdistro=el8.1 fstype=zfs mdscount=2 mdtcount=4 Test-Parameters: clientversion=2.12 env=SANITY_EXCEPT="27M 56ra 151 156 802" Test-Parameters: serverversion=2.12 env=SANITY_EXCEPT="56oc 56od 165a 165b 165d 205b" Test-Parameters: serverversion=2.12 clientdistro=el8.1 env=SANITYN_EXCEPT=106,SANITY_EXCEPT="56oc 56od 165a 165b 165d 205b" Signed-off-by:
Sebastien Buisson <sbuisson@ddn.com> Change-Id: I45599cdff13d5587103aff6edd699abcda6cb8f4 Reviewed-on: https://review.whamcloud.com/38430 Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Mike Pershin <mpershin@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 10 Jun, 2020 1 commit
-
-
Sebastien Buisson authored
Client enables encryption by default. However, this should be possible only if server side is encryption aware. Moreover, we want to give the ability to decide which clients can make use of encryption, by extending the nodemap mechanism with a new 'forbid_encryption' property, set to 0 by default. Signed-off-by:
Sebastien Buisson <sbuisson@ddn.com> Change-Id: I765e5ce555e8277319c03c770cb6e6ac73cfc9e8 Reviewed-on: https://review.whamcloud.com/36433 Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
John L. Hammond <jhammond@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 06 Jun, 2020 1 commit
-
-
Sebastien Buisson authored
Enable client side encryption. By default it is activated, letting user specifies actual encryption policy to use on a per-directory basis. It is possible to deactivate client side encryption by using the 'noencrypt' mount option. Also add the test dummy encryption mode option to ease testing. Signed-off-by:
Sebastien Buisson <sbuisson@ddn.com> Change-Id: I0e8d4db7ab8a77aba0600788cca9403f7c50f8a6 Reviewed-on: https://review.whamcloud.com/36143 Reviewed-by:
John L. Hammond <jhammond@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 02 Jun, 2020 1 commit
-
-
Lai Siyao authored
A specific restriper thread is created for each MDT, it does three tasks in a loop: 1. If there is directory whose total sub-files exceeds threshold (50000 by default, can be changed "lctl set_param mdt.*.dir_split_count=N"), split this directory by adding new stripes (4 stripes by default, which can be adjusted by "lctl set_param mdt.*.dir_split_delta=N"). 2. If a directory stripe LMV is marked 'MIGRATION', migrate sub file from current offset, and update offset to next file. 3. If a directory master LMV is marked 'RESTRIPING', check whether all stripe LMV 'MIGRATION' flag is cleared, if so, clear 'RESTRIPING' flag and update directory LMV. In last patch, the first part of manual directory stripe is implemented, and in this patch, sub file migrations and dir layout update is done. Directory auto-split is done in similar way, except that the first step is done by this thread too. Directory auto-split can be enabled/disabled by "lctl set_param mdt.*.enable_dir_auto_split=[0|1]", it's turned on by default. Auto split is triggered at the end of getattr(): since now the attr contains dirent count, check whether it exceeds threshold, if so, add this directory into mdr_auto_split list and wake up the dir restriper thread. Restripe migration is also triggered in getattr(): if the object is directory stripe, and LMV 'MIGRATION' flag set, add this object into mdr_restripe_migrate list and wake up the dir restriper thread. Directory layout update is similar: if current directory is striped, and LNV 'RESTRIPING' flag is set, add this directory into mdr_restripe_update list and wake up restriper thread. By default restripe migrate dirent only, and leave inode unchanged, it can be adjusted by "lctl set_param mdt.*.dir_restripe_nsonly=[0|1]". Currently DoM file inode migration is not supported, migrate dirent only for such files to avoid leaving dir migration/restripe unfinished. Add sanity.sh 230o, 230p and 230q, adjust 230j since DoM files migrate dirent. Signed-off-by:
Lai Siyao <lai.siyao@whamcloud.com> Change-Id: I8c83b42e4acbaab067d0092d0b232de37f956588 Reviewed-on: https://review.whamcloud.com/37284 Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Hongchao Zhang <hongchao@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 20 May, 2020 1 commit
-
-
Lai Siyao authored
This patch adds directory restripe support: * 'lfs setdirstripe -m -1 -c <stripe_count>' on an existed directory will change this directory layout, if 'stripe_count' is larger than current count, new stripes are allocated after current stripes, otherwise merge stripes of this directory, NB, if stripe count is unchanged, but hash type changed, it's treated as merging, but rehashing actually. * mdt_restripe() ia added to restripe directory. * mdd_dir_declare_layout_split() is added to split directory, which handles both plain and striped directory split. * lod_dir_declare_layout_split() will handle the internal of directory split. * directory merge is simple compared to split, which just records target stripe count in LMV, and update it. NB. this patch only restripe directory, but doesn't add the code to migrate sub files, which will be implemented in the following patch. Signed-off-by:
Lai Siyao <lai.siyao@whamcloud.com> Change-Id: I526f7423b909eb83cf8723e65981d713b3e42499 Reviewed-on: https://review.whamcloud.com/36898 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Hongchao Zhang <hongchao@whamcloud.com> Reviewed-by:
Yingjin Qian <qian@ddn.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 14 May, 2020 2 commits
-
-
Qian Yingjin authored
Both ext4 and ZFS allow storing the file creation time in the on-disk inode, and the new statx() API allows returning it to userspace, but as yet we do not have any mechanism to send it from the servers to the client. Add fields into struct mdt_body and an OBD_MD_FLBTIME flag to allow it to be requested and returned directly from MDTs. It does not need to get it from the OSTs or in the LVB since those objects are precreated and their creation time (birth time) is not accurate. This patch also adds support to lfs find to query on this field. Signed-off-by:
Qian Yingjin <qian@ddn.com> Change-Id: Ib122b336695cde511fa6d8fb9eca95a4da701430 Reviewed-on: https://review.whamcloud.com/36507 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Li Xi <lixi@ddn.com> Reviewed-by:
James Simmons <jsimmons@infradead.org> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
Sergey Cheremencev authored
Patch allows to apply quota settings not only for the whole system, but also for different OST pools. Since this patch each "LOD" pool is duplicated by QMT. Thus quota pools(QP) could be tuned by standard lctl pool_new/add/remove/erase commands. All QPs are subset of a global pool that includes all data devices in a system, including DOM. However DOM is not supported. I don't see a lot of work to add DOM support in future - just need to decide how MDTs could be combined in a pool. The main idea of QP is to find all pools for requested ID(usr/grp/prj) and apply minimum limit. The patch doesn't affect qsd side, so slaves know nothing about pools and different limits. Qunit and edquot are calculated for each slave on master. To apply quota on QP, the patch adds key "-o" to lfs setquota. To get quotas for QP, it provides long option "--pool" in lfs quota. See examples of using in sanity-quota_1b/c/d. Now QPs work properly only on a clean system. Support of recalculation granted space in case of adding/removing OSTs in a pool will be added in the next patch together with accounting already granted space by each ID in a POOl. Test-Parameters: testgroup=review-dne-part-4 Change-Id: I3396aded2156729b4fd15166eb59db59ee4c967e Signed-off-by:
Sergey Cheremencev <c17829@cray.com> Reviewed-on: https://review.whamcloud.com/35615 Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
James Simmons <jsimmons@infradead.org> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Shaun Tancheff <shaun.tancheff@hpe.com> Reviewed-by:
Hongchao Zhang <hongchao@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 07 May, 2020 2 commits
-
-
Sebastien Buisson authored
Older clients might send MGS_SET_INFO requests to the MGS. Newer MGS needs to handle that gracefully by returning: - -EINVAL for anything other than lov.stripe* - 0 for those parameters without doing anything, rather than returning -ENOTSUPP. Test-Parameters: clientversion=2.12 envdefinitions=SANITY_EXCEPT="27M 56ra 151 156 802" Signed-off-by:
Sebastien Buisson <sbuisson@ddn.com> Change-Id: Iba75c788eaefabd98bbb65a657f9a0150e20fafb Reviewed-on: https://review.whamcloud.com/38311 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
James Simmons <jsimmons@infradead.org> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
Lai Siyao authored
Add OBD_CONNECT2_FIDMAP connect flag, which indicates whether client supports FID mapping. Signed-off-by:
Lai Siyao <lai.siyao@whamcloud.com> Change-Id: I165598e7d19878d1d3dcfa8c6f8fcc3cc233e4c9 Reviewed-on: https://review.whamcloud.com/38232 Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Alex Zhuravlev <bzzz@whamcloud.com>
-
- 23 Apr, 2020 1 commit
-
-
James Simmons authored
The linux kernel offers a CONFIG_UAPI_HEADER_TEST that test if the UAPI headers can be built stand alone. Running this kernel option against the latest lustre UAPI headers expose some few issues still left. This patch makes everything compliant with this kernel option which should cover potential build issues with userland applications. A few kernel-only bits of code have been moved to the kernel headers where they belong. Change-Id: I1b287c8226dd1085080218fb92e7b31b32f36b07 Signed-off-by:
James Simmons <jsimmons@infradead.org> Reviewed-on: https://review.whamcloud.com/38215 Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
Yang Sheng <ys@whamcloud.com> Reviewed-by:
Gian-Carlo DeFazio <defazio1@llnl.gov> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 14 Apr, 2020 1 commit
-
-
Alexander Boyko authored
OBD_CONNECT_MNE_SWAB is equal to OBD_CONNECT_MDS_MDS, and it was used at MGC client in past for mne swabbing during interop. Right now it is interpreted at MGS like OBD_CONNECT_MDS_MDS and skip these clients from eviction and lock canceling after timeout. Fixes: 1bdc4fd0 ("LU-6307 obdclass: distinguish MGC/MDT connection properly") Test-Parameters: testlist=runtests clientversion=2.12 envdefinitions=MDS_MOUNT_OPTS="-orw",OST_MOUNT_OPTS="-orw" Test-Parameters: testlist=runtests serverversion=2.12 envdefinitions=MDS_MOUNT_OPTS="-orw",OST_MOUNT_OPTS="-orw" Test-Parameters: testlist=runtests clientversion=2.10 clientdistro=el7.6 envdefinitions=MDS_MOUNT_OPTS="-orw",OST_MOUNT_OPTS="-orw" Test-Parameters: testlist=runtests serverversion=2.10 serverdistro=el7.6 envdefinitions=MDS_MOUNT_OPTS="-orw",OST_MOUNT_OPTS="-orw" Signed-off-by:
Alexander Boyko <c17825@cray.com> Cray-bug-id: LUS-8484 Change-Id: I4f8ddeb1808cfaee7507e0efcdefa24040cfcbb6 Reviewed-on: https://review.whamcloud.com/37880 Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Artem Blagodarenko <c17828@cray.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 06 Apr, 2020 2 commits
-
-
Andreas Dilger authored
The OBD_CONNECT_LOCKAHEAD_OLD feature was added for a short time for compatibility with an implementation of LDLM lockahead that was later replaced by OBD_CONNECT_LOCKAHEAD2. Remove the compatibility code for this old implementation that has been disabled since the 2.13 release. Also remove other obsolete compatibility code dating back to 2.8.53. Test-Parameters: trivial Signed-off-by:
Andreas Dilger <adilger@whamcloud.com> Change-Id: I4444eff180b2c6e2b27d260413f2debbb2ce7057 Reviewed-on: https://review.whamcloud.com/38109 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com> Reviewed-by:
James Simmons <jsimmons@infradead.org>
-
Oleg Drokin authored
This code has been somewhat dormant since 2.9 and now it's time to remove it. Change-Id: I392c29d30e11b4feb362ac2f396a2f687c81c52a Signed-off-by:
Oleg Drokin <green@whamcloud.com> Reviewed-on: https://review.whamcloud.com/38106 Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
James Simmons <jsimmons@infradead.org> Tested-by:
jenkins <devops@whamcloud.com>
-
- 31 Mar, 2020 2 commits
-
-
Lai Siyao authored
Handle layout change internally when mapping name to stripe: * Move layout changing related code into lmv name to stripe mapping so callers doesn't need to take care of the internals. * lmv_name_to_stripe_index() maps name in new layout, and lmv_name_to_stripe_index_old() in old layout. * rename lmv_migrate_existence_check() to lmv_old_layout_lookup() to support directory restripe in the future. * support layout changing directory in LFSCK. Signed-off-by:
Lai Siyao <lai.siyao@whamcloud.com> Change-Id: Icf8bda5db884784f761a2d373a6f81d7e13f525f Reviewed-on: https://review.whamcloud.com/37711 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Hongchao Zhang <hongchao@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
Lai Siyao authored
Current directory striping strategy is fixed striping, i.e., it calls (hash(filename) % stripe_count) to decide stripe for file. The problem with this approach is that if stripe_count changes, most of the files will need to be relocated between MDTs. This makes directory split/merge quite expensive. This patch introduces consistent hash striping strategy: it calls (hash(filename) % LMV_CRUSH_PG_COUNT) to locate PG_ID (placement group index), and then calls crush_hash(PG_ID, stripe_index) to get a straw for each stripe, and the stripe with the highest staw will be used to place this file. As we can see, it uses the CRUSH algorithm, but it only uses it to map placement group pseudo-randomly among all stripes, while doesn't use it to choose MDTs if MDT is not specified. The latter is done by MDT object QoS allocation in LMV and LOD (LMV decides the starting stripe MDT, while LOD decides the rest stripes). This implementation contains below changes: ...
-
- 24 Mar, 2020 1 commit
-
-
Mikhail Pershin authored
Remove remaining unused lustre capability structures and defines. Test-Parameters: trivial Signed-off-by:
Mikhail Pershin <mpershin@whamcloud.com> Change-Id: Iebd5bf87537c19fb30804adaf623c185983c351b Reviewed-on: https://review.whamcloud.com/37895 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
James Simmons <jsimmons@infradead.org> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 11 Mar, 2020 1 commit
-
-
James Simmons authored
Attempting to compile strict C99 user land applications or libraries with the Lustre UAPI headers will fail. These same errors can be seen by enabling CONFIG_UAPI_HEADER_TEST as well. Update the Lustre UAPI headers to be compilable with -std=c99. Enhance our current test covering UAPI header handling. For OpenSFS branch we can't include <linux/stat.h> since we support kernels before struct statx existed and they will collide with the special definitions in lustre_user.h. Change-Id: Ifb0da33180dc3c7e116d6bf2b7f603ad0528277a Signed-off-by:
James Simmons <jsimmons@infradead.org> Reviewed-on: https://review.whamcloud.com/37678 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Gian-Carlo DeFazio <defazio1@llnl.gov> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Alex Zhuravlev <bzzz@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 08 Feb, 2020 1 commit
-
-
Wang Shilong authored
This is reserved for RDMA-only memory integrated with Lustre. The purpose of this bit is to: 1) disable short IO if memory is not dirextly addressie by CPU. 2) prevent CPU memory pages and RDMA memory pages merging into one RPC. Test-Parameters: trivial Change-Id: I148b269c5e7d7c52e760b20a6482c259407e0898 Signed-off-by:
Wang Shilong <wshilong@ddn.com> Reviewed-on: https://review.whamcloud.com/37383 Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Amir Shehata <ashehata@whamcloud.com>
-
- 28 Jan, 2020 3 commits
-
-
Swapnil Pimpale authored
A new RPC, OST_FALLOCATE has been added for space preallocation. This patch reserves OST_FALLOCATE opcode for fallocate syscall. Reserving opcode upfront would ensure consistency and would avoid protocol interoperability issues in the future. Test-Parameters: trivial testlist=sanity,sanityn,sanity-dom Signed-off-by:
Swapnil Pimpale <spimpale@ddn.com> Signed-off-by:
Li Xi <lixi@ddn.com> Signed-off-by:
Abrarahmed Momin <abrar.momin@gmail.com> Signed-off-by:
Arshad Hussain <arshad.super@gmail.com> Change-Id: Ie109f8f5720dec6d34c5ce4f7732fe49ccb47cd9 Reviewed-on: https://review.whamcloud.com/37277 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Bobi Jam <bobijam@hotmail.com>
-
Andreas Dilger authored
The LUSTRE_DIRECTIO_FL was added based on the upstream FS_DIRECTIO_FL flag in the hopes that it might be useful, but it has since been removed from the upstream in kernel commit v4.4-rc4-22-g68ce7bfcd995 and replaced by FS_VERITY_FL using the same value in kernel commit v5.3-rc2-4-gfe9918d3b228, which we are much more likely to use. Since LUSTRE_DIRECTIO_FL was unused, there is no risk to remove it. Test-Parameters: trivial Signed-off-by:
Andreas Dilger <adilger@whamcloud.com> Change-Id: I49e915612636a674a86d25be5d91a042693ebbe5 Reviewed-on: https://review.whamcloud.com/37295 Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
Shaun Tancheff <shaun.tancheff@hpe.com> Reviewed-by:
Arshad Hussain <arshad.super@gmail.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
James Simmons <jsimmons@infradead.org> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
James Simmons authored
Linux UAPI headers use the gcc attributre __packed__ to ensure that the data structures are the exact same size on all platforms. This comes at the cost of potential misaligned accesses to these data structures which at best cost performance and at worst cause a bus error on some platforms. To detect potential misaligned access starting with gcc version 9 a new compile flags was introduced which is now impacting builds with Lustre. Examining the build failures shows most of the problems are due to packed data structures in the Lustre UAPI header containing unpacked data structure fields. Packing those missed structures resolved many of the build issues. The second problem is that the lustre utilities tend to cast some of its UAPI data structure. A good example is struct lov_user_md being cast to struct lov_user_md_v3. To ensure this is properly handled with packed data structures we need to use the __may_alias__ compiler attribute. The one exception is struct statx which is defined out side of Lustre and its unpacked. This requires extra special handling in user land code due to the described issues in this comment. Fixing this problem exposed an incorrect wiretest for struct update_op Last problem address is the use of __swabXXp() on packed data structure fields. Because of the potential alignment issues we have to use __swabXX() functions instead. Change-Id: I149c55d3361e893bd890f9c5e9c77c15f81acc1b Signed-off-by:
James Simmons <jsimmons@infradead.org> Reviewed-on: https://review.whamcloud.com/36798 Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Quentin Bouget <quentin.bouget@cea.fr> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 14 Dec, 2019 2 commits
-
-
Mr NeilBrown authored
This arg is always '0', so remove it. Consequently, OBD_BRW_NOCACHE is never set, and cl_dirty_transit and obd_dirty_transit_pages are never non-zero. So they can be removed as well. Linux-commit: 8d1057264a75 Test-Parameters: trivial Signed-off-by:
Mr NeilBrown <neilb@suse.de> Change-Id: Ia047affc33fb9277e6c28a8f6d7d088c385b51a8 Reviewed-on: https://review.whamcloud.com/36319 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
James Simmons <jsimmons@infradead.org> Reviewed-by:
Shaun Tancheff <stancheff@cray.com> Reviewed-by:
Ben Evans <bevans@cray.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
Lai Siyao authored
Introduce a new connect flag OBD_CONNECT2_CRUSH to indicate whether client or server supports new directory hash type 'crush'. Test-parameters: trivial Signed-off-by:
Lai Siyao <lai.siyao@whamcloud.com> Change-Id: I073ab65eddf502c016f30ad535740f3d9a77459f Reviewed-on: https://review.whamcloud.com/36774 Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Olaf Faaland-LLNL <faaland1@llnl.gov> Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com>
-
- 22 Oct, 2019 2 commits
-
-
Qian Yingjin authored
In order to make direct inode scanning on the MDT useful, in addition to storing the file size/blocks via LSOM on the MDT, we also need to store the atime/mtime/ctime on the MDT inodes. Currently the atime is already lazily updated on the MDS (at close time). In this patch, the final mtime/ctime are sent to the MDS at close time and updated on the MDT inode, and make MDT-only scanning workable. Signed-off-by:
Qian Yingjin <qian@ddn.com> Change-Id: I4465281a03d70919c388cb241c16eebcb03e850f Reviewed-on: https://review.whamcloud.com/36286 Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Li Xi <lixi@ddn.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
Sebastien Buisson authored
Reserve OBD_CONNECT2_ENC connection flag so that 'encrypt' or 'test_dummy_encryption' client mount options can only be used if server side knows how to handle encrypted object size properly. Signed-off-by:
Sebastien Buisson <sbuisson@ddn.com> Change-Id: I42d0b597df3b68bd1de19394104e7fda1b76bf6c Reviewed-on: https://review.whamcloud.com/36360 Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 30 Sep, 2019 1 commit
-
-
Andriy Skulysh authored
Late resend if arrives much later than another modification RPC which has been already handled on this slot, may be still applied and therefore overrides the last one Send RPCs from client in increasing order for each tag and check it on server to check late resend. A slot can be reused by a client after kill while the server continue to rely on it. Add flag for such obsolete requests, here we trust the client and perform xid check for all in progress requests. Cray-bug-id: LUS-6272, LUS-7277, LUS-7339 Signed-off-by:
Andriy Skulysh <c17819@cray.com> Reviewed-by:
Vitaly Fertman <c17818@cray.com> Reviewed-by:
Alexander Boyko <c17825@cray.com> Reviewed-by:
Andrew Perepechko <c17827@cray.com> Change-Id: I97806577cf979f49a75379ffc55947cc3dcd02b1 Reviewed-on: https://review.whamcloud.com/35114 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Alexandr Boyko <c17825@cray.com> Reviewed-by:
Mike Pershin <mpershin@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 20 Sep, 2019 1 commit
-
-
Qian Yingjin authored
The patch integrates LSOM functionality with lfs find so that it is possible to use LSOM functionality directly on the client. The MDS fills in the mbo_size and mbo_blocks fields from the LSOM xattr, if the actual size/blocks are not available, and then set new OBD_MD_FLLSIZE and OBD_MD_FLLBLOCKS flags in the reply so that the client knows these fields are valid. The lfs find command adds "-l|--lazy" option to allow the use of LSOM data from the MDS. Add a new version of ioctl(LL_IOC_MDC_GETINFO) call that also returns valid flags from the MDS RPC to userspace in struct lov_user_mds_data so that it is possible to determine whether the size and blocks are returned by the call. The old LL_IOC_MDC_GETINFO ioctl number is renamed to LL_IOC_MDC_GETINFO_OLD and is binary compatible, but newly-compiled applications will use the new struct lov_user_mds_data. New llapi interfaces llapi_get_lum_file(), llapi_get_lum_dir(), llapi_get_lum_file_fd(), llapi_get_lum_dir_fd(...
-
- 07 Sep, 2019 1 commit
-
-
Patrick Farrell authored
The plain layout connect flag was added as part of an earlier implementation of LU-11213, but the design was improved before landing and the flag was not needed. Let's remove it. Since it was never actually marked as supported in any client/server version, we can just remove it entirely, leaving the flag bit open for future use. Signed-off-by:
Patrick Farrell <pfarrell@whamcloud.com> Change-Id: I30946a50299268d00cbfee2081607effd0e4fb47 Reviewed-on: https://review.whamcloud.com/36008 Reviewed-by:
Shilong Wang <wshilong@ddn.com> Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
Lai Siyao <lai.siyao@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 27 Jul, 2019 1 commit
-
-
Alex Zhuravlev authored
a new RPC_REINT_RMFID has been introduced by the patch. it's supposed to be used with corresponding llapi_rmfid() to unlink a batch of MDS files by their FIDs. the caller has to have permission to modify parent dir(s) and the objects themselves. Change-Id: I50421d85babc74d448842acea489321a5d40052d Signed-off-by:
Alex Zhuravlev <bzzz@whamcloud.com> Reviewed-on: https://review.whamcloud.com/34449 Reviewed-by:
Li Xi <lixi@ddn.com> Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Patrick Farrell <pfarrell@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 12 Jul, 2019 3 commits
-
-
Vitaly Fertman authored
Add a new SEL magic for storing SEL components on disk. It is never gets out of LOD, converted on read/write to COMP_V1. A the result, old MDS is not able to open SEL files. At the same time old clients are able to work with existing files seamlessly. Old clients still lacks lustre utils support, thus not possible to create new SEL files, etc. Cray-bug-id: LUS-2528 Signed-off-by:
Vitaly Fertman <c17818@cray.com> Change-Id: Ib3f0b1402cd920e56beaad78a74da485bd7ad342 Reviewed-on: https://review.whamcloud.com/35144 Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Alexey Lyashkov <c17817@cray.com> Reviewed-by:
Patrick Farrell <pfarrell@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
Lai Siyao authored
Change LMV_HASH_TYPE_SPACE to LMV_HASH_FLAG_SPACE to make it flexible in directory layout inheritance in the future. But it's still exposed to user as hash type "space" in "lfs setdirstripe" command to make it easy to understand. Signed-off-by:
Lai Siyao <lai.siyao@whamcloud.com> Change-Id: Ifa302204ed62dff8cc9d12fdc1f9ea86f8491d40 Reviewed-on: https://review.whamcloud.com/35318 Tested-by:
jenkins <devops@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Hongchao Zhang <hongchao@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
Andreas Dilger authored
Move MDS_INODELOCK_* flags into a named enum, and add the definitions for the newer flags into wirecheck/wiretest to ensure consistency. Rename MDS_INODELOCK_MAXSHIFT to MDS_INODELOCK_NUMBITS to hold current number of lockbits, rather than one less than the number of lockbits, since the only two places that use it expect it to be one larger than it is. Fix uses of MDS_INODELOCK_NUMBITS to be number of locks. This does not change the value of MDS_INODELOCK_FULL, which is used in the protocol to exchange supported lock bits between client and server. Signed-off-by:
Andreas Dilger <adilger@whamcloud.com> Change-Id: I0c2985bcc602b7182d5db2cf8d590923be2cab07 Reviewed-on: https://review.whamcloud.com/35045 Reviewed-by:
Patrick Farrell <pfarrell@whamcloud.com> Reviewed-by:
Mike Pershin <mpershin@whamcloud.com> Tested-by:
jenkins <devops@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
- 03 Jul, 2019 1 commit
-
-
Andriy Skulysh authored
This patch reserves the OBD_CONNECT2 flag for increasing XIDs. Change-Id: Id825ce1c86a345884c9d4cd90cd2e13839a268f0 Cray-bug-id: LUS-6272 Signed-off-by:
Andriy Skulysh <c17819@cray.com> Reviewed-on: https://review.whamcloud.com/35113 Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by: Jenkins Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Alexandr Boyko <c17825@cray.com>
-
- 16 Jun, 2019 1 commit
-
-
Oleg Drokin authored
Change-Id: I6e76cc7c06092f54b778f6e45932e21427991dcf
-
- 13 Jun, 2019 2 commits
-
-
Li Xi authored
PCC is a new framework which provides a group of local cache on Lustre client side. No global namespace will be provided by PCC. Each client uses its own local storage as a cache for itself. Local file system is used to manage the data on local caches. Cached I/O is directed to local filesystem while normal I/O is directed to OSTs. PCC uses HSM for data synchronization. It uses HSM copytool to restore file from local caches to Lustre OSTs. Each PCC has a copytool instance running with unique archive number. Any remote access from another Lustre client would trigger the data synchronization. If a client with PCC goes offline, the cached data becomes inaccessible for other client temporarilly. And after the PCC client reboots and the copytool restarts, the data will be accessible again. ToDo: 1) Make PCC exclusive with HSM. 2) Strong size consistence for PCC cached file among clients. 3) Support to cache partial content of a file. Change-Id: I188ed36c48aae22...
-
Lai Siyao authored
Reuse the same object alloc QoS code as LOD, but the QoS code is not moved to lower layer module, instead it's copied to LMV, because it involves almost all LMV code, which is too big a change and should be done separately in the future. And for LMV round-robin object allocation, because we only need to allocate one object, use the MDT index saved and update it to next MDT. Add sanity 413b. Signed-off-by:
Lai Siyao <lai.siyao@whamcloud.com> Change-Id: I53c3d863dafda534eebb6b95da205b395071cd25 Reviewed-on: https://review.whamcloud.com/34657 Tested-by: Jenkins Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Hongchao Zhang <hongchao@whamcloud.com> Reviewed-by:
Andreas Dilger <adilger@whamcloud.com>
-
- 01 Jun, 2019 2 commits
-
-
Patrick Farrell authored
Each stripe in a shared file in Lustre corresponds to a single LDLM extent locking domain and also to a single object on disk (and in the OSS page cache). LDLM locks are extent locks, but there are still significant issues with false sharing with multiple writers. On-disk file systems also have per-object performance limitations for both read and write. The LDLM limitation means it is best to have a single writer per stripe, but modern OSTs can be faster than a single client, so this restricts maximum performance unless special methods are used (eg, Lustre lock ahead). The on disk file system limitations mean that even if LDLM locking is not an issue (read and not write, or lockahead), OST performance in a shared file is still limited by having only one object per OST. These limitations make it impossible to get the full performance of a modern Lustre FS with a single shared file. This patch makes it possible to have >1 stripe on a given OST in each layout component. This is known as overstriping. It works exactly like a normally striped file, and is largely transparent to users. By raising the object count per OST, this avoids the single object limits, and by creating more stripes, also avoids the "single effective writer per stripe" LDLM limitation. However, it is only desirable in some situations, so users must request it with a special setstripe command: lfs setstripe -C [count] [file] Users can also access overstriping using the standard '-o' option to manually select OSTs: lfs setstripe -o [ost_indices] [file] Overstriping also makes it easy to test layout size limits,so we add a test for that. Signed-off-by:
Patrick Farrell <pfarrell@whamcloud.com> Change-Id: I14bb94b05642b3542a965e84fda4615b997a4dea Reviewed-on: https://review.whamcloud.com/28425 Tested-by: Jenkins Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Bobi Jam <bobijam@hotmail.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-
Mikhail Pershin authored
The mdt_dom_discard_data() issues new lock to cause data discard for all conflicting client locks. This was done in context of unlink RPC processing and may cause it to be stuck waiting for client to cancel their locks leading to cascading timeouts for any other locks waiting on the same resource and parent directory. Patch skips discard lock waiting in the current context by using own CP callback for that which doesn't wait for blocking locks. They will be finished later by LDLM and cleaned up in that completion callback. So current thread just makes sure discard locks are taken and BL ASTs are sent but doesnt't wait for lock granting and that fixes the original problem. At the same time that opens window for race with data being flushed on client, so it is possible that new IO from client will happen on just unlinked object causing error message and it is not possible to distinguish that case from other possibly critical situations. To solve that the unlinked object is pinned in memory while until discard lock is granted. Therefore, such objects can be easily distinguished as stale one and any IO against it can be just silently ignored. Older clients are not fully compatible with async DoM discard so patch adds also new connection flag ASYNC_DISCARD to distinguish old clients and use old blocking discard for then. Test-Parameters: testlist=racer,racer,racer Signed-off-by:
Mikhail Pershin <mpershin@whamcloud.com> Change-Id: I419677af43c33e365a246fe12205b506209deace Reviewed-on: https://review.whamcloud.com/34071 Tested-by: Jenkins Reviewed-by:
Andreas Dilger <adilger@whamcloud.com> Reviewed-by:
Patrick Farrell <pfarrell@whamcloud.com> Tested-by:
Maloo <maloo@whamcloud.com> Reviewed-by:
Oleg Drokin <green@whamcloud.com>
-