[PATCH 2/3] XFS: Print error when unable to allocate inodes.

raghu.prabhu13 at gmail.com raghu.prabhu13 at gmail.com
Sun Jun 3 06:12:48 CDT 2012


From: Raghavendra D Prabhu <rprabhu at wnohang.net>

When xfs_ialloc_ag_alloc is unable to allocate required number of inodes, printk
error about it once.

Signed-off-by: Raghavendra D Prabhu <rprabhu at wnohang.net>
---
 fs/xfs/xfs_ialloc.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/fs/xfs/xfs_ialloc.c b/fs/xfs/xfs_ialloc.c
index a02180a..343d7a8 100644
--- a/fs/xfs/xfs_ialloc.c
+++ b/fs/xfs/xfs_ialloc.c
@@ -744,6 +744,8 @@ xfs_dialloc(
 				xfs_trans_brelse(tp, agbp);
 				if (error == ENOSPC) {
 					*inop = NULLFSINO;
+					pr_err_once("XFS (%s): Unable to allocate inodes: Required %d, Current %llu, Maximum %llu",
+							mp->m_fsname, XFS_IALLOC_INODES(mp), mp->m_sb.sb_icount, mp->m_maxicount);
 					return 0;
 				} else
 					return error;
-- 
1.7.10.3



More information about the xfs mailing list