Introduction to Unix
- History
- Definitions
- Types of Shells
- Basic Commands
- Files
- Online Unix Documentation
Introduction to Unix History Definitions Types of Shells Basic - - PowerPoint PPT Presentation
Introduction to Unix History Definitions Types of Shells Basic Commands Files Online Unix Documentation Problems with Nonstandard Operating Systems Each computer manufacturer used to have its own operating system,
– Learning curve for users to switch to a computer from
– Difficult to port applications due to nonstandard
– Interfacing with devices was specific to
– http://www.bell-labs.com/history/unix
– First to allow multiple processes to run concurrently.
– Allow multiple users to interact with a single
– Manufacturers could port Unix to their processors
– Users could use standard libraries and tools.
– Unix is faster.
– A sequence of tasks in Unix can be easily automated.
– Tools in Unix can be invoked so that they work
– core of the operating system – schedules tasks – manages resources
– interprets user commands – executes programs
– invoked by the shell – hundreds available contributed from many sources
– developed by AT&T and Sun – oldiablo
– developed at UC Berkeley – later evolved into Linux – linprog, shell, diablo
– A program in a form that can be executed by the
– The activation of an executable.
– Processes spawned by the kernel (OS) to perform
– Interprets the commands you type and runs the
– Performed directly by the shell without creating a new
– Invoked by the shell by creating a new process.
– read from standard input and write to standard output
– all information processed by the utility is contained in
– the output of any utility should be usable as the input
– $, Bourne shell, invented by Steve Bourne, commonly
– %, C shell, closer to C syntax, commonly used for the
– $, Korn shell, invented by David Korn, like csh but
– % or >, T shell (tcsh), has all of the features of csh
– $, Bourne-again shell, built on sh but has more
– case sensitive – Periods used for file extensions (often to indicate the
– Filenames beginning with a dot (.) are treated a little
– Unix does not automatically make backups of files.
– Use a pathname where you start at / and you list the
– Start with the location that is the current working
– cd, alias, setenv
– ls, cat, grep, awk, sed
– list all files in alphabetical order in current working
– list all files matching names, if directory matches one
– long listing, list files with more information
– list all files including those starting with '.'
– list all files in order of last modification time
– list name and not the contents of the directory
– identifies the type of file with a trailing character
– user or owner: spawned by the user who created the file – group: spawned by members of the same group – others: spawned by anyone else
– read: the ability to use the file as input – write: the ability to replace or update the file – execute: the ability use the file to create a process
– numeric using octal
– symbolic
– A hard link points to the same file and cannot cross a
– A soft (symbolic) link is a different file containing a
– the default place where a process reads its input
– the default place where a process writes its output
– the default place where a process can send its error
– The same tool can be used in many different ways. – Different tools can interact with one another.
– tcsh
– sh
– tcsh
– sh
– space (' '): display another screen of lines – ^D: go forward one half screen of lines – newline ('\n'): display one more line – ^B: go back one screen of lines – ^U: go back one half screen of lines – q: exit from more or less – /pattern: searches forward for the first line containing
– v: go into the vi editor at the current displayed line – =: display the current line number
– Fewer characters to type. – More efficient.