xfs
[Top] [All Lists]

Re: Could not allocate buf during xfs_fsr?

To: Justin Piszcz <jpiszcz@xxxxxxxxxxxxxxx>
Subject: Re: Could not allocate buf during xfs_fsr?
From: Nathan Scott <nathans@xxxxxxx>
Date: Mon, 27 Mar 2006 08:55:01 +1000
Cc: linux-xfs@xxxxxxxxxxx
In-reply-to: <Pine.LNX.4.64.0603261730040.13535@p34>; from jpiszcz@xxxxxxxxxxxxxxx on Sun, Mar 26, 2006 at 05:31:32PM -0500
References: <Pine.LNX.4.64.0603260919080.17017@p34> <20060327075716.C753448@xxxxxxxxxxxxxxxxxxxxxxxx> <Pine.LNX.4.64.0603261730040.13535@p34>
Sender: linux-xfs-bounce@xxxxxxxxxxx
User-agent: Mutt/1.2.5i
On Sun, Mar 26, 2006 at 05:31:32PM -0500, Justin Piszcz wrote:
> # xfs_fsr -d /dev/hdb1 > /tmp/log 2>&1
> The box has 1GB of physical ram with 2GB of swap.
> ...
> # xfs_fsr -d /dev/hdb1 > /tmp/log 2>&1
> ...
> DEBUG: fsize=731070464 blsz_dio=16773120 d_min=512 d_max=2147483136 pgsz=4096
> Temporary file has 4 extents (2 in original)
> ino=183843 extents=4 can_save=3 tmp=/d3/.fsr/ag14/tmp13566
> DEBUG: fsize=733804544 blsz_dio=16773120 d_min=512 d_max=2147483136 pgsz=4096
> could not allocate buf: /d3/.fsr/ag14/tmp13566
> ino=183842 extents=3 can_save=2 tmp=/d3/.fsr/ag15/tmp13566
> DEBUG: fsize=733184308 blsz_dio=16773120 d_min=512 d_max=2147483136 pgsz=4096
> could not allocate buf: /d3/.fsr/ag15/tmp13566
> ino=183844 extents=3 can_save=2 tmp=/d3/.fsr/ag0/tmp13566
> DEBUG: fsize=734341120 blsz_dio=16773120 d_min=512 d_max=2147483136 pgsz=4096
> could not allocate buf: /d3/.fsr/ag0/tmp13566
> ino=183845 extents=3 can_save=2 tmp=/d3/.fsr/ag1/tmp13566
> DEBUG: fsize=733757440 blsz_dio=16773120 d_min=512 d_max=2147483136 pgsz=4096
> could not allocate buf: /d3/.fsr/ag1/tmp13566
> 
> Any clues to the proper fix?

Hmm, odd.  Its trying to allocate 16MG - 4KB, which looks like
the BUFFERMAX sizing case in xfs_fsr.c... which shouldn't really
pose a problem.  Unless there's a leak or something like that -
is the resident set size (RSS) column in top(1) for fsr growing
unbounded?  I can see a couple of leaks on error paths in there,
perhaps thats it, but I doubt it.

We could change the algorithm to reduce the buffer size if the
allocation fails, but thats likely to just delay the inevitable,
if it is fsr claiming all your memory.  Another thing to try
would be running fsr under one of the memory-problem-detection-
utilities like valgrind.

cheers.

-- 
Nathan


<Prev in Thread] Current Thread [Next in Thread>