3

I am running 14.04 LTS. I've got a mount point called /files that is owned by root, the group is plugdev and I've given the group write permission. I used some of the information in https://help.ubuntu.com/community/InstallingANewHardDrive to set this up. Specifically the following commands:

sudo chgrp plugdev /files
sudo chmod g+w /files

All the users on the machine are also part of plugdev.

I've mounted a drive that has 1 ext4 partition to it.

At this point both user1 and user2 can create files/folders in /files. But, if user1 creates a file or folder in /files then user2 cannot modify it or create files in it.

I am wondering, how can I make it so all users can read/write (and, where applicable, execute) any/all files/folders created in /files regardless of who created it.

If it matters, /files is also a Samba share that is mounted on a Windows 7 machine.

1
  • I recommend downloading this free PDF: sourceforge.net/projects/linuxcommand/files/TLCL/13.07/… and reading Chapter 9: Permissions, particularly the section at the end on "Special Permissions". A combination of the setgid bit, the sticky bit, and a proper umask setting for your group members, should solve your situation.
    – Wildcard
    Oct 7, 2015 at 18:12

1 Answer 1

3

What you're trying to create is a "world-readable" mount... Not very secure, but if that's what you want, you should not only allow the group, but also the user and others to read and write. Ideally, you would also like to do that for the already existing files recursively

So change:

sudo chmod g+w /files

to:

sudo chmod --recursive ugo+rw /files

However: absolutely, positively don't come back here to whine and complain after one of the users deletes the entire directory structure of another user to make space to store his/her/its collection of pr0n.

;-)

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .