Whamcloud - gitweb
LU-11971 utils: Send file creation time to clients 07/36507/20
authorQian Yingjin <qian@ddn.com>
Sat, 19 Oct 2019 08:46:36 +0000 (16:46 +0800)
committerOleg Drokin <green@whamcloud.com>
Thu, 14 May 2020 05:39:57 +0000 (05:39 +0000)
commit186b97e68abbc45c0e8d5ae7e2a0d10aaa918db6
treedb63ea2df2eff3de9a86ffe266a7f6bb0025d30a
parent15305c3c3fe7894d79c96f4dae0ada6713983376
LU-11971 utils: Send file creation time to clients

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>
18 files changed:
lustre/doc/lfs-find.1
lustre/include/lu_object.h
lustre/include/lustre/lustreapi.h
lustre/include/uapi/linux/lustre/lustre_idl.h
lustre/include/uapi/linux/lustre/lustre_user.h
lustre/llite/dir.c
lustre/mdt/mdt_handler.c
lustre/osd-ldiskfs/osd_handler.c
lustre/osd-zfs/osd_internal.h
lustre/osd-zfs/osd_object.c
lustre/osd-zfs/osd_xattr.c
lustre/ptlrpc/pack_generic.c
lustre/ptlrpc/wiretest.c
lustre/tests/sanity.sh
lustre/utils/lfs.c
lustre/utils/liblustreapi.c
lustre/utils/liblustreapi_layout.c
lustre/utils/wiretest.c