Where should I install binaries that don't come as .deb?

1

I'm going to run EC2 instance for dev purposes on AWS. Most likely Ubuntu (once had it on my laptop). I am Java developer, so I need JDK, Tomcat, Maven, Git and MongoDB on the server. But software in repos is too old (MongoDB in ubuntu repos is 2.0.x version, when I need 2.2.x). So, I'm going to download zipped binaries and use them.

Where do I install software which is not packed with .deb? Should I install it to /home/user/, or maybe to /opt as Chrome does?

madhead

Posted 2012-12-26T09:21:48.077

Reputation: 484

Of course, thank you. Just wait for another opinions, but documentation cite is enough! – madhead – 2012-12-26T21:15:30.410

Answers

3

Sometimes I make a ~/Installed directory. According to Geek Stuff, /opt is for software vendor add-ons. /usr/local appears to be the "most proper" directory to place manually installed source code, binaries and so on.

Update: TLDP says

The original idea behind '/usr/local' was to have a separate ('local') '/usr' directory on every machine besides '/usr', which might be just mounted read-only from somewhere else. It copies the structure of '/usr'. These days, '/usr/local' is widely regarded as a good place in which to keep self-compiled or third-party programs. The /usr/local hierarchy is for use by the system administrator when installing software locally. It needs to be safe from being overwritten when the system software is updated. It may be used for programs and data that are shareable amongst a group of hosts, but not found in /usr. Locally installed software must be placed within /usr/local rather than /usr unless it is being installed to replace or upgrade software in /usr.

0x90

Posted 2012-12-26T09:21:48.077

Reputation: 267

1

You can install it where you want. Personally, I would recommend /opt which seems made for manually installed programs. Let ~ for your personal data and /usr/share/ for Linux programs. But you are free to put it where you want.

air-dex

Posted 2012-12-26T09:21:48.077

Reputation: 195