From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bob Peterson Date: Fri, 4 Aug 2017 13:21:44 -0400 (EDT) Subject: [Cluster-devel] [PATCH] gfs2: forcibly flush ail to relieve memory pressure In-Reply-To: <1501864822-32906-1-git-send-email-adas@redhat.com> References: <1501864822-32906-1-git-send-email-adas@redhat.com> Message-ID: <2033509119.38883626.1501867304650.JavaMail.zimbra@redhat.com> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit ----- Original Message ----- | On systems with low memory, it is possible for gfs2 to infinitely | loop in balance_dirty_pages() under heavy IO (creating sparse files). | | balance_dirty_pages() attempts to write out the dirty pages via | gfs2_writepages() but none are found because these dirty pages are | being used by the journaling code in the ail. Normally, the journal | has an upper threshold which when hit triggers an automatic flush | of the ail. But this threshold can be higher than the number of | allowable dirty pages and result in the ail never being flushed. | | This patch forces an ail flush when gfs2_writepages() fails to write | anything. This is a good indication that the ail might be holding | some dirty pages. | | Resolves: rhbz#1389079 | Signed-off-by: Abhi Das | --- | fs/gfs2/aops.c | 14 +++++++++++++- | fs/gfs2/incore.h | 1 + | fs/gfs2/log.c | 4 ++++ | 3 files changed, 18 insertions(+), 1 deletion(-) Hi, Looks good. This is now pushed to the for-next branch of the linux-gfs2 tree: https://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2.git/commit/fs/gfs2?h=for-next&id=9513f7bd924e64b4a75bdb99f6d85027b799e1ba Regards, Bob Peterson Red Hat File Systems