3

For files that I want to share with all users on a system is there a folder where by default they have read access? If I have to create one, is there a best practice location for it?

2 Answers2

1

Generally, the folder that is predefined for that use would be your public folder. It is sometimes, on some distros, even set up to be available via network request and is usually pretty unprotected permission wise unless you have encrypted your home folder if you want my personal advice, I would either create a new folder in / (root) or a new partition with gparted or another partition editor for that kind of use.

sbergeron
  • 2,660
  • Ahh okay, I'll create a folder in root (I guess there's no conventional place for this?). I was considering a folder where any user would know where to look on any Ubuntu system where they and other users can drop or at least grab files. Kind of like /Users/Shared in OS X. – Louis Waweru Jul 25 '15 at 02:29
  • well there is a shared folder for each account, that's the public folder, but I don't know if there is one that is communally available and not user specific. You could try simlinking all of those public folders to just one of them – sbergeron Jul 25 '15 at 02:32
  • Thanks. That doesn't sound like a good idea for this purpose of saving bandwidth on a large file. I just need it for one file so the folder idea works great for the documentation it'll go in. I just wanted to follow any best practices there may have been. – Louis Waweru Jul 25 '15 at 02:34
  • well if you have the folders symlinked then each one is still the public folder where people will know to find it, and there is no extra space usage as all the folders except one are just shortcuts – sbergeron Jul 25 '15 at 02:35
  • The main idea behind the question would be a location that an average linux user would know exists already. The public folder doesn't sound like a place user would look there for other users' files – Louis Waweru Jul 25 '15 at 02:37
  • yeah. they would probably look in public to put stuff there but not as though it was going to already be shared with everyone. If you create one giant folder in root called "share" in all caps or something it'll show up – sbergeron Jul 25 '15 at 02:38
  • better yet put in links in everyone's home folder to it – sbergeron Jul 25 '15 at 02:39
  • Too much work! :) (Imagine every time there's a new user) – Louis Waweru Jul 25 '15 at 02:40
  • lol you run a corporate employee account server or something? that would be fun :P – sbergeron Jul 25 '15 at 02:41
  • Haha, no. It's for a research lab with a few members, but lots of collaboration happens with people from all over. I'm also not sure if I'd find corporate too fun either :p – Louis Waweru Jul 25 '15 at 02:43
  • 1
    I thought a script file is executed to create a new user: in that you can have a symlink created for the new user to point to the public folder. Now everyone has the symlink to the public folder. – LDC3 Jul 25 '15 at 03:45
  • Please don't create a directory in the root file system, http://refspecs.linuxfoundation.org/FHS_3.0/fhs/index.html – mgor Jul 25 '15 at 07:48
1

On several systems around here, it's become a tradition for each user to create a folder named "public" in their own home folder.

I.e., my home directory is "/home/dc/", and I have a public folder at "/home/dc/public". That public folder and all the files in it is world-readable. Also, the world execute bit is set on the "/home/dc/" and "/home/dc/public/" folders to allow everyone to get a listing of all the files in the public folder and read all those files (but not change any of them).

In particular, when people on the local network use their favorite browser to view

http://pooh.local/~dc/

they get a listing of all the files in my "~/public" folder, and they can click on any of them to view or download it.

I hear rumors that people in distant lands use the names "public_html/" or "www/" for their public folder, or make a single "/home/public/" folder per machine that all users on that machine share.

Related: