This module covers Introduction to Linux, History of Linux, Features of Linux, Advantage of Linux, File System Hierarchy Standard, Knowing root, Linux Commands, Working with Files and Directories, etc.
1. (Introductory module on Linux)
www.whitehatGuru.net
twitter.com/linuxender
linuxender.blogspot.com
2. Linux an open source operating system. Its source code can
be used freely, freely modified, and redistributed, both
commercially and non-commercially, by anyone under
licenses such as the GNU General Public License
3.
4. The Unix operating system was conceived and implemented
by Ken Thompson and Dennis Ritchie (both of AT&T Bell
Laboratories) in 1969 and first released in 1970. Its
availability and portability caused it to be widely
adopted, copied and modified by academic institutions and
businesses. But it was not freely distributed.
5. In 1983, Richard Stallman started the GNU project. His idea
was that unlike other products, software should be free from
restrictions against copying or modification in order to make
better and efficient computer programs. With his famous
1983 manifesto that declared the beginnings of the GNU
project
6. MINIX, a Unix-like system intended for academic use, was
released by Andrew S. Tanenbaum in 1987. MINIX was free
and designed for education in computer science. Students of
Computer Science all over the world read the codes to
understand the very system that runs their computer.
7. In 1991 while attending the University of
Helsinki, Torvalds, curious about the operating systems and
frustrated by the licensing of MINIX limiting it to educational
use only (which prevented any commercial use), began to
work on his own operating system which eventually became
the Linux kernel. In order to make the Linux available for
commercial use, Torvalds initiated a switch from his original
license (which prohibited commercial redistribution) to the
GNU GPL.
8.
9. Here are some basic and major features of Linux.
Free and Open source code for all: All source code of Linux is
available, including the whole kernel and all drivers, the development
tools and all user programs; also, all of it is freely distributable. Plenty of
commercial programs are being provided for Linux without source, but
everything that has been free, including the entire base operating
system, is still free.
c
Multiuser: Several users can logon to the same machine at the same
time There is no need to have separate user licenses.
Multitask: Several programs can run at the same time.
Multiplatform: runs on many different CPUs, not just Intel.
Networking: Linux supports networking and many network protocols like
TCP, IPv4, IPv6, etc.
10. Forget about viruses
Linux hardly has any viruses. A Linux virus is not impossible to get.
However, Linux makes it very hard for this to happen, for several reasons:
Most people use Microsoft Windows, and pirates want to do as much
damage (or control) as possible: therefore, they target Windows.
More eyes make fewer security flaws. Linux is Open source
software, which means that any programmer in the world can have a
look at the code (the "recipe" of any program), and help out, or just tell
other developers
11. Is your system unstable?
Have you ever lost your precious work because Windows crashed? Do you
always shut down your computer the proper way, or do you sometimes just
switch it off because Windows has gone crazy and doesn't let you do anything
anymore? Have you ever gotten the "blue screen of death" or error messages
telling you that the computer needs to be shut down for obscure reasons?
When a system crashes, it needs to be shut down or restarted. Therefore, if
your computer can stay up and running for a long time, no matter how much
you use it, then you can say the system is stable. Well, Linux can run for years
without needing to be restarted (most internet servers run Linux, and they
usually never restart). Of course, with heavy updates, it still needs to be
restarted (the proper way). But if you install Linux, and then use your system
as much as you want, leaving your computer on all the time, you can go on
like that for years without having any trouble.
12. Don't pay for your operating system
Unless you obtained Windows illegally, you probably paid for it. Linux
completely free of charge. Of course, some companies are making good
business by selling support, documentation, hotline, etc., for their own version
of Linux, and this is certainly a good thing. But most of the time, you won't
need to pay a cent.
13. Need new software? Don't bother searching the
web, Linux gets it for you.
If you want to check out a new piece of software in Windows, you'll need to:
Search the web to find which piece of software suits your needs.
Find a web site that allows you to download it.
Maybe pay for it.
Actually download the software.
Install it.
Sometimes reboot your computer.
That's a lot of work to just try out something new.
With Linux, everything is much simpler. Linux has what is called a "package
manager": each piece of software is contained in its own "package". If you
need some new software, just open the package manager, choose the
package and install it.
14. Forget about drivers
Imagine you want to install Windows on a whole new, untouched, computer.
For each little piece of hardware you'll have to find the latest driver (or use a
CD), install it, and reboot from time to time. Video card, sound
card, keyboard, mouse, motherboard chipset, etc. (better do the video card
driver first or you're stuck with your high-end screen showing a very low
resolution mode). And that comes after an already rather long installation of
Windows itself.
Linux doesn't need separate drivers. All the drivers are already
included in the Linux kernel, the core of the system, and that comes with
every single Linux installation. This means:
A very fast and standalone installation process. Once you're done, you
have everything you need to start working (including the software you'll
be using,.
Out-of-the-box ready peripherals.
15. The Filesystem Hierarchy Standard (FHS) defines the main directories and
their contents in Linux operating systems.
/ Primary hierarchy root and root directory of the entire file system
hierarchy.
/boot Contains the boot loader. It contains everything required for
the boot process
/etc Contains all the configuration files like DNS, Proxy, Apache and
other programs.
/home Contains the home directory of a normal user.
/root Contains the home directory of the super user, i.e., root.
/bin Contains commands that may be used by both the system
administrator and by users.
/sbin Utilities used for system administration (root-only commands)
are stored in /sbin, /usr/sbin, and /usr/local/sbin. /sbin contains binaries
essential for booting, restoring, recovering, and/or repairing the system
in addition to the binaries in /bin.
16. /lib The /lib directory contains those shared library images needed
to boot the system and run the commands in the root filesystem, ie. by
binaries in /bin and /sbin.
/usr Secondary hierarchy for read-only user data; contains the
majority of multi-user utilities and applications.
/mnt or /media In Linux, all the removable devices like cdrom, pen
drive, external hard disk, etc, are mounted /mnt or /media directory.
Both are temporary mounting point and their work are same.
/var contains variable data files. This includes spool directories and
files, administrative and logging data, and transient and temporary
files.
/dev Directory is the location of device files.
/tmp Temporary files.
/opt This directory is reserved for all the software and add-on
packages that are not part of the default installation.
17. Linux has two interfaces: 1. Command Line Interface (CLI) 2.
Graphical User Interface (GUI)
It has 7 virtual consoles, by pressing Alt+Ctrl+f1 to
Alt+Ctrl+f7, we can switch from one console to another.
Alt+Ctrl+f1 – 1st console
Alt+Ctrl+f2 – 2nd console
Alt+Ctrl+f3 – 3rd console
Alt+Ctrl+f4 – 4th console
Alt+Ctrl+f5 – 5th console
Alt+Ctrl+f6 – 6th console
Alt+Ctrl+f7 – 7th console
22. Root is by default an administrator name in Linux.
After login, when you open a terminal. You see the following prompt.
Here, root is admin name, localhost is the system name, tild(~) indicates the
home directory (this implies, root is in his home directory) and # indicates
authorized use, that means, root has the authority to access the particular
directory. Incase of a normal user, it will show $ prompt.
23. whoami - print effective userid.
date - print or set the system date and time.
cal - displays a calendar.
pwd - print name of current/working directory.
ls –l - list directory contents with details.
cd - Change the working directory
clear - Clear the screen
Getting help:-
whatis (command) - searches a set of database files containing short
descriptions of system commands for keywords and
displays the result on the standard output.
which (command) - Displays where a particular program in your path is
located.
man (command) - manual pages from the Linux Documentation
Project.
info (command) - read Info documents.
command --help - for more help.
24. Creating a file
Copying a file
Moving a file
Removing a file
(To remove a file forcefully, add –f between command and file, then it
wont ask you for the confirmation)
25. Renaming a file
In Linux everything is file. You should know how to edit a file.
Later in the module you will understand how to edit a file
using gedit and vi editor.
26. Creating a directory
Creating sub-directories
Creating multiple directories
Copying a directory
(To remove a directory forcefully, add –f between command and
directory, then it wont ask you for the confirmation)
27. Moving a directory
Removing a directory
To remove an empty directory, type command
Renaming a directory
(To remove a directory forcefully, add –f between command and
directory, then it wont ask you for the confirmation)
28. For more fun visit:
www.whitehatGuru.net
linuxender.blogspot.com
Notas do Editor
Portability is the software codebase feature to be able to reuse the existing code instead of creating new code when moving software from an environment to another.
In computing, the kernel is the main component of most computer operating systems; it is a bridge between applications and the actual data processing done at the hardware level. The kernel's responsibilities include managing the system's resources (the communication between hardware and software components).
Any file to which data is spooled to await the next stage of processing. A device file or special file is an interfacefor a device driver. Device files often provide simple interfaces to peripheral devices, such as printers. But they can also be used to access specific resources on those devices, such as disk partitions.
A terminal consists of a screen and keyboard that one uses to communicatewith a computer.