Delete Protection
Delete Protection guards your server against a rare but severe failure: a whole-server freeze that can happen when a media server or download app deletes a very large file. It is an opt-in feature — off by default — that a server admin turns on with a single switch. This page explains what it is, why it works, how to choose a threshold, and how to enable and manage it.
Delete Protection is off by default. A server admin turns it on with the Delete Protection toggle in Settings > General > Feature Flags. Enabling that switch applies the safeguard to your installed media and download apps and reveals the management page. There is nothing to install — it is a built-in feature you simply switch on.
Overview
On a server with a lot of RAM, deleting a very large file that is fully cached in memory can make the system spend a long time clearing that memory. While it does, the whole server can lock up — unreachable, and often only recoverable with a manual hard reboot. The deletes that trigger this are usually automated: an app’s own library maintenance, a database rebuild, or a quality upgrade replacing a big file — not something you did by hand.
When you enable it, Delete Protection puts a small, targeted safeguard in place that clears a large file’s memory in small, quick steps right before it is deleted. The delete stays fast, and no single step can lock up the server. It covers media servers (Emby, Jellyfin, Plex) and download apps (Radarr, Sonarr, SABnzbd, torrent clients, and more).
Key features
Opt-in, one switch
Off by default. A server admin enables it from Settings > General > Feature Flags — one toggle applies the safeguard to your installed media and download apps.
Stops the freeze at the source
Clears a large file's cached memory in small, yielding steps just before the delete, so the server never spins on a single long operation.
Covers the whole media stack
Media servers and download clients alike — the apps that routinely delete large files as part of normal maintenance.
Global default plus per-app overrides
A server default threshold (256 MiB) every app inherits, with an optional per-app override so a big-delete app can use a higher floor. Anywhere from 16 MiB to 1 TiB.
Per-app control
Once enabled, turn protection off for a specific app, or for the whole server, and your choice survives future updates.
Visible activity
See a running count of large deletes safely handled plus a recent-activity feed, so you can confirm it is working.
What causes the freeze
Deleting a file forces the operating system to release the memory that was caching that file’s contents. For a small file this is instant. For a very large file — several gigabytes — that is fully resident in RAM, the work grows with the file’s size, and on a high-memory server it can take long enough that the machine stops responding to everything else. Because one part of the system is stuck, the rest waits on it, and the server has to be hard-rebooted to recover.
The symptom is unmistakable and confusing: the server freezes for no obvious reason, nothing in the app logs points at a cause, and only a hard reboot brings it back — sometimes weeks apart. The trigger is almost always an automated delete of a large file: a media server rebuilding or replacing its own large database, or a download app removing or upgrading a large media file.
Delete Protection removes the cause. Instead of the delete releasing all of that memory in one long operation, the safeguard releases it in small, quick steps first, then performs the delete. The total work is the same, but no single step is ever long enough to lock up the server.
Who it’s for
This is for you if
- You run media servers (Emby, Jellyfin, Plex) or download apps (Radarr, Sonarr, SABnzbd, torrent clients)
- Your server has a large amount of RAM
- You have seen unexplained whole-server freezes that only a hard reboot fixes
- The freezes have no obvious cause and no clear entry in the application logs
- You want to confirm protection is active or adjust which apps it covers
What you can do
- Enable the Delete Protection toggle in Settings > General > Feature Flags to put the safeguard in place
- See status and recent activity on the Delete Protection page once enabled
- Adjust the size threshold that decides when protection engages
- Turn protection off for a specific app if you ever need to
- Watch the count of large deletes safely handled climb as it works
What’s protected
Delete Protection applies to the media servers and download apps that routinely delete large files. Only apps you actually have installed are affected; anything not installed is skipped.
| Category | Apps |
|---|---|
Media servers | Emby, Jellyfin, Plex |
Automation (\*arr) | Radarr, Sonarr, Lidarr, Readarr, Bazarr, Prowlarr |
Usenet clients | SABnzbd, NZBGet |
Torrent clients | qBittorrent, rTorrent, Deluge, Transmission |
Beyond this built-in list, a server admin can opt any other app into the same protection — including custom or third-party apps QuickBox does not manage. See Add a custom or third-party app below.
Manage from the Dashboard
The dashboard is the recommended way to enable and manage Delete Protection. Because it is off by default, the first step is to turn it on.
Step 1 — Turn Delete Protection on
In your server’s dashboard, open Settings > General > Feature Flags and turn on the Delete Protection toggle. This single switch is the master on/off: enabling it applies the safeguard to your installed media and download apps and reveals the Delete Protection page in the System area (and its QuickNav shortcut). Turning it back off removes the safeguard and hides the page.
The Delete Protection toggle in Settings > General > Feature Flags both enables the protection and reveals its management page. It is off by default — nothing is protected until an admin turns it on. Once on, protection persists across future updates until you turn it off.
Step 2 — Open the Delete Protection page
Once it is on, open System → Delete Protection from the sidebar (or its QuickNav shortcut). This is a system settings page on the default dashboard — it is an admin surface. There you get:
- Large deletes safely handled — a complete, all-time total of protected deletes. It is a permanent record that survives log rotation and updates, so it only ever climbs.
- Server-wide protection — a master switch to turn protection on or off for the whole server.
- Server default threshold — a set of presets (all inside the 16 MiB to 1 TiB range the server enforces) that decide how large a file must be before protection engages. The default is 256 MiB, and it is the floor every app inherits unless you give that app its own threshold.
- Protected apps table — each installed media/download app with its own on/off switch and its own editable threshold, so you can opt a single app out, or raise or lower just that app’s threshold, without touching the others. An Add custom app button here also lets you opt any other app — including custom or third-party apps QuickBox does not manage — into protection.
- Recent protected deletes — a sortable, filterable, selectable table of the deletes the safeguard has handled, with controls to remove logged entries you no longer need.
Every choice you make here — a disabled app, a custom threshold, a per-app override, a registered custom app, a whole-server opt-out — is remembered and survives future updates.
Set a threshold for just one app
Most servers are fine on the single server default. But some apps routinely delete much larger files than others — SABnzbd, for example, removes big usenet downloads as part of normal cleanup — and you may want protection to engage at a higher floor for those while smaller-delete apps stay on the default.
In the Protected apps table, each protected app’s Threshold column is a dropdown. It shows Server default (256 MiB) while the app is inheriting the global floor. Pick any other size to give that app its own threshold — the app then shows a Custom marker, meaning it no longer follows the server default. To hand the app back to the global floor, choose Server default again from the same dropdown.
A per-app override obeys the same limits as the server default — anywhere from 16 MiB to 1 TiB. An app with no override simply follows whatever the server default threshold is set to, so raising or lowering the server default moves every non-overridden app with it.
Add a custom or third-party app
Delete Protection is not limited to the built-in media and download apps. From the Delete Protection page, a server admin can opt any other app on the server — including custom or third-party apps QuickBox does not manage — into the same safeguard. In the Protected apps section, click Add custom app, give the app a short name, then choose how it runs:
- systemd service — for an app that runs as a systemd unit. Enter the unit’s base name (for example
myapp, which covers bothmyapp.serviceandmyapp@.service). QuickBox installs the same automatically-managed safeguard it uses for its built-in apps — there is no manual step. The app then appears in the Protected apps table as a normal protected row, marked custom, with its own threshold control and an option to remove it later. - cron / manual — for an app that is not a systemd service: one launched from a user crontab, a login or autostart script, or by hand (an IPTV tool run from a crontab, for example). Because there is no service for QuickBox to attach to, the dashboard instead gives you a copy-ready recipe — an
LD_PRELOAD=…prefix — to paste in front of the app’s launch command in its crontab or startup script. It takes effect on the app’s next run; no restart is needed. Reopen it any time from the row’s Show recipe button.
The safeguard behind the recipe covers any dynamically linked application that uses the system’s standard C library — which is nearly every app. You do not need QuickBox to support the app; pasting the recipe in front of its launch command is all it takes. The threshold you set for the app is baked into the recipe, so it engages at the same size floor as everything else.
A registered custom app is remembered and survives updates, just like every other choice. To stop protecting one, remove it with the row’s unregister control (or qb manage delete-safety -o unregister —app <name>). Built-in apps cannot be unregistered — turn those off with their per-app switch instead.
Manage the recent-deletes log
The Recent protected deletes feed is a full, sortable, filterable, and selectable table of the large deletes the safeguard has handled. Sort by time, app or actor, UID, or size; search across the app, process name, and full file path; and narrow the list with three filters: a time window (last 24 hours, 7 days, or 30 days), an app or actor, and a size floor (256 MB, 1 GB, or 10 GB and up). It is always paginated, so the list never grows unwieldy.
Click any row to expand it into a per-delete detail panel: the full absolute file path, the exact size in bytes, the process name, PID, and UID behind the delete, the time it happened (both absolute and relative), and, when the process maps to a protected app, that app and the size threshold that was in effect for it.
If you want to tidy the log, you can remove entries you no longer need:
- Delete one entry — from that row directly.
- Delete a selection — tick the rows you want and choose Delete selected.
- Clear older entries — use Clear delete log to remove everything older than 7, 30, or 90 days, or the entire log.
Removing logged entries only clears the visible activity list. The Large deletes safely handled counter is a permanent, all-time record and is not affected — it never goes down when you clear the log.
Choosing a threshold
The threshold is the file-size floor: a file has to be at least this big before the safeguard engages, and anything smaller deletes normally. A common question is whether the 256 MiB default is too low. It is not — and lower is the safe direction, not the risky one.
A lower threshold means more files are protected, and 256 MiB already sits well below the size where these freezes begin. There is no downside to a low floor: files under it delete exactly as they always did, and files over it get the safeguard. So leave the server default where it is. The per-app override exists for the opposite reason — to raise a specific app’s floor when that app’s everyday deletes are already large, so that protection and the activity feed stay focused on the genuinely huge deletes that actually carry the freeze risk, instead of firing on routine churn.
| Workload | Typical delete | Recommended threshold | Why |
|---|---|---|---|
Any app (default) | mixed | 256 MiB — leave it | Conservative floor, below the danger zone; right for almost everyone |
Media servers (Emby / Jellyfin / Plex) | 1–20 GiB | 1 GiB | Real library deletes are multi-GB; focuses protection + feed, skips metadata/transcode churn |
Usenet (SABnzbd / NZBGet) | 10–100 GiB | 10–50 GiB | Completed jobs are huge; only genuine large removals engage |
Torrent (qBittorrent / rTorrent / Deluge / Transmission) | 1–50 GiB | 1 GiB | Large season packs / ISOs |
\*arr automation (Radarr / Sonarr / …) | 100 MiB–20 GiB | 256 MiB (default) | They drive the media apps; default is usually right |
You rarely need to change this. Raise a specific app’s floor to match the size its real large deletes actually hit — never above it, or you lose protection where it matters.
Setting an app’s threshold higher than the files it actually deletes means those deletes fall below the floor and get no safeguard — exactly where you needed it. When you override an app, set the floor to match, or sit just under, the size of that app’s genuine large deletes. When in doubt, leave the server default.
Manage from the CLI
Everything the dashboard does is available from the terminal through qb manage delete-safety. The same settings back both surfaces, so a change made in either place is reflected in the other.
# Show current protection status (human-readable table)
qb manage delete-safety -o status
# Machine-readable status (JSON)
qb manage delete-safety -o status --json
# Turn protection on for all installed apps
qb manage delete-safety -o enable
# Turn protection on for just one app
qb manage delete-safety -o enable --app radarr
# Turn protection off for the whole server
qb manage delete-safety -o disable
# Opt a single app out of protection
qb manage delete-safety -o disable --app sabnzbd
# Set the server default threshold (bytes) — here, 512 MiB
qb manage delete-safety -o threshold --bytes 536870912
# Give one app its own threshold — SABnzbd at 50 GiB
qb manage delete-safety -o threshold --app sabnzbd --bytes 53687091200
# Clear an app's override so it follows the server default again
qb manage delete-safety -o threshold --app sabnzbd --resetCustom apps and the activity log are managed with the same command:
# Register a custom systemd app (auto-managed, exactly like a built-in)
qb manage delete-safety -o register --app myapp --kind systemd --unit myapp
# Register a custom cron / manually-launched app (recipe-based, no service)
qb manage delete-safety -o register --app iptvtool --kind manual
# Print the copy-ready LD_PRELOAD recipe to paste into the app's launch line
qb manage delete-safety -o recipe --app iptvtool
# Remove a custom app from protection
qb manage delete-safety -o unregister --app iptvtool
# List the protected-delete activity log (JSON)
qb manage delete-safety -o list-log --json
# Preview clearing log entries older than 30 days (removes nothing)
qb manage delete-safety -o prune-log --older-than-days 30 --dry-run
# Clear log entries older than 30 days
qb manage delete-safety -o prune-log --older-than-days 30qb manage delete-safety options
-o statusRequiredShow the protection table: shim state, system on/off, threshold, count of large deletes safely handled, and each installed app's status.
qb manage delete-safety -o status--jsonWith -o status, emit machine-readable JSON instead of the human table (the same data the dashboard reads).
qb manage delete-safety -o status --json-o enableEnable protection. With no --app, protects every installed app and clears any whole-server opt-out. With --app, re-enables just that app.
qb manage delete-safety -o enable-o disableDisable protection. With no --app, turns it off server-wide. With --app, opts just that app out; the others keep protection.
qb manage delete-safety -o disable --app emby--app <app>Target a single app for enable/disable, using its short name (emby, jellyfin, plex, radarr, sonarr, sabnzbd, qbittorrent, and so on).
qb manage delete-safety -o disable --app sonarr-o threshold --bytes <N>Set the server default threshold in bytes — the floor every app inherits unless it has its own override. Files at or above this size get the safeguard. Accepted range: 16 MiB (16777216) to 1 TiB (1099511627776). Default 256 MiB.
qb manage delete-safety -o threshold --bytes 1073741824-o threshold --app <app> --bytes <N>Set a per-app threshold override, using the app's short name. That app then deletes at its own floor instead of the server default; every other app is unchanged. Same 16 MiB to 1 TiB range applies.
qb manage delete-safety -o threshold --app sabnzbd --bytes 53687091200-o threshold --app <app> --resetClear an app's override so it follows the server default threshold again (--default is an accepted alias for --reset).
qb manage delete-safety -o threshold --app sabnzbd --reset-o register --app <name> --kind systemd --unit <base>Opt a custom systemd app into protection. --name is a short [a-z0-9] name; --unit is the systemd unit's base name (covers both <base>.service and <base>@.service). Auto-managed exactly like a built-in app.
qb manage delete-safety -o register --app myapp --kind systemd --unit myapp-o register --app <name> --kind manualOpt a custom cron / manually-launched app (not a systemd service) into protection. It gets a copy-ready LD_PRELOAD recipe instead of an automatic drop-in — see -o recipe.
qb manage delete-safety -o register --app iptvtool --kind manual-o recipe --app <name>Print the copy-ready LD_PRELOAD prefix for a manual custom app, to paste in front of its launch command in a crontab or startup script. Add --json for the machine-readable form. Systemd and built-in apps are auto-managed and need no recipe.
qb manage delete-safety -o recipe --app iptvtool-o unregister --app <name>Remove a registered custom app from protection (drops its drop-in and per-app settings). Built-in apps cannot be unregistered — use -o disable --app for those.
qb manage delete-safety -o unregister --app iptvtool-o list-log --jsonEmit the protected-delete activity log as JSON (the same data the dashboard table reads) — one row per handled delete, newest first. Add --limit N to cap the row count.
qb manage delete-safety -o list-log --json-o prune-logClear logged protected-delete entries. Use --all, --older-than-days N, --before <unix>, or --ids <csv> (comma-separated row ids from list-log); --ids takes precedence when given. Add --dry-run to preview the count without removing anything. Clearing the log never changes the all-time safely-handled total.
qb manage delete-safety -o prune-log --older-than-days 30 --dry-runReapply protection
If protection ever looks out of sync — for example after a manual change — reconcile every installed app back to your saved settings with:
qb fix delete-safetyThis rebuilds the safeguard if needed and brings each app’s protection in line with your saved choices. It is the same reconcile step that runs automatically on every update, so it is always safe to run.
Enabling, disabling, or changing the threshold updates the saved settings immediately, but a given app only picks up the change the next time its service restarts. Your protected-delete count and status reflect the saved state right away.
Configuration and files
Delete Protection stores its settings, its activity log, and the safeguard itself under standard QuickBox paths. You never need to edit these by hand — the dashboard and CLI manage them for you — but they are useful to know for support.
Troubleshooting
Symptom
- Whole server freezes for no obvious reason and needs a hard reboot
- The count of large deletes safely handled is not moving
- A protected app was recently reinstalled or changed
- You want to confirm which apps are actually protected right now
What to check
- Confirm protection is active with qb manage delete-safety -o status
- A zero count is normal until a large delete actually happens — it only counts real events
- Run qb fix delete-safety to reconcile every installed app back to your saved settings
- The status table lists every installed app with its protected state and threshold
The count only increases when a real large delete occurs. Many servers go long stretches between them, so a small or zero count does not mean protection is off — it means no qualifying delete has happened yet. Check the status table to confirm each app is protected.
Disabling protection — for an app or server-wide — removes the safeguard for that scope. On a high-RAM server that deletes large files, this re-exposes you to the freeze this feature prevents. Only opt out if you have a specific reason to, and re-enable it when you are done.
Best practices
Do
- Enable Delete Protection if you run media servers or download apps on a high-RAM server
- Turn on the Delete Protection toggle in Settings > General > Feature Flags (or
qb manage delete-safety -o enable) - Use
qb manage delete-safety -o statusto confirm which apps are protected - Run
qb fix delete-safetyafter any manual change to reconcile settings - Keep the server default 256 MiB threshold unless you have a specific reason to change it
- Use a per-app override only for apps that delete much larger files (like SABnzbd), and leave the rest on the server default
Don't
- Turn protection back off server-wide on a high-RAM media server without a clear reason
- Edit the files under
/etc/systemd/system/<service>.d/by hand — use the dashboard or CLI - Set the threshold so high that real large deletes fall below it and lose protection
- Assume a low protected-delete count means it is broken — it only counts real events
FAQ
No — there is nothing to install. It is a built-in feature that is off by default. A server admin turns it on with the Delete Protection toggle in Settings > General > Feature Flags; that switch applies the safeguard to your installed media and download apps.
It is the master on/off for the feature. Turning it on enables the protection — it applies the safeguard to your installed media and download apps — and reveals the Delete Protection management page. Turning it off removes the safeguard and hides the page. It is off by default, so nothing is protected until an admin enables it.
Media servers (Emby, Jellyfin, Plex) and download apps (Radarr, Sonarr, Lidarr, Readarr, Bazarr, Prowlarr, SABnzbd, NZBGet, qBittorrent, rTorrent, Deluge, Transmission). Only apps you actually have installed are affected.
No. The safeguard does the same total work a normal delete would, just in small steps instead of one long one, so the delete stays fast. It only engages for files above the size threshold — small deletes are untouched.
No, 256 MiB is a good default and lower is the safe direction. A lower threshold protects more files, and 256 MiB already sits below the size where these freezes begin — files under it delete exactly as before, files over it get the safeguard, so there is no downside to a low floor. Leave the server default alone. The per-app override exists to raise a specific app's floor when that app's everyday deletes are already large, so protection focuses on the genuinely huge deletes. Never raise a floor above the size an app actually deletes, or those deletes lose protection.
Very likely yes. The count is a permanent, all-time total — it survives log rotation and updates and never resets — so it only increases when a real large delete occurs, and those can be weeks apart. Run qb manage delete-safety -o status (or open the dashboard page) to confirm each app shows as protected — that is the real indicator, not the count.
Yes. On the dashboard's Delete Protection page, use that app's switch in the per-app table. From the CLI, run qb manage delete-safety -o disable --app <app>. The other apps keep their protection, and your choice survives future updates.
Any file at or above the threshold that applies to the deleting app. Every app inherits the server default threshold (256 MiB) unless you give it its own override. You can set the server default anywhere from 16 MiB to 1 TiB, from the dashboard or with qb manage delete-safety -o threshold --bytes <N>.
Yes. There is a server default threshold every app inherits, plus an optional per-app override. This is handy when one app deletes much larger files than the others — for example SABnzbd clearing big usenet downloads — and you want protection to engage at a higher floor there while smaller-delete apps stay on the default. On the dashboard's Delete Protection page, use the Threshold dropdown in that app's row: pick a size to override it (the row shows a Custom marker) or choose Server default to hand it back to the global floor. From the CLI, run qb manage delete-safety -o threshold --app <app> --bytes <N> to set an override, or qb manage delete-safety -o threshold --app <app> --reset to clear it. A per-app override obeys the same 16 MiB to 1 TiB range, and your choice survives future updates.
Yes. On the dashboard's Delete Protection page, use Add custom app in the Protected apps section to opt any app — including custom or third-party apps — into the same safeguard. If it runs as a systemd service, enter its unit base name and QuickBox manages it automatically, exactly like a built-in. If it runs from cron or a launch script, the dashboard gives you a copy-ready recipe to paste in front of its launch command (the safeguard covers almost any standard, dynamically linked app). From the CLI, run qb manage delete-safety -o register --app <name> --kind systemd --unit <base> or --kind manual.
Register it as a cron / manual app (Add custom app on the Delete Protection page, or qb manage delete-safety -o register --app <name> --kind manual). Because there is no service to attach to, QuickBox gives you a copy-ready LD_PRELOAD=… recipe — open it from the row's Show recipe button or with qb manage delete-safety -o recipe --app <name>. Paste that prefix in front of the app's launch command in its crontab or startup script. It takes effect on the app's next run — no restart needed — and the threshold you set is baked into the recipe.
No. Clearing logged entries — a single row, a selection, or everything older than N days — only tidies the visible activity list. The Large deletes safely handled counter is a permanent, all-time record and is never affected; it only ever climbs. From the CLI, qb manage delete-safety -o prune-log does the same, and you can add --dry-run to preview how many entries would be removed before doing it.
They should not. Your saved choices — threshold, opted-out apps, registered custom apps, and the whole-server switch — are read on every update precisely so they survive upgrades. If something ever looks out of sync, run qb fix delete-safety to reconcile every installed app back to your saved settings.
Related references
Related pages
Where the Delete Protection master on/off switch lives, alongside every other server setting.
Server health — CPU, memory, disk, and diagnostics for your server.
Gather diagnostics and find the page that owns your symptom.
The full qb CLI, including qb manage and qb fix commands.
Join the Community
Media server operators sharing configs, getting support, and shaping the future of QuickBox Pro.