Details

    • Technical task
    • Resolution: Duplicate
    • Critical
    • None
    • Lustre 2.5.0
    • 9857

    Attachments

      Activity

        [LU-3814] Fix sanity-hsm test 24: "Release does not change a/mtime (i/o)"
        jhammond John Hammond added a comment -

        Duplicate of LU-3811.

        jhammond John Hammond added a comment - Duplicate of LU-3811 .

        I see. Thanks for the experiment.

        jay Jinshan Xiong (Inactive) added a comment - I see. Thanks for the experiment.
        jhammond John Hammond added a comment -

        On http://review.whamcloud.com/7461 there was some discussion about setting the inode timestamps in mdt_hsm_release(). To test this I compared 7442+7461 with setting LA_

        {A,M,C}TIME to 7442+7461 without setting LA_{A,M,C}

        TIME. The script I used (hsm-times.sh) is attached. In the timestamp lines the first column is the current time, the second, third, and fourth are the atime, mtime, and ctime. I ran simultaneously on two nodes so the command execution times are all the same upto 1 second.

        ### without LA_ATIME | LA_MTIME | LA_CTIME
        1377703320:
        # sys_creat /mnt/lustre/f0
        1377703320: 1377703320 1377703320 1377703320
        1377703325: 1377703320 1377703320 1377703320
        # dd if=/dev/zero of=/mnt/lustre/f0 bs=1M count=10 conv=fsync status=noxfer
        10+0 records in
        10+0 records out
        1377703325: 1377703320 1377703325 1377703325
        1377703330: 1377703320 1377703325 1377703325
        # dd if=/mnt/lustre/f0 of=/dev/null bs=1M count=10 status=noxfer
        10+0 records in
        10+0 records out
        1377703330: 1377703330 1377703325 1377703325
        1377703335: 1377703330 1377703325 1377703325
        # dd if=/dev/zero of=/mnt/lustre/f0 bs=1M count=1 conv=fsync,notrunc status=noxfer
        1+0 records in
        1+0 records out
        1377703335: 1377703330 1377703335 1377703335
        1377703340: 1377703330 1377703335 1377703335
        # remount_clients
        1377703341: 1377703330 1377703335 1377703335
        1377703346: 1377703330 1377703335 1377703335
        # lfs hsm_archive /mnt/lustre/f0
        1377703346: 1377703330 1377703335 1377703335
        1377703361: 1377703330 1377703335 1377703335
        1377703366: 1377703330 1377703335 1377703335
        # lfs hsm_release /mnt/lustre/f0
        1377703366: 1377703330 1377703335 1377703335
        1377703371: 1377703330 1377703335 1377703335
        # remount_clients
        1377703371: 1377703320 1377703325 1377703325
        
        ### with LA_ATIME | LA_MTIME | LA_CTIME
        1377703320:
        # sys_creat /mnt/lustre/f0
        1377703320: 1377703320 1377703320 1377703320
        1377703325: 1377703320 1377703320 1377703320
        # dd if=/dev/zero of=/mnt/lustre/f0 bs=1M count=10 conv=fsync status=noxfer
        10+0 records in
        10+0 records out
        1377703325: 1377703320 1377703325 1377703325
        1377703330: 1377703320 1377703325 1377703325
        # dd if=/mnt/lustre/f0 of=/dev/null bs=1M count=10 status=noxfer
        10+0 records in
        10+0 records out
        1377703330: 1377703330 1377703325 1377703325
        1377703335: 1377703330 1377703325 1377703325
        # dd if=/dev/zero of=/mnt/lustre/f0 bs=1M count=1 conv=fsync,notrunc status=noxfer
        1+0 records in
        1+0 records out
        1377703335: 1377703330 1377703335 1377703335
        1377703340: 1377703330 1377703335 1377703335
        # remount_clients
        1377703341: 1377703330 1377703335 1377703335
        1377703346: 1377703330 1377703335 1377703335
        # lfs hsm_archive /mnt/lustre/f0
        1377703346: 1377703330 1377703335 1377703335
        1377703361: 1377703330 1377703335 1377703335
        1377703366: 1377703330 1377703335 1377703335
        # lfs hsm_release /mnt/lustre/f0
        1377703366: 1377703330 1377703335 1377703335
        1377703371: 1377703330 1377703335 1377703335
        # remount_clients
        1377703371: 1377703330 1377703335 1377703335
        

        Without setting the timestamps, after release and remount, all timestamps have reverted to those from the first write.

        I tried increasing the sleep duration to 30, 60, and 120, and still saw that without setting the timestamps in mdt_hsm_release() the final timestamps would be incorrect.

        jhammond John Hammond added a comment - On http://review.whamcloud.com/7461 there was some discussion about setting the inode timestamps in mdt_hsm_release(). To test this I compared 7442+7461 with setting LA_ {A,M,C}TIME to 7442+7461 without setting LA_{A,M,C} TIME. The script I used (hsm-times.sh) is attached. In the timestamp lines the first column is the current time, the second, third, and fourth are the atime, mtime, and ctime. I ran simultaneously on two nodes so the command execution times are all the same upto 1 second. ### without LA_ATIME | LA_MTIME | LA_CTIME 1377703320: # sys_creat /mnt/lustre/f0 1377703320: 1377703320 1377703320 1377703320 1377703325: 1377703320 1377703320 1377703320 # dd if=/dev/zero of=/mnt/lustre/f0 bs=1M count=10 conv=fsync status=noxfer 10+0 records in 10+0 records out 1377703325: 1377703320 1377703325 1377703325 1377703330: 1377703320 1377703325 1377703325 # dd if=/mnt/lustre/f0 of=/dev/null bs=1M count=10 status=noxfer 10+0 records in 10+0 records out 1377703330: 1377703330 1377703325 1377703325 1377703335: 1377703330 1377703325 1377703325 # dd if=/dev/zero of=/mnt/lustre/f0 bs=1M count=1 conv=fsync,notrunc status=noxfer 1+0 records in 1+0 records out 1377703335: 1377703330 1377703335 1377703335 1377703340: 1377703330 1377703335 1377703335 # remount_clients 1377703341: 1377703330 1377703335 1377703335 1377703346: 1377703330 1377703335 1377703335 # lfs hsm_archive /mnt/lustre/f0 1377703346: 1377703330 1377703335 1377703335 1377703361: 1377703330 1377703335 1377703335 1377703366: 1377703330 1377703335 1377703335 # lfs hsm_release /mnt/lustre/f0 1377703366: 1377703330 1377703335 1377703335 1377703371: 1377703330 1377703335 1377703335 # remount_clients 1377703371: 1377703320 1377703325 1377703325 ### with LA_ATIME | LA_MTIME | LA_CTIME 1377703320: # sys_creat /mnt/lustre/f0 1377703320: 1377703320 1377703320 1377703320 1377703325: 1377703320 1377703320 1377703320 # dd if=/dev/zero of=/mnt/lustre/f0 bs=1M count=10 conv=fsync status=noxfer 10+0 records in 10+0 records out 1377703325: 1377703320 1377703325 1377703325 1377703330: 1377703320 1377703325 1377703325 # dd if=/mnt/lustre/f0 of=/dev/null bs=1M count=10 status=noxfer 10+0 records in 10+0 records out 1377703330: 1377703330 1377703325 1377703325 1377703335: 1377703330 1377703325 1377703325 # dd if=/dev/zero of=/mnt/lustre/f0 bs=1M count=1 conv=fsync,notrunc status=noxfer 1+0 records in 1+0 records out 1377703335: 1377703330 1377703335 1377703335 1377703340: 1377703330 1377703335 1377703335 # remount_clients 1377703341: 1377703330 1377703335 1377703335 1377703346: 1377703330 1377703335 1377703335 # lfs hsm_archive /mnt/lustre/f0 1377703346: 1377703330 1377703335 1377703335 1377703361: 1377703330 1377703335 1377703335 1377703366: 1377703330 1377703335 1377703335 # lfs hsm_release /mnt/lustre/f0 1377703366: 1377703330 1377703335 1377703335 1377703371: 1377703330 1377703335 1377703335 # remount_clients 1377703371: 1377703330 1377703335 1377703335 Without setting the timestamps, after release and remount, all timestamps have reverted to those from the first write. I tried increasing the sleep duration to 30, 60, and 120, and still saw that without setting the timestamps in mdt_hsm_release() the final timestamps would be incorrect.
        jhammond John Hammond added a comment - - edited

        Please see

        http://review.whamcloud.com/7442 LU-3832 clio: honor O_NOATIME

        http://review.whamcloud.com/7461 LU-3811 hsm: handle file ownership and timestamps

        http://review.whamcloud.com/7472 LU-3814 hsm: strengthen sanity-hsm test 24

        jhammond John Hammond added a comment - - edited Please see http://review.whamcloud.com/7442 LU-3832 clio: honor O_NOATIME http://review.whamcloud.com/7461 LU-3811 hsm: handle file ownership and timestamps http://review.whamcloud.com/7472 LU-3814 hsm: strengthen sanity-hsm test 24

        John, please take a look since you're looking at this piece of code.

        jay Jinshan Xiong (Inactive) added a comment - John, please take a look since you're looking at this piece of code.

        People

          jhammond John Hammond
          jlevi Jodi Levi (Inactive)
          Votes:
          0 Vote for this issue
          Watchers:
          5 Start watching this issue

          Dates

            Created:
            Updated:
            Resolved: