chudak 23 Posted May 3, 2019 Share Posted May 3, 2019 I use Addic7ed and opensubtitles.org and lately noticed that Emby (on ubuntu) downloads 0 byte file size subtitles. Wondering if anybody has seen and fixed this issue? Very annoying ! Thx CC @@Luke Link to comment Share on other sites More sharing options...
speechles 1921 Posted May 3, 2019 Share Posted May 3, 2019 (edited) They could have changed their limits. Look in your log for anything indicating 403/501 for the subtitle fetches. The server should know not to do this, but it may have the wrong quota for fetches per interval. It might think it is okay to fetch 30 times in 2 hours. When now it is 20 times. The extra 10 would not know there is no data as it opens/closes the file handler. You would in effect simply be getting what "touch" does and create a file or modify the timestamp. If you exceed limits repeatedly they may place an entire lock on your IP to stop your abuse. They figure you have a malconfigured client or are just an abusive pest. That lock will lift eventually. That lock will show as 503. The first thing to do would be look at the log. Permissions wouldn't cause this as you wouldn't get the file to begin with. The fact it is empty might be an execute permission missing. That could cause the missing data.. maybe.. Probably not though. The +x so you gain the ability to execute files and enter subdirs. You probably have that or it wouldn't have saved the file to begin with. My thought is quota limits changed and Emby just needs to input these new values. The simplest answer is usually correct. Edited May 3, 2019 by speechles Link to comment Share on other sites More sharing options...
chudak 23 Posted May 3, 2019 Author Share Posted May 3, 2019 Thx @speechles I actually see *** Error Report *** in the log https://pastebin.com/cNy78sQk Link to comment Share on other sites More sharing options...
chudak 23 Posted May 4, 2019 Author Share Posted May 4, 2019 (edited) @@Luke Did you find any clues from the log? So it's broken in 4.1.1.0 I wonder if it's safe to downgrade to the older version? Edited May 4, 2019 by chudak Link to comment Share on other sites More sharing options...
Luke 37161 Posted May 5, 2019 Share Posted May 5, 2019 I don't see anything obvious, I also don't think downgrading will make any difference. I don't believe there's any widespread problem, it seems to be working fine in my testing. Have you run a disk scan to check your hard disk for errors? Link to comment Share on other sites More sharing options...
chudak 23 Posted May 17, 2019 Author Share Posted May 17, 2019 I still see the problem. Wonder if anybody can walk me thru how subtitles work in Emby? What is in /var/lib/emby/data/subtitles/ what is in media folder? Whats happens is not plugins are used? What if Addic7ed and Opensubtitles used ? Thx in advakce! @@Luke maybe, pls Link to comment Share on other sites More sharing options...
chudak 23 Posted May 17, 2019 Author Share Posted May 17, 2019 (edited) Corresponding error in the log when Emby is downloading 0 file size subtitle file say: System.UnauthorizedAccessException: System.UnauthorizedAccessException: Access to the path '/media/seagatecentral/Public/Videos/<NAME>/<NAME>.bif' is denied. ---> System.IO.IOException: Permission denied Dir permissions show: # owner: user # group: user # flags: -s- user::rwx group::rwx other::rwx Anybody knows whats wrong be able to create a file? MKV file was added without problems into the same folder ! Edited May 17, 2019 by chudak Link to comment Share on other sites More sharing options...
speechles 1921 Posted May 17, 2019 Share Posted May 17, 2019 Is there a sub-process getting those for Emby? Would they fall into the other? The other is obviously where you don't allow write access. It has to be this. It can create the file. It is there. You see it. It exists. The issue is whatever was trying to write into it failed with that permission error. Otherwise it wouldn't have even created the file handle to begin with and written it. Link to comment Share on other sites More sharing options...
chudak 23 Posted May 17, 2019 Author Share Posted May 17, 2019 Is there a sub-process getting those for Emby? Would they fall into the other? The other is obviously where you don't allow write access. It has to be this. It can create the file. It is there. You see it. It exists. The issue is whatever was trying to write into it failed with that permission error. Otherwise it wouldn't have even created the file handle to begin with and written it. You are right if file was created then something else is going on. Not sure about sub-processes yet. On my library settings level I clearly see option selected "Save subtitles into media folders" After manually removing subs from media filed and also from "/var/lib/emby/metadata/library/88/88c07a75c2b9c85a932fe449fc57caeaK" folder and after running library scan i see 0 file subs size in the media folder and good subs file in "/var/lib/emby/metadata/library/88/XXX" But why ? and why "Save subtitles into media folders" does not seem to be doing what is says it should be doing ? Link to comment Share on other sites More sharing options...
Q-Droid 657 Posted May 17, 2019 Share Posted May 17, 2019 Corresponding error in the log when Emby is downloading 0 file size subtitle file say: System.UnauthorizedAccessException: System.UnauthorizedAccessException: Access to the path '/media/seagatecentral/Public/Videos/<NAME>/<NAME>.bif' is denied. ---> System.IO.IOException: Permission denied Dir permissions show: # owner: user # group: user # flags: -s- user::rwx group::rwx other::rwx Anybody knows whats wrong be able to create a file? MKV file was added without problems into the same folder ! Was the mkv file added by the Emby server? The user has to be able to navigate the path from /media to Videos/ so even if the bif file itself has the right permissions the Emby server has to be able to reach it. The other log shows it timing out on opensubtitles. Connectivity? Addic7ed is in limbo right now. The plug-in doesn't work for many and Luke is waiting for them to release their API before he can overhaul the plug-in. Link to comment Share on other sites More sharing options...
chudak 23 Posted May 17, 2019 Author Share Posted May 17, 2019 Was the mkv file added by the Emby server? The user has to be able to navigate the path from /media to Videos/ so even if the bif file itself has the right permissions the Emby server has to be able to reach it. Yes, was added by Emby The other log shows it timing out on opensubtitles. Connectivity? I can browser and login to opensubtitles, what esle? Addic7ed is in limbo right now. The plug-in doesn't work for many and Luke is waiting for them to release their API before he can overhaul the plug-in. That's good to know, I actually added it to help fix the issue. And BTW subs were downloading fine till recently, suspecting l=maybe last 2 upgrades maybe... Link to comment Share on other sites More sharing options...
Q-Droid 657 Posted May 17, 2019 Share Posted May 17, 2019 Does the manual search for subs from the title or episode give any results? Just the search, not download. Also check the log after a search to see if it's able to connect. Link to comment Share on other sites More sharing options...
chudak 23 Posted May 17, 2019 Author Share Posted May 17, 2019 Does the manual search for subs from the title or episode give any results? Just the search, not download. Also check the log after a search to see if it's able to connect. oh yes, im far passed this point Link to comment Share on other sites More sharing options...
Q-Droid 657 Posted May 17, 2019 Share Posted May 17, 2019 So if you manually search and download the result is the same, empty files? I guess you could try SubDB though that's not a fix but just to confirm that there might be a bug is this release. Link to comment Share on other sites More sharing options...
chudak 23 Posted May 17, 2019 Author Share Posted May 17, 2019 Whatever this is - it is related to "Save subtitles into media folders" When this option is enabled, Emby writes a 0 size subs file into the media folder and keeps/add subs on scan in "/var/lib/emby/metadata/library/xxx" folder @@Luke FYI Link to comment Share on other sites More sharing options...
Luke 37161 Posted May 19, 2019 Share Posted May 19, 2019 This is probably tied to your permissions problem being discussed elsewhere. Link to comment Share on other sites More sharing options...
chudak 23 Posted May 19, 2019 Author Share Posted May 19, 2019 This is probably tied to your permissions problem being discussed elsewhere. If this is the case and I have these: # owner: user # group: user # flags: -s- user::rwx group::rwx other::rwx Tell me then: - what's wrong with those permissions - how come emby has no problems with any files in the same dirs and writes 0 size files for subs ? Link to comment Share on other sites More sharing options...
chudak 23 Posted May 19, 2019 Author Share Posted May 19, 2019 (edited) @Luke I have to admit that it is permissions issue! (Sharing details for benefits of the group) ((Why this is actually happening, what caused it, why emby can create file but can't write to it - kill me, I don't know. Hoping some ubuntu permissions experts read this and know the clues.)) The way I tested that this is related to permissions: logged as emby user (sudo su -s /bin/bash emby) created a new test dir in /var/lib/emby/metadata/library/ and copied a media file there downloaded subs via Emby UI and confirmed a normal size file was added I guess now the question is what to do about it? Option 1: change permission to correct values (read above) - open question is how? (I see now on problematic drive permissions drwxrwxrwx 2 nobody nogroup and as emby user drwxr-xr-x 4 emby emby! ) Option 2: I have all my media dirs/files are stored on Seagate Central drive connected via samba mount. I was thinking that if I add a user 'emby' to it with admin rights that can fix the issue. Now - what is emby default password ? (see https://emby.media/community/index.php?/topic/73779-emby-user-password-on-ubuntu/) - if I change emby user password - is it safe? @@Like? Thx all for participating I think it might be useful to others at some point ! Edited May 19, 2019 by chudak Link to comment Share on other sites More sharing options...
Luke 37161 Posted May 20, 2019 Share Posted May 20, 2019 I've updated the server to not leave 0 byte files behind in the event of failure. Or rather, it will try to delete it, hopefully permissions won't cause that to fail as well and then leave waste behind. Link to comment Share on other sites More sharing options...
chudak 23 Posted May 20, 2019 Author Share Posted May 20, 2019 I've updated the server to not leave 0 byte files behind in the event of failure. Or rather, it will try to delete it, hopefully permissions won't cause that to fail as well and then leave waste behind. Good it will help avoid undesirable crashes caused by this, thx Link to comment Share on other sites More sharing options...
chudak 23 Posted May 24, 2019 Author Share Posted May 24, 2019 I've updated the server to not leave 0 byte files behind in the event of failure. Or rather, it will try to delete it, hopefully permissions won't cause that to fail as well and then leave waste behind. @@Luke Additional data point. Here is what I tried - used Kodi to play a video from the same location, same permissions etc. And Kodi had NO problems to download and save subs into the media folder. Do you still believe this is not Emby issue ? Link to comment Share on other sites More sharing options...
alucryd 217 Posted May 24, 2019 Share Posted May 24, 2019 Is kodi on the same machine as emby? Is kodi launched as your user or as emby? Link to comment Share on other sites More sharing options...
chudak 23 Posted May 25, 2019 Author Share Posted May 25, 2019 Is kodi on the same machine as emby? Is kodi launched as your user or as emby? Kodi and emby are on different machines Not sure about user But they both read/write to/from same samba data storage Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now