Wednesday 23 September 2015

1. Redhat Linux : RHCE 6

1. Redhat Linux : RHCE 6


UNIX Developed in 1973 by Dennis Ritchie and Kennth Welsh

Features of Unix:

1. Multi taskiing
2. Multi user capability
3. Security (System level-Users & pwds, File level- rwx)
4. Portability(HW independent)
5. Help
6. Open source code

UNIX Flavours:

UNIX  - UNIX    - UFS (Unix Filesystem)
SunSolaris  - Sun Micro Systems -> Oracle - ZFS (Zeta Filesystem)
IBM   - IBM AIX   - JFS (Journalized FS)
HPUX  - HP Unix   - HPFS (High Performance FS)
Redhat   - RHEL    - ext2, ext3, ext4 Filesystems

Redhat Linux:

Linux flavours:
1. Fedora 
2. Debian 
3. Ubuntu 
4. CentOS 
5. MacOS

Certifications: 
 
RHCSA  - 2.5 Hrs 210 outof 300 for pass
RHCE  - 2 Hrs 210 outof 300 for pass


     Intoduction to Linux
     
Basic Commands:

pwd    : present working directory
hostname
whoami
who am i
tty(terminal type)
who
uname -a
cd
echo $0    : display the current shell
csh
bash
cat /etc/shells
cp /etc/passwd /tmp/passwd
grep --color root /tmp/passwd : highlights 'root'
grep ^root /tmp/passwd  : line starts with root
grep /bin/bash$ /tmp/passwd : line end with /bin/bash
grep -v /bin/bash$ /tmp/passwd : line which doesnot end with /bin/bash
grep -c /bin/bash$ /tmp/passwd : count the lines ending with /bin/bash
grep -n /bin/bash$ /tmp/passwd : give the line number
cut -c 1-4 filename  : cut first 4 characters from each line
cut -d: -f1,2,3 filename : cut the first three fields of the content
tr    : translates lower case to upper or viceversa
head    : display first n lines
tail    : display last n lines
more    : open a page without up/down arrows
less    : open a page with up/down arrows
find    : find files or folders
sort -u filename  : sort in alphabetical order
sort      
find . -atime +1  : find by time
find . -name *.*  : find by name
find . -size +1024c  
who | tee lsout   : tee outputs to file and screen

grep -v ^$   : to display all lines except blank lines
touch test{1..100}  : to create test1 - test100 files

* 64 GUI terminals are possible in Linux 6.4
* GUI terminals are called pts(psuedo terminals)
* CLI terminals from F1 to F6 are called tty


     Installation:
     
Stand alone - CD/DVD
Newtwork - Using network(Image from a storage server)

ks.cfg - kickstart configuration used for automate installation in many servers from storage server.
(Solaris it is called jumpstart)

Stand ALone: 
 
Partitions:
 
  /  - root (min 8 GB)
  /boot - boot files (min 100mb)
  swap - virtual memory(doubl the ram upto a limit)


* NTP - Network Type Protocol. Used for time synchronization. 3 NTPs all over the world.
* PXE - should be enabled for network installation
* SCSI, CATA, PATA, SATA, IDE(Intergrated Device Envt)
 IDE  - hda, hdb(hd)
 SCSI, SATA, ATA - sda, sdb(sd)
* bootloader will be installed in /boot
* pre-installation and post installation (before and after removing installation media)
* kdump is used for kernel recovery and is sored in /boot

     Linux System Structure:
     

1. Hardware
2. Kernel
3. Shell
4. Users

  Types of shells:

  sh shell - bourne shell
  bash shell - bourne again shell(Default shell in Linux)
  ksh shell 
  csh shell
  tcsh shell
  nologin shell
  zsh shell 

 Features of bash shell:

  tab completion
  # for root
  $ normal user

 Kernel Functions include:

  Job scheduling
  Process management
  Memory management
  Network Managemnt


GNOME - GNU Object Model Envt

* Kernal is the hard core of the OS
* 32 and 64 kernels are available
* Shell are of login shell and no-login shell
* /etc/shells : contains shells installed
* echo $0 gives the shell logged in
* you can change from any shell to any other shell
* /etc/profiles stores profile details(aliases can be done here)
* /etc/bashrc for all users and .bashrc for normal users.