diff options
Diffstat (limited to 'tests/volume.rc')
-rw-r--r-- | tests/volume.rc | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/tests/volume.rc b/tests/volume.rc index 6477dfb484f..85a2cb01727 100644 --- a/tests/volume.rc +++ b/tests/volume.rc @@ -944,3 +944,33 @@ function number_healer_threads_shd { local pid=$(get_shd_mux_pid $1) pstack $pid | grep $2 | wc -l } + +function get_mtime { + local time=$(get-mdata-xattr -m $1) + if [ $time == "-1" ]; + then + echo $(stat -c %Y $1) + else + echo $time + fi +} + +function get_ctime { + local time=$(get-mdata-xattr -c $1) + if [ $time == "-1" ]; + then + echo $(stat -c %Z $2) + else + echo $time + fi +} + +function get_atime { + local time=$(get-mdata-xattr -a $1) + if [ $time == "-1" ]; + then + echo $(stat -c %X $1) + else + echo $time + fi +} |