Whamcloud - gitweb
LU-16334 llite: update statx size/ctime for fallocate
authorQian Yingjin <qian@ddn.com>
Wed, 23 Nov 2022 07:44:47 +0000 (02:44 -0500)
committerAndreas Dilger <adilger@whamcloud.com>
Fri, 27 Oct 2023 21:48:28 +0000 (21:48 +0000)
commit0e0217521f31d138d5de982eee8abbeeb7eca8c4
tree56e0037cdc13209e130c757b6a604b8a5c997528
parent92e2338445e34baa5587c66c7176acaed343d751
LU-16334 llite: update statx size/ctime for fallocate

In the VFS interface ->fallocate(), it should update i_size and
i_ctime returned by statx() accordingly when the file size grows.

Add sanity/150h.

fallocate() call does not update the attributes on MDT.
We use STATX with cached-always mode to verify it as it will not
send Glimpse lock RPCs to OSTs to obtain file size information
and use the caching attributes (size) on the client side as much
as possible.

Lustre-change: https://review.whamcloud.com/49221
Lustre-commit: 51851705e936b2dbc9cf141ecf7ab4e3be04333a

Signed-off-by: Qian Yingjin <qian@ddn.com>
Change-Id: Ib8128892222a01cd00250c704328bd13cfb12e2d
Reviewed-by: Arshad Hussain <arshad.hussain@aeoncomputing.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Signed-off-by: Minh Diep <mdiep@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/c/ex/lustre-release/+/52736
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
lustre/llite/vvp_io.c
lustre/tests/sanity.sh