how to add permissions with samba

Posted on

A server stack is the collection of software that forms the operational infrastructure on a given machine. In a computing context, a stack is an ordered pile. A server stack is one type of solution stack — an ordered selection of software that makes it possible to complete a particular task. Like in this post about how to add permissions with samba was one problem in server stack that need for a solution. Below are some tips in manage your windows server when you find problem about windows, ubuntu, samba, , .

i have a samba file server on ubuntu server for my windows pc and when i try to write on the shared drive it says that i need permission to do that. i have done this:

sudo chown nobody:nogroup /var/www/html

and my smb.conf is:

    comment = Ubuntu File Server Share
    path = /var/www/html
    browsable = yes
    guest ok = yes
    read only = no
    create mask = 0755

i have another shared folder and that one is working fine with the same .conf
please can somebody tell me how to give myself permissions. thanks

Your connection probably doesn’t run as the user you think it does.

  • You can try to find out as with user samba runs that connection. Run

    chmod 1777 /var/www/html

    Then you should be able to create a file in that directory. It will have the user and group of the Samba process for this connection.

    Change the permissions back after that.

  • You can change the user and group of the Samba process with these lines in smb.conf

    force user = nobody
    force group = nogroup

Leave a Reply

Your email address will not be published. Required fields are marked *