I’m in charge of some applications that manage many TB of images. We’ve found that storing file paths in the database to be best.
There are a couple of issues:
- database storage is usually more expensive than file system storage
- you can super-accelerate file system access with standard off the shelf products
- for example, many web servers use the operating system’s sendfile() system call to asynchronously send a file directly from the file system to the network interface. Images stored in a database don’t benefit from this optimization.
- things like web servers, etc, need no special coding or processing to access images in the file system
- databases win out where transactional integrity between the image and metadata are important.
- it is more complex to manage integrity between db metadata and file system data
- it is difficult (within the context of a web application) to guarantee data has been flushed to disk on the filesystem
Related Posts:
- Difference between partition key, composite key and clustering key in Cassandra?
- How SID is different from Service name in Oracle tnsnames.ora
- What is a relation in database terminology?
- Will it break my site if I delete all transient records in wp_options table?
- Safest way to bulk delete post revisions
- Please explain how WordPress works with MySQL character set and collation at a low level
- How many users can WordPress handle?
- Automate WordPress Database Upgrade
- WordPress database scalability from the code perspective
- Why does $wpdb return strings for mysql integer values?
- How can I migrate from another platform to WordPress (using the same domain) and launch when ready?
- Where are image paths to product category images stored in WordPress database
- What’s the database relationship between a post and its attachments
- how do I determine which image is the featured image in the database
- Prevent changing the length of post_name column on WordPress Update
- Why does dbDelta() not catch MysqlErrors?
- Migrate a Non WordPress database to wordpress [closed]
- Moving an entire wordpress site from one domain to a new domain and database
- how to transfer wordpress sql/database from local to live
- Custom DB_COLLATE (collation) value not working on fresh install?
- What causes the “max_user_connections” warning on WordPress frontend?
- Get Database Credentials from within the themes file
- what to do when your WordPress database is too large?
- Change all http to https in mysql databse?
- How does WordPress create its database during installation?
- WordPress DB: options-table –> 32 gzipcompression?
- Subscribers to posts
- $wpdb->update has finished saving trigger?
- Having issues with wp_postmeta and wp_usermeta tables too big
- WordPress site uses MyISAM, should I switch to InnoDB necessary?
- WP Database Table to CSV file
- How can I UN-orphan media files?
- Does WordPress always create unique passwords?
- Uppercase to sentence case for post titles
- How to retrieve and show database table in wordpress dashboard
- Moving to another host; which tables to move in a database
- Merge two WordPress installations into one, and keep posts separated?
- Moving online website to MAMP or dumb idea?
- How can I transition a site from using the Beta Tester plugin to a “normal” install?
- Storing data for a wordpress plugin
- WordPress database import: Row size too large
- Advanced SELECT query with condtional statements
- WordPress choose wrong database
- How can I (semi) automate a database export and import to a different location?
- Insert post in another database
- Improve performance by removing unnecessary database queries
- Redirecting to old domain after migration website
- Localhost keeps redirecting to live domain
- Unable to set a default serialized array using dbdelta()
- Child parent relationship inside WP DB
- What does wp_term_taxonomy.parent reference?
- How to get nav_menu_item_id and slug from wp database
- Is there a way to execute a php script outside WordPress?
- Make changes of wp-db.php file persistent against updates
- How can I restrict php mail() to only send me one email after a db error
- Change the default data installed when setting up WordPress
- How to delete post comments from the database via SQL statement?
- Why does changing Database Table Prefixes result in loss of content?
- How to connect and insert data in database of wordpress?
- $wpdb->get_var – What value is returned when zero records are found?
- wp_option table error while importing
- SymmetricDS in dev + prod workflow?
- Fixing YARPP plugin FULLTEXT MySQL indexing
- What is wrong here? Issue with post_id and meta_value
- Error establishing a database connection in wordpress site , website not opening
- Counting post and changing roles in mysql database. Query not code
- wpdb Insert unknown post data dynamic foreach loop
- How do I use a database in a custom theme?
- Deleting empty meta key values
- I imported an restore an database and It shows #1067 – Invalid default value for ‘user_registered’
- WP 5.5, child themes, customizer and a weird cache issue
- How do you enable scripts on a WordPress installation in Softaculous?
- How to rerieve comments and their replies from DB
- Inserting data with Geometry field
- Best way to store 1 billion+ posts?
- Export only a part of the database for migration
- Why am I being prompted to reinstall wordpress?
- What’s the easiest way to connect external database and display data on wordpress?
- database error WordPress move from one hosting to other
- Character encoding issue – black diamond question marks on imported post excerpts
- Same DB for live and dev versions
- update multiple user meta field based on another meta field
- After renaming MySQL database, I can no longer access my Blog page
- Reinstall wordpress/mySQL caused database problem
- execute custom function on database connection error
- Call to a member function insert()
- Create a new table on the database and save parameters from a contact form
- not saving post in wp_post wordpress database table
- How to have WP Search widget index dynamically generated content?
- Preventing concurrent update of data
- How to add data from wordpress tables to new database tables you have created
- Category not displaying in add post, edit post, and categories page.
- Creating Tables in WordPress Database
- Calling update_user_meta inside of another function doesn’t work
- How to back-up a database on IIS
- $wpdb->prepare returns empty array
- Prevent creation of unused database tables?
- How to store a plain password in WordPress database in another field
- Where are database files of a WordPress website?
- How to properly configure SSL connection to remote azure database for running queries within a WordPress environment