Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-11258

lfs hsm_set generates spurious HE_ARCHIVE changelog events

    XMLWordPrintable

Details

    • Bug
    • Resolution: Won't Fix
    • Major
    • None
    • Lustre 2.10.0
    • 3
    • 9223372036854775807

    Description

      When you run a lfs hsm_set that does not change the hsm state of the file in question, a CL_HSM/HE_ARCHIVE changelog entry is generated.

      [root@lustre-client1 tmp]# touch foo
      142962 01CREAT 11:40:46.550070582 2018.08.16 0x0 t=[0x240018aa1:0x72:0x0] ef=0xf u=0:0 nid=192.168.131.17@tcp1 p=[0x240016b60:0x3:0x0] foo
      142963 11CLOSE 11:40:46.556858619 2018.08.16 0x42 t=[0x240018aa1:0x72:0x0] ef=0xf u=0:0 nid=192.168.131.17@tcp1
      [root@lustre-client1 tmp]# lfs hsm_set --exists foo
      142964 16HSM   11:43:11.612093202 2018.08.16 0x280 t=[0x240018aa1:0x72:0x0] ef=0xf u=0:0 nid=192.168.131.17@tcp1
      142965 11CLOSE 11:43:11.620994771 2018.08.16 0x2 t=[0x240018aa1:0x72:0x0] ef=0xf u=0:0 nid=192.168.131.17@tcp1
      [root@lustre-client1 tmp]# lfs hsm_set --exists foo
      142966 16HSM   11:43:27.083503844 2018.08.16 0x0 t=[0x240018aa1:0x72:0x0] ef=0xf u=0:0 nid=192.168.131.17@tcp1
      142967 11CLOSE 11:43:27.092638243 2018.08.16 0x2 t=[0x240018aa1:0x72:0x0] ef=0xf u=0:0 nid=192.168.131.17@tcp1
      

      The first hsm_set yields a 16HSM entry with flags 0x280, which is HE_STATE and no error. The second yields an entry with flags 0x0, which is HE_ARCHIVE and no error.

      Part of the code at issue is mdd_hsm_update_locked() which sets the cl_flags value to include HE_STATE only if the HSM flags changed. If there was no change the default value 0 remains in place, and this happens to correspond to HE_ARCHIVE and no error.

      This appears to have been introduced by LU-7264 and so should be limited to 2.10 and later.

      Attachments

        Activity

          People

            jhammond John Hammond
            olaf Olaf Weber
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: