[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20171031152045.vywymqu3i7ppsk4d@gaztest-VM>
Date: Tue, 31 Oct 2017 20:50:45 +0530
From: Gazala Muhamed <teamathena.nitc@...il.com>
To: tytso@....edu, adilger.kernel@...ger.ca,
linux-ext4@...r.kernel.org, linux-kernel@...r.kernel.org,
teamathena.nitc@...il.com
Subject: [PATCH v3] ext4: Make a log in dmesg when file creation fails due to
no free inodes
The error code for both "out of disk space" and "out of inodes" is the same
This is misleading to the user. Logging the exact reason helps to find
and debug the issue from the user's side.
Fix bug 197335 - https://bugzilla.kernel.org/show_bug.cgi?id=197335
---
Changes in v33
- Use ext4_warning instead of a bare printk
- Signed-off with real name
- Edit commit message
Signed-off-by: Gazala Muhamed <teamathena.nitc@...il.com>
---
fs/ext4/namei.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/fs/ext4/namei.c b/fs/ext4/namei.c
index c1cf020d..4b18badd 100644
--- a/fs/ext4/namei.c
+++ b/fs/ext4/namei.c
@@ -2463,6 +2463,8 @@ static int ext4_create(struct inode *dir, struct dentry *dentry, umode_t mode,
ext4_journal_stop(handle);
if (err == -ENOSPC && ext4_should_retry_alloc(dir->i_sb, &retries))
goto retry;
+ else if (err == -ENOSPC)
+ ext4_warning(dir->i_sb, "No space on disk, out of inodes");
return err;
}
--
2.11.0
Powered by blists - more mailing lists