Gitweb: http://git.fedorahosted.org/git/?p=cluster.git;a=commitdiff;h=183e3d6a5ea335... Commit: 183e3d6a5ea335db7f2c176a2fca009ab18e9f07 Parent: 144f8bed07e000b4394d3846c16a6855c7fb2448 Author: Bob Peterson rpeterso@redhat.com AuthorDate: Mon Dec 17 14:56:16 2012 -0600 Committer: Bob Peterson rpeterso@redhat.com CommitterDate: Fri Apr 5 07:02:04 2013 -0700
gfs2_convert: remember number of blocks when converting quotas
This patch changes function copy_quotas so that it properly copies the di_blocks field from the GFS1 quotas file to its new GFS2 file. If the quota file had a non-trivial size, gfs2_convert was copying all the data and pointers, but not properly setting the di_blocks. This ordinarily isn't tragic because the file is never deleted, but it did flag fsck.gfs2 errors.
rhbz#887374 --- gfs2/convert/gfs2_convert.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/gfs2/convert/gfs2_convert.c b/gfs2/convert/gfs2_convert.c index 613e508..597eb8c 100644 --- a/gfs2/convert/gfs2_convert.c +++ b/gfs2/convert/gfs2_convert.c @@ -2032,6 +2032,7 @@ static void copy_quotas(struct gfs2_sbd *sdp)
nq_ip->i_di.di_height = oq_ip->i_di.di_height; nq_ip->i_di.di_size = oq_ip->i_di.di_size; + nq_ip->i_di.di_blocks = oq_ip->i_di.di_blocks; memcpy(nq_ip->i_bh->b_data + sizeof(struct gfs2_dinode), oq_ip->i_bh->b_data + sizeof(struct gfs2_dinode), sdp->bsize - sizeof(struct gfs2_dinode));