]> git.apps.os.sepia.ceph.com Git - xfstests-dev.git/commit
xfs/133-4: filter redundant projid 0 quota report info out
authorZorro Lang <zlang@redhat.com>
Thu, 12 May 2016 02:55:19 +0000 (10:55 +0800)
committerEryu Guan <eguan@redhat.com>
Wed, 15 Jun 2016 07:06:57 +0000 (15:06 +0800)
commit8469a8c1b36cda424feeb33a95952d09630bf9c4
treedbb1208ee050a91ddeca1d392bccd45d8732caa2
parent048edf040490c8480db111849420492f78121846
xfs/133-4: filter redundant projid 0 quota report info out

After GETNEXTQUOTA ioctl being supported, xfs_quota -c "report"
always outputs one more quota line about default quota (as project
ID 0). In order to fix this problem, xfsprogs has merged commit
3d607a1.

Now xfstests face this same problem from this issue. xfs/133 and
xfs/134 can't match their golden output, due to this one more line
quota report output. So this patch filters this redundant quota info
out.

There're 3 kinds of xfsprogs:
1. not support GETNEXTQUOTA
2. support GETNEXTQUOTA but not merged commit 3d607a1
3. the latest version supports all

The 1st one won't report Project ID 0, the 2nd will report projid 0
info as "(null) 0 0 0 ...", the 3rd will report projid 0 info as
"#0 0 0 0 ...". To deal with all of these situations, we will use

  _filter_quota | grep -v "^#0 \|^(null) "

But if someone specifies a name for projid 0, e.g.
  # cat $projid_file
  # root:0

I think that means someone wants to deal with it by himself, the
common filter won't filter it out.

Signed-off-by: Zorro Lang <zlang@redhat.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Eryu Guan <eguan@redhat.com>
common/filter
tests/xfs/133
tests/xfs/134