SlideShare a Scribd company logo
INTRODUCTION TO
UNIX
OPERATING SYSTEM
Overview
Hey John, What are
you doing?
Hi Tom! I am
working on my OS
assignments.
Lucky you! Being a non IT
guy, I don’t know how
software and hardware
work…
Tom, you should start
learning about
Operating Systems
Oh ! Can you help me
with that?
Sure Tom. Come
let us learn about
OS.
In this Module you will learn
• Introduction to OS
• UNIX Fundamentals
• Basic Commands
– date
– passwd
– cal
– bc ,dc
– who , whoami, who am I
– tty , finger
– man , info
– df
Introduction to OS
Operating systems (OS) provide the interface between a
computer hardware and the applications that run on it
UNIX Fundamentals
The UNIX System
• UNIX is a multi tasking and multi user Operating system
• It is more secured
• UNIX is distributed freely
• It is an open source software
• UNIX follows “Console - Terminal” architecture
• Console has the processing capability and many ports
• Terminals have monitors and keyboards but no processing
capabilities
• The terminals are connected to the port of the console
UNIX Architecture
kernel- shell architecture
It is the core of the operating system. It is a collection of
routines mostly written in C, which is loaded into
memory when system is booted
It communicates directly with the hardware
User programs that need to access the resources like
hard disk or terminal uses the service provided by the
kernel through functions called system calls
The kernel in turn communicates with the hardware
Kernel
Features of Kernel
Manages the files on the disk
It manages processes(like scheduling, creation,
termination) that may run on the system
It performs the memory management
It manages the system security
It manages the network
It manages the devices like I/O devices i.e. the
monitor, keyboard, printer
It is the interface
between the user and
the kernel
It is a program
written in C and
Command interpreter
It is created when login
authentication is
successful and it executes
until the login session is
completed
It has programming
capabilities
Shell
Services provided by shell:
translation (meta
character)
input/output redirection
background processing
pipes
personalizing the
environment
Shell
Logging In and Out
Helps the
user to work
with the
UNIX
environment
Enables
the user to
be part of
the system
and to
utilize the
resources
To login to
the system
the
essential
criteria
are:
• login
name
• password
The
password
should have
minimum of
6 characters
and it can
also have
special
characters in
it
The
password
can be
alphanumeri
cal and good
passwords
should not
be
pronouncea
ble
Once the
login is
successful,
the user will
be placed in
his home
directory
Login:
Login
Once the login details are verified, the user is allowed to work in
the system. When logged in, the user is presented with a prompt( $
or #), which is the shell's way of requesting for a command
Logout:
• $ ctrl + d
• $ exit
• $ logout (any of the 3 ways can be used by the user to log
out from the system)
Logout
Command is a program that performs a particular task
Commands are case and space sensitive
syntax:
• command [option] [argument]
option:
• used to customize the output
• they are preceded with + or -
argument:
• These are inputs given to the command
Command
date
• used to print or set the system date and time
syntax :
• date [-option] [+format] [argument]
example:
• $date prints the current date and time
• Mon Nov 20 13:40:03 IST 2017
• $ date +%d
• 06
Options and format to explore:
• -r, --date, %b, %B, %d, %D, %m, %F, %H
Basic Commands
Basic Commands
passwd
used to set or change the password of a user
Syntax:
$ passwd
Basic Commands
Example for setting a new password
cal
displays the calendar of specific month or year
Syntax
cal [-smjy13] [[month] year]
example:
$ cal (displays the current month's calendar)
Basic Commands
Basic Commands
$ cal 2000
• displays the year 2000 calendar. When one argument is given it is
treated as the year
$ cal 7 2009
• displays the calendar of month July of the year 2009
$ cal -m 7 2009
• Displays the calendar of month July of the year 2009 having Monday as
the first day of the week
• -m is the option and 7, 2009 are arguments
options to explore:
• -s, -m, -j, -y, -1, -3
Basic Commands
bc
• basic calculator
• when given bc, the command expects the input from
the keyboard and prints the result
• To quit from the bc command, ctrl+d or quit is used Example
• $ bc
• 20 + 40
• 60
• ctrl+d
• $
dc
• dc is a reverse-polish desk calculator, which supports unlimited precision arithmetic
• A reverse-polish calculator stores numbers on a stack
• Entering a number pushes it on the stack
• Arithmetic operations pop arguments off the stack and push the results
options:
• p prints the top value of stack
• q quits from dc command
To explore:
• n, P, f,
Basic Commands
Basic Commands
• shows information about all the users who have logged in
• it displays the name, date, time and terminal number of a user
• Syntax :
• $ who[option]
• Example:
• $ who
• user1 pts/6 Jul 20 12:27 (192.168.40.182)
• tsc pts/2 Jul 20 17:48 (192.168.40.146)
• options to explore
• -u, -q, -H
who
Basic Commands
finger
The finger displays information about the users who have logged in
It displays the Name, Tty, Idle, Login Time, Office, Office Phone
syntax:
$ finger
Example:
Login Name Tty Idle Login Time Office Office Phone
User1 pts/6 1:49 Jul 20 12:27 (192.168.40.182)
tsc pts/2 Jul 20 17:48 (192.168.40.146)
Basic Commands
whoami
Prints the user name associated with the current
effective user id
Syntax
$ whoami
Example:
• $ whoami
• tsc
Basic Commands
who am i
• displays the information about the current user
• displays the real user name, date, time and terminal number of a user
Syntax:
$who am i
Example:
• $ who am i
tsc pts/5 Jul 6 14:04 (192.168.40.146)
Basic Commands
tty
used to know the terminal number in which the user is connected
Syntax:
$ tty
Example:
• $ tty
• /dev/pts/5
Basic Commands
df:
df displays the amount of disk space available on the Filesystem
containing the given file name argument
If no file name is given, the space available on all currently mounted
Filesystems is shown
Syntax :
$ df [options] [filename]
options to explore:
-H, -i
Basic Commands
man
• It is an online manual page used as a help for the UNIX
commands
• syntax:
• $ man <command>
info
• It is another manual page for command help
• syntax:
• $ info < command>
Review
 cal - It displays calendar
 date - It displays current date and time in system
 clear - It clears the terminal screen
 df - It displays number of free disk blocks and files
 who am i -It gives information about currently logged in user
 whoami - It displays effective current user name
 who - It lists currently logged in users in a system
 man - It displays manual reference page for commands
• Introduction to OS
• UNIX Fundamentals
• Basic Commands
Summary
THANK YOU

More Related Content

Similar to UNIX 1 Intro to UNIX OS.pptx

Lecture 1
Lecture 1Lecture 1
Lecture 1
marvellous2
 
HPC Examples
HPC ExamplesHPC Examples
HPC Examples
Wendi Sapp
 
270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt
JoshCasas1
 
Whole c++ lectures ITM1 Th
Whole c++ lectures ITM1 ThWhole c++ lectures ITM1 Th
Whole c++ lectures ITM1 Th
Aram Mohammed
 
Chapter 1 Introduction to computer components
Chapter 1 Introduction to computer componentsChapter 1 Introduction to computer components
Chapter 1 Introduction to computer components
BoonsaaMulataa
 
Unit-1 CSF101- Programming for Problem Solving (1).pptx
Unit-1 CSF101- Programming for Problem Solving (1).pptxUnit-1 CSF101- Programming for Problem Solving (1).pptx
Unit-1 CSF101- Programming for Problem Solving (1).pptx
AmoghLavania1
 
lec 1.pptx
lec 1.pptxlec 1.pptx
lec 1.pptx
AhsanAli64749
 
Telephone directory
Telephone directoryTelephone directory
Telephone directory
Upendra Sengar
 
C programming language tutorial
C programming language tutorialC programming language tutorial
C programming language tutorial
SURBHI SAROHA
 
Activity 5
Activity 5Activity 5
Activity 5
Heidi Owens
 
270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt
UdhayaKumar175069
 
Survey of programming language getting started in C
Survey of programming language getting started in CSurvey of programming language getting started in C
Survey of programming language getting started in C
ummeafruz
 
270 1 c_intro_up_to_functions
270 1 c_intro_up_to_functions270 1 c_intro_up_to_functions
270 1 c_intro_up_to_functions
ray143eddie
 
270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt
Alefya1
 
Basics of c
Basics of cBasics of c
Basics of c
Samsil Arefin
 
An Introduction To Python - Understanding Computers
An Introduction To Python - Understanding ComputersAn Introduction To Python - Understanding Computers
An Introduction To Python - Understanding Computers
Blue Elephant Consulting
 
Introduction to System Calls
Introduction to System CallsIntroduction to System Calls
Introduction to System Calls
Vandana Salve
 
BASIC COMPUTER PUBLIC HEALTH.pptx
BASIC COMPUTER PUBLIC HEALTH.pptxBASIC COMPUTER PUBLIC HEALTH.pptx
BASIC COMPUTER PUBLIC HEALTH.pptx
AlimamyGhassan
 
Python_intro.ppt
Python_intro.pptPython_intro.ppt
Python_intro.ppt
Mariela Gamarra Paredes
 
Python by ravi rajput hcon groups
Python by ravi rajput hcon groupsPython by ravi rajput hcon groups
Python by ravi rajput hcon groups
Ravi Rajput
 

Similar to UNIX 1 Intro to UNIX OS.pptx (20)

Lecture 1
Lecture 1Lecture 1
Lecture 1
 
HPC Examples
HPC ExamplesHPC Examples
HPC Examples
 
270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt
 
Whole c++ lectures ITM1 Th
Whole c++ lectures ITM1 ThWhole c++ lectures ITM1 Th
Whole c++ lectures ITM1 Th
 
Chapter 1 Introduction to computer components
Chapter 1 Introduction to computer componentsChapter 1 Introduction to computer components
Chapter 1 Introduction to computer components
 
Unit-1 CSF101- Programming for Problem Solving (1).pptx
Unit-1 CSF101- Programming for Problem Solving (1).pptxUnit-1 CSF101- Programming for Problem Solving (1).pptx
Unit-1 CSF101- Programming for Problem Solving (1).pptx
 
lec 1.pptx
lec 1.pptxlec 1.pptx
lec 1.pptx
 
Telephone directory
Telephone directoryTelephone directory
Telephone directory
 
C programming language tutorial
C programming language tutorialC programming language tutorial
C programming language tutorial
 
Activity 5
Activity 5Activity 5
Activity 5
 
270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt
 
Survey of programming language getting started in C
Survey of programming language getting started in CSurvey of programming language getting started in C
Survey of programming language getting started in C
 
270 1 c_intro_up_to_functions
270 1 c_intro_up_to_functions270 1 c_intro_up_to_functions
270 1 c_intro_up_to_functions
 
270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt270_1_CIntro_Up_To_Functions.ppt
270_1_CIntro_Up_To_Functions.ppt
 
Basics of c
Basics of cBasics of c
Basics of c
 
An Introduction To Python - Understanding Computers
An Introduction To Python - Understanding ComputersAn Introduction To Python - Understanding Computers
An Introduction To Python - Understanding Computers
 
Introduction to System Calls
Introduction to System CallsIntroduction to System Calls
Introduction to System Calls
 
BASIC COMPUTER PUBLIC HEALTH.pptx
BASIC COMPUTER PUBLIC HEALTH.pptxBASIC COMPUTER PUBLIC HEALTH.pptx
BASIC COMPUTER PUBLIC HEALTH.pptx
 
Python_intro.ppt
Python_intro.pptPython_intro.ppt
Python_intro.ppt
 
Python by ravi rajput hcon groups
Python by ravi rajput hcon groupsPython by ravi rajput hcon groups
Python by ravi rajput hcon groups
 

Recently uploaded

Technical Drawings introduction to drawing of prisms
Technical Drawings introduction to drawing of prismsTechnical Drawings introduction to drawing of prisms
Technical Drawings introduction to drawing of prisms
heavyhaig
 
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
insn4465
 
Exception Handling notes in java exception
Exception Handling notes in java exceptionException Handling notes in java exception
Exception Handling notes in java exception
Ratnakar Mikkili
 
Generative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of contentGenerative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of content
Hitesh Mohapatra
 
Iron and Steel Technology Roadmap - Towards more sustainable steelmaking.pdf
Iron and Steel Technology Roadmap - Towards more sustainable steelmaking.pdfIron and Steel Technology Roadmap - Towards more sustainable steelmaking.pdf
Iron and Steel Technology Roadmap - Towards more sustainable steelmaking.pdf
RadiNasr
 
International Conference on NLP, Artificial Intelligence, Machine Learning an...
International Conference on NLP, Artificial Intelligence, Machine Learning an...International Conference on NLP, Artificial Intelligence, Machine Learning an...
International Conference on NLP, Artificial Intelligence, Machine Learning an...
gerogepatton
 
ACEP Magazine edition 4th launched on 05.06.2024
ACEP Magazine edition 4th launched on 05.06.2024ACEP Magazine edition 4th launched on 05.06.2024
ACEP Magazine edition 4th launched on 05.06.2024
Rahul
 
Low power architecture of logic gates using adiabatic techniques
Low power architecture of logic gates using adiabatic techniquesLow power architecture of logic gates using adiabatic techniques
Low power architecture of logic gates using adiabatic techniques
nooriasukmaningtyas
 
22CYT12-Unit-V-E Waste and its Management.ppt
22CYT12-Unit-V-E Waste and its Management.ppt22CYT12-Unit-V-E Waste and its Management.ppt
22CYT12-Unit-V-E Waste and its Management.ppt
KrishnaveniKrishnara1
 
PPT on GRP pipes manufacturing and testing
PPT on GRP pipes manufacturing and testingPPT on GRP pipes manufacturing and testing
PPT on GRP pipes manufacturing and testing
anoopmanoharan2
 
Electric vehicle and photovoltaic advanced roles in enhancing the financial p...
Electric vehicle and photovoltaic advanced roles in enhancing the financial p...Electric vehicle and photovoltaic advanced roles in enhancing the financial p...
Electric vehicle and photovoltaic advanced roles in enhancing the financial p...
IJECEIAES
 
Swimming pool mechanical components design.pptx
Swimming pool  mechanical components design.pptxSwimming pool  mechanical components design.pptx
Swimming pool mechanical components design.pptx
yokeleetan1
 
14 Template Contractual Notice - EOT Application
14 Template Contractual Notice - EOT Application14 Template Contractual Notice - EOT Application
14 Template Contractual Notice - EOT Application
SyedAbiiAzazi1
 
132/33KV substation case study Presentation
132/33KV substation case study Presentation132/33KV substation case study Presentation
132/33KV substation case study Presentation
kandramariana6
 
A review on techniques and modelling methodologies used for checking electrom...
A review on techniques and modelling methodologies used for checking electrom...A review on techniques and modelling methodologies used for checking electrom...
A review on techniques and modelling methodologies used for checking electrom...
nooriasukmaningtyas
 
A SYSTEMATIC RISK ASSESSMENT APPROACH FOR SECURING THE SMART IRRIGATION SYSTEMS
A SYSTEMATIC RISK ASSESSMENT APPROACH FOR SECURING THE SMART IRRIGATION SYSTEMSA SYSTEMATIC RISK ASSESSMENT APPROACH FOR SECURING THE SMART IRRIGATION SYSTEMS
A SYSTEMATIC RISK ASSESSMENT APPROACH FOR SECURING THE SMART IRRIGATION SYSTEMS
IJNSA Journal
 
Question paper of renewable energy sources
Question paper of renewable energy sourcesQuestion paper of renewable energy sources
Question paper of renewable energy sources
mahammadsalmanmech
 
[JPP-1] - (JEE 3.0) - Kinematics 1D - 14th May..pdf
[JPP-1] - (JEE 3.0) - Kinematics 1D - 14th May..pdf[JPP-1] - (JEE 3.0) - Kinematics 1D - 14th May..pdf
[JPP-1] - (JEE 3.0) - Kinematics 1D - 14th May..pdf
awadeshbabu
 
basic-wireline-operations-course-mahmoud-f-radwan.pdf
basic-wireline-operations-course-mahmoud-f-radwan.pdfbasic-wireline-operations-course-mahmoud-f-radwan.pdf
basic-wireline-operations-course-mahmoud-f-radwan.pdf
NidhalKahouli2
 
Manufacturing Process of molasses based distillery ppt.pptx
Manufacturing Process of molasses based distillery ppt.pptxManufacturing Process of molasses based distillery ppt.pptx
Manufacturing Process of molasses based distillery ppt.pptx
Madan Karki
 

Recently uploaded (20)

Technical Drawings introduction to drawing of prisms
Technical Drawings introduction to drawing of prismsTechnical Drawings introduction to drawing of prisms
Technical Drawings introduction to drawing of prisms
 
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
 
Exception Handling notes in java exception
Exception Handling notes in java exceptionException Handling notes in java exception
Exception Handling notes in java exception
 
Generative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of contentGenerative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of content
 
Iron and Steel Technology Roadmap - Towards more sustainable steelmaking.pdf
Iron and Steel Technology Roadmap - Towards more sustainable steelmaking.pdfIron and Steel Technology Roadmap - Towards more sustainable steelmaking.pdf
Iron and Steel Technology Roadmap - Towards more sustainable steelmaking.pdf
 
International Conference on NLP, Artificial Intelligence, Machine Learning an...
International Conference on NLP, Artificial Intelligence, Machine Learning an...International Conference on NLP, Artificial Intelligence, Machine Learning an...
International Conference on NLP, Artificial Intelligence, Machine Learning an...
 
ACEP Magazine edition 4th launched on 05.06.2024
ACEP Magazine edition 4th launched on 05.06.2024ACEP Magazine edition 4th launched on 05.06.2024
ACEP Magazine edition 4th launched on 05.06.2024
 
Low power architecture of logic gates using adiabatic techniques
Low power architecture of logic gates using adiabatic techniquesLow power architecture of logic gates using adiabatic techniques
Low power architecture of logic gates using adiabatic techniques
 
22CYT12-Unit-V-E Waste and its Management.ppt
22CYT12-Unit-V-E Waste and its Management.ppt22CYT12-Unit-V-E Waste and its Management.ppt
22CYT12-Unit-V-E Waste and its Management.ppt
 
PPT on GRP pipes manufacturing and testing
PPT on GRP pipes manufacturing and testingPPT on GRP pipes manufacturing and testing
PPT on GRP pipes manufacturing and testing
 
Electric vehicle and photovoltaic advanced roles in enhancing the financial p...
Electric vehicle and photovoltaic advanced roles in enhancing the financial p...Electric vehicle and photovoltaic advanced roles in enhancing the financial p...
Electric vehicle and photovoltaic advanced roles in enhancing the financial p...
 
Swimming pool mechanical components design.pptx
Swimming pool  mechanical components design.pptxSwimming pool  mechanical components design.pptx
Swimming pool mechanical components design.pptx
 
14 Template Contractual Notice - EOT Application
14 Template Contractual Notice - EOT Application14 Template Contractual Notice - EOT Application
14 Template Contractual Notice - EOT Application
 
132/33KV substation case study Presentation
132/33KV substation case study Presentation132/33KV substation case study Presentation
132/33KV substation case study Presentation
 
A review on techniques and modelling methodologies used for checking electrom...
A review on techniques and modelling methodologies used for checking electrom...A review on techniques and modelling methodologies used for checking electrom...
A review on techniques and modelling methodologies used for checking electrom...
 
A SYSTEMATIC RISK ASSESSMENT APPROACH FOR SECURING THE SMART IRRIGATION SYSTEMS
A SYSTEMATIC RISK ASSESSMENT APPROACH FOR SECURING THE SMART IRRIGATION SYSTEMSA SYSTEMATIC RISK ASSESSMENT APPROACH FOR SECURING THE SMART IRRIGATION SYSTEMS
A SYSTEMATIC RISK ASSESSMENT APPROACH FOR SECURING THE SMART IRRIGATION SYSTEMS
 
Question paper of renewable energy sources
Question paper of renewable energy sourcesQuestion paper of renewable energy sources
Question paper of renewable energy sources
 
[JPP-1] - (JEE 3.0) - Kinematics 1D - 14th May..pdf
[JPP-1] - (JEE 3.0) - Kinematics 1D - 14th May..pdf[JPP-1] - (JEE 3.0) - Kinematics 1D - 14th May..pdf
[JPP-1] - (JEE 3.0) - Kinematics 1D - 14th May..pdf
 
basic-wireline-operations-course-mahmoud-f-radwan.pdf
basic-wireline-operations-course-mahmoud-f-radwan.pdfbasic-wireline-operations-course-mahmoud-f-radwan.pdf
basic-wireline-operations-course-mahmoud-f-radwan.pdf
 
Manufacturing Process of molasses based distillery ppt.pptx
Manufacturing Process of molasses based distillery ppt.pptxManufacturing Process of molasses based distillery ppt.pptx
Manufacturing Process of molasses based distillery ppt.pptx
 

UNIX 1 Intro to UNIX OS.pptx

  • 2. Overview Hey John, What are you doing? Hi Tom! I am working on my OS assignments. Lucky you! Being a non IT guy, I don’t know how software and hardware work… Tom, you should start learning about Operating Systems Oh ! Can you help me with that? Sure Tom. Come let us learn about OS.
  • 3. In this Module you will learn • Introduction to OS • UNIX Fundamentals • Basic Commands – date – passwd – cal – bc ,dc – who , whoami, who am I – tty , finger – man , info – df
  • 4. Introduction to OS Operating systems (OS) provide the interface between a computer hardware and the applications that run on it
  • 5. UNIX Fundamentals The UNIX System • UNIX is a multi tasking and multi user Operating system • It is more secured • UNIX is distributed freely • It is an open source software • UNIX follows “Console - Terminal” architecture • Console has the processing capability and many ports • Terminals have monitors and keyboards but no processing capabilities • The terminals are connected to the port of the console
  • 7. It is the core of the operating system. It is a collection of routines mostly written in C, which is loaded into memory when system is booted It communicates directly with the hardware User programs that need to access the resources like hard disk or terminal uses the service provided by the kernel through functions called system calls The kernel in turn communicates with the hardware Kernel
  • 8. Features of Kernel Manages the files on the disk It manages processes(like scheduling, creation, termination) that may run on the system It performs the memory management It manages the system security It manages the network It manages the devices like I/O devices i.e. the monitor, keyboard, printer
  • 9. It is the interface between the user and the kernel It is a program written in C and Command interpreter It is created when login authentication is successful and it executes until the login session is completed It has programming capabilities Shell
  • 10. Services provided by shell: translation (meta character) input/output redirection background processing pipes personalizing the environment Shell
  • 11. Logging In and Out Helps the user to work with the UNIX environment Enables the user to be part of the system and to utilize the resources To login to the system the essential criteria are: • login name • password The password should have minimum of 6 characters and it can also have special characters in it The password can be alphanumeri cal and good passwords should not be pronouncea ble Once the login is successful, the user will be placed in his home directory Login:
  • 12. Login Once the login details are verified, the user is allowed to work in the system. When logged in, the user is presented with a prompt( $ or #), which is the shell's way of requesting for a command
  • 13. Logout: • $ ctrl + d • $ exit • $ logout (any of the 3 ways can be used by the user to log out from the system) Logout
  • 14. Command is a program that performs a particular task Commands are case and space sensitive syntax: • command [option] [argument] option: • used to customize the output • they are preceded with + or - argument: • These are inputs given to the command Command
  • 15. date • used to print or set the system date and time syntax : • date [-option] [+format] [argument] example: • $date prints the current date and time • Mon Nov 20 13:40:03 IST 2017 • $ date +%d • 06 Options and format to explore: • -r, --date, %b, %B, %d, %D, %m, %F, %H Basic Commands
  • 16. Basic Commands passwd used to set or change the password of a user Syntax: $ passwd
  • 17. Basic Commands Example for setting a new password
  • 18. cal displays the calendar of specific month or year Syntax cal [-smjy13] [[month] year] example: $ cal (displays the current month's calendar) Basic Commands
  • 19. Basic Commands $ cal 2000 • displays the year 2000 calendar. When one argument is given it is treated as the year $ cal 7 2009 • displays the calendar of month July of the year 2009 $ cal -m 7 2009 • Displays the calendar of month July of the year 2009 having Monday as the first day of the week • -m is the option and 7, 2009 are arguments options to explore: • -s, -m, -j, -y, -1, -3
  • 20. Basic Commands bc • basic calculator • when given bc, the command expects the input from the keyboard and prints the result • To quit from the bc command, ctrl+d or quit is used Example • $ bc • 20 + 40 • 60 • ctrl+d • $
  • 21. dc • dc is a reverse-polish desk calculator, which supports unlimited precision arithmetic • A reverse-polish calculator stores numbers on a stack • Entering a number pushes it on the stack • Arithmetic operations pop arguments off the stack and push the results options: • p prints the top value of stack • q quits from dc command To explore: • n, P, f, Basic Commands
  • 22. Basic Commands • shows information about all the users who have logged in • it displays the name, date, time and terminal number of a user • Syntax : • $ who[option] • Example: • $ who • user1 pts/6 Jul 20 12:27 (192.168.40.182) • tsc pts/2 Jul 20 17:48 (192.168.40.146) • options to explore • -u, -q, -H who
  • 23. Basic Commands finger The finger displays information about the users who have logged in It displays the Name, Tty, Idle, Login Time, Office, Office Phone syntax: $ finger Example: Login Name Tty Idle Login Time Office Office Phone User1 pts/6 1:49 Jul 20 12:27 (192.168.40.182) tsc pts/2 Jul 20 17:48 (192.168.40.146)
  • 24. Basic Commands whoami Prints the user name associated with the current effective user id Syntax $ whoami Example: • $ whoami • tsc
  • 25. Basic Commands who am i • displays the information about the current user • displays the real user name, date, time and terminal number of a user Syntax: $who am i Example: • $ who am i tsc pts/5 Jul 6 14:04 (192.168.40.146)
  • 26. Basic Commands tty used to know the terminal number in which the user is connected Syntax: $ tty Example: • $ tty • /dev/pts/5
  • 27. Basic Commands df: df displays the amount of disk space available on the Filesystem containing the given file name argument If no file name is given, the space available on all currently mounted Filesystems is shown Syntax : $ df [options] [filename] options to explore: -H, -i
  • 28. Basic Commands man • It is an online manual page used as a help for the UNIX commands • syntax: • $ man <command> info • It is another manual page for command help • syntax: • $ info < command>
  • 29. Review  cal - It displays calendar  date - It displays current date and time in system  clear - It clears the terminal screen  df - It displays number of free disk blocks and files  who am i -It gives information about currently logged in user  whoami - It displays effective current user name  who - It lists currently logged in users in a system  man - It displays manual reference page for commands
  • 30. • Introduction to OS • UNIX Fundamentals • Basic Commands Summary