File MOVE fails at the end (NTFS/exFAT)

Support for Ubuntu and other Desktop Linux distributions
Post Reply
devster
Posts: 417
Joined: 06 Jun 2017, 22:56

File MOVE fails at the end (NTFS/exFAT)

Post by devster »

Hello,
I'm having an issue that I have trouble understanding, I have one disk on which I have the files and another on which i have the library, the first is formatted in exFAT, the second is an NTFS drive mounted with ntfs-3g, with permissions and a UserMapping file.

I'm running the following command:

Code: Select all

/usr/bin/filebot -script fn:amc -no-xattr --output "/mnt/bellatrix/Media/Movies" --action move --conflict auto --log-file amc.log --def unsorted=y subtitles=en artwork=y excludeList=".excludes" movieFormat="{n.colon(' - ')} ({y}, {director})/{ny.colon(' - ')}{' - ' + fn.matchAll(/extended|uncensored|uncut|directors[ ._-]cut|remastered|unrated|special[ ._-]edition/)*.upperInitial()*.lowerTrail().sort().join(', ').replaceAll(/[.]/, ' ') + ' '}{' PT'+pi} [{source} ({vf} {vc}) ({channels} {ac})]-{group}{subt}" /mnt/downloads/Whatever.Movie.2017
The MOVE operation seems to proceed, I can check the file is present in the destination location using 'ls' but right when it finishes it seems to fail, here and below the output log:

Code: Select all

/usr/bin/filebot -script fn:amc -no-xattr --output "/mnt/bellatrix/Media/Movies" --action move --conflict auto --log-file amc.log --def unsorted=y subtitles=en artwork=y excludeList=".excludes" movieFormat="{n.colon(' - ')} ({y}, {director})/{ny.colon(' - ')}{' - ' + fn.matchAll(/extended|uncensored|uncut|directors[ ._-]cut|remastered|unrated|special[ ._-]edition/)*.upperInitial()*.lowerTrail().sort().join(', ').replaceAll(/[.]/, ' ') + ' '}{' PT'+pi} [{source} ({vf} {vc}) ({channels} {ac})]-{group}{subt}" usbhdd/downloads/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT
Locking /home/devster/.filebot/logs/amc.log
Run script [fn:amc] at [Wed Jun 07 00:41:44 CEST 2017]
Parameter: unsorted = y
Parameter: subtitles = en
Parameter: artwork = y
Parameter: excludeList = .excludes
Parameter: movieFormat = {n.colon(' - ')} ({y}, {director})/{ny.colon(' - ')}{' - ' + fn.matchAll(/extended|uncensored|uncut|directors[ ._-]cut|remastered|unrated|special[ ._-]edition/)*.upperInitial()*.lowerTrail().sort().join(', ').replaceAll(/[.]/, ' ') + ' '}{' PT'+pi} [{source} ({vf} {vc}) ({channels} {ac})]-{group}{subt}
Argument[0]: /mnt/usbhdd/downloads/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT
Use excludes: /mnt/bellatrix/Media/Movies/.excludes (78)
Input: /mnt/usbhdd/downloads/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT.mkv
Group: [mov:brain on fire 2016] => [Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT.mkv]
Get [English] subtitles for 1 files
Looking up subtitles by hash via OpenSubtitles
No matching subtitles found: /mnt/usbhdd/downloads/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT.mkv
Rename movies using [TheMovieDB]
Auto-detect movie from context: [/mnt/usbhdd/downloads/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT.mkv]
[MOVE] From [/mnt/usbhdd/downloads/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT.mkv] to [/mnt/bellatrix/Media/Movies/Brain on Fire (2017, Gerard Barrett)/Brain on Fire (2017) [WEB-DL (1080p AVC) (5.1 AC3)]-FGT.mkv]
[MOVE] Failure: java.nio.file.FileSystemException: /mnt/bellatrix/Media/Movies/Brain on Fire (2017, Gerard Barrett)/Brain on Fire (2017) [WEB-DL (1080p AVC) (5.1 AC3)]-FGT.mkv: Operation not permitted
Processed 0 files
FileSystemException: /mnt/bellatrix/Media/Movies/Brain on Fire (2017, Gerard Barrett)/Brain on Fire (2017) [WEB-DL (1080p AVC) (5.1 AC3)]-FGT.mkv: Operation not permitted
Processing 1 unsorted files
[MOVE] From [/mnt/usbhdd/downloads/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT.mkv] to [/mnt/bellatrix/Media/Movies/Unsorted/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT.mkv]
[MOVE] Failure: java.nio.file.FileSystemException: /mnt/bellatrix/Media/Movies/Unsorted/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT.mkv: Operation not permitted
Processed 0 files
FileSystemException: /mnt/bellatrix/Media/Movies/Unsorted/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT/Brain.on.Fire.2016.1080p.WEB-DL.DD5.1.H264-FGT.mkv: Operation not permitted
Finished without processing any files
Failure (°_°)
Directory gets created normally, but files fail for some reason.
How should I go about trying to figure out what's happening?

Thank you
I only work in black and sometimes very, very dark grey. (Batman)
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: File MOVE fails at the end (NTFS/exFAT)

Post by rednoah »

Looks like a permission issue:

Code: Select all

java.nio.file.FileSystemException: /path/to/file: Operation not permitted
What permissions do the newly created directories have? Default directory permissions depend on your umask.
:idea: Please read the FAQ and How to Request Help.
devster
Posts: 417
Joined: 06 Jun 2017, 22:56

Re: File MOVE fails at the end (NTFS/exFAT)

Post by devster »

Below are the default permissions for a directory:

Code: Select all

devster@rpi3:/mnt/bellatrix $ mkdir test && lh
total 0
drwxrwsr-x 1 devster devster 0 Jun  7 19:27 test
And the default file permissions are:

Code: Select all

devster@rpi3:/mnt/bellatrix $ cd test && touch test.txt && lh
total 0
-rw-rw-r-- 1 devster devster 0 Jun  7 19:28 test.txt
However, what prompted me to ask here is the fact that during the execution of the filebot command this happens:

Code: Select all

devster@rpi3:/mnt/bellatrix $ lh Media/Movies/Brain\ on\ Fire\ \(2017\,\ Gerard\ Barrett\)/
total 138M
drwxrwsr-x 1 devster devster  248 Jun  7 00:42 .
drwxrwsr-x 1 devster devster  20K Jun  7 00:42 ..
-rwxrwxr-x 1 devster devster 138M Jun  7 00:42 Brain on Fire (2017) [WEB-DL (1080p AVC) (5.1 AC3)]-FGT.mkv
and the script seems to fail right at the end of the move or copy.

Since it was missing, below the output of the sysinfo script:

Code: Select all

FileBot 4.7.9 (r4984)
JNA Native: 5.1.0
MediaInfo: 0.7.73
7-Zip-JBinding: 9.20
Chromaprint: 1.4.2
Extended Attributes: OK
Unicode Filesystem: OK
Script Bundle: 2017-05-15 (r500)
Groovy: 2.4.10
JRE: Java(TM) SE Runtime Environment 1.8.0_65
JVM: 32-bit Java HotSpot(TM) Client VM
CPU/MEM: 4 Core / 224 MB Max Memory / 11 MB Used Memory
OS: Linux (arm)
Package: DEB
uname: Linux rpi3 4.9.24-v7+ #993 SMP Wed Apr 26 18:01:23 BST 2017 armv7l GNU/Linux
Done ヾ(@⌒ー⌒@)ノ
I only work in black and sometimes very, very dark grey. (Batman)
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: File MOVE fails at the end (NTFS/exFAT)

Post by rednoah »

No idea. It's probably an issue with the 3rd party file system driver you're using. I doubt that you'll have issues like that with well-supported file systems like ext. There's a reason why NTFS/exFAT drivers were read-only for a long time.
:idea: Please read the FAQ and How to Request Help.
devster
Posts: 417
Joined: 06 Jun 2017, 22:56

Re: File MOVE fails at the end (NTFS/exFAT)

Post by devster »

I'm convinced it's something related to the origin, COPY works but MOVE doesn't.
Oh well, I can live with this.
Thank you for the help.
I only work in black and sometimes very, very dark grey. (Batman)
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: File MOVE fails at the end (NTFS/exFAT)

Post by rednoah »

COPY is read only. MOVE requires read and write permissions.


i.e. MOVE = COPY + DELETE and you don't have DELETE permissions, which explains:

Code: Select all

Operation not permitted
:idea: Please read the FAQ and How to Request Help.
Post Reply