3

I originally posted this question over on AskUbuntu but it didn't get any traction so I'll ask here.

In ubuntu or linux in general is there a "correct" location to install services that you download from the internet and want to run. I would like to have services such as redis or ventrilo auto run but to me it doesn't make sense to put them in the ~/redis or ~/ventrilo directories since they aren't user specific.

Keep in mind that I'm relatively new to the linux world having been a .Net developer for about 4 years now.

1 Answers1

4

So according to the Filesystem Hierarchy Standard software manually installed should be placed into /usr/local/, see man hier for more details.

In the *nix world, services are called daemons and they're typically controlled by init scripts. Software installed using your distro's package manager (apt, yum, pacman) should have init scripts included. Your system's init scripts can be found in /etc/init.d/. If you're compiling/installing software manually, you may have to write your own init script. If thats the case, there's a template in /etc/init.d/skeleton

Creek
  • 5,062
  • 1
    +1 BUT: Most linux distros don't use SysV style init (/etc/init.d) anymore, and even fewer will in the future. While the init systems they do use (predominantly, systemd) are usually compatible with scripts placed in /etc/init.d, for the most part standard system daemons are not "controlled by init scripts" -- they're controlled by init, and started via whatever configuration method is used by the particular init system. I.e., most of them do not have scripts in /etc/init.d on most distros (notable exceptions being Debian and CentOS, but both of those are moving to systemd). – goldilocks May 30 '14 at 16:51
  • https://unix.stackexchange.com/a/480897/5132 /etc/init.d/skeleton is no more. – JdeBP Nov 10 '18 at 04:55