Move your media or Docker data to another disk
Your disk is full, or you added a bigger one. This page shows how to move your media and downloads, or Docker’s own storage, to the new disk. Your apps keep working because the paths inside the apps do not change.
What lives where
Section titled “What lives where”Three places can fill a disk. Each one moves in a different way.
| Data | Where it is | How to move it |
|---|---|---|
| Media and downloads (also books, photos, Immich and Nextcloud files) | The folders you set in System > Folders | Move your media and downloads. For Immich and Nextcloud, also read Move the Immich or Nextcloud folder. |
| Docker’s images, containers and volumes | /var/lib/docker by default |
Move Docker’s storage. This is a standard Docker setting, not a Deployrr menu. |
The Deployrr Docker folder (appdata, .env, compose files, secrets) |
The path you chose in Prerequisites | Do not move it. See the note below. |
Check which disk is full first:
df -hLook for a line at or near 100% in the Use% column. Then see how big each part is. Replace YOUR_FOLDER with the folder you want to measure:
sudo du -sh YOUR_FOLDERBefore you start
Section titled “Before you start”- You have a new disk that is already formatted and visible to Linux. This page does not format disks.
- You made a backup of your Docker folder. Tools > Backups needs a Pro license and stops all your apps while it runs. At the end it asks whether to restart the Docker stack. If you answer no, start your apps later with Tools > Stack Manager > Up. A backup holds only the Docker folder. It does not hold your media or Docker’s images.
- The new disk has more free space than the data you move.
- For Stack Manager, you have a Basic, Plus or Pro license and all Prerequisites steps are done. To set a folder in System > Folders you need the same. See Licenses.
- If your media is on a NAS, you do not need a local disk. Mount the share with SMB or NFS Mount or Rclone, then go to Move your media and downloads.
Mount the new disk for good
Section titled “Mount the new disk for good”A disk you mount by hand is gone after a reboot. Add it to /etc/fstab, the file Linux reads at boot. This example uses a disk with an ext4 filesystem. Replace the values in capitals where the steps say so.
-
Find your disk and its UUID:
Terminal window lsblk -fLook for the new disk and its partition, such as
sdb1. Copy the longUUIDvalue next to it. -
Make the mount folder. This example uses
/mnt/data. Use any path you like:Terminal window sudo mkdir -p /mnt/data -
Copy the file as a backup:
Terminal window sudo cp /etc/fstab /etc/fstab.before-newdisk -
Open the file:
Terminal window sudo nano /etc/fstab -
Add this line at the end. Replace
YOUR_UUIDwith the UUID from step 1. Changeext4if your disk uses another filesystem:UUID=YOUR_UUID /mnt/data ext4 defaults,nofail 0 2 -
Save the file.
-
Test it:
Terminal window sudo mount -aNo output means the file is fine. If you see an error, fix the line it names. Or put your copy back:
Terminal window sudo cp /etc/fstab.before-newdisk /etc/fstab -
Check that the disk is mounted:
Terminal window findmnt /mnt/data -
Make your Linux user the owner of the mount folder. Replace
YOUR_USERwith your Linux username. Skip this step if you only move Docker’s storage:Terminal window sudo chown YOUR_USER:YOUR_USER /mnt/data
The nofail option lets the server boot even if the disk is missing. If you later see an empty folder where your data should be, check that the disk is mounted. See Media app shows an empty library.
To understand how a permanent mount entry works, read UDMS part 07: Make a mount permanent with fstab (manual setup). It covers a network share, not a local disk, so use the steps on this page for your disk.
Move your media and downloads
Section titled “Move your media and downloads”Moving changes where the files live on your server. It does not change the paths inside your apps. Media Folder 1 is still /data/media1 and the Downloads Folder is still /data/downloads for your apps. You do not need to change any library or root folder inside Plex, Jellyfin, Sonarr or Radarr.
-
Go to Tools > Stack Manager > Stop Container.
-
At “Select an app to stop:”, type the number next to
alland press Enter. Look for “All containers stopped”. -
Copy your files. Replace
OLD_FOLDERwith your current folder andNEW_FOLDERwith the folder on the new disk. Keep the/at the end of both paths:Terminal window sudo rsync -aHAX --info=progress2 OLD_FOLDER/ NEW_FOLDER/A big library takes a long time. If the copy stops, run the same command again. It carries on where it left off. If
rsyncis not found, install it with your package manager, such assudo apt install rsyncon Debian or Ubuntu. -
Check the copy. This dry run lists differences and changes nothing. It prints nothing when both folders match:
Terminal window sudo rsync -aHAXn --itemize-changes OLD_FOLDER/ NEW_FOLDER/ -
Compare the sizes:
Terminal window sudo du -sh OLD_FOLDER NEW_FOLDER -
In Deployrr, go to System > Folders.
-
Select the folder you moved, such as Media Folder 1 or Downloads Folder.
-
Pick the new folder in the directory browser, choose Select, then Confirm. See Set a folder for each prompt. To see the folder prompts, watch Deployrr 5 walkthrough: Setup Folders at 21:36 (shows Deployrr v5; menus and steps differ in v6).
-
Repeat steps 7 and 8 for every folder you moved.
-
Go to Tools > Stack Manager > Recreate.
-
At “Select an app to recreate:”, type the number of one app that uses the folder, or the number next to
all. Wait for “APP recreated” or “All containers recreated”.
Check that it worked (see Check it worked). Keep the old copy until you are sure.
Delete the old copy
Section titled “Delete the old copy”Do not delete the old copy until your apps have run for a few days with the new folder. To make sure nothing still uses it, rename it first. Replace OLD_FOLDER with your old folder:
sudo mv OLD_FOLDER OLD_FOLDER.oldIf everything works after a few days, delete it. Check the path twice. This cannot be undone:
sudo rm -rf OLD_FOLDER.oldMove the Immich or Nextcloud folder
Section titled “Move the Immich or Nextcloud folder”The Immich Folder holds every photo and video uploaded to Immich. The Nextcloud Folder holds the files in Nextcloud. Move them with the steps above. Keep these points in mind:
- Their databases stay in the Docker folder, in
appdata/immich-postgresqlandappdata/nextcloud-mariadb. The database lists every file by its place inside the folder. So the new folder must hold the whole old folder with the same layout. Copy the folder you set in System > Folders, not a folder inside it. - Copy with
sudo, as in step 3. Nextcloud’s files belong to the web server user inside the container (www-data), not to your Linux user.rsync -akeeps the owner. Do not runchownon the new Nextcloud folder. Copy into a folder on the new disk, such as/mnt/data/nextcloud, not into the mount folder itself. - At step 7, select Immich Folder or Nextcloud Folder. At step 11, recreate
immichornextcloud. Recreate is enough, because both apps always have their folder.
Check that the app sees its files. For Immich, you see folders such as library, thumbs and upload:
sudo docker exec immich ls /usr/src/app/uploadFor Nextcloud, you see a folder for each Nextcloud user:
sudo docker exec nextcloud ls /var/www/html/dataIf the app shows an error or does not start, the new path does not hold the old files:
- Nextcloud says the data directory is invalid and asks for a file called
.ocdata. Immich does not start, and its log names a.immichfile. These are hidden files the apps put in their folders.rsync -acopies them, so a missing file means the copy or the path is wrong. - If Nextcloud says the data directory is readable by other users, run
sudo chmod 0770 NEW_FOLDER. - To go back, set the folder to the old path in System > Folders and recreate the app again. Your old copy is still there.
Then remove the old copy as in Delete the old copy.
Move Docker’s storage
Section titled “Move Docker’s storage”Docker keeps images, containers and volumes in /var/lib/docker. If that disk is full, you can point Docker at a folder on the new disk. This is a standard Docker setting called data-root. Deployrr has no menu for it.
Check how Docker stores images before you start:
sudo docker info --format '{{.Driver}}'If it prints overlay2, your images and containers are in /var/lib/docker and the steps below move them. If it prints overlayfs, Docker uses the containerd image store. Then most of the image data is in /var/lib/containerd, which data-root does not move. Check its size with sudo du -sh /var/lib/containerd before you go on, because the steps below may free much less space than you expect.
-
Make the folder on the new disk. This example uses
/mnt/data/docker:Terminal window sudo mkdir -p /mnt/data/docker -
Stop Docker:
Terminal window sudo systemctl stop docker docker.socket -
If
/etc/docker/daemon.jsonexists, copy it. Skip this if the file does not exist:Terminal window sudo cp /etc/docker/daemon.json /etc/docker/daemon.json.bak -
Open the file:
Terminal window sudo nano /etc/docker/daemon.json -
Add the
data-rootkey. If the file is new, it holds only this:{"data-root": "/mnt/data/docker"}If the file already has keys, add
data-rootto them. Keep a comma between keys and keep the file valid JSON. For example, with the log limit from Free up disk space used by Docker:{"data-root": "/mnt/data/docker","log-driver": "json-file","log-opts": {"max-size": "10m","max-file": "3"}} -
Save the file.
-
Copy Docker’s data to the new folder. This can take a long time:
Terminal window sudo rsync -aHAX --info=progress2 /var/lib/docker/ /mnt/data/docker/ -
Start Docker:
Terminal window sudo systemctl start docker -
Check the path Docker uses now:
Terminal window sudo docker info --format '{{.DockerRootDir}}'It prints
/mnt/data/docker. If it still prints/var/lib/docker, checkdaemon.jsonfor typos. -
Go to Tools > Stack Manager > Up. Look for “Docker stack is up”. Many apps don’t start on their own when Docker starts, so this step brings them back.
If you installed cAdvisor or Node Exporter, their files still name /var/lib/docker, so they may show old or empty Docker data after the move.
If Docker does not start, put your copy of daemon.json back, or remove the data-root line, then start Docker again. Your old data is still in /var/lib/docker:
sudo cp /etc/docker/daemon.json.bak /etc/docker/daemon.jsonsudo systemctl start dockerIf you had no daemon.json before, delete the new file instead with sudo rm /etc/docker/daemon.json.
When your apps have run well for a few days, free the old space. Rename the old folder first to prove nothing uses it:
sudo mv /var/lib/docker /var/lib/docker.oldCheck your apps again. Then delete it. This cannot be undone:
sudo rm -rf /var/lib/docker.oldCheck it worked
Section titled “Check it worked”-
See the free space on both disks:
Terminal window df -h -
For media, list the folder inside an app. Replace
APPwith the app’s name, such asjellyfin:Terminal window sudo docker exec APP ls /data/media1You see your media type folders, such as
moviesandtv. -
Open the app. Your library shows your titles. In Sonarr, Radarr or Lidarr, the root folder list shows a path under
/data/media1. -
For Docker’s storage, list your containers:
Terminal window sudo docker ps -aYour apps show as
Up. With a license you can use Tools > Stack Manager > Containers Status instead. -
Reboot once. Then check that the disk is mounted:
Terminal window findmnt /mnt/dataMany apps, including Jellyfin, Sonarr and Radarr, are set not to start on boot. Go to Tools > Stack Manager > Up to start them, then check that they show as
Up.
If apps do not start
Section titled “If apps do not start”- If an app shows
RestartingorExited, see A container keeps restarting, is unhealthy or has exited. - If a media app shows an empty library, the disk is probably not mounted, or your user does not own the folder. See Media app shows an empty library.
- If an app cannot write to the new folder, make your user the owner. See The app cannot read or write the folder.
- If you see
no space left on device, the wrong disk is still full. Rundf -hand see Free up disk space used by Docker.

