Module 1 Introduction to Linux Linux Basics Users
Module 1 Introduction to Linux
Linux Basics • Users must log-in • Linux is case sensitive • File and Directories naming conventions (No spaces!) • Files and Directories starting with a dot (. ) are hidden
Linux Users • There are two kinds of users in Linux: 1. An Administrator (root) and only one. 2. Regular Users (Every one beside root) • Services and Daemons have a unique user name to operate the service/daemon on their behalf. • The first user in the system is root (UID 0) and the first regular user will be created with UID of 500. • Services and Daemons are granted UID from 1 ->499
Linux Users • root (AKA Super User) is the system administrator with unlimited privileges (God) • The root user has the unique User Identification Number (UID) of 0 (zero) • The Linux prompt (Shell Prompt) ends with a # sign when we are logged in as the root user
Linux Users • Regular Users have very limited privileges in the system. • Regular Users are granted UID starting at 500 and above. • The Linux prompt (Shell Prompt) ends with a $ sign when we are logged in as a regular user
The Linux SHELL • Can you “talk” in 000111110000110101001 ? ! • In Linux, the shell is a program that interprets commands and acts as an intermediary between the user and the inner workings of the operating system.
The Linux SHELL • On most Linux systems, there are several shells available. For the average user, they offer similar functionality, but each has different syntax and capabilities. • Most shells fall within one of two classes: those descended from the Bourne shell (i. e. sh), which first appeared in Version 7 Unix, and those from the C Shell (i. e. csh), which made its debut in BSD. Nearly every Linux system has these two shells installed, but may also have several others
The Linux SHELL • SHELL: sh, csh, ksh and bash • Bourne Again Shell: bash • Switching shells is easy (when we are switching a shell we are actually opening a new Sub Shell under our original shell)
The Linux SHELL • We can find the system default shell by echoing the variable: # echo $SHELL • We can find the shell we are currently on by echoing the following variable: # echo $0 • To close a shell simply issue the command: # exit
Which Linux are you on ? • Find your Operating System name: # cat /etc/issue ( the cat command shows us a text file on our screen) • Find your Kernel Version and CPU architecture: # uname -a • Find the system host name: # hostname
The Linux SHELL Command Structure Command Options # ls path -l -l /home -a /tmp -al /var
The Linux man command • Every command in the system has a manual • To read this manual issue the command: # man [Command Name] # man ls • We can search for a specific word in all the manuals descriptions by using the following option: # man –k [specific word] # man –k partition • Search inside the manual with / and exit with q
Who are you and where are you ? • Find who are you: # whoami # id • Find where are you: # pwd
Shut Down Linux • Issue the following command to shut down the system: # shutdown -h now
<Insert Picture Here>
- Slides: 16