Re: [PATCH 3/7] sysfs: Keep an nlink count on sysfs directories.

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

 



Hello,

On 01/12/2010 10:06 AM, Eric W. Biederman wrote:
>> 64k is too small.  10 gig interfaces can currently service 50-100k users, 
>> each of which requires their own network device.
> 
> 64k is the point at which I stop returning a userful nlink number to
> userspace, sysfs directories can still scale to any size.
> 
> I could legitimately always return nlink == 1, and all userspace
> utilities that I know of would be fine, but I am trying to be a bit
> more polite than that.

I don't think it's more polite.  It's more error-prone.  64k is a
limit where breach would be rare enough to be unexpected but would
still happen on corner cases.  I don't know what would be the end
result of incorrect nlink but it's far better to have something which
behaves consistently than to have something which flips its meaning
after reaching certain rare but still quite possible limit.  If nlink
is something we can ignore, just set it to 1 for all sysfs files.  If
nlink must be kept correct, use 32bit limit and fail to create more.

> I don't see the link count as interesting enough to store more than
> 16bits for it.  Even with 32bits of storage for nlink sysfs would have
> to have to handle the rollover case as I am doing now.  So I don't
> see any advantage to storing more bits.

I really don't think reiserfs's example is a good one to follow
especially with significantly lowered limit.

Thanks.

-- 
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux