LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   how/where to install apps for all users (https://www.linuxquestions.org/questions/linux-newbie-8/how-where-to-install-apps-for-all-users-274577/)

slug420 01-06-2005 09:49 AM

how/where to install apps for all users
 
im running suse 9.1 pro if its relevant...

trying to find out how and where I should be installing programs so that they are available to all users. I am aware of the security concerns and how dangerous it is to login as root, but I usually do login as root for administrative tasks, so assuming I download the app as root, how should I install it (and where do you reccomend to install it) so that all users can access it.

Thanks

rjlee 01-06-2005 09:55 AM

I do not recommend downloading anything as root.
Download it as a regular user. In the case of source tarballs (.tar.gz files), compile the software as a regular user; you only need to be root to install it.

Tip: from a console, you can use the su command to switch to the root user account without needing to log out; you will still need the login password.

The /usr/local/bin/ directory is supposed to be used for executable files for all users. Generally, you need to set the install prefix to /usr/local/ for this location to be used; other files will then go into appropriate places, documentation in /usr/local/doc, data files in /usr/local/share and so on.

The /usr/local directory structure is similar to /usr (used for software that ships as a part of your distro) and /opt (a legacy location used for “optional” or additional software).

slug420 01-06-2005 10:11 AM

so a user's ability to run a program depends just on where it is located (in /usr/sbin) and not on who installed it?

rjlee 01-17-2005 01:57 PM

No, it depends on:

- the permissions of the mounted filesystem (if the filesystem has the noexec option set, nothing on that filesystem will run)

- the permissions and owner of the file. A file can be marked as executable for the owner user, the owning group, or everyone. By default, most packages set themselves to be run by everyone. (NB: scripts also have to be readable before they can be run)

- the permissions of the directory that the file is in. If a user cannot read the directory, then they can't run executables in that directory.

Security packages like sudo can be used to add more fine-grain tuning to who can use what.

shengchieh 01-17-2005 03:47 PM

You might be interested in

http://www.comptechdoc.org/os/linux/commands/
http://tldp.org/HOWTO/HighQuality-Apps-HOWTO/fhs.html

Then you can figure out where files should be.

Sheng-Chieh


All times are GMT -5. The time now is 05:55 PM.