INTRODUCTION TO LINUX
Linux is said to be the world's fastest growing operating systems because of it's diverse functionality, effeciency and capabilities.
Linux was developed from another operating system called UNIX.
Linux was first developed in USA by Linus in the early 80's.
However, today Liux is the most common operating system used by high end servers.
Linux was developed because Unix was not user friendly, it had no GUI(Graphical User Interface) hence it could only work with the Command line and to do anything with it some had to execute only commands.
Unlike for Microsoft Windows, Linux comes as both a desktop and a network opearating system ,the system incorporates tool which can be used for diverse activities like computer programing, software development and other heavy computing operations while for Windows, it developes different operating systems for different tasks.
UNIX has various flavours.
They include:
Caldera
Linux also has various flavours/brands. They include
Linux Red Hat
Suse Linux
Sam Linx
Fedora
Ubuntu
Mubuntu Linux
Linux Mint
Debian
Cairos Linux
e.t.c
The brands of Linux can never get exhausted in that, Linux is open source meaning that any one can edit anything in the operating sytem but the task is to advertise world over, if the change is liked by the people it will become acceptable and coppies of that editorial will circulate all over the world.
This is the very reason why there are so many Linux flavours on the market today.
LINUX KEYBOARD SHORTCUT KEYS
CTRL + B |
Moves the cursor backward one character. |
CTRL + C |
Cancels the currently running command. |
CTRL + D |
Logs out of the current session. |
CTRL + F |
Moves the cursor forward one character. |
CTRL + H |
Erase one character. Similar to pressing backspace. |
CTRL + P |
Paste previous line and/or lines. |
CTRL + S |
Stops all output on screen (XOFF). |
CTRL + Q |
Turns all output stopped on screen back on (XON). |
CTRL + U |
Erases the complete line. |
CTRL + W |
Deletes the last word typed in. For example, if you typed 'mv file1 file2' this shortcut would delete file2. |
CTRL + Z |
Cancels current operation, moves back a directory and/or takes the current operation and moves it to the background. See bg command for additional information about background. |
Command line shortcuts
In addition to the below command line shortcuts, it is also helpful to use the alias command that allows you to specify a keyword for frequently used commands or mistakes.
~ |
Moves to the user's home directory. |
!! |
Repeats the line last entered at the shell. |
!$ |
Repeats the last argument for the command last used. |
reset |
Resets the terminal if terminal screen is not displaying correctly. |
shutdown -h now |
Remotely or locally shuts the system down. |
|
|
|
Linux usage in everyday life
You can use Linux as a server operating system or as a stand alone operating system on your PC. As a server operating system it provides different services/network resources to a client. A server operating system must be:
- Stable
- Robust
- Secure
- High Performance
Linux offers all of the above characteristics plus it is free and open source. It is an excellent operating system for:
- Desktop computer
- Web server
- Software development workstation
- Network monitoring workstation
- Workgroup server
- Killer network services such as DHCP, Firewall, Router, FTP, SSH, Mail, Proxy, Proxy Cache server etc
What is the Linux Kernel?
The kernel is heart of the Linux operating system. It manages the resources of Linux. Resources include:
- File management
- Multitasking
- Memory management
- I/O management
- Process management
- Device management
- Networking support including IPv4 and IPv6
- Advanced features such as virtual memory, shared libraries, demand loading, shared copy-on-write executables etc
The kernel decides who will use these resources and for how long and when. It runs your programs or sets up to execute binary files.
The kernel acts as an intermediary between the computer hardware and various applications.
BASIC COMPUTER REQIREMENTS FOR LINUX
Because we don’t live in an ideal world, we’ll assume you know little about your PC and need a primer on its components. We’ll run down both the minimal and ideal Linux PC configurations and then give a compatibility list.
NOTE: When buying a PC, the temptation is to spend as little as possible or to try to squeeze by with lesser or inferior components. We understand the need to live on a budget—we certainly don’t have thousands of dollars worth of computer equipment sitting around our home offices. But there comes a point when you need to make the necessary investment if you want to run Linux effectively. Too often we see people complaining in the Usenet newsgroups that Linux doesn’t run properly on their PCs or that XFree86 won’t run in higher resolutions on their unsupported graphics cards. You can avoid this by either taking an inventory of your PC before installing Linux (which may mean actually taking off the cover and physically poking through the components) or making sure a new PC meets the compatibility guidelines. Either action is a real pain, we admit; but by spending some time up front, you’ll avoid many problems later in the installation and configuration process. You may be pleased with yourself after saving some cash buying a new graphics card from NoNameClone Corp., but in the end you’re better off paying a little more for hardware that’s been thoroughly tested by the huge number of existing Linux users.
Table 1.1 lists the minimum and ideal configuration guidelines for Linux.
Table 1.1 Linux PC Configuration Guidelines
|
PC Component |
Minimum |
Ideal |
Processor |
Intel 80386 or equivalent |
Pentium is ideal (power, power, power!); i486 works fine, as do Intel clones |
RAM |
4MB (8MB for running X Window) |
16MB |
Graphics card |
VGA graphics |
SVGA graphics; card explicitly supported by XFree86 |
Hard drive |
125MB |
500MB or more |
Bus |
Anything but MCA |
Anything but MCA |
CD-ROM |
Double-speed drive |
Quadruple-speed drive |
Mouse |
Microsoft, Logitech, or compatible |
Microsoft, Logitech, or compatible |
Network card |
None |
Supported model (if networking) |
|
NOTE: If you’re not sure about your particular hardware setup and Linux compatibility, check out the Hardware Compatibility List from Google or the the appropriate Linux flavour you are using on their website.
WARNING: Watch out for hardware advertised as “plug-and-play.” Most of this hardware is extremely difficult to use with Linux, although it can be done by first booting DOS and then “warm booting” into Linux with Loadbin. Some experimental kernel patches and a plug-and-play configuration tool are included in Slackware, but in general, if you can avoid plug-and-play devices (at least until Linux support improves) you’ll be better off.
The Core Components
In the rest of this chapter, we’ll run down the various PC components and warn you about any potential downfalls if you want to use Linux. In addition, you’ll want to check out Chapter 3 for a discussion of supported graphics cards—support that becomes vitally important if you’re looking to run XFree86 (the implementation of the X Window System) with Linux.
In this section, we’ll begin with a rundown of the basic components of your computer: bus, processor, and so on.
Bus
Linux runs on all the major bus architectures—ISA, VLB, PCI, EISA—except for the nonstandard Micro Channel Architecture, found on most IBM PS/2 models. (Not every IBM PC features an MCA bus, luckily; the ValuePoint and PS/1 models feature an industry-standard ISA bus.)
Processor
Linux needs at least an Intel 80386-based processor in order to run efficiently. Don’t bother with a 80286-based PC. If you’ve got an older PC sitting in the closet and you think it might be neat to recycle by using Linux, leave it there, donate it to your local charity, or give it to the kids to bang on. It won’t be useful in your Linux adventure.
Basically, any PC built around the Intel 80386 or better (including the i486, and Pentium, and chips from AMD and Cyrix) is capable of running Linux. If there is no math coprocessor (which may be an issue in older 80386-based PCs), Linux has built-in FPU emulation.
A Few CPU Problems
There are a few reported instances of Linux conflicting with a CPU or math coprocessor:
- • Some AMD 486DX CPUs may hang in very specific situations, a problem that’s not unique to Linux. If this happens to you, contact your PC vendor and get a replacement chip.
- • Some older math coprocessors from Cyrix, IIT, and ULSI (the Math*Co series) have problems with the FSAVE and FRSTOR instructions, which may cause problems with Linux. Again, you can get a replacement chip from your PC vendor.
An A-Z Index of the Linux BASH command line
alias Create an alias apropos Search Help manual pages (man -k) awk Find and Replace text, database sort/validate/index break Exit from a loop builtin Run a shell builtin bzip2 Compress or decompress named file(s)
cal Display a calendar case Conditionally perform a command cat Display the contents of a file cd Change Directory cfdisk Partition table manipulator for Linux chgrp Change group ownership chmod Change access permissions chown Change file owner and group chroot Run a command with a different root directory cksum Print CRC checksum and byte counts clear Clear terminal screen cmp Compare two files comm Compare two sorted files line by line command Run a command - ignoring shell functions continue Resume the next iteration of a loop cp Copy one or more files to another location cron Daemon to execute scheduled commands crontab Schedule a command to run at a later time csplit Split a file into context-determined pieces cut Divide a file into several parts
date Display or change the date & time dc Desk Calculator dd Data Dump - Convert and copy a file ddrescue Data recovery tool declare Declare variables and give them attributes df Display free disk space diff Display the differences between two files diff3 Show differences among three files dig DNS lookup dir Briefly list directory contents dircolors Colour setup for `ls' dirname Convert a full pathname to just a path dirs Display list of remembered directories du Estimate file space usage
echo Display message on screen egrep Search file(s) for lines that match an extended expression eject Eject removable media enable Enable and disable builtin shell commands env Environment variables ethtool Ethernet card settings eval Evaluate several commands/arguments exec Execute a command exit Exit the shell expand Convert tabs to spaces export Set an environment variable expr Evaluate expressions
false Do nothing, unsuccessfully fdformat Low-level format a floppy disk fdisk Partition table manipulator for Linux fgrep Search file(s) for lines that match a fixed string file Determine file type find Search for files that meet a desired criteria fmt Reformat paragraph text fold Wrap text to fit a specified width. for Expand words, and execute commands format Format disks or tapes free Display memory usage fsck File system consistency check and repair ftp File Transfer Protocol function Define Function Macros
gawk Find and Replace text within file(s) getopts Parse positional parameters grep Search file(s) for lines that match a given pattern groups Print group names a user is in gzip Compress or decompress named file(s)
hash Remember the full pathname of a name argument head Output the first part of file(s) history Command History hostname Print or set system name
id Print user and group id's if Conditionally perform a command ifconfig Configure a network interface import Capture an X server screen and save the image to file install Copy files and set attributes
join Join lines on a common field
kill Stop a process from running
less Display output one screen at a time let Perform arithmetic on shell variables ln Make links between files local Create variables locate Find files logname Print current login name logout Exit a login shell look Display lines beginning with a given string lpc Line printer control program lpr Off line print lprint Print a file lprintd Abort a print job lprintq List the print queue lprm Remove jobs from the print queue ls List information about file(s) lsof List open files
make Recompile a group of programs man Help manual mkdir Create new folder(s) mkfifo Make FIFOs (named pipes) mkisofs Create an hybrid ISO9660/JOLIET/HFS filesystem mknod Make block or character special files more Display output one screen at a time mount Mount a file system mtools Manipulate MS-DOS files mv Move or rename files or directories
netstat Networking information nice Set the priority of a command or job nl Number lines and write files nohup Run a command immune to hangups nslookup Query Internet name servers interactively
passwd Modify a user password paste Merge lines of files pathchk Check file name portability ping Test a network connection popd Restore the previous value of the current directory pr Prepare files for printing printcap Printer capability database printenv Print environment variables printf Format and print data ps Process status pushd Save and then change the current directory pwd Print Working Directory
quota Display disk usage and limits quotacheck Scan a file system for disk usage quotactl Set disk quotas
ram ram disk device rcp Copy files between two machines. read read a line from standard input readonly Mark variables/functions as readonly remsync Synchronize remote files via email return Exit a shell function rm Remove files rmdir Remove folder(s) rsync Remote file copy (Synchronize file trees)
screen Terminal window manager scp Secure copy (remote file copy) sdiff Merge two files interactively sed Stream Editor select Accept keyboard input seq Print numeric sequences set Manipulate shell variables and functions sftp Secure File Transfer Program shift Shift positional parameters shopt Shell Options shutdown Shutdown or restart linux sleep Delay for a specified time sort Sort text files source Run commands from a file `.' split Split a file into fixed-size pieces ssh Secure Shell client (remote login program) strace Trace system calls and signals su Substitute user identity sum Print a checksum for a file symlink Make a new name for a file sync Synchronize data on disk with memory
tail Output the last part of files tar Tape ARchiver tee Redirect output to multiple files test Evaluate a conditional expression time Measure Program running time times User and system times touch Change file timestamps top List processes running on the system traceroute Trace Route to Host trap Run a command when a signal is set(bourne) tr Translate, squeeze, and/or delete characters true Do nothing, successfully tsort Topological sort tty Print filename of terminal on stdin type Describe a command
ulimit Limit user resources umask Users file creation mask umount Unmount a device unalias Remove an alias uname Print system information unexpand Convert spaces to tabs uniq Uniquify files units Convert units from one scale to another unset Remove variable or function names unshar Unpack shell archive scripts until Execute commands (until error) useradd Create new user account usermod Modify user account users List users currently logged in uuencode Encode a binary file uudecode Decode a file created by uuencode
v Verbosely list directory contents (`ls -l -b') vdir Verbosely list directory contents (`ls -l -b') vi Text Editor
watch Execute/display a program periodically wc Print byte, word, and line counts whereis Report all known instances of a command which Locate a program file in the user's path. while Execute commands who Print all usernames currently logged in whoami Print the current user id and name (`id -un') Wget Retrieve web pages or files via HTTP, HTTPS or FTP
xargs Execute utility, passing constructed argument list(s) yes Print a string until interrupted
. Run a command script in the current shell ### Comment / Remark
We shall continue keeping you ahead in all you need..
|