plex-dbrepair
Docker app from bmartino1's Repository
Plex DBRepair is a one shot Plex database maintenance tool using ChuckPa DBRepair version 26 10 00 Automatically discovers a running Plex Docker container through the host Docker…
Requirements
Overview
Readme
View on GitHubDBRepair
If you're reading this, you are on the wrong branch.
DBRepair.sh and the Windows .bat/.ps1 scripts are retired.
DBRepair is now a compiled program on the main branch: https://github.com/ChuckPa/DBRepair/tree/main
Download the latest release for your OS and CPU: https://github.com/ChuckPa/DBRepair/releases/latest
Copyright (c) 2022-2026, ChuckPa. All Rights Reserved.
Categories
Download Statistics
Total Downloads Over Time
Related apps
Explore more like this
Explore allLinks
Details
bmmbmm01/plex-dbrepairRuntime arguments
- Network
bridge- Shell
bash- Privileged
- false
- Extra Params
--hostname dbrepair
Template configuration
automatic=upstream auto; check=integrity checks; vacuum=compact; repair=rebuild including FTS; reindex=rebuild indexes; deflate=compact only if needed; prune=PhotoTranscoder cleanup. Select one mode.
- Target
- DBREPAIR_MODE
- Default
- automatic
- Value
- automatic
auto detects one eligible Plex container. If you have multiple Plex containers, enter the exact Docker container name shown by docker ps (example: plex). Do not enter a Docker image name here.
- Target
- PLEX_CONTAINER_NAME
- Default
- auto
- Value
- auto
Create timestamped cold database archives inside the TARGET Plex container at Plex Media Server/DBRepair-Backups; skipped for prune. Backups take disk space and are not automatically deleted.
- Target
- ENABLE_BACKUPS
- Default
- true
- Value
- true
Restart the target Plex Docker container after successful maintenance. On database errors the script intentionally does not auto-restart Plex.
- Target
- RESTART_PLEX
- Default
- true
- Value
- true
For prune mode only: remove eligible PhotoTranscoder cached files older than this number of days.
- Target
- PRUNE_DAYS
- Default
- 30
- Value
- 30
Case-insensitive name substring used when Plex Container Name=auto. Image names containing plex are also considered. Candidates must contain the Plex database at the configured path.
- Target
- PLEX_CONTAINER_MATCH
- Default
- plex
- Value
- plex
Path INSIDE the target Plex container to its config mount, usually /config. This is NOT a host volume to mount to DBRepair.
- Target
- PLEX_MOUNT
- Default
- /config
- Value
- /config
Relative path inside the target Plex container's config directory. Leave at default unless that Plex installation differs.
- Target
- PLEX_REL
- Default
- Library/Application Support/Plex Media Server
- Value
- Library/Application Support/Plex Media Server
If upstream DBRepair stop cannot shut down Plex, allow SIGTERM to the Plex Media Server process. No forced Docker stop/offline repair fallback is implemented.
- Target
- ALLOW_PLEX_KILL
- Default
- true
- Value
- true
Maximum DBRepair operation duration in seconds. A failure or timeout requires reviewing the database before restarting Plex.
- Target
- DBREPAIR_TIMEOUT
- Default
- 7200
- Value
- 7200
Maximum seconds to wait for the Plex process to stop before aborting.
- Target
- STOP_TIMEOUT
- Default
- 90
- Value
- 90
Host folder for timestamped DBRepair execution logs. Docker logs also show output.
- Target
- /logs
- Default
- /mnt/user/appdata/plex-dbrepair-logs
- Value
- /mnt/user/appdata/plex-dbrepair-logs
REQUIRED: Docker host socket for discovering Plex and running docker inspect/exec/cp/restart. Grants this tool host-level Docker control.
- Target
- /var/run/docker.sock
- Default
- /var/run/docker.sock
- Value
- /var/run/docker.sock