On Tue, May 08, 2001 at 03:03:28PM +0100, Paul Jakma wrote:
> Last time i tried Reiserfs was an extremely easy way to bring a box
> down. try the following in a scratch dir:
>> for i in `seq 0 1024` ; do for j in `seq 0 32768` ; do mkdir $i ;
> touch $i/$j ; done ; done
>> ext2, while extremely slow as the number of dirs and files gets
> large, survived. reiserfs panic'ed the box. IIRC correctly from l-k,
> reiserfs has problems with being easily provoked into using too much
> memory.
What kernel/Reiser version was that ? I have it running here and it's
ticking along nicely, on the box I'm writing this on (750MHz Athlon, 256M
RAM). Mind you, bash is not what I'd call fast - it started nearly 20 minutes ago,
and it's only on its 5th directory. I did rewrite it slightly as
for i in seq 0 1024;do mkdir $i;for j in seq 0 32768;
do touch $i/$j;done;echo $i;done
just to give me a hint as to what was happening, and because it didn't seem
sensible to generate 32M "cannot make directory" errors. As it was so slow,
I wrote the same loop in Perl as
#!/usr/bin/perl
for $dir (0..1024) {
mkdir $dir, oct"777";
for $file (0..32768) {
open FILE, ">$dir/$file";
close FILE
}
print "$dir\n"
}
It started 10 minutes later than the bash version, but had made 297
directories when both processes failed just now. The box didn't panic,
although with the perl version running the load was around 2.5, with top
showing the perl program taking 95% of the CPU, and the failure was simply
because I ran out of space on the device :-(
Regards,
Niall
P.S. This was with 2.2.18 with ReiserFS version 3.5.29
Maintained by the ILUG website team. The aim of Linux.ie is to
support and help commercial and private users of Linux in Ireland. You can
display ILUG news in your own webpages, read backend
information to find out how. Networking services kindly provided by HEAnet, server kindly donated by
Dell. Linux is a trademark of Linus Torvalds,
used with permission. No penguins were harmed in the production or maintenance
of this highly praised website. Looking for the
Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!