Re: too many links error when creating directories

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



On 9/27/07, chitgoks <chitgoks@xxxxxxxxx> wrote:
> john yeah. a few images per directory (for now, maybe in the future more
> images). the directory name would point to the username.

The traditional way to deal with this would be to split up the
usernames alphabetically, e.g., make subdirectories of the top
directory for each of the 26 letters of the alphabet and then put the
directories matching the usernames in the subdirectory corresponding
to their first letter.

a/alice
b/bob
b/bill
c/charlie
e/etc

If you have more than 32000 users starting with any particular letter,
such as "s", then you do the same but with the first two letters:

s/m/smith
s/t/stevens

Of course all of this is just a trivial case of a hashing algorithm
where the extra layers of directories correspond to hash buckets, so
you can switch to a more complex hash if you prefer.
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux