Jump to content

File Structure


Guest adam13
 Share

Recommended Posts

Hello,

 

I've been using Linux for about two weeks. I have Mandrake 9.2 installed. This was installed by John, the "computer guy" at my father's work who was very excited that I was willing to give Linux a shot. Forgive me if I'm still thinking of things in a Windozy way.

 

My main question right now is about the file structure. Where should I install programs that I would have installed to "Program Files" on my old window's machine?

 

So far all I've installed are Thunderbird and Firefox. I downloaded both using root by going to their respective websites and downloading the "tar" files. I downloaded those installation files to /root . John said that when installing new software I should do so as root.

 

1.) Is there a place I should download compressed program files??

 

2.) I extracted the files to /usr/local. (So the program files are in /usr/local/firefox or usr/local/thunderbird) Is this the correct spot?

 

3.) Both programs work when logged in as root. Thunderbird also works when logged in as "adam", the user that John created for me. However Firefox (V1.07) won't seem to run. It starts to run and asks me if I want to create a new profile or use the default profile, but then it doesn't start. Any suggestions?

 

4.) Any general place I can look for information regarding file structure and how/where to download new software?

 

Thanks!

Link to comment
Share on other sites

Try to use files that end in "rpm" and are designed for you version of linux. While other types can be used, the rpm files will install in the proper places with the correct user permissions.

Second, use the program in the Mandrake Control Center for installing them. Linux installs files into the /usr directory or partition for use.

Link to comment
Share on other sites

I've read about these RPM files. It sounds like they usuall come packaged with your distibution. How do you go about finding RPM files the programs you want aren't already packaged?

 

The only Firefox file that I can find on the Mozilla website was firefox-1.0.7.installer.tar.gz . I don't know what type of file this is. It seemed to sort of extract and run without really installing it but that doesn't sound like the right way to go about it.

Link to comment
Share on other sites

If I can't find an RPM for a program for my distro of Linux then does that mean that I'm pretty much out of luck?

 

Does the fact that I didn't use an RPM method for installing Thunderbird mean that it may be unstable or flawed, even though it seems to be running so far?

Link to comment
Share on other sites

Tarballs (files ending in .tar or .gz) are just another way of packaging a program in linux. So they are programs, but may need adjustments depending upon the distro. Usually a "readme" file is found after unpacking that explains instalation variations. The rpm files are designed to install specifically in a specific distro. So, tarballs are more generic where rpm's are specific.

 

Either can work but one may require more customization. Either can have bugs due to the software, but not due to the package method.

Link to comment
Share on other sites

I extracted the files to /usr/local. (So the program files are in /usr/local/firefox or usr/local/thunderbird) Is this the correct spot?

That's a good place. /usr/local is more or less reserved for software that you do not install from a rpm package. Some people use /opt, but IMHO /usr/local makes better sense.

 

Does the fact that I didn't use an RPM method for installing Thunderbird mean that it may be unstable or flawed...

No, but you can avoid some of the problems you're having by using the preferred method for installing software on your system, in this case from rpm packages. Installing from tarballs (.targz, .tar.gz, which are often raw source code) isn't hard, but is best left for more experienced users. Stay with rpms until you really get the hang of Linux. Even then, it's still best to use rpms when possible.

Hint: best to uninstall Firefox and Thunderbird per their directions (I think that's simply deleting the respective directories in /usr/local, but check) before installing them again from rpms. Also, in your case I'd delete the /.mozilla, /.fullcircle and /.thunderbird directories in your /home directory. Not to worry, they'll be recreated fresh when you reinstall Firefox and Thunderbird, but of course you will lose any info there.

 

As for your other questions, well, this looks like a good time to again post my standard Software Installation Guide for n00bs. No offense, everyone here was a n00b once. It should answer most of your questions and get you on your way. Once your get the hang of it, installing software in Linux is actually slicker and easier than in Windoze. It's just different.

 

Here it is - hope it helps, and feel free to post back here with more questions:

 

**Basic urpmi setup and usage**

 

Urpmi will easily and automagically take care of finding, downloading and installing software and its dependencies, if any. The "Software Management" utility in Mandrake/Mandriva Control Center is a simple to use GUI frontend for urpmi (think of it as roughly the equivilent to "Add/Remove Software" in Windows Control Center). But it's also very easy and more powerful to use urpmi from the command line.

 

You can, of course, just use the CDs and install software from those. But to best use either the GUI installer or to use urpmi manually, if you have a broadband connection you should set up online sources for downloading/installing/updating software. To do that you need to know how to 'su' to root, which is very simple. Just open a terminal (konsole, xterm, aterm, whatever) which will show a '$' prompt character and do this:

 

$ su (hit enter)

Password: <type.your.root.password> (hit enter)

#

 

Note that the cursor changed from '$' to '#' indicating you now have 'root' administrator rights, so be careful! This is similar to the difference between 'user' and 'administrator' rights in Win2k/XP. If you don't fully understand the 'su' process or root permissions some simple Googling will explain it.

 

Now to setup your online software sources. Go here:

 

http://easyurpmi.zarb.org/

 

There's also a handy link to that site in the upper right of any page of this forum. Follow the directions to setup your online package sources. Choose them carefully, staying with sources for your particular version of Mandrake/Mandriva. You'll want to add the main sources for your version, the updates, Contrib, PLF free and non-free, and maybe some others like the Seer of Souls rpms.

Warning!: Add the Cooker sources at your own risk. Cooker is beta stuff still in testing for the next release and may or may not cause you problems.

When you've finished setting up your source mirrors you can start using the real power of urpmi. You can now install/uninstall a package using your newly-setup online sources either by using the GUI installer in Mandrake/Mandriva Control Center, or better, by manually installing with urpmi from the command line.

 

To install manually open a terminal, 'su' to root, then type:

 

# urpmi -v <packagename> ('-v' for verbose output is optional, but I like the extra info it provides)

 

Note that usually <packagename> can be just the 'simple' version. Using the text email client Mutt for an example, instead of typing the full package name:

 

# urpmi -v mutt-1.5.9i-8mdk.i586.rpm

 

Use:

 

# urpmi -v mutt

 

That's it - that's all you have to do do install! With that simple command urpmi will automagically go to the 'Net sources you choose, find and download the latest available Mutt rpm for your version of Mandrake/Mandriva, grab any other packages needed to resolve all dependencies and install everything in the correct order. If urpmi can't complete the installation, either because all the required software isn't available on the source mirrors you choose or possibly some other conflict(s), it will stop the install process before actual changes are made and give you some info about the problem.

 

Similarly, for packages you've downloaded and saved, just use the 'cd' command to navigate to the directory where you saved them:

 

# cd /mysaved/rpm/is.here

 

Then (for this, you may need to use the full packagename):

# urpmi -v <packagename>

 

Uninstalling a package is simply 'urpme' instead of 'urpmi'.

 

Be aware that while using rpms compiled for other versions of Mandrake/Mandriva or for other distros sometimes will work fine, they may not and the possibility for problems exists. Think of this as similar to installing Windows software where installing something on Win98 but meant for XP (or vice-versa) may not work. The software should be compiled for use with the distro and version it's installed on. So always try to use correct rpms for your distro and version whenever possible, which in the case of Mandrake/Mandriva is almost always. If you must use a rpm from another version or distro, it may or may not work.

 

But unlike Windows, Linux and urpmi allows you to first do a 'test' installation instead of having to just try installing and see what happens. To do a test install, do this:

 

# urpmi -v --test <packagename>

 

This does a 'dry run' to check if the package(s) can be sucessfully installed but without actually changing anything on the system. If all is well, remove the '--test' switch to install normally.

 

It's important to always install rpms when possible, not from tarballs, when using any rpm-based distro like RedHat, Suse or Mandriva, at least until you have a good understanding of just what you're doing. This is also true of '.deb' package based distros such as Debian or Ubuntu.

Why? Because if you always install rpms (or .debs), then Mandriva's urpmi (or Suse's YAST, Debian's apt or whatever package manager) is able to properly keep track of everything installed on your system and so keep everything correctly configured and updated and avoid conficts. But if you install any packages from source tarballs no information about that package or the files it installed are entered into the urpmi database. You then have a situation where urpmi may not properly keep things straight since it has no info about the installed tarballs or their contents. The chances of installing from tarballs breaking anything is fairly slight, but it can happen, so why risk it if you don't have to? Also, software installed from a rpm package is usually easier to uninstall than that installed from a tarball.

 

Sometimes a particular piece or a newer version of software may only be available as a source tarball. No problem - it's very easy make your own rpms from source tarballs with a handy utility called checkinstall, included on the Mandriva CDs. In a nutshell, checkinstall makes a simple .rpm package by replacing the traditional compile and install commands:

 

./configure

make

make install

 

With:

 

./configure

make

checkinstall

 

I won't go into more detail about checkinstall here. Google for more info about it or install the checkinstall package and type 'man checkinstall' in a terminal.

 

This should be enough to get you going. For more info, open a terminal and type 'man urpmi" or do some Googling, particularly 'easy urpmi'. Lotsa info available.

Edited by Crashdamage
Link to comment
Share on other sites

Follow Crashdamage's advice: use EasyUrpmi.

...

But if you want to know more, or try some program that is not available with urpmi, then my article might interest you:

http://yves.gablin.club.fr/pc/linux.php?ar...oftware/install

 

However, always try with urpmi first!

 

Yves.

Link to comment
Share on other sites

Wow,

 

Thanks for all of the great info Crash. I've poked around the MCC and the URPMI website, but I just didn't understand what I was supposed to do.

 

I was feeling pretty beat up last night, but armed with this new information I think I'm ready to have at it!!

 

I could probably tag this one solved but I think I'll wait a little bit and see if I'm successful first.

 

Thanks!

Link to comment
Share on other sites

One more thing the version you are using is really old and is not even supported anymore. The time it was created Firefox probably didn't exist. 9.2 used Mozilla as default browser. I mean that you likely won't find Firefox with urpmi unless you find some unofficial repository.

Lot of things chaged since 9.2 times like the distro's name. The new name is Mandriva. The latest release is Mandriva Linux 2006, it would be 11.0 if they'd still use version numbers I think.

Link to comment
Share on other sites

Just about all programs are converted to RPM install form so forget about installing tarball versions until you gain more advanced experience. This applies to Firefox as an example :- within a day or two of Mozilla releasing an up dated version of Firefox, someone within Mandriva constructs the RPM install version of it and it appears within hours on the Mandriva mirror sites. Mandriva does not use the same version number for the rpm form as Mozilla use for their version number but when you install the rpm version and click on the Firefox -----> Help -----> About Firefox you will see the original Firefox version number and you can see therefore if it is the latest version.

Installing software via urpmi installing rpms is even easier than installing software in Windows, in my opinion, and it doesn't require reboots.

Descriptions for setting up urpmi by using easy-urpmi are long winded but necessary, yet the actual doing it is really quite simple and fairly quick.

 

Installing by other means than RPM does NOT make their install more unstable or unreliable. The Install method makes no difference to these two factors. Lack of proper knowledge as to correctly installing tarballs may result in you not being able to use the application or know where to find it to use it and so on but that is all.

 

Cheers. John.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...