[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: reading an empty directory after reboot is very slow

On Mon, Apr 13, 2015 at 02:39:40PM +0200, Vincent Lefevre wrote:
> I have some regular directory ~/eftests/tmp, and after a reboot,
> I often check that it is empty (as I remove its contents before
> the reboot): from the ~/eftests directory, I do
>   ypig:~/eftests> ll tmp
> which corresponds to
>   ls -bF --color -l tmp
> after alias expansion.
> The problem is that this operation is (always?) very slow: something
> like 100 seconds (1 minute and 40 seconds). It has been reproducible
> for several months. The logs show nothing during this operation.
> Any idea?
> I'm thinking of a possible hardware problem (the machine and the disk
> are 5 years old), but I would have expected some message in the logs
> in such a case. Is there any way to check?

I would probably start with running "strace ll tmp" and seeing what
happens. Does ls hangup on reading its own files, for example (by the
time you get to login, everything that ls depends on SHOULD already be
in the buffers, but you never know), or is it waiting while reading the
directory, or perhaps even waiting while outputting the result?

Some other things to investigate: Is tmp a regular directory? Does 'll
~/eftests' exhibit the same delay? What about some other method of
listing the directory contents such as 'for i in tmp/*; do echo $i;

> -- 
> Vincent Lefèvre <vincent@vinc17.net> - Web: <https://www.vinc17.net/>
> 100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
> Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
> -- 
> To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org 
> with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
> Archive: [🔎] 20150413123940.GA5535@ypig.lip.ens-lyon.fr">https://lists.debian.org/[🔎] 20150413123940.GA5535@ypig.lip.ens-lyon.fr

Attachment: signature.asc
Description: Digital signature

Reply to: