Learning Command Line

J

jeremy Johnson

Guest
Hey guys,
I am new to the forum and new to the linux world in general. I just got ubuntu and I am interested in learning the command line. I have a book to learn bash. My question, solely out of curiosity, is how long it will take to realistically learn the command line. I want to be able to use it for the majority of the time. If people would be willing to post their experiences in learning bash, what helped, and what didn't, that would be greatly appreciated. Thank you in advance!
 


Welcome to the future.

So, I started learning bash way back.. I would say it took me maybe 2-3 weeks to be completely comfortable. Everything from file creation to moving directories from one machine to another. Don't try to force yourself. Just learn at your own pace. Ubuntu is one of those systems where almost everything is already setup. When you are comfortable with Ubuntu try another distro that requires YOU to set stuff up. I recommend Arch for that kind of thing. When you boot the system, there is no graphics (the live disk anyway). Then you have to do EVERYTHING in CLI. What seems to help is just diving in. Doing everyday activities in the terminal. (moving, deleting, editing files. Reading email *text only*. Installing / upgrading software. )
 
Hello Jeremy! How long it takes to learn the command line is a pretty open-ended question. I've been playing with Linux for several years, and I am still learning the command line. Well, I could be a slow learner, but I think you will find that Linux has a huge set of commands, not to mention writing scripts in BASH or an other shell. Whole college-level courses have been devoted to networking, administration, and security. Personally, I believe the best way to learn the command line is to just jump in and use it. I strongly suggest keeping a notebook or journal, and writing down what you find out about various commands that you use. You would be surprised at how often you will come across a situation where you say, "gee, I solved that problem once, now how did I do it?"

I also suggest that you have a good reference book next to your Linux box. The book I recommend is O'Reilly's "Linux In A Nutshell" 6th ed. by Siever, Figgins, Love, and Robbins. This is a true reference book, like a dictionary, where commands are grouped by task, and alphabetically and each command has an explanation, switches, and examples of usage. It weighs in at over 900 pages. It is Linux distribution independent. It also covers BASH, the common command line editors, sed, awk, and a whole lot more. Now, notice I said reference book - this book is not a tutorial on how to use Linux. It is much like an encyclopedia covering the command line and other tools.

I am talking pretty low tech here with notebooks and physical reference books, but it is pretty hard to be learning something at the command line and looking up something online, both at the same time. Having said that, I think you will also find that googling commands and other things you run into in using Linux to also be an excellent source of information.

It helps also to have some particular tasks in mind. For example, get an older box and load the minimal install without the GUI, or load the server version. Ubuntu has both. Try setting up a network so that your main box and the older box can "talk" to each other and share files back and forth. I have 4 computers in my little network: I have a Windows 7 desktop, an Ubuntu Desktop, a network "server" running headless and at the command line. It provides storage, web development, and printer services to all the other computers. And I have a really old box (~12-14 years old) with just 128mb of ram running headless and at the command line, that I use for Linux programming, particularly assembly language. I haven't had this much fun playing with computers since the DOS days! Linux really does bring the fun back into computing. I've learned more about Linux networking, programming, and command line stuff doing this than in any structured college course. Good Luck, and have a lot of fun!

~todd
 
I agree with what others here are saying. The best way to learn is to just dive in and play around. One of the things I would recommend is to learn the "man" command and make it your friend. Linux has an amazing amount of documentation built right into the system. If you ever have a question about what a command does or how to use it just use "man command" and it will provide a manual for whatever command.
 
As mentioned by Todd earlier in this article, you will always be learning new things about the command line. I primarily learned simply by wanting to know how to do something in the command line, then googling it. It is very simple.

Here are some commands to get you started playing, you can even pipe commands from one to another by using the | key.

ls List the contents of a directory
echo sometext Print sometext to the terminal
nano somefile Edit somefile like a normal human being
vi somefile Edit somefile the (inefficient) geeky way
sudo somecommand Run a command as root
sudo apt-get install somepackage Install somepackage (assuming you are on Ubuntu or Debian type distro)
fortune | cowsay Have an ascii cow read you a fortune, requires the fortune and cowsay packages, great example of piping commands

I wish you luck on your adventures :)
 
Great answers in this thread!

I'll add that you'll always be learning things when using the cli. I've been using Linux for a long time (since 96ish?) and an still learning new things.
 
There is so much to learn and I don't think any of us out here know it all (as we work with different distros). You have to just jump right in and start slow. I learn something new everyday. I had an interview last year and some of the senior guys asked me what was in the /var/etc directory. It seemed like an odd question at the time and my answer to them is what got me the job.
Just stay in the "shell" and it will all come natural in time.

Good luck
 
Try INX this is a small operating system that has a built in tutorial. It is not graphical user interface only terminal.

goto:
inx
maincontent
net
 
Try INX this is a small operating system that has a built in tutorial. It is not graphical user interface only terminal.

goto:
inx
maincontent
net

If the OP wants to learn the GNU/Linux command-line, then why are you suggesting a different OS?
 
As a newby i was looking to learn the terminal to.
I looked around and have checked many (linux,unix) Os's.
Correct me if I am wrong but most linux Os's are unix based.
So on my way I encountered INX and it's just a fun way to learn the basic terminal commands that are similar to ubuntu terminal, linux mint terminal, backtrack terminal, and some more. It's tutorials are to get used of the navigating in the terminal like ls, cd, find, pwd, and more. A while ago I started reading
LINUX: Rute User's Tutorial and Exposition
This book is online available and for free. I recommend it for beginners and novice users.
 
All Linux systems use the Linux kernel. Linux is Unix-like and Linux is not a Posix system either.

Ah I am gonna have to read your thread on a kernel and look up what a Posix system is.
Mmhh more food for tought:)
Thanks for reply
 
If the OP wants to learn the GNU/Linux command-line, then why are you suggesting a different OS?
If the OP was interested in answers, he/she would have made at least one more post in the last 4 1/2 months. If this thread benefits anyone, it will not be the OP. (I hate drive-by posters.:mad:)
 
Hey guys,
I am new to the forum and new to the linux world in general. I just got ubuntu and I am interested in learning the command line. I have a book to learn bash. My question, solely out of curiosity, is how long it will take to realistically learn the command line. I want to be able to use it for the majority of the time. If people would be willing to post their experiences in learning bash, what helped, and what didn't, that would be greatly appreciated. Thank you in advance!

Hi Girls 'n Gyus,

"If you have to ask, it aint" CLI.
"How do I get to Carnegie Hall?"
"Practice, practice, practice."
Don't let 'em get u down.:cool:
 
Last edited:

Members online


Latest posts

Top