Storing confluence attachments in database or file system / best practice

Hi,

what reasons would there be other than running confluence in a cluster to store attachments in the database? ok backup may be a little bit easier but since I backup the home-directory anyway there is no big difference, isn't it?

The local file system access is much faster than our db-connection and if there are a lot of large attachments i would think this would slow down confluence noticeably.

Besides, there must be a reason why file system storage is the default configuration...

thanks in advance for your opinions and experiences!

3 answers

1 accepted

Hi Chrisi,

I can't think in any other reason besides facilitate the backup operation in a non-clustered environment, in fact, depending on the system configuration, store into the database can be wrost than storing into the file system, as you mentioned, file system tends to be faster than database.

Cheers

Not so much back-up but production/DR replication for site failover purposes would be easier with the attachments held in the database.

If the attachments are on a filesystem being replicated (e.g. SRDF or snapshots) and the database replicated separately then to recover to DR you need to make sure that your replication is in sync.

Holding all of the data in the same place would mitigate this requirement.

It depends on the features of the database you have available and its performance. For example if you can afford a well specified Oracle Database and sufficient cache memory then performance of confluence with attachments is pretty good.

If you also have a database replication option such as Active DataGuard then you can replicate your whole database (with attachments) to another site and configure confluence for high availability using DNS resolution (e.g. F5 GTM).

Your attachments and pages are always going to be kept in sync on the remote site, and your recovery point and time of operation will be almost immediate.

If you were trying to do this with your attachments stored in a filesytem - perhaps using a regular rsync with cron... in the event of failure the attachments are likely to be out of sync with the database data.

However Atlassian have now deprecated database attachment storage... I would like to the reasons behind this decision.

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Jul 10, 2018 in Confluence

We want to see the templates you've created in Confluence!

Hi Community, Jessica here from the Confluence Product Marketing team!  July’s community challenge is all about sharing pictures  — and as an extension of our first post on what ...

742 views 21 12
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you