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

lod_get_default_lov_striping() misinterprets composite striping for append

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • Lustre 2.16.0
    • None
    • None
    • 3
    • 9223372036854775807

    Description

      In lod_get_default_lov_striping() if the default striping is composite and dah_append_stripes is non zero then we try to read lmm_pattern from a struct lov_comp_md_v1 which isn't really there and we get confused.

      To reproduce:

      $LUSTRE/tets/llmount.sh 
      POOL=lustre.pool0
      lctl pool_new $POOL
      lctl pool_add $POOL OST0000
      lctl pool_add $POOL OST0001
      lfs setstripe -E 1M -c 1 -p $POOL -E 2M -c 2 -p $POOL -E eof -c -1 /mnt/lustre
      lctl set_param debug='+layout trace'
      lctl clear echo XXX >> /mnt/lustre/f0
      lctl dk | grep lod_get_default_lov_striping
      

      Output:

      00000004:00000001:1.0:1649345555.830519:0:1905344:0:(lod_object.c:5263:lod_get_default_lov_striping()) Process entered
      00000004:00000001:1.0:1649345555.830540:0:1905344:0:(lod_object.c:5347:lod_get_default_lov_striping()) Process leaving (rc=18446744073709551594 : -22 : ffffffffffffffea)
      00000004:00000001:1.0:1649345555.830543:0:1905344:0:(lod_object.c:5263:lod_get_default_lov_striping()) Process entered
      00000004:00000001:1.0:1649345555.830553:0:1905344:0:(lod_object.c:5347:lod_get_default_lov_striping()) Process leaving rc=18446744073709551594 : -22 : ffffffffffffffea)
      
                      if (!lov_pattern_supported(v1->lmm_pattern) &&
                          !(v1->lmm_pattern & LOV_PATTERN_F_RELEASED)) {
      			lod_free_def_comp_entries(lds);
                              RETURN(-EINVAL);
                      }
      

      This is because we use composite in two different senses: lti_ea_store contains a composite layout, and we should return a composite layout.

      Attachments

        Issue Links

          Activity

            People

              jhammond John Hammond
              jhammond John Hammond
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: