Sonarr -> Prowlarr -> Transmission Docker mapping

Sonarr version (exact version): 3.0.6.1265
OS: Ubuntu
Description of issue: Trying to figure out the appropriate mapping because Sonarr is not importing

I realize there have been some similar issues, but using those answers I’ve not managed to solve for my problem.

Currently, Sonarr does not import files once completed and seeded in Transmission. I have a Ubuntu server running multiple Docker containers (Sonarr, Prowlarr, Transmission-OpenVPN etc.). But I am brand new to this world! I figure it has something to do with Sonarr and Transmission running in two separate containers and needing paths mapped appropriately—here are my docker-compose.yml snippets

Sonarr

 sonarr:
    image: ghcr.io/linuxserver/sonarr
    container_name: sonarr
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=America/Chicago
    volumes:
      - /home/acd37/media/sonarr/data:/config
      - /home/acd37/media/sonarr/tvseries:/tv 
      - /home/acd37/media/sonarr/downloadclient-downloads:/downloads
    ports:
      - 8989:8989
    restart: unless-stopped

Transmission

transmission-openvpn:
    cap_add:
      - NET_ADMIN
    volumes:
      - '/home/acd37/media/transmission/:/data'
    environment:
      - OPENVPN_PROVIDER=NORDVPN
      - OPENVPN_USERNAME=<user>
      - OPENVPN_PASSWORD=<pass>
      - LOCAL_NETWORK=192.168.1.0/24
    logging:
      driver: json-file
      options:
          max-size: 10m
    ports:
      - '9091:9091'
    image: haugene/transmission-openvpn

Prowlarr

prowlarr:
    image: ghcr.io/linuxserver/prowlarr:develop
    container_name: prowlarr
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=America/Chicago
    volumes:
      - /home/acd37/media/prowlarr/data:/config
    ports:
      - 9696:9696
    restart: unless-stopped

https://trash-guides.info/hardlinks/

I appreciate the link, but I’ve reviewed this. My Sonarr set up is correct—what I’m looking for, as mentioned in original post, is help to map the paths between Transmission and Sonarr containers.

  - /home/acd37/media/sonarr/data:/config
  - /home/acd37/media/sonarr/tvseries:/tv 
  - /home/acd37/media/sonarr/downloadclient-downloads:/downloads

you may have reviewed that guide, but you appear to have skimmed it and did not take any actions based on it. Your sonarr setup and transmission setups are incorrect and suboptimal as well. even if you fix those as is or add a remote path map you will kill your harddrives early with everything being a copy delete and use double space for every single torrent.

that is the solution to your issue. Having consistent and well-planned paths.

Shit to fix in general (needless to say, stop all containers first, make a backup, I’m not responsible, blah blah):

  • make a /home/acd37/docker path
  • make a subfolder underneath for each of the containers, see below
  • move the config files of each container to their respective subfolder
  • make a /home/acd37/media/tvseries folder
  • move your sorted series folders to this folder (for the record, currently found in /home/acd37/media/sonarr/tvseries)
  • make a /home/acd37/media/torrents folder

Thing to pay attention to: we’re giving the entire /media path to sonarr as a mount! NOT individual subfolders!

Shit to fix in sonarr once it’s started:

  • add /media/tvseries as a root path (in settings)
  • use the Mass Editor to update all your series to use the /media/tvseries root path
  • delete the old root path once done

I have no experience with this one. I changed it to a more sane approach of splitting config and data (torrents). However you have to configure it in the application, tell it to use the new /media/torrents path to download files to.

Just a small update here to keep all docker config files nicely contained in the /home/acd37/docker folder (see general steps above). Nothing to be done in the application to the best of my knowledge.

General cleanup: get rid of unused paths.


That should do it unless I missed something, you can now laugh and cry and join me in mocking linuxservers’ fucking retarded suggested paths which keep wrecking people’s understanding of docker mounts, which I really really really wish they would update in their documentation after all these years.

2 Likes

One nit - sonarr root folder gets /media/tvseries

The container does get /media still.

LSIO did indicate their paths are optional but that requires users to not follow the many not great videos and guides that exist and/or actually read instructions

I beg to differ, sonarr needs both /media/tvshows and /media/torrents, so you use /media as a mount :wink:

Thanks @Thirrian I have implemented your changes (and I think these have given me a clearer idea of exactly what these volume paths should be and why… though god it would be good to sit down with someone at a meetup and try and understand this better).

Currently doing a test download… we’ll see :grimacing:

@Thirrian download completed, but is still sitting in the queue. Seeding is complete. I’m not sure what to provide you to start debugging this. But here is what I’m seeing:

And my current docker-compose.yml based on your suggestions (I think I got it right):

version: "3.6"
services:
  sonarr:
    image: ghcr.io/linuxserver/sonarr
    container_name: sonarr
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=America/Chicago
    volumes:
      - /home/acd37/docker/sonarr:/config
      - /home/acd37/media:/media
    ports:
      - 8989:8989
    restart: unless-stopped
  prowlarr:
    image: ghcr.io/linuxserver/prowlarr:develop
    container_name: prowlarr
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=America/Chicago
    volumes:
      - /home/acd37/docker/prowlarr:/config
    ports:
      - 9696:9696
    restart: unless-stopped
  transmission-openvpn:
    cap_add:
      - NET_ADMIN
    volumes:
      - /home/acd37/docker/transmission:/config
      - /home/acd37/media/torrents:/media/torrents
    environment:
      - OPENVPN_PROVIDER=NORDVPN
      - OPENVPN_USERNAME=<user>
      - OPENVPN_PASSWORD=2<pass>
      - LOCAL_NETWORK=192.168.1.0/24
    logging:
      driver: json-file
      options:
          max-size: 10m
    ports:
      - '9091:9091'
    image: haugene/transmission-openvpn

I’m wondering if this is the issue? Transmission is downloading the files into /home/acd37/media/transmission/completed

Screen Shot 2021-08-13 at 1.34.35 PM

Debug logs :grimacing:
Debug level would probably be sufficient, the guide says trace but I think that’s overkill in this situation.

Change that path to /media/torrents and should be good to go I think?

Yup we’re on the same page.

Mount gets media

Root in the app is media/tvseries

Alright! Debug logs it is. I just re-downloaded after changing the Transmission path, and can confirm the files successfully downloaded and landed in /media/torrents. They then appeared to fail on imports.

From what I can tell with my limited knowledge from the logs, it’s something to do with a write permissions issue?

Logs: https://pastebin.com/AUGG3i8y

Deviation from the problem at hand first… a slight misconfiguration, which is my fault in hindsight. Amended my earlier post in case someone stumbles upon it:

Debug|EpisodeFileMovingService|Moving episode file: /media/torrents/Breaking.Bad.SEASON.01.S01.COMPLETE.1080p.10bit.BluRay.6CH.x265.HEVC-PSA/Breaking.Bad.S01E07.A.No-Rough-Stuff-Type.Deal.1080p.10bit.BluRay.6CH.x265.HEVC-PSA.mkv to /media/Breaking Bad/Season 1/Breaking.Bad.S01E07.A.No-Rough-Stuff-Type.Deal.1080p.10bit.BluRay.6CH.x265.HEVC-PSA.mkv

You set /media as the root path in sonarr, which I incorrectly told you to. You should really set it to /media/tvseries, so this episode ends up in /media/tvservies/Breaking Bad.
Sorry, some more moving of files, deleting root path in Sonarr, adding root path, using Mass Editor…


Actual issue (not moving files) is permissions: System.UnauthorizedAccessException: Access to the path is denied.

Sonarr doesn’t have access to either source or destination. At a minimum, sonarr needs access to /media/torrents and /media/tvseries (see above to correct this path). If being lazy/less secure, access to the entire /media mount.

OMG I THINK IT WORKED! Thanks so much! @Thirrian

Now to get on with Plex :grimacing:

I take it back. Once I did the move, the imported successfully, it went green, the Season 1 said 7/7, and then they all disappeared and it went to 0/7 and red again :sob:

Some more logs I guess? Which include the name of an episode that disappeared and/or sonarr’s daily disk scan.

How did you move the files?

1 Like

So I just cleared everything out… and re-downloaded Season 01 of Breaking Bad (just what I’ve been using for testing)… it downloaded fine… and then just disappeared.

Here is the log: https://pastebin.com/U5ZicYKn

I’m also confused about why the log has so many different shows being looked at… I’m not downloading any of these other than Breaking Bad.

OK looking in the non-debug log file I also see there is still a permissions error:

I thought I had taken care of this by basically opening /media using sudo chmod -R 777 media but I guess not?

2021-08-14 07:15:37.6|Warn|ImportApprovedEpisodes|Couldn't import episode /media/torrents/Breaking.Bad.SEASON.01.S01.COMPLETE.1080p.10bit.BluRay.6CH.x265.HEVC-PSA/Breaking.Bad.S01E05.Gray.Matter.1080p.10bit.BluRay.6CH.x265.HEVC-PSA.mkv

[v3.0.6.1265] System.UnauthorizedAccessException: Access to the path is denied.
  at System.IO.File.Move (System.String sourceFileName, System.String destFileName) [0x00116] in <254335e8c4aa42e3923a8ba0d5ce8650>:0 
  at NzbDrone.Common.Disk.DiskProviderBase.MoveFileInternal (System.String source, System.String destination) [0x00000] in M:\BuildAgent\work\63739567f01dbcc2\src\NzbDrone.Common\Disk\DiskProviderBase.cs:268 
  at NzbDrone.Mono.Disk.DiskProvider.MoveFileInternal (System.String source, System.String destination) [0x000a3] in M:\BuildAgent\work\63739567f01dbcc2\src\NzbDrone.Mono\Disk\DiskProvider.cs:306 
  at NzbDrone.Common.Disk.DiskProviderBase.MoveFile (System.String source, System.String destination, System.Boolean overwrite) [0x000e1] in M:\BuildAgent\work\63739567f01dbcc2\src\NzbDrone.Common\Disk\DiskProviderBase.cs:255 
  at NzbDrone.Common.Disk.DiskTransferService.TryMoveFileVerified (System.String sourcePath, System.String targetPath, System.Int64 originalSize) [0x00047] in M:\BuildAgent\work\63739567f01dbcc2\src\NzbDrone.Common\Disk\DiskTransferService.cs:487 
  at NzbDrone.Common.Disk.DiskTransferService.TransferFile (System.String sourcePath, System.String targetPath, NzbDrone.Common.Disk.TransferMode mode, System.Boolean overwrite) [0x004b9] in M:\BuildAgent\work\63739567f01dbcc2\src\NzbDrone.Common\Disk\DiskTransferService.cs:367 
  at NzbDrone.Core.MediaFiles.EpisodeFileMovingService.TransferFile (NzbDrone.Core.MediaFiles.EpisodeFile episodeFile, NzbDrone.Core.Tv.Series series, System.Collections.Generic.List`1[T] episodes, System.String destinationFilePath, NzbDrone.Common.Disk.TransferMode mode) [0x00129] in M:\BuildAgent\work\63739567f01dbcc2\src\NzbDrone.Core\MediaFiles\EpisodeFileMovingService.cs:116 
  at NzbDrone.Core.MediaFiles.EpisodeFileMovingService.MoveEpisodeFile (NzbDrone.Core.MediaFiles.EpisodeFile episodeFile, NzbDrone.Core.Parser.Model.LocalEpisode localEpisode) [0x00046] in M:\BuildAgent\work\63739567f01dbcc2\src\NzbDrone.Core\MediaFiles\EpisodeFileMovingService.cs:79 
  at NzbDrone.Core.MediaFiles.UpgradeMediaFileService.UpgradeEpisodeFile (NzbDrone.Core.MediaFiles.EpisodeFile episodeFile, NzbDrone.Core.Parser.Model.LocalEpisode localEpisode, System.Boolean copyOnly) [0x001ab] in M:\BuildAgent\work\63739567f01dbcc2\src\NzbDrone.Core\MediaFiles\UpgradeMediaFileService.cs:77 
  at NzbDrone.Core.MediaFiles.EpisodeImport.ImportApprovedEpisodes.Import (System.Collections.Generic.List`1[T] decisions, System.Boolean newDownload, NzbDrone.Core.Download.DownloadClientItem downloadClientItem, NzbDrone.Core.MediaFiles.EpisodeImport.ImportMode importMode) [0x0029b] in M:\BuildAgent\work\63739567f01dbcc2\src\NzbDrone.Core\MediaFiles\EpisodeImport\ImportApprovedEpisodes.cs:109 

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