| To: | linux-xfs@xxxxxxxxxxx |
|---|---|
| Subject: | bad calc for flagging pagf_metadata |
| From: | Roger Willcocks <willcor@xxxxxxxxx> |
| Date: | Wed, 26 Oct 2005 13:54:37 +0100 |
| Domainkey-signature: | a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=uMSpm3hQtpvJFu6ujkJXUpdVq8C5+7YI4sBoKVM33EGXnKXab27SmWmkySoLQjrmJC99cMJD8PIMR9FlXFGbcRkcqR1nFjhW9zOm5uDIZ/D3Fnc83rjOnyO41nGCUhel+d0lP++4MXi8a1NAdCthlX2mnV3NjeHuKI90wd6iLiw= |
| Sender: | linux-xfs-bounce@xxxxxxxxxxx |
When XFS_MOUNT_32BITINODES is true and imaxpct is set, the calculation
for max_metadata in xfs_initialize_perag is incorrect, yielding a
value that's tens of thousands of times too large. This results in the
entire area of the disk that's available for inodes being flagged as
preferred for metadata. The allocator won't touch that area until all
the other ag's are full. Patch-like fix below. Since this only sets a
runtime ag preference flag, it's safe for existing file systems.
--
Roger
xfs_mount.c / xfs_initialize_perag:
icount = sbp->sb_dblocks * sbp->sb_imax_pct;
do_div(icount, 100);
icount += sbp->sb_agblocks - 1;
- do_div(icount, mp->m_ialloc_blks);
+ do_div(icount, sbp->sb_agblocks);
max_metadata = icount;
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | TAKE 944820 - fix large direct IOs, Nathan Scott |
|---|---|
| Next by Date: | Re: bad calc for flagging pagf_metadata, Eric Sandeen |
| Previous by Thread: | TAKE 944820 - fix large direct IOs, Nathan Scott |
| Next by Thread: | Re: bad calc for flagging pagf_metadata, Eric Sandeen |
| Indexes: | [Date] [Thread] [Top] [All Lists] |