Filesystem Hierarchy Standard

learn more… | top users | synonyms

1
vote
2answers
50 views

Linux file hierarchy - what's the best location to store lockfiles?

I want to synchronize processes based on lock files (/ socket files). These files should only be removable by their creator user. There are plenty of choices: /dev/shm /var/lock /run/lock ...
-4
votes
1answer
70 views

Why nobody is using /opt directory? [duplicate]

In the Linux FHS, it says all third party packages should use /opt. However, I didn't see anybody is using /opt. Also, /opt is not in $PATH in anyway, so I think the OS is not intended to let us use ...
1
vote
1answer
80 views

Why is /bin a symbolic link to /usr/bin?

According to the Filesystem Hierarchy Standard the /bin directory should contain utilities needed in single user mode. In practice, many Linux distributions make the directory a symbolic link to ...
2
votes
1answer
38 views

Where should I install seafile-server: /opt or /home?

Reading Filesystem Hierarchy Standard I was considering those directories: /opt: Optional application software packages. /home: Users' home directories, containing saved files, personal settings, ...
2
votes
1answer
18 views

Which FHS dirs can I outsource and how?

At the moment I have a computer w/ Ubuntu on a HDD with everything on one partition. I'd like to add a SSD and move / to it, outsourcing /boot to a separate partition (on the SSD, too) and leave /home ...
3
votes
1answer
94 views

How should executables installed under /opt be added to the path?

Can programs installed under /opt be safely symlinked into /usr/local/bin, which is already in the PATH by default in Ubuntu and other Linux distros? Alternatively, is there some reason to create a ...
1
vote
1answer
38 views

What is “site specific” data?

I have heard references in the FHS to "site-specific" data. Python also has the notion of "site packages". In FHS, is "site" just a general term for an instance of someone using an FHS filesystem? ...
3
votes
2answers
55 views

How to split FHS read-only and read/write directories across two disks with Linux/systemd, without partitioning the raed/write disk?

My objective is to have the physical storage for the Linux FHS read/write directories (/home, /srv, /tmp, /var) on a separate (logical or physical) disk from the potentially read-only rest of the root ...
2
votes
2answers
74 views

Are there any sed scripts built in to mainstream Linux distros?

When I was studying bash, I found it very helpful to go and study the bash scripts already present on a clean install of Linux—/etc/profile, for instance, and anything in /etc/rc.d/init.d/. These are ...
9
votes
2answers
746 views

Is there a reason I would not add /usr/local/sbin, /usr/sbin, /sbin to my path on Debian?

Compare Debian (left) and Ubuntu (right): $ ifconfig $ ifconfig bash: ifconfig: command not found eth0 Link encap ... $ which ifconfig ...
10
votes
1answer
334 views

What is the meaning/purpose of *.pid files in /var/run

I'm quite new in Linux world, and now I'm trying to understand FHS principles. In /var/run I found about ten *.pid files like crond.pid which contains just pids. There is more than ten process ...
0
votes
0answers
33 views

Config folder for a service

Context When running the Deluge daemon (deluged) as a service, you can specify an option to where the config folder will be created. The deluge-user I've created, is a system account, and therefore ...
25
votes
5answers
887 views

What are the alternatives to the FHS?

Please don't crucify me for asking this question. :) I'm a long time Linux user for over 15 years but one thing I hate with a passion is the mandated directory structure. I don't like that /usr/bin ...
2
votes
2answers
46 views

Usability of /usr/share today

How is separating architecture dependent static data from architecture independent static data useful today? I imagine it could theoretically be useful in multi-architecture networks with a ...
0
votes
1answer
53 views

/usr/share/src?

Source code is text; text is architecture-independent data (i.e., /usr/shareable). Would it be, for some reason, a bad idea to have /usr/src/ link into /usr/share/src in a Linux distro?
0
votes
1answer
52 views

Does Linux have any symlinks by default? [closed]

I have written a program that performs health checks on servers. One of its functions is that it can check whether or not a symlink exists. I am currently in the process of writing unit tests (for use ...
1
vote
0answers
25 views

Moving to FHS 3: How to overwrite GNU Autotools directory variables?

In GNU Autotools, the directory variables $sharedstatedir and $localstatedir expand to $(prefix)/com and $(prefix)/var respectively. However the com and var directories don't exist anymore in FHS 3, ...
4
votes
1answer
111 views

Where to store shared data in FHS 3.0?

I'm working on a FHS2-conforming application that used to store data in $sharedstatedir (i.e. $(prefix)/com, e.g. /usr/local/com). This directory is no more in FHS 3.0, and it seems that we need to ...
0
votes
1answer
35 views

Installing JDK in a FHS-compliant way

I'm trying to install JDK on elementaryOS 0.3, but I'd like to do it in a FHS-compliant way. I've read a couple of answers about this topic, and a lot of them state that a program could be installed ...
1
vote
2answers
112 views

Where should Steam install game data on linux, to be FHS-compliant?

I want to create a folder on my linux system for Steam to download game data to. I am doing this so the data is shared between users, and games do not have to be downloaded multiple times. ...
0
votes
1answer
148 views

Difference between /opt/bin and /opt/X/bin directories

The /opt/ directory in Linux is used for installing add on packages. What is the difference between the /opt/<package>/bin directory and the /opt/<package>/X/bin directory? What is the ...
3
votes
2answers
918 views

Per user tmpfs directories

Using the shared /tmp directory is known to have lead to many security vulnerabilities when predictable filenames have been used. And randomly generated names aren't really nice looking. I am ...
1
vote
1answer
55 views

Where should generated scripts be placed in the filesystem?

I am writing a piece of software (C++) which generates Python scripts. Where should these temporarily existing scripts be placed in the file system? I read a couple pages about the Filesystem ...
7
votes
1answer
1k views

what is the distinction between /media, /mnt and /run/mount?

In FHS-2.3, we have /media that holds mount points for removable media such as CD-ROMs and we have /mnt that holds temporarily mounted filesystems. On the other hand, we have /run/media and ...
32
votes
9answers
4k views

What is the /boot partition really for?

I'm reading a relatively old text on Linux partitions and file systems (the LPIC 1 Certification Bible). It says: Some versions of the Linux boot loaders cannot access a kernel that is outside ...
1
vote
0answers
32 views

About the status of the File Hierarchy standard

In the question Where can I find the Official File Hierarchy Standard for UNIX? one writes: As with all things unix, it's less of a law and more of a guideline; how much of it is adhered to varies by ...
0
votes
2answers
491 views

Where to install mininet [duplicate]

I read some posts and parts of FHS to understand which directory I should install packages in. As far as I could understand /opt is for independent packages and /usr/local is for packages that are not ...
4
votes
2answers
366 views

Installing from source - do I need to keep the extracted tarball directory

If I'm installing from source, do I need to keep the extracted tarball directory? So if I download the git tarball. I then do: tar -xvzf git.tar.gz This will create a git.x.x. directory, into ...
1
vote
2answers
104 views

Hardcoded /usr/bin/env in configure scripts

I'm building a Linux system that doesn't have a /usr directory. Getting the toolchain to work was surprisingly easy, but I'm hitting this irritation with a lot of auto* scripts: configure, etc. often ...
3
votes
2answers
384 views

Why is “dir-or-file-in-usr-local” an error rather than a warning?

I'm building some rpm packages and checking for standards and style conformance using rpmlint. The packages are specific to systems at my place of work and they won't get pushed upstream. Our ...
1
vote
2answers
56 views

Installing a program in Linux via package

I'm trying to create a *.deb-Package to install a program I have written. It consists of three executables which hash to be in the same subdirectory. Example: .../myprogram/ | +- Program A ...
2
votes
2answers
365 views

How to add new elements to PATH for daemons (or other best practices)?

I want to add some scripts for custom administrative work to a Linux server (Ubuntu 12.04). Ultimately those scripts are callback scripts from at least one daemon (PostgreSQL in my case but that ...
21
votes
1answer
857 views

At what point did the /home directory appear?

Originally in Unix, /usr was used for user (home) directories. So if I had a user named alex, my home directory would be /usr/alex. (Interestingly, Plan 9, the successor to Unix, still has user ...
1
vote
2answers
570 views

Is file /etc/vfstab Solaris specific?

Is file /etc/vfstab Solaris specific. I mean it only exists in SunOS/Solaris and there is no such file in other UNIX-es/Linux/*BSD.
3
votes
2answers
92 views

Which directories are writeable in a system following FHS?

I need to ensure that, when deleting a specific user from a system, all of his/her files are removed. User creation/deletion will happen a lot on this system, so I want to reuse UID's and want to ...
26
votes
6answers
11k views

where is `cd` located? [duplicate]

In a bash sub shell I get the following error when running cd sudo: cd: command not found This is expected because I don't have a path. Usually to work around this I just provide the full path like ...
2
votes
3answers
900 views

Where to put wrapper scripts?

I created some scripts for administrative tasks etc, I made them to be independent from environment - every dependency is injected through arguments. However it is annoying to provide to script ...
3
votes
2answers
647 views

Logic behind Postgres binary installation path on Debian

It appears that the Postgresql installation is split into three folder locations on Debian: Configuration: /etc/postgresql Binaries: /usr/lib/postgresql Data: /var/lib/postgresql I ...
3
votes
4answers
443 views

Is the Filesystem Hierarchy Standard a UNIX standard or a GNU/Linux standard?

The Filesystem Hierarchy Standard says where to put stuff in a UNIX distribution. Is the FHS used/designed for use outside of GNU/Linux, or is it mostly limited to GNU/Linux?
4
votes
1answer
191 views

Why does System V traditionally symlink /bin to /usr/bin?

This systemd wiki page about the /usr merge, under Myth #6, states that /bin has traditionally been a symlink to /usr/bin on System V UNIX. What is the motivation for this? For backwards ...
1
vote
1answer
147 views

Where to drop libraries according Filesystem Hierarchy Standard

I do operate a Linux-based build system. The build system itself is based on Jenkins, Nexus, Maven, Ant and Shell scripting. Some projects need some special tools and libraries for building. ...
3
votes
2answers
141 views

Are there any discussions about proposing a new filesystem hierarchy standard?

Are there any current discussions about switch to a different standard directory hierarchy for Linux? The only thing I currently know of is GoboLinux, which looks quite outdated.
39
votes
8answers
2k views

What's the most appropriate directory where to place files shared between users?

Or: where can I put files belonging to a group? Suppose there are two users on a Unix system: joe and sarah. They are both members of the movies-enthusiast group. Where should I put their movie ...
13
votes
3answers
3k views

Is it bad/dangerous/inappropriate to put arbitrary backups in /var/backups?

There's a system-created /var/backups directory on Debian-based systems. I need a place to store backups of several git repositories (the primaries are on bitbucket). If I store them in ...
2
votes
0answers
270 views

Best location and permissions for socket files [duplicate]

I will have a couple of WSGI applications. They will communicate with nginx using sockets. For that purpose I've created the directory /run/wsgi in which I will place all the socket files that are ...
6
votes
2answers
1k views

FHS differences between OS X, Linux and FreeBSD

I've read that there is a different behavior between FreeBSD and Linux with the /usr/local, in FBSD ports are installed there, in Linux not, can someone explain more on this? I'd like to know where ...
3
votes
1answer
133 views

Where to securely place files needed by PHP in Linux filesystem (according to FHS)

I have a PHP script running on my LAMP server that requires certain files in order to produce HTML content. The script is publicly accessible (i.e. http://example.com/script.php) but the files ...
17
votes
2answers
6k views

Permissions/ownership of /usr/local/bin

From what I understand, the right place to put your own scripts is /usr/local/bin (for instance a script I use to back up some files). I notice that this folder is currently (by default) owned by ...
19
votes
2answers
8k views

Where should a local executable be placed?

I have an executable for the perforce version control client (p4). I can't place it in /opt/local because I don't have root privileges. Is there a standard location where it needs to be placed under ...
56
votes
4answers
19k views

What is the difference between /tmp and /var/tmp?

On most FHS systems, there is a /tmp folder as well as a /var/tmp folder. What is the functional difference between the two?