Can't move/rename files with Sonarr/Transmission on Docker/Synology

First, I apologize for asking this at all. I know similar questions have been asked dozens of times, but most of them seem to trail off without a real resolution, or the situation are different enough that I can’t connect the dots.

Here’s what I want to happen: I want Sonarr to watch for new episodes, then for Transmission to download them, and then for Plex to be able to play them. If someone can point me to a better guide for this, I’ll gladly take a look and try a different approach.

Here’s my current situation: I followed this guide to get set up. The directions are mostly fine, except that it provides no information on what Sonarr should be doing once it hands off a new download to Transmission. I think the guide assumes that I want my Plex library to be the same place that downloads end up, which I want to avoid.

Sonarr is getting episodes from RSS feeds. It passes them to Transmission, and they download successfully, but it can’t move them. My sonarr user is in the MediaUsers group, which has read/write access in the entire /Data Shared Folder.

When shows finish downloading, I get the error “Import failed, path does not exist or is not accessible by Sonarr: /Data/TV Shows/{show name}”. No matter what path I try, this happens. Here’s screenshots to show how I have things set up. Maybe someone can just tell me what needs to change.

Docker:

09%20AM
image

In my Transmission Docker environment, I also have these variables that might be relevant. I don’t think they’re relevant to Sonarr moving files, but Transmission seems to be behaving as expected.

TRANSMISSION_DOWNLOAD_DIR = /Data/Downloads/Torrents/Completed
TRANSMISSION_INCOMPLETE_DIR = /Data/Downloads/Torrents/InProgress
TRANSMISSION_WATCH_DIR = /Data/Downloads/Torrents/ToFetch

Download Client:

Remote Path Mappings:

I’m really not sure about remote path mappings, so I’ve been trying a bunch of things. As you can see from the Docker config screenshots, Sonarr and Transmission can access the same locations.

Can anybody point out where I’m going wrong here?

Not sure if it matters, but you have a / here, after /Data, which you don’t have in your sonarr container.

The error suggests sonarr can’t write to that location. Try to create a file/folder there from within the sonarr container, or at least doublecheck the permissions from within the container.

Also: as long as you use the same mount (in this case /Data) you don’t need remote path mappings.

It was worth a shot, but no luck.

Question… you say create a file/folder from within the sonarr container. You mean through the container’s terminal, right?

When I create a bash shell, I’m able to log in to the container, change directories, mkdir a test directory inside Data/TV Shows. Everything seems fine. it shows me as root. Here’s what I see inside the relevant directories. Let me know if this helps.

Starting point:

Inside /Data:

image

Inside TV Shows:

Did you set the PUID and PGID variables for both containers to be the same as the user outside the containers having access to those directories?

(Again, not sure if applicable, there’s a Downlads and Downloads directory inside /Data)

youre mounting /Data to /Data so theres no point in mounting /Data/Downloads/Torrents as anything as its already there due to being under /Data. you’d only do something like that if you wanted to replace a folder under /Data with another folder outside of that structure (even without the typo it makes no sense to do it)

you dont need any remote path mappings as both containers have /Data mounted as /Data so theres a common path structure across both. you’d only need them if the structure was not the same, eg, you mounted /Data as /Media for sonarr

in the transmission client setup take out the directory and add sonarr to the category field - if you download anything else at all, not just via sonarr, then youll get sonarr trying to play with those jobs if they look like one if its series.
plus im presuming youve set /Data/TV Shows as one of the root folders for sonarr - never mix downloading and sorted files under the same folder structure.
by adding the category in there the completed download files will end up in the /Data/Downloads/Torrents/Completed/sonarr folder

do you have any logs (preferably debug level logs) of failed imports? they may provide more info (or not)

Thank you so much!

I removed the directory from the Transmission client setup and added sonarr to the category, and I think that’s what did it. I’m surprised the reddit post I followed doesn’t get in to any of this.

I had already removed the mappings based on Thirran’s advice. I admit that it didn’t make much sense to have it, but think I was flailing at possible solutions. I’m new to Sonarr and Synology, and I’ve only got some basic Docker experience.

One last question before I close this out… should Sonarr be removing the original file? I’m not seeing an option for this, and I think Transmission’s option to remove completed downloads just removes it from the list.

The downloaded file is put in /Data/Downloads/torrents/Completed/sonarr/crazy.file.name720p.etc...,
A renamed copy is put in /Data/TV Shows/Show Name/Season/Nicely Formatted Episode - S01E01.mkv

Thanks!

Sonarr should remove the torrent when it’s done seeding, and meanwhile hardlinks or copies it to the final destination, depending on if that is on the same volume or not. So you’re probably not seeing two files, but one file and a link if all is well.

Hello all. Someone else struggling with this issue… :frowning:

I’m running haugene-transmission-openvpn1 and linuxserver-sonarr1 under Docker on Synology NAS and everything works fine apart from the automatic import of downloaded episodes where I get the usual import failed error message. I’ve read so many posts about this issue that I’ve confused myself so I’m hoping someone can help me with what will probably take seconds to fix. I’m pretty sure it’s a folder issue rather than permissions, but glad to be proved otherwise.

I have folders:

/PlexMedia
/PlexMedia/download
/PlexMedia/Movies
/PlexMedia/TV Shows

In the Transmission Docker I have:

PlexMedia/download with mount path /download
docker/TransmissionVPN/resolv.conf with mount path /etc/resolv.conf
docker/TransmissionVPN with mount path /config

Environment Variables are set to:

TRANSMISSION_DOWNLOAD_DIR = /download/completed
TRANSMISSION_INCOMPLETE_DIR = /download/incomplete
TRANSMISSION_WATCH_DIR = /download/watch
TRANSMISSION_HOME = /download/transmission-home

All of these four folders exist.

In the Sonarr Docker I have:

PlexMedia/download/completed with a mount path of /download
docker/Sonarr with a mount path of /config
PlexMedia/TV Shows with a mount path of /tv

In the Sonarr application settings under the Download Client section I have a remote path mapping

Host: IP address of my NAS
Remote Path: /PlexMedia/download/completed/
Local path: /download/

I have been absolutely unable to join the dots around what should be what to get the auto import to work. Can someone please help an old man who grew up with MS DOS 3.1 to solve this! :wink:

Would have probably been better to open a new topic, but anyway… :slight_smile:

  • Mount /PlexMedia everywhere with the same name. Maybe just call it /PlexMedia as well to make it easy.
  • (edit) remove whatever other mounts you have for data (not the one for config files)
  • Adjust data paths in transmission / environment vars / sonarr as required, using ONLY the /PlexMedia mount.
  • Remove the remote path mapping.

If you’re still not getting anywhere, please post the error you get from the sonarr logs, and what you changed (if anything) config-wise in sonarr/transmission/…

Thanks for the reply. Just so I’m clear what you’re suggesting:

In the Transmission Docker I have:

PlexMedia/download with mount path /download
Change this to PlexMedia with mount path /PlexMedia

docker/TransmissionVPN/resolv.conf with mount path /etc/resolv.conf
docker/TransmissionVPN with mount path /config

Leave these two unchanged.

Environment Variables are set to:

TRANSMISSION_DOWNLOAD_DIR = /download/completed
TRANSMISSION_INCOMPLETE_DIR = /download/incomplete
TRANSMISSION_WATCH_DIR = /download/watch
TRANSMISSION_HOME = /download/transmission-home

Leave these unchanged?

In the Sonarr Docker I have:

PlexMedia/download/completed with a mount path of /download

Change this to PlexMedia with mount path /PlexMedia

docker/Sonarr with a mount path of /config
PlexMedia/TV Shows with a mount path of /tv

Leave these unchanged

In the Sonarr application settings under the Download Client section I have a remote path mapping

Host: IP address of my NAS
Remote Path: /PlexMedia/download/completed/
Local path: /download/

Delete this.

Have I understood you correctly?

Change these to /PlexMedia/download/completed etc…

This can be removed, you will already have the generic /PlexMedia mount under which everything lives.

The rest of the changes / things to leave are ok.

(The general idea is to have only a single media mount, which is named exactly the same in all your dockers. This will allow all applications to automagically see and deal with files, because the path your download client reports is also what sonarr can see, so no remote path mapping necessary. As a bonus you’re no longer moving files from one mount to the other (which is slowww because it’s a copy+delete rather than instant move).

This also kind of assumes all dockers run as the same user, so you have no permissions shenanigans…)

Thank you for the help here. I’ve made the changes as you suggest so now have:

In the Transmission Docker:

PlexMedia with mount path /PlexMedia
docker/TransmissionVPN/resolv.conf with mount path /etc/resolv.conf
docker/TransmissionVPN with mount path /config

Environment Variables are set to:

TRANSMISSION_DOWNLOAD_DIR = /PlexMedia/download/completed
TRANSMISSION_INCOMPLETE_DIR = /PlexMedia/download/incomplete
TRANSMISSION_WATCH_DIR = /PlexMedia/download/watch
TRANSMISSION_HOME = /PlexMedia/download/transmission-home

In the Sonarr Docker:

PlexMedia with mount path /PlexMedia
docker/Sonarr with a mount path of /config

I have also deleted the Remote Path Mapping from the Sonarr application settings.

Both dockers start okay, but Sonarr throws an error message:

DiskScanService: Series’ root folder (/tv) is empty.

Folder /tv was previously a volume setting on the Sonarr Docker - PlexMedia/TV Shows with a mount path of /tv

I can’t find a reference to /tv in the Sonarr settings, but when I look at the file locations for the downloaded episodes, they show as in /tv/blah… Do I need to manually change something?

BTW, both Transmission and Sonarr dockers are running using the same GUID/PID.

You’ll have to add /PlexMedia/TV Shows as a root folder in sonarr, then use the mass editor to set the root path of all your series to this folder, then delete /tv as a root folder.

Got it. That seems to have fixed the final problem :smiley: and Sonarr just succesfully imported a test download!

Thank you so much for all your help (and patience) Thirrian :grinning: It is truly appreciated.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.