Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a couple folders I'd like to set up on my network. The file server is Linux/Samba and the clients are all Windows machines.

Where is the best place on an Ubuntu file system to put these shared folders, like Applications (install exes), Books (pdfs, epubs), Videos, etc?

share|improve this question

4 Answers 4

up vote 4 down vote accepted

The general rule with linux is that if it's something that doesn't fit anywhere else, you should dump it in /srv/.

share|improve this answer
1  
[citation needed] –  Dennis Williamson Sep 19 '09 at 13:28
    
I agree, best place for random files served over network is /srv/ –  theotherreceive Sep 19 '09 at 13:35
2  
@Dennis '/srv contains site specific data that is served by this system'. Sounds pretty much exactly like what he's looking for. pathname.com/fhs/pub/… –  Cian Sep 19 '09 at 15:19
2  
/srv is a good choice for stuff you're serving, and this is true in the sense that if you're serving something that doesn't have a specific location already, like /var/www, then /srv makes sense. /srv is definitely not a 'miscellaneous' folder though! –  Lee B Sep 19 '09 at 16:10
1  
Well, I consider /var/www to be a legacy directory, since "user-controlled" data does not belong into /var. /var/www should be named /srv/www (or /srv/default-www or something similar). –  Sebastian Rittau Oct 14 '09 at 13:11

Take a look at http://en.wikipedia.org/wiki/Filesystem_Hierarchy_Standard, this explains how the directories are organized in Linux. User spesific files are stored under /home directory with seperate directories for each users.

share|improve this answer
1  
These files are not user-specific; they are shared by all users on the network –  rcampbell Sep 19 '09 at 13:31

For example: /home/shares.

share|improve this answer

The Filesystem Heirarchy Standard does not give clear guidance (at least to me) on placement of files under these circumstances. However, interpreting what it has to say about things in general that seem to also apply here, I would place such documents in one of the following places (in order of preference):

  1. /var/share
  2. /var/local/share
  3. /home/share
  4. /home/[department or category]/share
  5. /share

Consideration of ease of managing access rights should be given to how you plan to further subdivide the structure.

A couple of commenters have mentioned /srv and one could make the argument that your files could be placed under /srv/samba. However, I disagree if the files may be made available via other services or locally to the host system.

Granted, these are my interpretations and recommendations. If you want better guidance, you should consult the FHS mailing list.

share|improve this answer
    
FHS doesn't specify a /share, and /home is for actual system users home directories. /srv is specifically for 'data services provided by the system' –  theotherreceive Sep 19 '09 at 15:24
    
FHS doesn't preclude the use of local standards: "Local placement of local files is a local issue, so FHS does not attempt to usurp system administrators." –  Dennis Williamson Sep 19 '09 at 15:41
    
If you want to invent locations then that's fine, call it /mysambastuff, but the question asked about standards –  theotherreceive Sep 20 '09 at 0:23

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.