Re: Installation directory for new applications



On 9 Feb 2007, in the Usenet newsgroup linux.redhat, in article
<1171021513.932770.161760@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>, kimi wrote:

I've looked through the manuals and not found the answer as well as
this newsgroup and found different answers. I'm new (day two) to Red
Hat version 2.4.18.4 (I believe - no access right now)

2.4.18.4 is a kernel version - from roughly four years ago, and
probably not the greatest thing to start with. To find out what version
of Red Hat you have, find a command prompt and enter the command

cat /etc/*release

which will give you the contents of a file - either /etc/redhat-release or
/etc/fedora-release - indentifying the release.

and want to install a few tools

For newbies, it's _generally_ better to stick with 'rpm' packages that
were built for your release until you gain some "which way is up" type
of experience. If you have experience in other forms of UNIX, this may
not apply. Bear in mind that there are over 300 different Linux
distributions, and a heck of a lot of different releases by those
distributors. Ignoring 'beta' releases, Red Hat has released at least
thirty different (and not very compatible) versions over the 12 years
they've been around.

and am not sure which directory to download the installation .gz to so
that it installs correctly.

Download it and build the software where ever you'd like. Many years
ago, a security auditor at our company recommended creating a separate
directory for building stuff, AND A SEPARATE USER who "owns" only this
directory tree. Thus, we have

[compton ~]$ grep builder /etc/passwd
builder:x:65523:65523:Software Building account:/usr/local/src:/bin/bash
[compton ~]$ grep builder /etc/group
builder:*:65523:builder

Those are not distribution or UNIX standard accounts. Neither user or
group accounts own ANY other files/directories. The user has permissions
of 'others' which is to say they can write to /tmp/ and /usr/tmp (other
than their home directory) and that is all.

Tarballs are unpacked in /usr/local/src/ then audited and built there. If
the software does not _require_ root permission to _run_ (for example,
it's not opening a network socket), then the software is test run from
the source directory by the 'builder' user, so that if something goes
horribly wrong, 'builder' is the only user effected. Only when things
are correct is root needed to _install_ the software so that regular
users can then run it. We've been using this method WITHOUT PROBLEMS
for over twenty years - yes, that predates Linux.

I think the best place would be /tmp but do not want it to run from /
tmp/x.

From the Linux 'Filesystem Hierarchy Standard' (http://www.pathname.com/fhs/)

----
/tmp : Temporary files

Purpose

The /tmp directory must be made available for programs that require
temporary files.

Programs must not assume that any files or directories in /tmp are
preserved between invocations of the program.
----

What is the best place to download and then install new applications
from?

The "best place" is what-ever works for you. What would be a good
place is something like '/usr/local/src/' or similar.

Old guy
.