Details

    • Bug
    • Resolution: Fixed
    • Major
    • Lustre 2.8.0
    • Lustre 2.7.0, Lustre 2.8.0
    • None
    • 3
    • 9223372036854775807

    Description

      In lustre 2.7, inode I_NEW state is cleared in the later phase, which cause the following owner/group changing (in osd_attr_init0()) will be performed in I_NEW state, which means the dquot_initialize() won't be skipped for these operations,

      2.7.0

      /**
       * Helper function for osd_object_create()
       *
       * \retval 0, on success
       */
      static int __osd_object_create(struct osd_thread_info *info,
                                     struct osd_object *obj, struct lu_attr *attr,
                                     struct dt_allocation_hint *hint,
                                     struct dt_object_format *dof,
                                     struct thandle *th)
      {
              int     result;
              __u32   umask;
      
              /* we drop umask so that permissions we pass are not affected */
              umask = current->fs->umask;
              current->fs->umask = 0;
      
              result = osd_create_type_f(dof->dof_type)(info, obj, attr, hint, dof,
                                                        th);
              if (result == 0) {
                      osd_attr_init(info, obj, attr, dof);
                      osd_object_init0(obj);
              }
      
              if (obj->oo_inode != NULL) {
                      LASSERT(obj->oo_inode->i_state & I_NEW);
      
                      unlock_new_inode(obj->oo_inode);  --->It will unlock new inode here, so it will cause the above osd_attr_init to call quota_initialization (with I_NEW).  But in 2.6.0, we used to unlock the new inode in ldiskfs_new_inode.
              }
      
              /* restore previous umask value */
              current->fs->umask = umask;
      
              return result;
      }
      

      It is caused by this patch
      http://review.whamcloud.com/13187

      Attachments

        Issue Links

          Activity

            People

              yong.fan nasf (Inactive)
              di.wang Di Wang
              Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: