From mboxrd@z Thu Jan 1 00:00:00 1970 From: Steven Whitehouse Date: Thu, 1 Jun 2017 16:39:25 +0100 Subject: [Cluster-devel] [PATCH 8/8] gfs2: Warn when not deleting inodes under memory pressure In-Reply-To: <1496242992-1607-9-git-send-email-agruenba@redhat.com> References: <1496242992-1607-1-git-send-email-agruenba@redhat.com> <1496242992-1607-9-git-send-email-agruenba@redhat.com> Message-ID: <4613d63e-94c2-c34d-64ff-f639d707ea6c@redhat.com> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Hi, On 31/05/17 16:03, Andreas Gruenbacher wrote: > Signed-off-by: Andreas Gruenbacher > --- > fs/gfs2/super.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/fs/gfs2/super.c b/fs/gfs2/super.c > index ace4814..3637662 100644 > --- a/fs/gfs2/super.c > +++ b/fs/gfs2/super.c > @@ -1548,8 +1548,11 @@ static void gfs2_evict_inode(struct inode *inode) > * will be deallocated when another inode is allocated in the same > * resource group. > */ > - if (current->flags & PF_MEMALLOC) > + if (current->flags & PF_MEMALLOC) { > + fs_warn(sdp, "not deleting inode %llu under memory pressure\n", > + (unsigned long long)ip->i_no_addr); > goto out; > + } > > /* Must not read inode block until block type has been verified */ > error = gfs2_glock_nq_init(ip->i_gl, LM_ST_EXCLUSIVE, GL_SKIP, &gh); NACK for this one. We shouldn't be printing out messages in this case, we just need to handle the situation properly, Steve.