Create Attachments on the local filesystem

Christopher Hicks chicks at
Mon Oct 20 23:16:06 UTC 2003

On Mon, 20 Oct 2003, Myk Melez wrote:
> What gets much slower?

Programmer brains when people start debating whether it's better to store 
database data in the database or the file system.  ;)  This has been 
redebated so many times.....

I haven't benchmarked this stuff personally and given that our bugzilla is
one of the smallest databases we have as far as file attachments go
clearly I'm in the "put it all in the database camp".  But a few facts
stand out for me.  Some folks go to extensive effort to structure their
squid caches (and other caches) as multi-level directory structures to
overcome filesystem perfomance issues.  It seems that dumping gigabytes of
little files into many filesystems (maybe even yours!) can cause directory
lookup time to rise dramatically.  Databases can have performance problems
too, but MySQL gives me a lot more levers to tinker with to make it work
well than any filesystem and making a two or three level deep structure to
store a linear data set doesn't seem like a lever to me because I like to
keep levers as _simple_ machines.

It just seems so so much easier to let the database take care of it (and
it seems to do that just fine) than to try to overcome the filesystem
scaling issues, yet many people going down that road anyway.  One of the
biggest selling points I've repeatedly heard in the community for using
bugzilla is it's performance and scalability far surpass the competition.  
Maybe that's because it relies on a database to store the data?  The slow 
competition is still slowly catching on to this I'm sure.


Programming is a Dark Art, and it will always be. The programmer is
fighting against the two most destructive forces in the universe:
entropy and human stupidity. They're not things you can always
overcome with a "methodology" or on a schedule.
		-Damian Conway, Perl God

More information about the developers mailing list