Tag Archives: GNU/Linux

She sells seashells by the seashore. Well, yes… that may be true, but that’s not the type of shell we’re going to talk about here today.

I’m going to talk a bit about the Linux shell. What is the Linux shell? What does it do? How can I interact with it on my GNU/Linux operating system? Those are all good questions. While today’s most popular distributions of GNU/Linux are morphing into operating systems that are more and more graphic user interface oriented, the real power of Linux still resides in the command line.

When you boot up your Ubuntu or Mandriva GNU/Linux operating systems, most of you see a graphical login screen. Others, like myself, might see a non-graphic command line login. Both do basically the same thing. They log the user into the Linux shell so that he may begin to utilize his system’s potential to perform tasks. That’s what we do with our computers, regardless of what the tasks happen to be… emailing pics to auntie Myrtle or hacking cloud and cluster security systems.

The Linux shell is the interface between you in that seat in front of your monitor and the operating system that controls the hardware in that box under the desk that does the actual stuff you want done. There are numerous shells in Linux; the most commonly used one is called BASH – Bourne Again Shell. You’re in the shell anytime you’re logged into your GNU/Linux operating system; whether you’re interacting with it graphically or from the command line.

Graphic User Interfaces or GUIs are just “front ends” to applications that are running in the shell. I’ll be talking mostly about the non-graphical command line interface here today, though. You can access your command line interface from within your GUI by using the graphic front end application for the command line provided by your desktop environment. For example, in Gnome, you could use Gnome Terminal; or in KDE, you could use Konsole. Either way, these are both just graphical front ends for the BASH shell command line.

When you first login, you’ll get what’s known as a prompt. It is just a blank line waiting for your input (commands). It’ll look something like this:

joe@mysystem:~$

The first part, “joe”, is just the user’s login name. “@mysystem” is the name of the computer the user is logged into. The “~” character tells us that user Joe is working from his home directory. The “$” character is the standard character denoting a non-root, regular user.

Let’s say Joe wants to list all the files in his home directory. All he has to do is type:

joe@mysystem:~$ ls

This command, known as “list”, tells the shell that user Joe wants to see a list of all the contents of his home directory. The shell immediately responds after Joe hits the Return (Enter) key on his keyboard with this output:

It looks like Joe has five regular directories, a Dropbox directory, and the directory that contains his desktop icons. In reality, there are more directories and files in Joe’s home directory, but they’re what are known as “hidden” files. Their names are usually preceded by a .(period) to make them hidden. If joe wants to see all his directories and files he can list them this way:

joe@mysystem:~$ ls -a

The “-a” option means all. The list command will list all items in a directory when using the -a option. Joe’s list now looks something like this:

The above directories are hidden by the preceding .(period), as mentioned above.

Let’s say Joe want’s to create a grocery list for his afternoon shopping chores. He can do this via the shell and command line also by using a command line editor such as vim. He would first do this by bring up the vim application in the command line interface:

joe@mysystem:~$ vim groceries

This command would initiate the vim application using a new file called “groceries”. Vim or Vi-Improved, as it’s known, is a non-graphical text editing application. It would look something like this to Joe:

lettuce

tomatoes

catfood

peanut butter

eggs

milk

bread

~

~

~

–INSERT– 10,1 All

Once Joe had finished typing out his grocery list, he would save it using the vim command :wq, which would also close the vim application and bring Joe back to the command line prompt. He could also print his list from the command line like this:

joe@mysystem:~$ lpr groceries

The lpr command would tell the shell that Joe wants to output the contents of the groceries file to the printer. The printer would receive the data and the command to print from the computer’s hardware and begin printing Joe’s grocery list.

All of this we’ve talked about today doesn’t even scratch the surface of the power at your finger tips when using the Linux shell. Your first step should be to read the Linux manual page for the BASH shell. There is some very useful information in that document. Stay tuned here… I’ll come up with some other lessons in the future. Remember what I always say…

I recently did some soul searching regarding my GNU/Linux philosophy. I found that I wasn’t being true to myself.

For years now, I’ve run Slackware Linux as my primary operating system and a second, fully updated version of Debian as my secondary OS. I’m a firm believer in simplicity and stability. I enjoyed both of those qualities in Slack and Deb, of course. They are both rocks when it comes to stability. I’ve never had a crash in either operating system that was due to the OS itself. Any crashes were usually caused by something stupid that I had done.

All that being said, while contemplating upgrading from Debian Lenny to Squeeze, I had an epiphany. Slackware and Debian are not very much alike, other than their common quality of stability. Where Slack has a relatively small application set; Debian’s repos are huge. Where Slack uses close to the newest versions of its software; Debian uses versions that are typically three to four releases old (VERY stable and proven stuff).

It was always difficult for me to sync Slack’s apps with Debian’s in my primary and secondary operating systems because of the discrepancy in releases; especially so with Mozilla apps like FF and TB. This got me thinking… maybe Debian, even though it had always been my fall-back operating system, might not be serving my purposes that well after all. Is there something better out there for what I want to do?

As most of you know, I have five tester slots on a dedicated drive just for trying out and learning other distributions of GNU/Linux. No, I don’t do virtual. I like to REALLY install and set up operating systems. Virtual computing is like virtual sex. It works, but it’s not nearly as much fun (or as messy). In one of my tester slots there is almost always an installation of Arch Linux. Why Arch? Well, it’s a cool distribution. That’s why.

Seriously, Arch is a very stable, very robust distribution of GNU/Linux. It’s been around about ten years now. It’s a fork of the old Crux branch of the Linux Tree. I started playing around with Arch about three years ago, I think. I was impressed right off the bat. One of the greatest things about Arch is its outstanding support community, particularly the wiki. There is an abundance of information for Arch users of all sizes and shapes. Support is a good thing!

As a result of all this deep thinking and philosophizing, I decided to install Arch as my official secondary operating system. I spent the past three days installing and setting it up. I’m using it now to post this article. I have everything set up to closely match my Slackware installation. I keep both sync’d (manually) and updated. If my Slack craps out, I can always boot Arch and seamlessly carry on until I fix my Slack. Odds of Slack crapping out? Null. You never know, though.

The GNU/Linux computer operating system created through the sewing of miscellaneous Richard Stallman body parts around Linus Torvalds‘ heart is not perfect. Here’s a list of my 5 top pet peeves:

coming in at #5 is the fact that using the GNU/Linux operating system causes me great distress due to the guilt of not having paid $300+ to purchase this operating system in a very earth-unfriendly, made-in-China package from my local Bloat Buy retail software outlet.

#4 would, of course, be the pain caused by my empathetic tendencies toward those poor souls out there using other operating systems, and my terrible evangelistic need to convert them all. I’m becoming a damned Jehovah’s Witness of GNU/Linux… *Knock-Knock* “Hello, ma’am. I’d like to talk with you a bit today about the everlasting joy of Linux. Come to the light with me, won’t you? Yes, you can bring your cat, too.”

3rd on the list is the fact that GNU/Linux does not follow the engineered obsolescence business plan that has kept free markets and manufacturing buzzing for the past 50 years. It is instead a steady, long-life item that will eventually put many folks out of work. Besides, the best distributions are given away for no cost at all. What’s up with this? This is NOT your granddad’sCapitalism, comrades.

my 2nd most peeving peeve is the gnawing certainty that the GNU/Linux was actually a technology that the C.I.A. leaked after discovering its usage in the computers on that crashed alien craft that’s kept in storage in Area 51. No current human intellect could have come up with something so efficient and useful. I think the aliens may have assimilated us without our knowledge or consent. Maybe that’s a good thing, upon further reflection.

and first/foremost on my list is the fact that GNU/Linux has increased my boredom exponentially over the last 5 years. I no longer have to run crap cleaners, antivirus apps, defraggers, malware hunters, cookie cullers, bloated/inefficient backup apps, etc. Sheeesh! I have all this time on my hands to do really useful computer stuff nowadays. So, what do I do? I choose to sit here and tap out masterpieces such as this one for your entertainment and enlightenment.

Here’s what I like. They’re all good. However, like anyone, I have my personal favorites. Here goes…

My Top Five GNU/Linux Operating Systems and Why

Slackware Linux – To me, Slackware just fits. Folks have heard me say for years now that Slackware is the only Linux operating system that comes pre-packaged with ATTITUDE. It’s a biker’s Linux. It’s not all-inclusive. It’s not warm and fuzzy. It’s not even user friendly, at times. When you kick that baby over, though, it RUNS… and it runs hard and long. Slackware is the oldest surviving still maintained Linux. Its age grants it bragging rights. It is a survivor.

Debian – Debian is old; not as old as Slack, but close. It’s also “old school”, kinda’ like me. It’s there when you need it. It’s nothing fancy, really. It’s the Sears Craftsman of Linux operating systems; dependable, steady, and ROCK-FRIGGIN’ SOLID. I use Debian on my desktop machine as a secondary operating system. It’s fully operable and synch’d with my Slackware primary OS. No better fall back can be had.

Arch Linux – While I’m not nearly as experienced with Arch as I am with Slack and Deb, I still have had some experience with it. I’m MOST impressed with Arch’s Support Community. I capitalize those words because in Arch’s case, they deserve to be capitalized. Most GNU/Linux operating systems out there have extensive and informative support apparati; Arch’s is superior. Their wiki is the best I’ve ever run across.

Zenwalk – Zen’s parent is Slackware. Because of this, Zen has all the stability and reliability of its parent with a more mellow attitude. It’s a bit lighter than Slackware; as if Slack were anywhere near being called “bloated”. I ran Zen many times on my systems. I don’t currently have it installed because Zen doesn’t yet have an x86_64 architecture. I’m patiently waiting, though.

CentOS – I installed Cent because I had already run Fedora Core and was looking to get as close to RedHat as possible without having to spend money to do so. CentOS is the answer. It’s as close as you’ll get to RedHat without the monetary outlay. It’s sharp, clean, stable, and very usable as a primary operating system. For you RPM fans, this might be a good choice.

Those are my five most loved GNU/Linux operating systems. However, I really love them all (with a couple exceptions that we won’t go into here); and with that in mind, here’s an honorable mention list (in no particular order):

Ubuntu – Why? Because this is the one that got it all started for me. I had an old stack of Mandrake floppies that someone had given me years ago, but I had never installed them on anything. Ubuntu was the first Linux I ever installed. It took away my Linux virginity and stole me from MS Windows all in one shot.

Ark Linux – Ark is a main line (not a branch) Linux operating system. It’s been around for quite some time. While development is sometimes a bit slow in coming, Ark is still alive and well, as I was recently updated by one of their beta-testers, the Borg_Queen. Ark is a good, solid Linux.

Vector – An impressive Slack baby. Stable and very usable. Needs an x86_64 version, though

Xfce – the little mouse that roared. I run Gnome here and KDE there, but Xfce is my absolute favorite of them all. It’s not near as polished (read as bloated) as KDE nor as user-friendly as Gnome, but it works. And for me, it works well. I love that little mouse.

Next week, 10 things I love about MS Windows. HA! Just kidding. Had you going there for a bit, though.