Jump to content
kumzrocks

Server running on Android box not able to delete media on external storage

Recommended Posts

kumzrocks

Hi All

Thanks a lot for enabling it for android started working flawlessly from day 1. I have just 1 small issue while deleting a media.

I have set up server in android box and also connected to external storage. I can read and play contents from this storage but when i try to delete it gives error "There was an error deleting the item from Emby Server. Please check that Emby Server has write access to the media folder and try again."

  • I have checked the permission of the user in emby server it has the permission to delete folders 
  • Also check in android box with Emby app permission it has the same permission as a FTP server which i running i can access the FTP server via file browser and delete connect in other devices

Please find below the logs i found after deleting

Android version is 8.1

Box Model is H96 Max + rk3328

 

2020-01-14 22:50:25.256 Info HttpServer: HTTP DELETE http://192.168.1.2:8096/emby/Items/3253. UserAgent: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.117 Safari/537.36
2020-01-14 22:50:25.394 Info App: Removing item from database, Type: Movie, Name: Drishyam, Path: /storage/9AF2BF43F2BF2285/kumz data/others_col_mov/Drishyam.mkv, Id: 3253
2020-01-14 22:50:25.394 Info App: Deleting path /storage/emulated/0/Android/data/com.emby.embyserver/files/metadata/library/b4/b4f809d7af3ceea667ccc7ec0e25993e
2020-01-14 22:50:25.399 Info App: Deleting path /storage/9AF2BF43F2BF2285/kumz data/others_col_mov/Drishyam.mkv
2020-01-14 22:50:25.404 Error HttpServer: Error processing request
    *** Error Report ***
    Version: 4.4.0.6
    Command line: /data/app/com.emby.embyserver-_PINun7Ob5gNnDxAYXd78A==/base.apk
    Operating system: Unix 4.4.120.0
    64-Bit OS: True
    64-Bit Process: True
    User Interactive: False
    Runtime: file:///mscorlib.dll
    System.Environment.Version: 4.0.50524.0
    Processor count: 4
    Program data path: /storage/emulated/0/Android/data/com.emby.embyserver/files
    Application directory: /data/user/0/com.emby.embyserver
    Mono: 6.6.0 (2019-08/e1ef774391d)
    Android Version: 8.1.0-REL - Base: - SDK: OMr1
    Build ID: OPM6.171019.030.B1 - Incremental: 053034 Patch-Level: 2018-07-05
    Fingerprint: Android/rk3328/rk3328:8.1.0/OPM6.171019.030.B1/053034:user/release-keys
    Model: H96 Max+ - rockchip/Android
    Hardware: rk3328/rk3328/rk30board/rk30sdk
    SupportedAbis: arm64-v8a, armeabi-v7a, armeabi
    System.UnauthorizedAccessException: System.UnauthorizedAccessException: Access to the path '/storage/9AF2BF43F2BF2285/kumz data/others_col_mov/Drishyam.mkv' is denied. ---> System.IO.IOException: Permission denied
     --- End of inner exception stack trace ---
     at System.IO.FileSystem.DeleteFile (System.String fullPath) [0x0006d] in <b7bb5f3538424ec1927304809f832185>:0
     at System.IO.File.Delete (System.String path) [0x00014] in <b7bb5f3538424ec1927304809f832185>:0
     at Emby.Server.Implementations.IO.ManagedFileSystem.DeleteFileInternal (System.String path, System.Boolean sendToRecycleBin) [0x00000] in <35383502c6e541e18437747c81175cb9>:0
     at Emby.Server.Implementations.IO.ManagedFileSystem.DeleteFile (System.String path, System.Boolean sendToRecycleBin) [0x00024] in <35383502c6e541e18437747c81175cb9>:0
     at Emby.Server.Implementations.Library.LibraryManager.DeleteItem (MediaBrowser.Controller.Entities.BaseItem item, MediaBrowser.Controller.Library.DeleteOptions options, MediaBrowser.Controller.Entities.BaseItem parent, System.Boolean notifyParentItem) [0x00223] in <35383502c6e541e18437747c81175cb9>:0
     at Emby.Server.Implementations.Library.LibraryManager.DeleteItem (MediaBrowser.Controller.Entities.BaseItem item, MediaBrowser.Controller.Library.DeleteOptions options, System.Boolean notifyParentItem) [0x0001f] in <35383502c6e541e18437747c81175cb9>:0
     at MediaBrowser.Api.Library.LibraryService.Delete (MediaBrowser.Api.Library.DeleteItems request) [0x00099] in <f28ad1a682514afd90f07da8ebb51b31>:0
     at MediaBrowser.Api.Library.LibraryService.Delete (MediaBrowser.Api.Library.DeleteItem request) [0x00012] in <f28ad1a682514afd90f07da8ebb51b31>:0
     at (wrapper dynamic-method) System.Object.lambda_method(System.Runtime.CompilerServices.Closure,object,object)
     at Emby.Server.Implementations.Services.ServiceController+<>c__DisplayClass6_0.<VoidActionDelegate>b__0 (System.Object service, System.Object request) [0x00000] in <35383502c6e541e18437747c81175cb9>:0
     at Emby.Server.Implementations.Services.ServiceController.Execute (Emby.Server.Implementations.HttpServer.HttpListenerHost appHost, System.Object requestDto, MediaBrowser.Model.Services.IRequest req) [0x00073] in <35383502c6e541e18437747c81175cb9>:0
     at Emby.Server.Implementations.Services.ServiceHandler.ProcessRequestAsync (Emby.Server.Implementations.HttpServer.HttpListenerHost appHost, MediaBrowser.Model.Services.IRequest httpReq, MediaBrowser.Model.Services.IResponse httpRes, Emby.Server.Implementations.Services.RestPath restPath, System.String responseContentType, System.Threading.CancellationToken cancellationToken) [0x00168] in <35383502c6e541e18437747c81175cb9>:0
     at Emby.Server.Implementations.HttpServer.HttpListenerHost.RequestHandler (MediaBrowser.Model.Services.IRequest httpReq, System.ReadOnlyMemory`1[T] urlString, System.ReadOnlyMemory`1[T] localPath, System.Threading.CancellationToken cancellationToken) [0x00b48] in <35383502c6e541e18437747c81175cb9>:0
    Source: mscorlib
    TargetSite: Void Throw()
    InnerException: System.IO.IOException: Permission denied
    Source:
    TargetSite: 

 

 

Share this post


Link to post
Share on other sites
Luke

Hi, the server doesn't have permission to delete the files. If you can resolve this then the delete feature should work. Please let me know if this helps. Thanks.

Share this post


Link to post
Share on other sites
kumzrocks

Hi @@Luke I checked the permission it has read and write permission settings. I tried with options within emby server app there is no option to give permission to path.

Any idea how to give the permission? When I launched the server it asked the permission to read and write I gave permission.

As far Android 8.1 I don't have option to give permission unless the application is asking far. Like when I started FTP it asked for giving permission for write access for path but I didn't get any options from emby server

Share this post


Link to post
Share on other sites
Luke

That's not something you set within emby server, it's something you do on the Android device. The emby server application is what needs delete permissions.

Share this post


Link to post
Share on other sites
kumzrocks

@@Luke thanks for quick response. I was also sure it was in Android just couldn't figure out how to give the access to the storage there is no option in Android settings. Also I googled around if there is way nothing seems to work.

Share this post


Link to post
Share on other sites
Luke

@@softworkz may have some tips.

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...