Linux Basics --For those new (or relatively new) to Linux

Post tutorials, HOWTO's and other useful resources here.
Post Reply
User avatar
Ahau
King of Docs
King of Docs
Posts: 1331
Joined: 28 Dec 2010, 15:18
Distribution: LXDE & Xfce 32/64-bit
Location: USA

Linux Basics --For those new (or relatively new) to Linux

Post#1 by Ahau » 29 Dec 2010, 17:19

**Updated to include information from Captain Picard's links/guide post here: http://www.slax.org/forum.php?action=vi ... ght=nvidia**

Porteus will likely be a popular tool for folks who are new to Linux in general, as it provides an easy way to get up and running in Linux without having to install to a hard drive (no repartitioning or rewriting your HD's MBR required!).

As a relatively unskilled Linux user myself, I think it may be useful to dedicate a thread to providing information on the basics of Linux and the Command Line Interface (CLI).

I am trying to read more so that I can ask less. Here are some links that I have found useful thus far, and I'll come back to add to it as I go:

General Linux Info that is helpful for newbies:
http://tldp.org/, the Linux Documentation Project. In particular, their intro to linux handbook, here: http://www.tldp.org/LDP/intro-linux/html/
http://www.linux-tutorial.info/modules. ... pageid=224, from linux-tutorial.info
http://www.linux.org/lessons/
http://linux.about.com/cs/glossaries/a/aglossary.htm, a glossary of linux terms

Info that is specific to learning linux commands/bash:
http://www.linuxcommand.org/index.php has some good information that will get you started with the command line, and also lists tons of man pages online, so you can browse them while not in linux.
http://oreilly.com/linux/command-directory/
http://www.linfo.org/command_index.html has more information on commands, in a more user-friendly format than the standard man pages (poke around the rest of their site, http://www.linfo.org as well!).
http://www.hypexr.org/bash_tutorial.php

Also, if someone is asking you to enter a command that you aren't familiar with, check the man page for that command. For example, in the terminal, enter "man grep" (without the quotes) to see a brief description of what this command does, and the modifiers that can be used with it.

http://www.linuxquestions.org/ is also a great resource, you can search their forums to find answers to lots and lots of questions.

http://www.slackbook.org/html/index.html has a lot of great info that is specific to slackware (on which Porteus is based), as well as general info for linux usage and the CLI.

If these links fail to provide the guidance you need, please keep the following in mind as you post on this forum:
How to ask questions the smart way:http://www.catb.org/~esr/faqs/smart-questions.html

Captain Picard's post http://www.slax.org/forum.php?action=vi ... ght=nvidia has a lot more links that may be useful, which I've not included here, to keep the focus of this post on general linux info and an intro to the CLI.

Thanks!
Last edited by Ahau on 05 Jan 2011, 17:30, edited 2 times in total.
Please take a look at our online documentation, here. Suggestions are welcome!

User avatar
brokenman
Site Admin
Site Admin
Posts: 5574
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v3.2rcX all desktops
Location: Brazil
Contact:

Re: Linux Commands --For those new (or relatively new) to Li

Post#2 by brokenman » 29 Dec 2010, 21:55

I have a text file full of useful commands. A small script allows me to search for a command i need. For example: cmd unpack initrd would bring up results for any lines with 'unpack initrd' and give me the code. I use it everyday!!
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
X-Factor
Black ninja
Black ninja
Posts: 88
Joined: 29 Dec 2010, 23:19
Location: bali, indonesia

Re: Linux Commands --For those new (or relatively new) to Li

Post#3 by X-Factor » 29 Dec 2010, 23:40

This would be my home for most of my time next year :good: ...... hope more links to common command appear here.
I've been confine to my quarter
http://img143.imageshack.us/i/medusathing.jpg/

User avatar
Ahau
King of Docs
King of Docs
Posts: 1331
Joined: 28 Dec 2010, 15:18
Distribution: LXDE & Xfce 32/64-bit
Location: USA

Re: Linux Basics --For those new (or relatively new) to Linu

Post#4 by Ahau » 05 Jan 2011, 17:32

I've updated the original post to include more information...
Please take a look at our online documentation, here. Suggestions are welcome!

User avatar
francois
Contributor
Contributor
Posts: 5078
Joined: 28 Dec 2010, 14:25
Distribution: kde xfce porteus manjaro kubun
Location: Enfin l'été, le changement climatique attendu: le soleil.

Re: Linux Commands --For those new (or relatively new) to Li

Post#5 by francois » 10 Jan 2011, 18:18

@ahau:
Very good idea to get captain picard's famous thread in a place where it will not move.
brokenman wrote:I have a text file full of useful commands. A small script allows me to search for a command i need. For example: cmd unpack initrd would bring up results for any lines with 'unpack initrd' and give me the code. I use it everyday!!
It would be a great idea to post such a list. I like the copy paste method for cli mode. This way there are lot less errors. And it might be faster also.

Posted after 3 days 21 hour 9 minutes 36 seconds:
Re: Linux Basics --For those new (or relatively new) to Linux
Here is a list of useful commands:
http://vectorlinux.osuosl.org/Uelsk8s/test/
Voltaire: Le mieux est l'ennemi du bien.

User avatar
Rava
Contributor
Contributor
Posts: 1319
Joined: 11 Jan 2011, 02:46
Distribution: Porteus 3.1.0 x86-64 XFCe
Location: Germany

Re: Linux Commands --For those new (or relatively new) to Li

Post#6 by Rava » 20 Aug 2015, 22:10

brokenman wrote:I have a text file full of useful commands. A small script allows me to search for a command i need. For example: cmd unpack initrd would bring up results for any lines with 'unpack initrd' and give me the code. I use it everyday!!
Late reply is laaate, but that sound's like a neat script. Do you share it?


I went another approach, I created some scripts all named help.*, while the * is either simple the command name that it's about, or more than just one command.

Here is the full list:

Code: Select all

root@porteus:/mnt/sda2/iso# help.
help.7z              help.find            help.realpath
help.COLUMNS+LINES   help.firefox         help.rename
help.EMPTY           help.growisofs       help.ripit
help.aria2c          help.gvfsd-metadata  help.shred
help.cdda2wav        help.less            help.slackyd
help.cdparanoia      help.mkisofs         help.stat
help.cdrdao          help.mlabel          help.swap
help.cdrecord        help.mmv             help.tar
help.ctorrent        help.mount           help.time
help.date+hwclock    help.mplayer         help.toupper
help.dd.random+cp    help.mtpaint         help.truecrypt
help.diff            help.nero            help.unset
help.digest          help.opera           help.wget
help.fdupes_clone    help.perl            help.xzip
help.ffmpeg          help.qiv 
help.EMPTY sure im my template for a new file, since by standard the info output is dark blue, and the name of the script is like it's title and in colour as well.

For these scripts I use my colour coding by using variables that have the one escape sequence, but are named like $bold or $red or $off. :)

By this, having colours in a script is easy and understandable coding, cause who wants to remember what "\033[5m" or "\033[60G" stands for, and all the others?

The first is flashing, but bash shows me that not as flashing but as underlined, I started that years back, maybe they nowadays even changed flashing to underlined to eliminate nasty flashing script coding. I agree to such change out of that reason...

And the second is flush-right.

Mostly I use a colour, or a colour and bold.

</digress>
Cheers!
Yours Rava

User avatar
brokenman
Site Admin
Site Admin
Posts: 5574
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v3.2rcX all desktops
Location: Brazil
Contact:

Re: Linux Basics --For those new (or relatively new) to Linu

Post#7 by brokenman » 20 Aug 2016, 21:28

What a great idea! This would have been exactly the thing I was looking for when I started out learning bash scripting.

I when the lazy route and just put useful commands into a single text file in this format.

awk '{print $(NF-1)}' get second last field
sed 's/\(.*\).../\1/' remove last three characters

https://www.dropbox.com/s/yxoxh97wxn1tir7/cmd.txt?dl=0
How do i become super user?
Wear your underpants on the outside and put on a cape.

Bogomips
Full of knowledge
Full of knowledge
Posts: 2563
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: Linux Basics --For those new (or relatively new) to Linu

Post#8 by Bogomips » 21 Aug 2016, 17:39

brokenman wrote:the lazy route and just put useful commands into a single text file in this format.
Even less organised. Upon working out how to use a new command, I would need, put sample input and output of said command in text file of useful info. Upon requiring to use this command some weeks or months later, just need earch of file, narrowing down if necessary, with regular expression.
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

User avatar
Rava
Contributor
Contributor
Posts: 1319
Joined: 11 Jan 2011, 02:46
Distribution: Porteus 3.1.0 x86-64 XFCe
Location: Germany

Re: Linux Basics --For those new (or relatively new) to Linu

Post#9 by Rava » 24 Aug 2016, 04:49

@Bogomips, @brokenman

We are quite the lazy bunch, eh, quick and dirty coding rules. Well, at times it sucks, like when I created my internal / external hard disc / USB flash drive compressed indexing solution...

It works a okay, but when I would have spend 2 more days really pondering about the way to implement it the best way, it would have been so much better than the solution I now have. It is split between 5 or 7 main executables, at least 2 of these are used as kind of "in-line code" that gets loaded by many other scripts, but also each indexed and numbered device must have its own script, and I have to hard-code in each and every script how many possible devices I have, e.g. does it have to look for externalUSB01 to ..15 or ..17? When I add new ones I have to edit at least 3 scripts...

So you see, at times it is better to work longer and harder prior starting the coding itself to get a better thought out solution, than start coding quicker and have a few days earlier results, but have to work with more work and sucky code for years. Yeah, you can call be Bill G. Rava now. :wall:
Cheers!
Yours Rava

Post Reply