How OpenProject backup and restore works for packaged and Docker installs
A backup is only useful once you have completed a restore from it, so the question for an operations or security lead is not whether backups run but whether the team can rebuild a working OpenProject from them and show the evidence. The scope of what must be captured depends on how OpenProject was installed. On packaged installs, sudo openproject run backup writes the PostgreSQL dump, attachments, configuration and git and svn repositories to /var/db/openproject/backup. On Docker Compose, the database is dumped with pg_dump from the db container and the Docker volumes are backed up separately. On the all-in-one container, the bind-mounted folders such as /var/lib/openproject carry the state. Each layout has different gaps, so confirm the list against the OpenProject backup documentation for your exact install before you sign off.
Plan for a backup and restore test at four points: the first production go-live, before every upgrade, before any external audit that asks about recoverability, and after any change to storage, the database host or the install method. Pre-upgrade backups matter most because a failed migration is the moment you need a known-good copy. Check the attachment limit early. Backups include attachments only up to a total size, 4096 MB by default, set with OPENPROJECT_BACKUP__ATTACHMENT__SIZE__MAX__SUM__MB in the advanced configuration. If your instance holds more attachment data than that, the backup is silently incomplete for files unless you raise the limit or back up the attachment storage through another route. Decide which path you will use and record it.
Before the restore test, write down what you need to prove: the restored instance logs in through your identity setup, attachments open, work packages and their history match the source, and the PostgreSQL version and required extensions are present (OpenProject officially supports PostgreSQL 16 or later since 16.0.0). Restore into a separate host or Compose project, never over production, and record the time taken, the backup size and any manual steps. Keep backup encryption keys, the SECRET_KEY_BASE value and configuration files in the same recovery plan, because an encrypted or reconfigured instance cannot start without them. Ask your DeployOpen or internal team to confirm these steps against your version and environment before relying on them in an audit.
What a complete OpenProject backup must include
A restorable OpenProject backup is a set of components that work together, not a single file. The database holds the structure of work packages and users, while files, configuration and repositories sit outside it, so each one needs its own capture and check.
PostgreSQL database dump
The dump holds projects, work packages, users, roles and journals. On packaged installs, sudo openproject run backup writes it to /var/db/openproject/backup. On Compose installs, the dump is taken with pg_dump from the db container. Check that the dump file is not empty and that it restores into a scratch database before you rely on it.
Attachment files
Files uploaded to work packages, wiki pages and documents live on disk, not in the database. A dump restores the rows that point to them but not the files themselves, so those links break. Backups include attachments only up to a total size cap, so confirm that the cap covers your current attachment volume before trusting a run.
- Default attachment cap
- 4096 MB
Configuration files
The configuration holds the secret key, database settings, mail, proxy and authentication values that the instance needs to start and to decrypt stored data. Without the matching configuration, a restored database may not start or may not read its own encrypted fields. Store the configuration copy separately from the data copy and keep it access controlled.
Git and SVN repositories
Packaged installs also back up the git and svn repositories that projects link to through the repository module. These are separate directories with their own history. Confirm which repository types your teams use, since a backup that skips them leaves repository links without the code behind them.
Docker volumes and bind mounts
Compose installs keep data in Docker volumes, while the all-in-one container keeps its data in bind-mounted folders such as /var/lib/openproject. Back up these volumes or folders alongside the database dump, and record which paths your deployment uses, because a missing mount leaves the restored instance empty.
Backup docsMatching versions and restore order
A dump, its attachments and its configuration must come from the same instance and the same OpenProject release. Restore the database and files together, then start the application and check its version. Record the release number with every backup so a restore test reflects what you would actually need in an incident.
Running the backup on packaged, Compose and all-in-one installs
Packaged installs from the .deb or .rpm packages use a single built-in command that gathers everything OpenProject needs to recover. Run it on the server as a user with sudo rights, and it writes the output to a fixed backup directory. The run covers the PostgreSQL dump, attachments, configuration and the git and svn repositories, so you do not need to assemble the pieces yourself.
- Command:
sudo openproject run backupstarts the full backup from the server shell. - Output location: The backup is written to
/var/db/openproject/backup, which should be on storage separate from the instance. - Included items: The PostgreSQL dump, attachments, configuration, and git and svn repositories are covered in one run.
- Scheduling: Wrap the command in a cron job or systemd timer, then copy the output off the server on a schedule you set.
- Disk space: Check free space before the run, because the output grows with attachments and repositories.
Confirm the exact command syntax, options and output layout against the backup documentation for your OpenProject version before you write runbooks.
Compose installs split the data across containers and Docker volumes, so there is no single command that captures everything. The database is exported from the database container with pg_dump, and the volumes that hold attachments and configuration are backed up as separate steps. Both parts are needed for a usable restore, and a dump without the volumes leaves attachments missing.
- Database dump: Run
pg_dumpinside the db container to write a logical copy of the PostgreSQL database to a file outside the container. - Volume backup: Back up the Docker volumes that store attachments and application files, using the volume names from your Compose file.
- Consistent pairing: Take the dump and the volume copy close together in time, and label both with the same date so they restore as one set.
- Stopping services: Decide whether to pause writes during the run, since copying files while the application is active can capture partial changes.
- Credentials: Keep the database user and password out of shell history and scripts that other staff can read.
Confirm the pg_dump options, the database container name and the volume names against the backup documentation for your version and your Compose file.
The all-in-one container runs the application and its services in one image and keeps its state in folders bound to the host. Backing up that setup means copying the host folders that the container mounts, such as /var/lib/openproject, along with the database data the image manages. The host path is the source of truth, so the backup is a file-level copy of those folders plus the database export.
- Bind-mounted folders: Identify each host path mapped into the container, and confirm which one holds attachments, configuration and the database files.
- File-level copy: Copy the bind-mounted folders with a tool that preserves ownership and permissions, since the restored files must match the container user.
- Database export: Export the database from inside the container so the dump matches the stored files.
- Version match: Record the image tag used at backup time, because restoring onto a different version needs its own upgrade planning.
- Permissions check: Confirm the backup copy keeps the same owner IDs, since mismatched IDs cause startup failures on restore.
Confirm the mounted paths and the database export method against your container configuration and the backup documentation for your version.
Why attachments can silently fall outside the backup
Attachments are the part of an OpenProject backup most likely to be incomplete without anyone noticing, because the backup command can finish successfully while holding only part of the files. Backups include attachments only up to a total size, which defaults to 4096 MB. The limit is set with the OPENPROJECT_BACKUP__ATTACHMENT__SIZE__MAX__SUM__MB configuration key, documented in the OpenProject advanced configuration guide. Once total attachment storage passes that cap, files beyond it are not part of the archive, so a green job log does not prove every file was captured.
Start by measuring. Add up the size of the attachment directory on the packaged host or the mounted volume on a Docker install, and compare the total with the cap in effect on your instance. If you have raised the cap in the past, confirm the value the running containers or services actually read, since a setting in the wrong environment file has no effect. Record the result alongside the backup date so the comparison is repeatable at each review. Ask your installation partner or check the vendor's documentation to confirm exactly which files the cap counts and how files are ordered when the limit is reached.
If your attachments approach or exceed the cap, plan a separate file-level copy of the attachment storage on its own schedule, using snapshots or a file-level tool that you have tested for restores. Treat the database dump and the attachment copy as two parts of one recovery point, and check that they were taken close together. Raising the cap is an option, but it increases backup time and storage needs, so size the change against your backup window and retention policy before you make it.
Backup options compared by install type and attachment strategy
This table compares the three built-in backup paths for OpenProject and a separate attachment copy, showing what each one captures and what to confirm before relying on it. Read each row against your install type, then check the attachment row, because the default size cap can leave files out of a backup. The main takeaway is that no single path covers everything without verification.
| Approach | What it captures | What to confirm | When it fits |
|---|---|---|---|
Packaged run backup (sudo openproject run backup) | PostgreSQL dump, attachments, configuration, and git and svn repositories, written to /var/db/openproject/backup | Free disk space in the backup path, whether attachments fall under the size cap, and that the output directory is copied off the server | Deb or rpm installs on supported Linux hosts where the built-in command is the standard procedure |
| Docker Compose dump plus volume backup | Database dumped with pg_dump from the db container, plus the Docker volumes that hold application data | The volume names in your Compose file, that the dump and volume copy are taken together, and that restores are tested into a clean stack | Compose deployments where the database runs in its own container and you manage volumes directly |
| All-in-one container bind-mount backup | Bind-mounted host folders such as /var/lib/openproject, which hold the application state | Which host paths your container mounts, whether the database is inside the container or external, and whether a consistent database dump is also taken | Single-container installs where the host folders are the simplest place to find all state |
| Separate attachment copy (outside the built-in backup) | Whatever files you copy from attachment storage, independent of the size cap | The storage location, the total attachment size compared with the default cap of 4096 MB, and how the copy stays in step with the database dump | Instances whose attachments exceed the backup cap or where files must be retained on a separate schedule |
Attachment size cap setting (OPENPROJECT_BACKUP__ATTACHMENT__SIZE__MAX__SUM__MB) | Limits the total attachment size included in a backup, 4096 MB by default | Current attachment total on disk, the value set in your environment, and whether files beyond the limit are absent from the backup | Instances near or above the default limit, where raising the value or adding a separate copy is needed |
| Restore test into a clean environment | Confirms that the dump, volumes or folders, and attachments work together on a second host or stack | The exact restore steps for your install type, the OpenProject version match, and the time and disk the test needs in your environment | Any install type, and before a backup is relied on for recovery or an audit |
Setting up and testing a backup sequence
This sequence confirms what is installed, prepares the database and storage, caps attachment size deliberately, schedules backups, moves copies off the host and proves them with a test restore on a separate machine. The result is a backup you have actually restored, not just one that was written.
Confirm install type and version
Identify whether the instance runs as a packaged install (.deb or .rpm), a Docker Compose stack, or the all-in-one container, and record the exact OpenProject version. The backup steps differ by install type, and a restore must target the same version it came from. Run the version check your install type documents and save the output with the runbook. Done when you have a written record of the install type, the version and the host names of the server or containers.
Check database extensions and storage paths
Confirm the PostgreSQL version is 16 or later, since OpenProject officially supports that from version 16.0.0, and that the pg_trgm, btree_gist and unaccent extensions are present. Then locate where attachments, configuration and the backup target live: /var/db/openproject/backup on packaged installs, or the Docker volumes and bind-mounted folders such as /var/lib/openproject on container installs. Check free disk space on the backup target against the current size of those paths. Done when the extensions are listed as installed and every path that a restore needs is identified and writable by the backup job.
Set the attachment size cap
By default, backups include attachments only up to a total of 4096 MB. Decide whether that limit fits your attachment volume, then set OPENPROJECT_BACKUP__ATTACHMENT__SIZE__MAX__SUM__MB in the configuration your install reads, and restart the services as the configuration documentation describes. Attachments beyond the cap are not in the backup, so the cap must be a recorded decision agreed with the business owner. Done when the effective value is confirmed on the instance and the decision is written down with the date.
Schedule the backup run
On packaged installs, schedule sudo openproject run backup with cron or a systemd timer under a user with the required permissions. On Docker Compose, schedule the pg_dump from the database container together with a backup of the Docker volumes. On the all-in-one container, schedule a backup of the bind-mounted folders. Capture the job output to a log file. Done when a manual run completes and the output lists the database dump, attachments, configuration and repositories, and the scheduled job has run once without errors.
Store copies off the host
Copy each backup set to storage that is separate from the OpenProject host, such as a second server, object storage or a backup platform you already operate, and encrypt copies in transit and at rest. Keep the file names tied to the run date and the OpenProject version. Confirm that the retention period and the access rights match your data protection policy. Done when a copy exists off the host, its checksum matches the original, and someone other than the operator can see the copy location in the runbook.
Restore to a separate test host
Provision a separate host or container set running the same OpenProject version as the source, with the same database extension requirements. Restore the database dump, the attachments and the configuration from an off-host copy, following the restore steps in the backup documentation for your install type. Start the services and do not connect the test host to production users or email. Done when the restore completes without errors and the services report healthy.
Verify users, projects, attachments and login
Sign in as an administrator and as a regular user on the test host. Check that user and group counts look right, that a sample of projects shows its work packages, Gantt data and wiki pages, and that a few attachments open and match their original size. Test a login through the same authentication method production uses. Record the results and the time the restore took. Done when the checklist passes and any gap, such as a missing attachment beyond the cap, is documented and assigned to an owner.
Repeat the test on a schedule
Set a recurring restore test on a separate host, repeated on a cadence your own recovery objectives set, and rerun the verification checklist each time. Record each result, and rerun the sequence after every OpenProject upgrade or change to the attachment cap. Confirm with your team who owns the test and who is informed of failures. Done when the first scheduled test has a recorded result and the next date is on the team calendar.
How to prove a restore works before you need one
A backup that has never been restored is a hypothesis, and the people who ask for evidence (auditors, CISOs and the owners of the business continuity plan) will want to see a completed restore, not a backup log. Schedule a restore test against the output of sudo openproject run backup on packaged installs, or against the database dump and Docker volume copies on Compose and all-in-one containers, and treat the test as a controlled exercise with a written record. Restore into a non-production host that matches the production OpenProject release, PostgreSQL version and extensions, and check the release notes for the version you are restoring before you start. Confirm that the target database has the pg_trgm, btree_gist and unaccent extensions, since the restore will not produce a working instance without them.
Once the restore completes, compare evidence rather than relying on the application looking healthy. Record counts of projects, work packages, users and journals in the source and the restored database, and compare the number of attachment files on disk with the number of attachment records. Check that the attachment total is complete: if the instance holds more than the configured backup limit set with OPENPROJECT_BACKUP__ATTACHMENT__SIZE__MAX__SUM__MB (4096 MB by default), attachments beyond that cap are not in the archive, so the test will reveal a gap that a successful backup run does not. Open a sample of recent work packages with attachments, confirm the files download, and confirm that the configuration and the encryption key or secret material needed by the instance are available to the restore team. Record the backup file name, the run date, the operator, the counts, the discrepancies and the time the restore took.
Write the test up as a short runbook entry that a second engineer could repeat, and keep the results with the backup policy so they can be shown during an assessment. Plan for the test to recur, especially after OpenProject upgrades or changes to storage, and decide who signs off on a failed comparison. Restoring a single accidentally deleted project without rolling back the whole instance is a separate procedure covered in the sibling topic on restoring a deleted OpenProject project, so this test should prove the whole instance comes back, not that one project can be extracted.
Protecting backup copies and credentials
A backup of OpenProject holds the database, attachments and configuration, so it carries the same sensitivity as the live instance. The cards below cover the controls that keep those copies inside your infrastructure, limit who can read them and remove them on a schedule you set.
Encryption at rest for backup storage
The backup output from sudo openproject run backup lands in a local directory, and the Docker approach stores dumps and volume data on the host or in a backup target you choose. OpenProject does not encrypt that output for you in the sources we reviewed, so confirm whether your storage layer (full-disk encryption, an encrypted volume or an encrypted backup repository) covers the backup location. Check that every copy, including copies on removable or secondary media, is encrypted.
Access control on backup folders and volumes
The packaged backup directory and the Docker volumes that hold the database and attachments should be readable only by the service account and a small set of administrators. Review ownership and file modes after each backup run, and confirm that the backup path is not exposed through a web server, a shared network folder or a container mount that other workloads can reach.
Database credentials inside dumps
A PostgreSQL dump can contain role definitions, connection-related settings and data that reference the application database user. Treat the dump as a secret, avoid placing database passwords in shell history or in plain-text scripts, and confirm which credentials the backup job uses. Rotate the database password after restoring into a new environment so an old copy cannot authenticate.
Retention and deletion of old copies
Retention is a policy you set, not a default you can assume. Decide how many daily, weekly and monthly backups to keep, and make sure deletion removes all three parts of a backup (database dump, attachments and configuration) together. Ask your backup tooling vendor or platform team how expired copies are removed from offsite and object storage, since copies that survive pruning can outlive your data retention rules.
Keeping copies inside your infrastructure
Backups of OpenProject contain project data, personal data of users and any attachments, so offsite copies should go to storage in accounts, data centers or regions you approve. Confirm where replicas and cloud snapshots are created, who operates the storage and whether any vendor support process can reach the data. Record the answers as part of your data processing documentation.
Attachment limits and what a backup omits
Backups include attachments only up to a total size, 4096 MB by default, controlled by OPENPROJECT_BACKUP__ATTACHMENT__SIZE__MAX__SUM__MB. Any attachments beyond that cap are not in the archive, so a backup that looks complete may not hold every file. Record the value you use, compare it with your attachment volume, and confirm how files above the cap are protected by another method.
Questions teams ask before backing up OpenProject
Can our team back up a packaged OpenProject install without outside help?
Yes, a team with Linux administration experience can run the backup command on a packaged install, provided it has shell access to the host and knows where the output lands. The command writes the PostgreSQL dump, attachments, configuration and git and svn repositories to /var/db/openproject/backup. The harder part is the recurring routine around it: copying those files off the host, keeping retention rules, and proving that a restore works. Whether that fits your staff depends on how many people already own patching and disaster recovery for the platform. Ask your team to name an owner for the restore test before deciding.
What drives the cost of OpenProject backup and restore work?
The main cost components are internal staff time, backup storage, and restore testing. Staff time covers scheduling, offsite copies, monitoring of backup jobs, and periodic restore drills. Storage grows with the database, the attachment volume and the number of retained copies. Restore testing needs a spare host or environment, which is often the largest hidden cost for small teams. Most of this is recurring, while the initial setup is one-time. When requesting a quote, ask for the retention period, the number of restore tests per year, the storage location, and who performs each test.
Do attachments always end up in an OpenProject backup?
No, attachments are only included up to a total size. The default cap is 4096 MB, and it is set with the configuration key OPENPROJECT_BACKUP__ATTACHMENT__SIZE__MAX__SUM__MB. If your attachment store exceeds that limit, a backup can silently omit files that users expect to recover. Check your current attachment volume against the cap before you rely on the default. Then decide whether to raise the value, back up the attachment storage separately at the file system or volume level, or both. Confirm the chosen approach with a restore test that includes a known attachment.
How do I back up an OpenProject Docker Compose install?
For Docker Compose, the backup dumps the database with pg_dump from the db container and separately backs up the Docker volumes that hold attachments and configuration. Both parts are required, because a database dump alone does not restore uploaded files. Schedule the dump and the volume copy together so they describe the same point in time as closely as your setup allows. Store the Compose file and environment file with the backup, since the restore needs the same image version and settings. Keep the image tag you ran at backup time in your restore notes.
How is the all-in-one container backed up differently?
The all-in-one container keeps its data in bind-mounted host folders such as /var/lib/openproject, so the backup works on those folders rather than on named volumes. A consistent backup still needs a database dump, because copying live PostgreSQL files is unreliable. Confirm which host paths your container mounts, and make sure your backup job reads every one of them. Ask whether the database lives inside the container or on a separate host, since that changes which dump command applies. Test a restore on a second host before you rely on the job.
What does a restore test for OpenProject need to prove?
A restore test should prove that the instance starts, users can sign in, work packages and their history load, and a known attachment opens. It should also confirm that the configuration matches the original and that the version of OpenProject matches the backup. Run the test on an isolated host so it cannot send email or touch production data. Record how long the restore took, because that figure is the most useful input for your recovery planning. Repeat the test after each major upgrade and after any change to attachment storage or the backup cap.
When should we bring in a partner for OpenProject backups?
Bring in a partner when the backup needs to meet an internal or external control, when no one on your team can run a timed restore, or when the instance is large or has grown beyond the default attachment cap. DeployOpen implements, hardens, backs up, upgrades and documents self-hosted platforms in your own infrastructure, and most engagements are fixed-scope with agreed deliverables and timelines. Ask for a written scope that names the backup targets, retention, restore test frequency, and handover documentation before work starts.
What do we need to give a partner before a backup project starts?
Expect to provide administrative access to the OpenProject host or containers, the installed version and deployment method, the database location, and the storage targets for backups. You also need to define a restore window, which is the period when a test restore can run on a spare environment without affecting users. Share your retention policy and any compliance requirements that the backup must support. Ask any partner to confirm in writing which of these items they need, and which ones they will request during the project.
How backup components flow from the install to an off-host copy
The flow starts on the running OpenProject install, which can be a packaged host, a Docker Compose stack or an all-in-one container. Packaged installs run sudo openproject run backup, which writes a PostgreSQL dump, attachments, configuration and git and svn repositories to the backup folder. Compose stacks dump the database with pg_dump from the db container and back up Docker volumes, while the all-in-one container backs up its bind-mounted folders such as /var/lib/openproject. Check that every output reaches an off-host boundary and that a test restore environment can rebuild the instance from that copy alone.
Backup outputs from each install type move to an off-host copy, then to a test restore.
How DeployOpen scopes and tests OpenProject backups
DeployOpen treats an OpenProject backup as a set of pieces that must all come back together: the database, attachments, configuration and any repositories, on the install type you actually run. We scope the work in writing, build the backup job for your packaged or Docker setup, and prove it by restoring to a separate environment before handing it over.
How we scope
- Confirm whether the install is packaged, Docker Compose or the all-in-one container, since each stores its data in different places
- Agree the attachment size cap and whether the 4096 MB default fits your stored files
- Record retention periods, backup storage location and who is allowed to trigger a restore
- Set the scope, deliverables and timeline in a written, fixed-scope agreement before work starts
How we build
- Configure the scheduled backup using the openproject run backup command for packaged installs
- Set up pg_dump from the db container and volume backups for Compose, and bind-mounted folder backups for the all-in-one container
- Adjust OPENPROJECT_BACKUP__ATTACHMENT__SIZE__MAX__SUM__MB where your attachment volume requires it
- Store backup output off the application host with access controls and encryption in line with your policy
How we hand over
- Run a full restore into a separate environment and record the steps, timings and any gaps found
- Document the exact restore sequence for packaged, Compose and all-in-one installs as used in your environment
- Deliver a runbook covering backup schedules, monitoring of job results, and retention settings
- Walk your operations team through a restore drill so they can repeat it without us
How we support
- Ongoing support, upgrades and continuous testing are available as retainers
- Repeat restore tests after OpenProject upgrades, since backup contents and paths can change between releases
- Review backup coverage whenever storage, attachment volumes or install layout change
- Confirm each restore test with you against the scope, so any gap is tracked to closure

