[Synology] Kodi cannot access files on one share after moving them from another share (likely due to permissions)

Support for Synology NAS, QNAP NAS and other Embedded Linux systems
Post Reply
NickiS1305
Posts: 4
Joined: 19 Feb 2023, 19:53

[Synology] Kodi cannot access files on one share after moving them from another share (likely due to permissions)

Post by NickiS1305 »

hello :)

I set up Filebot, wrote an SH script and linked it to JDownloader. Everything works too. Filebot renames the file and moves it to the correct folder.But when I try to play this file with Kodi, there is an error message!If I move the file manually, there is no error.

Filebot v. 4.9.6 and Kodi v.20
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Files Move Problem Kodi

Post by rednoah »

:?: What does the error message say?

:?: Are you processing local files or remote files? What OS and file system are you using? Are FileBot and Kodi running on the same machine?

:?: FileBot does not modify files, so the behaviour you describe shouldn't be possible. What is the difference between a file that was moved by filebot and a file that was moved with the mv command? There must be a difference.

:?: Does disabling xattr metadata make a difference?
:idea: Please read the FAQ and How to Request Help.
NickiS1305
Posts: 4
Joined: 19 Feb 2023, 19:53

Re: Files Move Problem Kodi

Post by NickiS1305 »

Error Message:
Playback failed, One or more items failed to play.

I process local files.
Script:

Code: Select all

#!/bin/sh
##FileBot benötigt diese Variablen
##/bin/mkdir /volume1/video/Downloads/videos/testordner
LOG="/volume1/amc.log"
EXC="/volume1/amc.txt"
SERIEN="/volume1/Serien/{n}/{s}/{n}.{s00e00} - {t} ({y}) {vf}"
FILME="/volume1/Filme/{n} ({y}) {source}({vf}@{vc}) [{rating}]/{n} ({y}) {source}({vf}@{vc}) [{rating}]"
##UNSORTIERT="/path/{file.structurePathTail}" ### Wenn Filebot mal etwas nicht zuordnen kann, dann kannst du es in einen seperaten Ordner verschieben lassen, dann bleibt es im Downloadordner übersichtlich.
##FileBot ausführen
/var/packages/filebot/target/bin/filebot -script fn:amc --lang de --log-file $LOG --action move "$1" --output "/volume1/video" --def "seriesFormat=$SERIEN" "movieFormat=$FILME" "animeFormat=$ANIME" "unsortedFormat=$UNSORTIERT" -non-strict --def unsorted=y "artwork=y" ##--def clean=y
## Aufräumen, --def root löscht den Unterordner mit
## /var/packages/filebot/target/bin/filebot -script fn:cleaner "$1" --def root=y
OS: Synology DSM 7.1.1-42962 Update 2
Device: DS 720+
Filesystem: BTRFS
Both running on the same Maschine

I will check xattr and mv command later, thanks.
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Files Move Problem Kodi

Post by rednoah »

If it's all local files, then the issue is most likely not related to filebot, at least not directly. The local file system is extremely stable and reliable, so that eliminates all known remote file system issues.

:arrow: The first step is to check CRC32 checksums. If the file is the same byte for byte, then the file is the same and cannot not work. That would lead me to double-check my all my assumptions. As for a random guess, could be something obscure such as the OS running into some kind of "open files" limit, or Kodi just being buggy, and looking into Kodi logs might shed some light on things.
:idea: Please read the FAQ and How to Request Help.
NickiS1305
Posts: 4
Joined: 19 Feb 2023, 19:53

Re: Files Move Problem Kodi

Post by NickiS1305 »

I tried it with copy and duplicate and it worked, KODi can play the files. But now the root folder does not work anymore ..

It looks like move is not working properly with the file system? Or is it because of the different folders ..
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Files Move Problem Kodi

Post by rednoah »

NickiS1305 wrote: 20 Feb 2023, 17:10 It looks like move is not working properly with the file system?
We can generally assume that basic fundamental file system operations work, otherwise nothing on that machine would work, i.e. you'd have much bigger problems.


:?: Do you have issues with any software other than Kodi? That would help narrow down the issue. If the issue is specific to Kodi, then I'd start reading the Kodi logs.


:?: Are you sure that Kodi is aware of the new file paths? If you move A to B, and Kodi didn't get the memo, then Kodi won't be able to play A because A no longer exists at that file path after the move operation.
:idea: Please read the FAQ and How to Request Help.
NickiS1305
Posts: 4
Joined: 19 Feb 2023, 19:53

Re: Files Move Problem Kodi

Post by NickiS1305 »

I don't know why, but it works now. Now i have everything in the same "subVolume".

Volume 1 with subvolume "Downloads" "Movies" "Series". It doesn't work from one to another subVolume with move command, KODi dont play anything.
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Files Move Problem Kodi

Post by rednoah »

NickiS1305 wrote: 20 Feb 2023, 21:17 Volume 1 with subvolume "Downloads" "Movies" "Series". It doesn't work from one to another subVolume with move command, KODi dont play anything.
That would strongly suggest a permission issue. Please check the Kodi logs to confirm. FileBot does not touch Synology-specific permissions (i.e. ACLs) so you may need to fix them in the Synology Permissions WebUI. Standard Unix file permissions and file ownership may also be at play, but since you're using Synology, I'd start by checking Synology ACL permissions since those can override standard Unix permissions. Keep in mind that ACLs can get complicated as they are inherited and computed from parent folders, so different permissions may apply depending where the file is located.


:!: Note that "I move the file manually, there is no error." would typically suggest that it's not a permission issue, but in this case, maybe you used the Synology WebUI to move files? That's very different from moving files normally (i.e. the mv command) because Synology software might do Synology-specific things, e.g. set permissions, refresh computed permissions, refresh media index, etc.
:idea: Please read the FAQ and How to Request Help.
Post Reply