Three hex characters will distribute 400K files into 100 files per directory. Cache::FileCache uses a similar scheme.use Digest::MD5 qw(md5_hex); my $name = "123456.jpg"; my $path = md5_hex($name); $path =~ s#^(.)(.)(.).*#$1/$2/$3/$name#;
-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.
In reply to •Re: Need directory scheme to store 400,000 images
by merlyn
in thread Need directory scheme to store 400,000 images
by markjugg
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |