[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gluster-devel] files exist but readdir do not see them
From: |
Emmanuel Dreyfus |
Subject: |
Re: [Gluster-devel] files exist but readdir do not see them |
Date: |
Tue, 12 Jul 2011 08:29:00 +0000 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Mon, Jul 11, 2011 at 11:36:58AM +0000, Emmanuel Dreyfus wrote:
> I tried starting up from scratch: stop/delete/create/start the volume.
> I get exactly the same result.
I think I tracked down the problem. It happens in dht_deitransform()
As I understand, this function decides which subvolume is to use given
an offet to readdir. Here is the important code:
cnt = y % max;
x = y / max;
subvol = conf->subvolumes[cnt];
y is the offset requested in the readdir call, max is the amount of
subvolumes. When I do ls /gfs/misc, two readdir operations are sent,
and I get this:
1st call: y = 0, cnt = 0, max = 2, x = 0
2nd call: y = 776, cnt = 0, max = 2, x = 388
Therefore both readdir calls fetch data from the same subvolume,
which explains why I never see the files from the other ones.
How is it supposed to work? I suspect there is some assumption on
what offsets the client will use in readdir operations. Or did
I misunderstood dht logic?
--
Emmanuel Dreyfus
address@hidden