Whamcloud - gitweb
EX-3637 osd-ldiskfs: revalidate nonrotational state
authorAndreas Dilger <adilger@whamcloud.com>
Sat, 4 Dec 2021 05:14:09 +0000 (22:14 -0700)
committerAndreas Dilger <adilger@whamcloud.com>
Wed, 19 Jan 2022 21:27:35 +0000 (21:27 +0000)
commit5a1da772cf1721967d9dae55fae3d19aebba70f8
tree6c533a8b64e121d26854f0baf7c48e41468b8a69
parentebeda3f866d61653cb791d4dae15ef407f611208
EX-3637 osd-ldiskfs: revalidate nonrotational state

Until the nonrotational state of the device is correctly exported by
the underlying storage, periodically recheck the nonrotational state
in case it is changed by the udev/tune_devices.sh script after the
OST is mounted.  It would be possible to check less often (e.g. after
a time limit or some number of operations), but directly checking the
rotational state each time is not more expensive and is only checked
on statfs RPCs (sent about once per 5s from the MDS).

If the nonrotational state is changed and the flash-related cache
parameters have not been explicitly set, then tune them appropriately.

Rename the parameter functions and variables for read_cache_enable,
writethrough_cache_enable, and read_cache_max_filesize to match the
parameter names to make them easier to find in the code.

Lustre-change: https://review.whamcloud.com/45745
Lustre-commit: TBD (from cbc74314532632fbcab88531d43deed7555e125e)

Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Change-Id: Iec78a5d5c22c0474eda84a5a793fbb006f3ebbe5
Reviewed-on: https://review.whamcloud.com/45829
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Li Dongyang <dongyangli@ddn.com>
Reviewed-by: Gaurang Tapase <gtapase@ddn.com>
Tested-by: Gaurang Tapase <gtapase@ddn.com>
lustre/osd-ldiskfs/osd_handler.c
lustre/osd-ldiskfs/osd_internal.h
lustre/osd-ldiskfs/osd_io.c
lustre/osd-ldiskfs/osd_lproc.c
lustre/osd-zfs/osd_internal.h
lustre/osd-zfs/osd_lproc.c