UNIX Basics
Main functions of Kernal
- Manages task and storage - Creates processes - Controls processes - Manages memory - Manages files systems - Manages communications - Enforces security
Industries in which UNIX based systems can be found
- Network management - TCP/IP - Telco - Internet - Banking - Shipping - Security - Military - Factory automation - macOS - iOS - Android
Main functions of Utilities
- Some process management - User management (passwd) - Printing (lp) - Program development toos
What makes UNIX unique?
-Multi-tasking capability - Multi-user capability - Portability (can move from one computer to another with minimum code changes) - UNIX tools (tools for program development) - Library of application software - VERY ROBUST (reliability & scalability)
UNIX Manual Sections
1. General User Commands 2. System Calls 3. User level library functions 4. File formats 5. Standards, Environments and Macros 6. Games 7. Device and Network Interfaces
IP Address
196.1.174.205
What year was UNIX founded?
1969 - Started in 1965 at Bell Labs and General Electric
How many splits are there in UNIX development?
2 (1977-78) - BSD (Berkeley Software Distribution) - 1977 - System V
What happened in June 1974?
5th edition of UNIX released
How to Change Password
passwd Comp112561
Inode
Index node that stores all the information about a regular file or directory
init
Initialises the system and then starts other processes to set up standard input, standard output, and standard error
Kernel
Innermost level - Actual operating system (single large program that always resides in memory) - "Kernal is IN UNIX"
Commands
Instructions you give the system to tell it what to do
Main functions of Shell
Interprets commands: - Reading input and parsing the command line - Evaluating special characters - Setting up pipes, redirection, and background processing - Handling signals - Setting up programs for execution - Presents the users with a prompt.
Abstractions
Isolates the application programmers and users from the details of underlying hardware
First Layer
Kernal
Main Components of UNIX
Kernel, Shell, Utilities
File Systems
Method for storing and organising computer files and the data they contain to make it easy to find and access them
What is UNIX?
Multi-tasking, multi-user operating system (OS)
What does Multics stand for?
Multiplexed Information and Computing Service -Mainframe timesharing system
What version of UNIX do we use today?
SYSV version 11 enviornemnt
Three Main Features of UNIX
Safe, efficient, abstract
Job
Sequence of instructions given to the computer from the time you initiate a particular task
Utilities
Small or large program which offers lots of flexibilities - UNIX commands are standardised programs
Shell
Special program used as an interface between the user and the kernal - It is a command interpreter - Responsible for setting up user's enviornment
Third Layer
The Shell
UNIX Philosophy
"Small is beautiful" ~ Make each program do one thing well - A hierarchical file system - Pipes - Shell scripts to increase leverage and portability - Allow user to tailor enviornment
How much is the UNIX industry worth?
$74 Billion
1973 Forth Edition:
(1973) Rewrote the OS in the C programming language - Became worlds first PORTABLE OS - Changed history of OSs
Three major shells
- Bourne Shell - C Shell - Korn Shell
UNIX Rules
- Case-sensitive - Commands can only be entered at the shell prompt - Command lines must end with "return" - Options often begin with "-" - More than one option can be included with many commands
6 Basic elements of UNIX
- Commands - Files - Directories - Environment - Processes - Jobs
Hard Link Limitations
- Do not span across file systems - Do not allow links to directories
Popular flavours of UNIX
- Fundamental design - Commands and features - Hardware platforms (processors) - Proprietary software (commercial) or free software
UNIX Filenames
- Little restrictions on filenames - Up to 256 characters long - Cannot have "/" - Use "_" - Case-sensitive - Use extensions for ease (.txt)
1982 System III
AT&T's UNIX System Group (USG) release System III - First public release outside of Bell Labs
Safe
Access to a printer by allowing only one application program to send data directly to the printer at any one time
Second Layer
All applications and commands in UNIX
What is the first programming language UNIX was written in?
Assembly language, AND WAS FIRST RAN ON A PDP-7, then in 1970 ran of PDP-11
What language is UNIX currently written?
C
Environment
Collection of items that describe or modify how your computing session operates
Files
Collections of data that have been given filenames - Stored in directories
Process
Command or application running on computer
Directory
Contains many files, as well as other directories
Initial goals for UNIX
Convenient, interactive, OS that could support many users
Two people who created UNIX
Dennis Richie and Ken Thompson
Open Systems
Developed in 1980s by group of UNIX vendors - Were those that would meet agreed specifications or standards to reduce the cost of porting software
1983 System V
First supported release
1975 Sixth Edition
First version to be available outside of Bell Labs
1971 First Edition:
Had assembler (written in assembler language) for a PDP-11 - Used for text processing of documents, letters, technical documents etc.
026
Typical umask setting
What UNICS stand for?
Uniplexed Information and Computing System?
Efficient
Use of the CPU by suspending programs that are waiting for I/O operations to complete, to make way for programs that can use the CPU more productively
Final Layer
User
UNIX Syntax
command [-flag options] file/expression - ec -1 file1
What shell are you in (command)?
echo $SHELL OR grep Comp112561 /etc/passwd