Lidarr Deleting Files Before Import #3399

Closed
opened 2026-02-20 02:17:35 -05:00 by deekerman · 9 comments
Owner

Originally created by @sirEgghead on GitHub (Dec 21, 2023).

Is there an existing issue for this?

  • I have searched the existing open and closed issues

Current Behavior

Multi-site setup. Download completes in torrent client. Lidarr immediately removes download from the client before rsync pulls the files.

Expected Behavior

Wait until successful import before deleting torrent from client. Radarr works properly with the same setup.

Steps To Reproduce

  1. Root : /multimedia/media/music
  2. Remote Mapping: /home/user/completed/ --> /multimedia/staging
  3. Deluge client with "Remove Completed" selected
  4. Select an album to search and download.
  5. Once download is complete and torrent is no longer seeding, torrent is deleted from client. Same client used in Radarr.
  6. Fail to import events are logged due to file having not made it to the staging directory

Environment

- OS: Ubuntu 22.04
- Lidarr: 2.0.7.3849
- Docker Install: yes
- Using Reverse Proxy: no
- Database: Sqlite 3.41.2

What branch are you running?

Master

Trace Logs?

lidarr_trace.txt

Trace Logs have been provided as applicable. Reports may be closed if the required logs are not provided.

  • I have read and followed the steps in the wiki link above and provided the required trace logs - the logs contain trace - that are relevant and show this issue.
Originally created by @sirEgghead on GitHub (Dec 21, 2023). ### Is there an existing issue for this? - [X] I have searched the existing open and closed issues ### Current Behavior Multi-site setup. Download completes in torrent client. Lidarr immediately removes download from the client before rsync pulls the files. ### Expected Behavior Wait until successful import before deleting torrent from client. Radarr works properly with the same setup. ### Steps To Reproduce 1. Root : /multimedia/media/music 2. Remote Mapping: /home/user/completed/ --> /multimedia/staging 3. Deluge client with "Remove Completed" selected 4. Select an album to search and download. 5. Once download is complete and torrent is no longer seeding, torrent is deleted from client. Same client used in Radarr. 6. Fail to import events are logged due to file having not made it to the staging directory ### Environment ```markdown - OS: Ubuntu 22.04 - Lidarr: 2.0.7.3849 - Docker Install: yes - Using Reverse Proxy: no - Database: Sqlite 3.41.2 ``` ### What branch are you running? Master ### Trace Logs? [lidarr_trace.txt](https://github.com/Lidarr/Lidarr/files/13746259/lidarr_trace.txt) ### Trace Logs have been provided as applicable. Reports may be closed if the required logs are not provided. - [X] I have read and followed the steps in the wiki link above and provided the required trace logs - the logs contain `trace` - that are relevant and show this issue.
Author
Owner

@sirEgghead commented on GitHub (Dec 21, 2023):

image

image

image

image

image

Just some extra info on my settings in case it is needed. In the trace it is mentioned that the import directory doesn't exist, and it is because it doesn't. My rsync schedule doesn't always run before the torrents and data vanish.

@sirEgghead commented on GitHub (Dec 21, 2023): ![image](https://github.com/Lidarr/Lidarr/assets/6648625/32cbcae9-8c07-41d6-81f0-b9b8f5d39194) ![image](https://github.com/Lidarr/Lidarr/assets/6648625/2d6b88d8-dd0c-44d7-9007-3ed9d6e106bc) ![image](https://github.com/Lidarr/Lidarr/assets/6648625/051dbbd2-743b-4d94-98f0-31f3074de30a) ![image](https://github.com/Lidarr/Lidarr/assets/6648625/47172b9a-00af-49dc-a6cc-8248cdc84374) ![image](https://github.com/Lidarr/Lidarr/assets/6648625/985953bc-5e76-4ce9-ae3d-a0d229a54435) Just some extra info on my settings in case it is needed. In the trace it is mentioned that the import directory doesn't exist, and it is because it doesn't. My rsync schedule doesn't always run before the torrents and data vanish.
Author
Owner

@mynameisbogdan commented on GitHub (Dec 21, 2023):

what should I look for in the logs?

you're saying you're using the same setup with other arrs and only with Lidarr you're having issues?

So far I would say this is a support thing, but I would've like to inspect further if there's something missing from Lidarr.

@mynameisbogdan commented on GitHub (Dec 21, 2023): what should I look for in the logs? you're saying you're using the same setup with other arrs and only with Lidarr you're having issues? So far I would say this is a support thing, but I would've like to inspect further if there's something missing from Lidarr.
Author
Owner

@sirEgghead commented on GitHub (Dec 21, 2023):

Sorry, I meant to note an item that I used for test that got caught in the logs.

2023-12-21 15:15:21.6|Debug|DownloadEventHub|[Bullet for My Valentine - Gravity (Deluxe Edition) (2018)[FLAC]eNJoY-iT] Removing download from Deluge history
2023-12-21 15:15:22.2|Debug|DownloadEventHub|[Highly Suspect] Removing download from Deluge history

These are 2 items near the end of the logs that were removed before I transferred them.

I don't have all *arrs operational just yet, but I do have Radarr running without issue using the same configuration that I posted above. Granted, Radarr will post import error events stating that XYZ doesn't exist and cannot import until rsync pulls the files from my remote site, but it will wait indefinitely until the import is successful before removing the torrent. Lidarr seems to be "removing once completed" regardless of the import state. I'm no expert, so I could certainly be doing something wrong, but I have yet to find out what.

Thank you for your patience in looking into this for me.

@sirEgghead commented on GitHub (Dec 21, 2023): Sorry, I meant to note an item that I used for test that got caught in the logs. `2023-12-21 15:15:21.6|Debug|DownloadEventHub|[Bullet for My Valentine - Gravity (Deluxe Edition) (2018)[FLAC]eNJoY-iT] Removing download from Deluge history` `2023-12-21 15:15:22.2|Debug|DownloadEventHub|[Highly Suspect] Removing download from Deluge history` These are 2 items near the end of the logs that were removed before I transferred them. I don't have all *arrs operational just yet, but I do have Radarr running without issue using the same configuration that I posted above. Granted, Radarr will post import error events stating that XYZ doesn't exist and cannot import until rsync pulls the files from my remote site, but it will wait indefinitely until the import is successful before removing the torrent. Lidarr seems to be "removing once completed" regardless of the import state. I'm no expert, so I could certainly be doing something wrong, but I have yet to find out what. Thank you for your patience in looking into this for me.
Author
Owner

@sirEgghead commented on GitHub (Dec 21, 2023):

image

image

image

Just a bit more comparison on one of the items from the trace logs that I noted in the previous post. Though I have to admit that I laughed at the contradiction. 😁

@sirEgghead commented on GitHub (Dec 21, 2023): ![image](https://github.com/Lidarr/Lidarr/assets/6648625/6addf559-8171-4d43-883f-f0b18f168c2a) ![image](https://github.com/Lidarr/Lidarr/assets/6648625/682d179e-7a69-4944-ab58-5ebc303f828f) ![image](https://github.com/Lidarr/Lidarr/assets/6648625/0ef81840-b255-472e-96d4-d4388c76d7fc) Just a bit more comparison on one of the items from the trace logs that I noted in the previous post. Though I have to admit that I laughed at the contradiction. 😁
Author
Owner

@bakerboy448 commented on GitHub (Dec 21, 2023):

Lidarr immediately removes download from the client before rsync pulls the files.

This is mostly environmental config / support issue, not a lidarr bug. rsync syncing after download is not a supported setup for the *Arrs.

https://wiki.servarr.com/lidarr/troubleshooting#remote-path-mapping

  • sync as you download
  • remote mount
  • import via custom script

Please use Discord for support/questions.

Once download is complete and torrent is no longer seeding, torrent is deleted from client. Same client used in Radarr.
Fail to import events are logged due to file having not made it to the staging directory

Failed Imports being erroneously treated as successful (i.e. the removal) are covered under https://github.com/Lidarr/Lidarr/issues/2746

@bakerboy448 commented on GitHub (Dec 21, 2023): > Lidarr immediately removes download from the client before rsync pulls the files. This is mostly environmental config / support issue, not a lidarr bug. rsync syncing after download is not a supported setup for the \*Arrs. https://wiki.servarr.com/lidarr/troubleshooting#remote-path-mapping - sync as you download - remote mount - import via custom script Please use [Discord](http://lidarr.audio/discord) for support/questions. > Once download is complete and torrent is no longer seeding, torrent is deleted from client. Same client used in Radarr. > Fail to import events are logged due to file having not made it to the staging directory Failed Imports being erroneously treated as successful (i.e. the removal) are covered under https://github.com/Lidarr/Lidarr/issues/2746
Author
Owner

@mynameisbogdan commented on GitHub (Dec 21, 2023):

@bakerboy448 Sonarr behaves the same way? 🤔

@mynameisbogdan commented on GitHub (Dec 21, 2023): @bakerboy448 Sonarr behaves the same way? 🤔
Author
Owner

@bakerboy448 commented on GitHub (Dec 21, 2023):

@bakerboy448 Sonarr behaves the same way? 🤔

#2746 covers it. lidarr erroneously treats downloads as successful even if they fail vs. being stuck in queue like radarr/sonarr which is the root of the issue

@bakerboy448 commented on GitHub (Dec 21, 2023): > @bakerboy448 Sonarr behaves the same way? 🤔 #2746 covers it. lidarr erroneously treats downloads as successful even if they fail vs. being stuck in queue like radarr/sonarr which is the root of the issue
Author
Owner

@mynameisbogdan commented on GitHub (Dec 21, 2023):

Good to know. I'll have to look into it some day.

@mynameisbogdan commented on GitHub (Dec 21, 2023): Good to know. I'll have to look into it some day.
Author
Owner

@sirEgghead commented on GitHub (Dec 21, 2023):

Glad to see there's an open bug for this. A little less glad to see that 2746 is 20 months old, but nevertheless, thank you.

As far as rsync after the download finishes, I'm just working with bad internet over here. Doing what I can. It's not something that I'll address the support community on due to circumstances. I'll use a workaround and build a custom import script until the bug gets some work.

Thanks again and happy holidays.

@sirEgghead commented on GitHub (Dec 21, 2023): Glad to see there's an open bug for this. A little less glad to see that 2746 is 20 months old, but nevertheless, thank you. As far as rsync after the download finishes, I'm just working with bad internet over here. Doing what I can. It's not something that I'll address the support community on due to circumstances. I'll use a workaround and build a custom import script until the bug gets some work. Thanks again and happy holidays.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Lidarr#3399
No description provided.