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

ll_dom_lock_cancel() should zero kms attribute

Details

    • 3
    • 9223372036854775807

    Description

      ll_dom_lock_cancel() should set lov->lloi_kms to 0 like in mdc_ldlm_blocking_ast(). Otherwise, obsolete file size can be brought back.

      The below test illustrates the issue:

      test_5() {
              $MULTIOP $DIR1/$tfile Oz40960w100_z200w100c &
              MULTIPID=$!
      
              # let MULTIPID to create the file                                                                                                                                            
              sleep 1
              $MULTIOP $DIR2/$tfile oO_RDWR:Tw100c
              kill -USR1 $MULTIPID
              wait
              $MULTIOP $DIR2/$tfile oO_RDWR:z400w100c
              $CHECKSTAT -s 500 $DIR2/$tfile || error "wrong size"
      }
      run_test 5 "Race two writes, check file size"
      

      The $DIR2/$tfile should be 500 bytes at the end. We get 4096.

      == sanity-dom test 5: Race two writes, check file size =============================================== 12:29:42 (1557826182)
      /mnt/lustre2/f5.sanity-dom has size 4096, not 500
       sanity-dom test_5: @@@@@@ FAIL: wrong size 
        Trace dump:
        = /home/vs/lustre-release/lustre/tests/test-framework.sh:5873:error()
        = sanity-dom.sh:133:test_5()
        = /home/vs/lustre-release/lustre/tests/test-framework.sh:6160:run_one()
        = /home/vs/lustre-release/lustre/tests/test-framework.sh:6199:run_one_logged()
        = /home/vs/lustre-release/lustre/tests/test-framework.sh:5998:run_test()
        = sanity-dom.sh:135:main()
      Dumping lctl log to /tmp/test_logs/1557826153/sanity-dom.test_5.*.1557826183.log
      Dumping logs only on local client.
      Resetting fail_loc on all nodes...done.
      

       

      Attachments

        Activity

          [LU-12296] ll_dom_lock_cancel() should zero kms attribute

          Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/40296/
          Subject: LU-12296 llite: improve ll_dom_lock_cancel
          Project: fs/lustre-release
          Branch: b2_12
          Current Patch Set:
          Commit: 98ee0d5b10858287c74e1b7d51129b7a5fd97ae9

          gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/40296/ Subject: LU-12296 llite: improve ll_dom_lock_cancel Project: fs/lustre-release Branch: b2_12 Current Patch Set: Commit: 98ee0d5b10858287c74e1b7d51129b7a5fd97ae9

          Mike Pershin (mpershin@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/40296
          Subject: LU-12296 llite: improve ll_dom_lock_cancel
          Project: fs/lustre-release
          Branch: b2_12
          Current Patch Set: 1
          Commit: b1352e2139481852bb58b0147d0c133d77e1293e

          gerrit Gerrit Updater added a comment - Mike Pershin (mpershin@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/40296 Subject: LU-12296 llite: improve ll_dom_lock_cancel Project: fs/lustre-release Branch: b2_12 Current Patch Set: 1 Commit: b1352e2139481852bb58b0147d0c133d77e1293e

          Mike Pershin (mpershin@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/40277
          Subject: LU-12296 llite: ll_dom_lock_cancel() KMS fixes
          Project: fs/lustre-release
          Branch: b2_12
          Current Patch Set: 1
          Commit: f35dd0ca455172913916411886758112514e3408

          gerrit Gerrit Updater added a comment - Mike Pershin (mpershin@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/40277 Subject: LU-12296 llite: ll_dom_lock_cancel() KMS fixes Project: fs/lustre-release Branch: b2_12 Current Patch Set: 1 Commit: f35dd0ca455172913916411886758112514e3408
          pjones Peter Jones added a comment -

          Landed for 2.13

          pjones Peter Jones added a comment - Landed for 2.13

          Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/34858/
          Subject: LU-12296 llite: improve ll_dom_lock_cancel
          Project: fs/lustre-release
          Branch: master
          Current Patch Set:
          Commit: 707bab62f5d6c704b30e4ee9e769b5c9f026e1e7

          gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/34858/ Subject: LU-12296 llite: improve ll_dom_lock_cancel Project: fs/lustre-release Branch: master Current Patch Set: Commit: 707bab62f5d6c704b30e4ee9e769b5c9f026e1e7

          Vladimir Saveliev (c17830@cray.com) uploaded a new patch: https://review.whamcloud.com/34858
          Subject: LU-12296 llite: clear KMS on DoM lock cancel
          Project: fs/lustre-release
          Branch: master
          Current Patch Set: 1
          Commit: 805ee4ee0cd9fe926700d786ace2103a1070b9ac

          gerrit Gerrit Updater added a comment - Vladimir Saveliev (c17830@cray.com) uploaded a new patch: https://review.whamcloud.com/34858 Subject: LU-12296 llite: clear KMS on DoM lock cancel Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: 805ee4ee0cd9fe926700d786ace2103a1070b9ac

          People

            vsaveliev Vladimir Saveliev
            vsaveliev Vladimir Saveliev
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: