From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Akshat Aranya" Subject: Re: readdir & bonnie++ Date: Mon, 5 Jun 2006 09:06:02 -0400 Message-ID: References: <20060601233334.GA506@fspc268> <20060604094850.GA9923@fspc268> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: linux-fsdevel@vger.kernel.org Return-path: Received: from py-out-1112.google.com ([64.233.166.182]:4060 "EHLO py-out-1112.google.com") by vger.kernel.org with ESMTP id S1751083AbWFENGE (ORCPT ); Mon, 5 Jun 2006 09:06:04 -0400 Received: by py-out-1112.google.com with SMTP id b36so1404856pyb for ; Mon, 05 Jun 2006 06:06:03 -0700 (PDT) To: "Tomas Hruby" In-Reply-To: <20060604094850.GA9923@fspc268> Content-Disposition: inline Sender: linux-fsdevel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org On 6/4/06, Tomas Hruby wrote: > My problem with bonnie happens in a test which counts how many files where > created. It just call readdir in loop and counts how many entries were > returned. As far as I understand the bonnie code, there were no files deleted > yet. > > I checked the glibc code (i hope that the correct one) and it seems that the > loop inside readdir is returned only if there are no more data in the buffer > and so the getdents is called again. My problem is that there SHOULD be the > last entry still in the buffer. > So, what you're saying is that the getdents() call actually returns the last entry, but readdir() somehow ignores that last entry? If that is the case, I would look at the d_off value for that last entry for weirdness. > Tomas -Akshat