View Full Version : Linux in a nutshell
Somewhere around here, I've got a book called "Unix in a Nutshell"
http://www.oreilly.com/catalog/covers/unixnut3.s.gif
Reckon this will help me with Linux?
More, let's start talking about Linux, but keep it fairly simple at first. What I'm looking for is general information about what I can and can't do, what will or will not work and getting a feel for linux.
One of the things I need to do is download Jave for my linux box. How does the installation work? Is it all done from a command line or is there a run box like on windows?
How do the commands work on the command line and how do you get to the command line? Is it more of a DOS based command structure or is it more like Unix?
Chad
Chad...there's a whole raft of "How to install.." info here ("").
Lotsa weird stuff there, too:
Q: How to upgrade from Hoary Hedgehog to Breezy Badger (experimental)
[ 12-20-2005, 08:20 AM: Message edited by: Donn ]
imported_GregW
12-20-2005, 07:22 AM
Since you've istalled Ubuntu, I'll assume you are using the Gnome desktop.
Ubuntu uses what is called a "synaptic" package manager. A good thing to remember is that Unix/Linux software comes in packages, so being able to manage these packages comes in handy, the package management software for Gnome is pretty simple to use, all you really have to know is what software you need. Have a look at this link from Ubuntu's wiki How to install software (http://tinyurl.com/7zzqo) You may want to keep the URL to the Ubuntu wiki, it's really pretty good.
To get Java working on your machine go the Java website and get Linux package. They provide the install instructions as well.
You'll also want to install Flash media player, as well as w32codec, neiher one of these are essential but they'll enhance your browsing...or not. ;)
Just keep the wiki url handy, you'll find answers to most of your questions there.
Donn....good post, everything one needs is right there!
[ 12-20-2005, 05:50 PM: Message edited by: GregW ]
I will look at those links a little later. I installed Flash last night while I had it hooked up to the internet. I hope today to be able to download the Java stuff.
Come guys give me more entry level linux stuff, anything you can think of, even if it seems simple minded. ;)
Chad
brian.cunningham
12-20-2005, 03:20 PM
Originally posted by cs:
Somewhere around here, I've got a book called "Unix in a Nutshell"
http://www.oreilly.com/catalog/covers/unixnut3.s.gif
Reckon this will help me with Linux?
...I've been working with Unix/Linux for years, that's the 1st book I recommend people buying. It's great for looking up commands that apply to all Unix/Linux installations.
essaunders
12-20-2005, 03:22 PM
I concur. It's the first book I got once I started working for a living. It's also the first book I put my name on so that it wouldn't walk away...
Meerkat
12-20-2005, 03:37 PM
From the Gnome desktop, you get to a command prompt by starting up an XTerm.
You can also do alt-<function key> (usually for values F1-F8) to get to a virtual console. You'll have to log in, but then you have a pure Linux promt, not unlike a Dos prompt.
High C
12-20-2005, 04:35 PM
Originally posted by brian.cunningham:
....that's the 1st book I recommend people buying....Just ordered a copy. Thanks!
Meerkat
12-20-2005, 04:44 PM
"Linux Network Administrator's Guide" (often refered to as "the NAG") is also excellent.
It and the "nutshell" book are both part of the "Linux Bookshelf" CD that contains other titles as well.
Log is as me on the linux box, I can't create directorys in the root directory. What do I do to be able to create directorys?
Oh and Meer, I remember the shell from back way back when when we had a SCO/Unix server. You could use the alt +F1-12 to get to different log in screens. Didn'work here.
Chad
Meerkat
12-20-2005, 07:59 PM
Originally posted by cs:
Log is as me on the linux box, I can't create directorys in the root directory. What do I do to be able to create directorys?
Depending on the permission on "/", you probably have to be root (system adminstator) to create directories there.
I vaguely recall something about something you have to do to enable using alt-F1 through alt-F8 (almost never is it all the way up to F12 on Linux, at least by default) from within X.
However, you can fire up an XTerm (X Terminal) and have a fully functional command prompt (as constrained by your user permissions).
[ 12-20-2005, 09:00 PM: Message edited by: Meerkat ]
imported_GregW
12-20-2005, 08:03 PM
Chad,
To create a directory in anything other than your home directory you have to be "root"
In your case here is what you do:
Applications--System Tools--Root Terminal
You will prompted to enter a password.
You then navigate to where you want to create your directory the commmand to make a directory is: mkdir
[ 12-20-2005, 09:05 PM: Message edited by: GregW ]
Meerkat
12-20-2005, 08:04 PM
To become root without rebooting, you use the "su" (superuser) command. It will prompt you for a password and then start up a shell. Once you logout of that shell, you'll be returned to the user you were before.
Good information, after I take it back down and stow it in the corner for the night. :rolleyes: ;)
I tried to log in as root but it wouldn't take my password. This was trying to log in as root when logging in as a different user. BTW I looked for Xterm and couldn't find that command.
I found some commands on the web for basic stuff (ie change directories and making directories).
Will play some more tommorow and maybe this time I can bring home a hub that works so I can try duel systems through the dsl router.
Chad
John Bell
12-20-2005, 08:12 PM
I'm new to this also. Why would you want to make a new folder in root? It seems to me that you should only put your data in your user folders, and ignore that other stuff in root, etc, unless you want to tweak the system?
I'm getting ready to make one of my PC's a dual boot Windows/Ubuntu box. I'd be loading it right now except that I just figured out that I'm out of CD's to burn the ISO image!
Meerkat
12-20-2005, 08:15 PM
"XTerm does not appear as a command under desktop systems. It's usually an icon shaped like a shell, possibly with some additional decoration.
In the Unix world, a "command prompt" is called a "shell" or "shell prompt."
Meerkat
12-20-2005, 08:17 PM
John's correct. Normally a user's directories will go in his home directory. For example, if my user name is "user", my home directory is /home/user (or ~user as a shortcut) and if I wanted to create a new directory called "test", it would be /home/user/test.
BTW, "usr" (/usr) does not mean "user" - it stands for Unix System Resources and is more like the system and system32 directories in Windows.
[ 12-20-2005, 09:18 PM: Message edited by: Meerkat ]
I was looking at installing the java package I downloaded. It said to choose what directory you wanted to put it in, so I was going to the root directory and going to create a directory called java.
On second thought I probably need to be logged in as root to install jave system wide. But now to figure out why it wouldn't log me in as root.
Chad
Meerkat
12-20-2005, 08:37 PM
Originally posted by cs:
I was looking at installing the java package I downloaded. It said to choose what directory you wanted to put it in, so I was going to the root directory and going to create a directory called java.
Oy! this could get complicated.
Did you download a binary or a source package?
Whichever, software is epected to be installed, and found, in specific places.
Since Java is not part of the standard distro, it's binary (".exe" file) should be in /usr/local/bin, and it's libraries should be in /usr/local/lib.
Usually, often even with a binary package, there will be a make file (usually called "makefile") that one runs to get things installed were they're expected to be. It's usually run as "make install". This is true whether or not it's a binary or source package. The makefile has the necessary info to also compile the package if needed.
[ 12-20-2005, 09:38 PM: Message edited by: Meerkat ]
imported_GregW
12-20-2005, 09:05 PM
Just make things clear.
Since Chad is using Ubuntu I'll assume when he logs on he's in the Gnome GUI.
If this is so, all that he has to do if he needs to perform any root like functions, is get to the "Root Terminal" under system tools, type in the root password when prompted at which point he will have root priviledges.
Meerkat
12-20-2005, 09:36 PM
Chad;
Have a look at: http://java.sun.com/j2se/1.4.2/install-linux.html
Sun's instructions on installing Java on Linux.
Meerkat
12-20-2005, 09:39 PM
Also "Installing Java on Linux" (no quotes) brings up a wealth of links on the topic.
Paul G
12-20-2005, 10:36 PM
the root password is not set by default in Ubuntu
open a terminal
cd /wherever
sudo mkdir test
enter your password at the prompt
to make a directory called test
I was trying to log into root using the password I had set up on installation. I guess that password is the one I use for my login under chad. I'll try and log into root without a password.
The Java version I downloaded is at this link.
http://www.java.com:80/en/download/manual.jsp
I downloaded the Linux RPM self extracting version. Here are the instructions they post.
1. At the terminal: Type:
su
2. Enter the root password.
3. Change to the directory in which you want to install. Type:
cd <directory path name>
For example, to install the software in the /usr/java/ directory, Type:
cd /usr/java/
Note about root access: To install the JRE in a system-wide location such as /usr/local, you must login as the root user to gain the necessary permissions. If you do not have root access, install the JRE in your home directory or a subdirectory for which you have write permissions.
4. Change the permission of the file you downloaded to be executable. Type:
chmod a+x jre-1_5_0-linux-i586.bin
5. Verify that you have permission to execute the file. Type:
ls -l
I already see one mistake I was making, I was not logging in as a superuser.
Chad
Meerkat
12-21-2005, 11:25 AM
Any progress?
SuperUser == root you know?
[ 12-21-2005, 12:25 PM: Message edited by: Meerkat ]
Dave, this is a home project. As indicated in an earlier post I had already put it up last night. Tonight I should be able to spend some quality time with it.
I plan on borrowing one of our old hubs/routers tonight and see if I can make the dsl work that way.
Chad
Meerkat
12-21-2005, 11:37 AM
okie dokie smile.gif
John Bell
12-21-2005, 11:47 AM
I managed to get it Ubuntu installed last night on our old Celeron 533. It's dual boot with Win98 SE. The installation went without a hitch and it appears to run OK. It's actually seems a little slower than when running windows. I did do the Firefox tweaks and that helped a bit. I thought I had more RAM than I did and I suspect that's the bulk of my problem with speed. There's only 468 megs installed right now. I suspect another 512 DIMM would help quite a bit.
My initial impressions are that it's VERY different from what I'm used to. Thank goodness for the Ubuntu forums and Google, though. The good news is that Windows still runs normally, cuz if it didn't my wife would have my behind in a sling.
John, what I did was take an old system that was junked at work and turned it into a linux box. So when I get done with it I will have two systems at the house and if ever we get a laptop for the wife we will have three.
I mentioned to the wife last night that we might want to look at a wireless network. I first need to make sure that my dsl router will talk through a hub/router.
Chad
Just thought of this. What about the num lock? It is set to be on in the BIOS but when the machine boots and linux takes over it turns off.
Chad
Paul G
12-21-2005, 02:39 PM
Chad,
use sudo (SUperuser) to make admin changes
to set root password;
sudo passwd root
you will be asked for login password, then follow the prompt.
Your very best resource is the ubuntu forum. The friendliest, most helpful community out there. Use the search feature and check out the dozens of useful threads from people just like you.
Also try this resource;
http://www.ubuntuguide.org/
or
http://www.cs.cornell.edu/~djm/ubuntu/
I may one day visit a linux forum, but I seem to be getting good info here and I much rather talk with you guys here. Heck if I went over there and called them a bunch of geeks, they may get upset. ;)
Chad
John Bell
12-21-2005, 03:03 PM
I haven't had to post a thing. Just searching the previous messages (it actually WORKS over there) and you'll find the answer. For instance, I could not get my system to play my MP3's. A quick search and a cutting and pasting some apt-get mumbo jumbo in the terminal and sound miraculously appeared.
imported_GregW
12-21-2005, 05:15 PM
Just thought of this. What about the num lock? It is set to be on in the BIOS but when the machine boots and linux takes over it turns off. Easy! (ha) Num_lock (http://www.ubuntuguide.org/#numlockx)
You can do this easily by copying and pasting the instructions in a terminal window.
N.B Notice each command starts with "sudo".
Meerkat
12-21-2005, 05:23 PM
Originally posted by GregW:
N.B Notice each command starts with "sudo".Which, IIRC, means "super user do once".
If you're going to do several commands, it's easier to just "su" and log in as root/superuser. You can then skip the "sudo" at the beginning of each command.
John Bell
12-23-2005, 10:34 AM
I'm finally getting a lot more satisfied with Ubuntu. My biggest complaint was internet speed, or more correctly, Firefox's browsing speed. It turns out there are a bunch of tweaks that you need to do in Firefox's about:config file that really will pump up the volume. I've still got to figure out how to get it to play and stream windows media files, but that's about my only complaint.
What do I like about it?
- no spyware, viruses, or popups.
- multiple workspaces (there are four separate desktops that you can place applications.)
- can't mess it it up by indavertently deleting files (in GUI mode, anyway)
- apt-get install rocks!
- comes with a nice set of bundled free applications. Open Office has turned into a very complete package. Gimp is comparable to photoshop. PDF creation is easy.
- reads all my windows data with no problems.
Now to find an open source 3-CAD program...
John, sounds like you've got to play with more than me. I have to break it down and store it when not in use, at least until I find it a permanant home in the house.
Chad
imported_GregW
12-23-2005, 12:15 PM
John,
Stream Windows media files?
Go to Ubuntu How To's (http://www.majalah.com/#codecs) they have it all.
John Meachen
12-23-2005, 12:39 PM
Like Chad,I have an old system that ought to convert to a Linux box,450MHz processor 128meg RAM enough?The idea is to format the drive and install from cd.Any advice in English rather than gibberish would be gratefully received.
Meerkat
12-23-2005, 12:53 PM
Originally posted by John Meachen:
Like Chad,I have an old system that ought to convert to a Linux box,450MHz processor 128meg RAM enough?The idea is to format the drive and install from cd.Any advice in English rather than gibberish would be gratefully received.What kind of processor does it have?
John Meachen
12-23-2005, 01:28 PM
Its a Pentium 3.I have already seen a penguin on my monitor and a Slackware installation progress bar.Then an error message.I had hoped for an easy installation but am now wondering about what I might be letting myself in for.
Meerkat
12-23-2005, 01:29 PM
Originally posted by John Meachen:
Its a Pentium 3.I have already seen a penguin on my monitor and a Slackware installation progress bar.Then an error message.I had hoped for an easy installation but am now wondering about what I might be letting myself in for.Fun! ;) smile.gif
What is the error message?
Henning 4148
12-23-2005, 01:56 PM
John,
if you find that 3D CAD for Linux, please let me know ...
Henning 4148
12-23-2005, 01:58 PM
John II,
the RAM is a bit low for a current distribution
John Bell
12-23-2005, 02:04 PM
I'd probably do a dual boot no matter what.
For Ubuntu, I found this link to be extremely helpful for getting my dual boot system up and running: http://users.bigpond.net.au/hermanzone/
P.I. Stazzer-Newt
12-23-2005, 02:42 PM
Originally posted by John Meachen:
Its a Pentium 3.I have already seen a penguin on my monitor and a Slackware installation progress bar.Then an error message.I had hoped for an easy installation but am now wondering about what I might be letting myself in for.Man's right - fun. 450Mhz and 128Mb is a little light for the lastest distro's but would go well with RH 7.2 or similar.
I've got 512Mb of SDRAM sitting (unemployable) on the Kitchen Table - PM me an address and its yours for free.
John Meachen
12-23-2005, 03:10 PM
I have already begun to wonder what I'm letting myself in for.Having found that I had ISO versions of the installation disks,I had to reload Windows 98 and use ISOBuster to transfer the data to the C:\ drive.I suspect that I should have partitioned the drive before installing Windows.
The error message began "fatal server error" and spat out dozens of further lines at a speed too great to read.Thanks to John Bell for his link,I can see myself making great use of it.
Henning's remark about the memory requirement for current versions of Linux makes me wonder what happened to the original notion of a compact,stable OS.Fortunately,I think I can get hold of another memory chip but it might not be matched to the existing memory too well.
Meerkat
12-23-2005, 05:15 PM
Originally posted by John Meachen:
Henning's remark about the memory requirement for current versions of Linux makes me wonder what happened to the original notion of a compact,stable OS.Nothing really. There are Linux distributions that will run just fine in 32mb or less (as low as ~16mb). However, those are more oriented towards server and/or dedicated (embedded) applications. Add a heavy weight application like the Apache webserver or X-Windows and suddenly Linux needs a whole lot more ram to perform well.
I've got a BSD distribution that will store on a 16mb compact flash card (with room to spare) and it loads and runs on a 486-class "network utility" computer (Soekris 4501) and acts as a high quality firewall and router with a web-based control interface. It's called m0n0wall (0=zero, not capital letter O). Fun stuff.
BTW, if you like app-get (debian based distros), you'll LOVE gentoo linux' "portage" application. Derived from BSD's "ports" app.
chrisk
12-24-2005, 01:44 AM
Came in a little late on this thread. I've had a UNIX box on my work desk of every job I have had since 1981. Haven't used a Microsoft OS since DOS 3.3.
The su command really stands for "switch user" not superuser, allowing you to switch to any user that you happen to know the password for and get an interactive shell. If no username is specified it's assumed you want to switch user to the root user. This gives you access to special operating system calls and all files that no other user has access to. The BSD world requires you to be a member of the "wheel" group in order to be able to su to root. This gives the admin control over who can be root. The name "wheel" references the phrase "big wheel". If you are a "big wheel" then you can have root access.
The sudo command is similar, but rather then give you an interactive shell it just runs a single command for you. However, the sudo command has some restrictions on who can us the sudo command and what commands they can run with priviledges other then their own. This info is kept in the /etc/sudoers file. This allows the administrator to determine who can run which commands with what permissions. To see if you can run a command you can use the -l option to sudo:
$ sudo -l
Sorry, but calling the su comamnd the "super user" command is one of those pet peeves of mine so I had to speak up, couldn't help myself.
I am mostly from a BSD background. I worked for BSDi from 1994 until we got acquired by WindRiver in 2001 and they cancelled the BSD/OS product. I was the last person in the company to be assigned BSD/OS tasks which ended last year. I am now on the team working on the LINUX product. We make an embedded product. Our small end version was targeted to run in 8 MB of RAM. We had to apply special patches to the LINUX kernel to meet that target. Th epatch set is known as Linux-tiny. We also had a target of a filesystem of 4MB, after compression so we can boot from FLASH type devices. We used a package called busybox to make that happen. This product is aimed at cell phone type thingys. Nokia is a customer so you can expect your cell phones to be running LINUX shortly. I think there is actually already a cell phone manufacturer whose product is based off of LINUX just to give you an idea of how small footprint Linux can operate in.
Anyway, the su thing hit a nerve and I had to chime in, I don't usually post here.
Chris Kottaridis (chriskot@quietwind.net)
Meerkat
12-24-2005, 01:52 AM
Thanks for the contribution Chris - and don't be shy about posting! smile.gif
Thanks for the clarification on "su" and "sudo"! FWIW, I only recently discovered that "usr" wasn't a contraction of "user". ;)
You guys using the micro-C library too? I believe that m0n0wall is using that and busybox. Flash image size is about 5mb, based on freeBSD 4.10 or 4.11 (next version will be based on 6.0). http://www.m0n0.ch/wall/ if you're interested. They do a m0n0BSD too, but it hasn't been worked on in awhile AFAIK.
[ 12-24-2005, 02:55 AM: Message edited by: Meerkat ]
chrisk
12-24-2005, 02:16 AM
No, we didn't use uClibc. The engineering group wasn't very keen on it. You can either link the applications statically so you don't need the shared libraries on the target to save space or we have an option to use a program called libraryopt. The libraryopt program walks through all the applications and then rebuilds the libc and libm libraries to only contain the routines that the executables actually use. So the shared libraries on the target can be smaller.
However, the sales guys are totally enamored with uClibc it's what the customer's keep asking for. So, on our next version the customer can choose to use uClibc or glibc. Sales guys typically win over technical guys here. The company is more interested in making a buck then promoting the best technology. That's why BSD was dropped and Linux put in it's place. The customers want to buy Linux, even though it's more of a resource hog and slower by my experince this last year. Seems the older I get the less it bothers me to make the tradeoff of providing something people want to buy rather then the best technical answer. I guess I've decided I like getting paychecks over being technically "right".
Chris Kottaridis (chriskot@quietwind.net)
Meerkat
12-24-2005, 02:21 AM
Yeah, that eating thing definitely orders one's priorities... ;)
I'd be very interested in knowing more about that lib generator app. Is it open source?
Meerkat
12-24-2005, 02:30 AM
NM - found it on SourceForge. It's written in Python, one of my favorite languages! smile.gif
chrisk
12-24-2005, 02:44 AM
Libraryopt really didn't save us as much as we were hoping. That probably had something to do with engineering relenting on uClibc for the next release.
Chris Kottaridis (chriskot@quietwind.net)
John Meachen
12-24-2005, 03:46 AM
I'm taking a break from trying Linux.I have Ubuntu and Mandriva disks burnt from a Linux magazine cover disk and myDSL and BSD disks from downloads.In each case I have had to explode an ISO image because the computer will not boot from an ISO and in no case did an OS load.Although I have a moderate amount of experience with computers,it has nearly all been with Windows and a tiny bit of using OS/2.It would be nice to be able to just load a CD and to have an installation result.I suppose it is another demonstration of getting what you pay for.My alternative project for the Christmas break is a Rozinante half model,I should have no problem with that.
raycon
12-24-2005, 06:40 AM
John like others have said you may need to change the device boot order in your bios and possible enable load OS. Change the boot BIOS order to floppy,CD, hard drive.
P.I. Stazzer-Newt
12-24-2005, 01:27 PM
Here's one for Meerkat - from one of our travelling Linux gurus, his parting shot as he left for yet another trip to the gulf...
HAVE GNU WILL TRAVEL.
A small measure of sucess. I brought one of our old 10/100 hubs from work and hooked up everything to the network here in the office. Ran an internet speed test and noticted only 1 kb/s difference in speed on the network as oppossed to off the network. I still need to run a cat 5 under the house to where the linux box is set up, but at least I know it works.
Chad
Meerkat
12-29-2005, 05:37 PM
Perhaps you can use 5 cats to run the cat-5 under the house. Fish is a good bait for cats... ;)
P.I. Stazzer-Newt
12-30-2005, 09:16 AM
John Meachen check your PM.
John Meachen
12-30-2005, 09:37 AM
Thanks P.I.!Challenging things these computers.I am just beginning to fumble through the vagaries of Linux and am impressed with it's stability while being frustrated at the difficulty of navigating through a foreign GUI.It seems more than able to do anything I might need,if only I could tell it what to do.
P.I. Stazzer-Newt
12-30-2005, 09:49 AM
Linux/Unix is fun, there are few things in this life quite as satisfying as leaving a dedicated Apple evangelist to the tender mercies of the bash prompt.
There is so much to learn - and it keeps changing.
One of the guys in the office produced a test for a windows user who thinks he's ready for Linux;
Click Start/run and click the drop down.
If the list includes REGEDIT - its time for Linux.
imported_GregW
12-30-2005, 10:07 AM
One of the guys in the office produced a test for a windows user who thinks he's ready for Linux;
Click Start/run and click the drop down.
If the list includes REGEDIT - its time for Linux.:D
Powered by vBulletin® Version 4.1.12 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.