PostgreSQL has support for out-of-line blobs, which it refers to as "large objects".
Such files are split up into small chunks (half a page, IIRC), and Pg can do random I/O on them. It's sort of a primitive transactional filesystem built on top of a database table, with simple permissions and all.
The main PostgreSQL documentation, linked above, provides much more information.