Can't delete files created by Docker user

  • I know the answer to this is going to be something very simple, but I couldn't a clear way forward by googling it. I'm a bit reluctant to try a bunch of changes without knowing what I'm doing..


    I have a new install of OMV5. I set it up using the PDF guide, all good. I can access my shared folders from a windows PC. I can copy, move, delete files on the shares ok. I learned about Docker and Portainer as well. Part of that was setting up a dedicated user for Docker, I called that user Docker1. I've got SABNZB running in Portainer and used the Docker1 user when I set that up. It all works fine.

    When a download completes I can't delete the file from the shared folder. I get the error " File Access Denied - you require permission from unix user\docker1 "


    Can someone please point me the right direction?

  • In your docker container configuration try setting an environment variable UMASK=000

    --
    Google is your friend and Bob's your uncle!


    A backup strategy is worthless unless you have a verified to work by testing restore strategy.


    OMV AMD64 7.x on headless Chenbro NR12000 1U Intel Xeon CPU E3-1230 V2 @ 3.30GHz 32GB ECC RAM.


  • It only works for new files downloaded after you made the change and restarted the container. Have you done all that?


    Post the permissions on the file using this command in the shell:


    ls -al filename

    --
    Google is your friend and Bob's your uncle!


    A backup strategy is worthless unless you have a verified to work by testing restore strategy.


    OMV AMD64 7.x on headless Chenbro NR12000 1U Intel Xeon CPU E3-1230 V2 @ 3.30GHz 32GB ECC RAM.


  • It only works for new files downloaded after you made the change and restarted the container. Have you done all that?

    Yes. I deleted everything from my completed downloads folder using the CLI. In portainer I stopped the container, edited the stack and added the environment variable you suggested, saved the stack. The container is then up and running.

    I then downloaded a new file and could not delete it from the Windows share.



    ls -al filename

    Code
    ls -al 36d02fa1f9bc4be8a1c01970535517a4.mkv
    -rw-r--r--+ 1 docker1 users 528355946 May 31 00:21 36d02fa1f9bc4be8a1c01970535517a4.mkv
  • I found the answer. It was a setting in SABNZB. Folders / advanced. PERMISSIONS FOR COMPLETED DOWNLOADS. I changed the setting from nil (blank) to 777 and that's fixed it.


    Apologies for the false alarm. The error message made think it was a OMV folder or user permissions issue..

  • The UMASK=000 amounts to the same thing.

    --
    Google is your friend and Bob's your uncle!


    A backup strategy is worthless unless you have a verified to work by testing restore strategy.


    OMV AMD64 7.x on headless Chenbro NR12000 1U Intel Xeon CPU E3-1230 V2 @ 3.30GHz 32GB ECC RAM.


    • Offizieller Beitrag

    I found the answer. It was a setting in SABNZB. Folders / advanced. PERMISSIONS FOR COMPLETED DOWNLOADS. I changed the setting from nil (blank) to 777 and that's fixed it.


    Apologies for the false alarm. The error message made think it was a OMV folder or user permissions issue..

    I'm not a fan of 777, and would rather just set permissions properly.. but I guess if you're happy.

  • I'm not a fan of 777, and would rather just set permissions properly.. but I guess if you're happy.

    I'd be thankful for your further guidance. I guess its the execute part we want to leave out? I believe original permissions were 644, if i add group and public write permissions it should be 666?

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!