Accessing binary blob data in MySQL backend

csg nginx-forum at nginx.us
Tue May 31 18:42:31 MSD 2011


Igor Sysoev Wrote:
-------------------------------------------------------
 
> I can not say anuthing about subject, I'm just
> interesting are any
> advanatges to store images in MySQL instead of
> file system ?

First of all quite a lot of backend processes and application code
relies on it. Those interfaces cannot be changed easily. But on the
other hand for the ease of handling the data. For redundancy it is much
easier and more performant to do MySQL replication instead of file
system based approaches. With millions of files even when using deep
hashed subdirectory trees a full rsync(1) run would take several hours
up to half a day to perform a sync. Even when using tools utilizing the
inotify(7) framework like lsyncd(1) [1] you have to run a full rsync(1)
run from time (e.g., reboots due to kernel updates, inotify event
overflow, etc.). With data backup you would face the same issues, too.
As company policies discourage the use of AGPL-licenses software,
MongoDB/gridfs is also not an option. Our current solution is Apache 2.2
MPM worker/Perl-based but on the long term this does not scale too well
anymore, that's why we are looking for alternatives.

[1] http://code.google.com/p/lsyncd/

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,202577,202648#msg-202648




More information about the nginx mailing list