Why Learn the Unix/Linux Command Line and Shells?

Ian! D. Allen – www.idallen.com

Fall 2017 - September to December 2017 - Updated 2019-03-01 02:59 EST

1 What is Linux and why do I care?Indexup to index

Linux is an Operating System. Other examples of Operating Systems are the Android O/S that runs your phone (a Linux derivative), Microsoft Windows, and Apple OSX.

The job of an Operating System is to manage the computer hardware so that multiple programs can use it. Examples of hardware that needs managing include memory, CPU, and peripherals. You don’t want one program to cause another program to crash, and you want to share memory among several programs at the same time.

The Linux operating system and its derivatives are found in very high-profile places such as Android phones, Google, Facebook, and the New York Stock Exhange. If you want to work with leading-edge technology, you need to know how to work with Linux.

2 GNU – Gnu’s Not UnixIndexup to index

GNU stands for “Gnu’s Not Unix”, a modern rewrite of the Unix operating system and utilities from the 1970s.

2.1 A Linux “distribution” is a Linux Kernel bundled with GNU UtilitiesIndexup to index

You will hear people talk about “Linux distributions”, which are packaged versions of the central Linux O/S kernel bundled and tested to work with with compatible utilities.

3 Linux is EverywhereIndexup to index

4 Linux and Open Source Job MarketIndexup to index

http://www.cio.com/article/739097/Open_Source_Career_Opportunities_Continue_to_Abound

Regardless of the health of the overall IT job market, open source is one area of the tech market that’s always growing. In addition to traditional areas such as scripting languages and server operating systems, mobile app development, the cloud and big data offer new open source opportunities.

http://www.infoworld.com/t/information-technology-careers/the-open-source-job-market-booming-223463
The many job openings being advertised at OSCON make the convention floor look more like a job fair.
http://www.linux.com/news/featured-blogs/185-jennifer-cloer/720243-samsung-talks-about-its-aggressive-linux-talent-recruitment-strategy
I recently spoke to Samsung’s Ibrahim Haddad who is the head of the company’s Open Source Group in Silicon Valley. He is leading efforts to find the best Linux and open source sofware talent to help Samsung maintain its market position and shares with us why this is a priority for the company, how they’re finding this talent and what they’re doing to attract and retain open source developers.
http://www.linuxfoundation.org/publications/linux-foundation/2013-linux-jobs-report
Tech is in, but nowhere is the opportunity for career advancement and big financial reward more evident than in the Linux jobs market where salaries for skilled Linux talent are rising at nearly double the rate of other tech professionals.
http://www.pcworld.com/article/2011376/good-news-for-job-hunters-in-android-linux-and-open-source.html
Good news for job hunters in Android, Linux, and open source: “the most important thing they have in common is that they each require a fundamental understanding of Linux” and “technology professionals with these skills and expertise are being sought like never before”

5 Can’t I just learn Unix online?Indexup to index

Sure! You will find a video course by first logging in to lynda.com, then see Unix for Mac OS X Users

5.1 Some online coursesIndexup to index

6 Command Line vs. GUI: Power Users need more than GUIIndexup to index

Sysadmin motto: “Anything worth doing will be done more than once.”

This is a short note I wrote on why even modern GUIs just don’t have the power needed to handle repeated tasks. The original article appeared in the Ottawa Linux User Group http://oclug.on.ca/archives/oclug/2006-October/051531.html whose mailing List you can find here http://oclug.on.ca/mailman/listinfo/oclug

A GUI user wrote:

There are plenty of examples. Take sending a message by e-mail for example. No complex menu navigaion is required for that in a GUI, such as Evolution, for example. You simply click on “New” fill in the form with appropriate data, and click send.

Okay, I just sent a file to one user. Now how do I repeat that and only have to change the userid, or only the file name, without having to “fill in the form” again (possibly making mistakes or forgetting exactly what I filled out in the previous form)?

In a command line, I back up one line (one keystroke) and change “user1” to “user2” or “file1” to “file2” and push return. If I realize I want to do this a lot, I save that line in a script file and pass the userid or file name in as a parameter, so I only need type “./mailusers user3” or “./mailfiles file3”.

Say it’s tomorrow and I can’t remember exactly which files I sent to whom. My command line history tells me exactly what I sent and to whom and allows me to repeat what I did exactly, only changing the little bits I want changed.

Say it’s next month and I realize I’m always sending these emails to the same people, so I collect the command lines that do that and put them all into one script file that makes it all happen: “./doall”

Say it’s next year and I realize I’m always doing these things at the same time every month, so I put an entry in my crontab that will automatically run my “doall” script on the 15th of every month.

Say I want my friend in Slovenia to be able to do exactly what I do. I send him my script file.

What existing GUI lets me do that sort of thing? To summarize:

You’re talking about taking an action that you can repeat later with the same parameters, or parameters you can easily change. So, write the software so that it can save and retrieve parameters for a future session without using a complex menu.

My command line doesn’t require me to rewrite any applications. I can parametrize and run all the applications unchanged.

What existing GUI lets me do these things, all of which I do a lot?

“Anything worth doing will be done more than once.”

References:

http://osnews.com/story.php/6282/The-Command-Line--The-Best-Newbie-Interface/page1/

7 Point-and-Grunt and Free Software IdealsIndexup to index

8 Getting Useful Work DoneIndexup to index

The designer of a program that provides a graphical user interface must anticipate all the possible ways in which the user will interact with the program and provide ways to trigger the appropriate program responses by means of pointing and clicking. Consequently, the user is constrained to working only in predicted ways. The user is therefore unable to adapt the graphical user interface program to accommodate unforeseen tasks and circumstances. In a nutshell, that’s why many system administration tasks are performed using the shell: system administrators, in fulfilling their responsibility to keep a system up and running, must continually deal with and overcome the unforeseen.

– Bill McCarty, “Learning Debian GNU/Linux”, Chapter 13

9 Mastery of UnixIndexup to index

Mastery of UNIX, like mastery of language, offers real freedom. The price of freedom is always dear, but there’s no substitute. Personally, I’d rather pay for my freedom than live in a bitmapped, pop-up-happy dungeon like NT. I’m hoping that as IT folks become more seasoned and less impressed by superficial convenience at the expense of real freedom, they will yearn for the kind of freedom and responsibility UNIX allows. When they do, UNIX will be there to fill the need.

– Thomas Scoville, “The Elements of Unix Style: Unix as Literature” http://www.thomasscoville.com/PCarticle.html (no longer online)

10 In the Beginning was the Command LineIndexup to index

Back in the days of the command-line interface, users were all Morlocks who had to convert their thoughts into alphanumeric symbols and type them in, a grindingly tedious process that stripped away all ambiguity, laid bare all hidden assumptions, and cruelly punished laziness and imprecision. Then the interface-makers went to work on their GUIs, and introduced a new semiotic layer between people and machines. People who use such systems have abdicated the responsibility, and surrendered the power, of sending bits directly to the chip that’s doing the arithmetic, and handed that responsibility and power over to the OS. This is tempting because giving clear instructions, to anyone or anything, is difficult. We cannot do it without thinking, and depending on the complexity of the situation, we may have to think hard about abstract things, and consider any number of ramifications, in order to do a good job of it. For most of us, this is hard work. We want things to be easier. How badly we want it can be measured by the size of Bill Gates’s fortune. […]

In other words, the first thing that Apple’s hackers had done when they’d got the MacOS up and running–probably even before they’d gotten it up and running–was to re-create the Unix interface, so that they would be able to get some useful work done. At the time, I simply couldn’t get my mind around this, but: as far as Apple’s hackers were concerned, the Mac’s vaunted Graphical User Interface was an impediment, something to be circumvented before the little toaster even came out onto the market.

– Neal Stephenson, “Cryptonomicon”, “In the beginning was the Command Line” http://www.csn.ul.ie/~caolan/publink/etexts/stephenson.txt

Author: 
| Ian! D. Allen, BA, MMath  -  idallen@idallen.ca  -  Ottawa, Ontario, Canada
| Home Page: http://idallen.com/   Contact Improv: http://contactimprov.ca/
| College professor (Free/Libre GNU+Linux) at: http://teaching.idallen.com/
| Defend digital freedom:  http://eff.org/  and have fun:  http://fools.ca/

Plain Text - plain text version of this page in Pandoc Markdown format

Campaign for non-browser-specific HTML   Valid XHTML 1.0 Transitional   Valid CSS!   Creative Commons by nc sa 3.0   Hacker Ideals Emblem   Author Ian! D. Allen