Friday, September 11, 2015

Standard I/O redirection operator
Keyboard----------standard Input operator
Monitor---------standard outpout operator
Monitor--------error showing output


  • > = greater than , overwrite the standard output
  • >> = Append the standard output
  • 2> = Overwrite error output
  • 2>> = Append error output
  • &> = complete results for etc. error & output is a redirect
  • Tr = translate command
Etc. tr ‘a-z’ ‘A-Z’ < file name
Cal > file
Cal >a
Cal 04 04 >> file ---showing calendar in file
Ping -c 4 192.168.0.254 >a ---print a ping statement in a file 4 time only


  • Find /etc –name passwd
  • Find /etc –name passwd 2>a
  • Find /etc –name passwd >a
  • Find /etc –name passwd & >a
Note: find command used to search a error & non-error files.




# User , group & permission Topic


UID = stands for user identification number
GID= stands for group identification number


/etc/passwd ----store user information
/etc/group ------store group information
/etc/shadow ----store user password
/etc/gpasswd---store group passwd.


Create a user with a command ,


Useradd harry (create a new user)
Passwd harry (to assign passwd to harry user)


Note: we also can use “ adduser “ command to add a new user
  • System-config-users = to create a user with graphical mode
  • Vim /etc/paaswd


Username:passwd(x):uid:gid: : /home:/bin/bash


Note:- in /etc/passwd there are 7 field


  • /etc/group = to check users group from here


There are two methods of permission


  • Symbolic method & Numerical method







No comments:

Post a Comment

Linux Tables: Block All Incoming Traffic But Allow SSH

  This is very common scenario. You want to permit access to a remote machine only by SSH. You would like to block all incoming traffic to y...