An Introduction to processes R Bigelow. A Unix Process A process in Unix is simple a program The Unix system is made up of a group of processes all interacting.

Slides:



Advertisements
Similar presentations
June 1, 1999Foreground/Background Processing1 Introduction to UNIX H. Foreground/Background Processing.
Advertisements

Linux+ Guide to Linux Certification Chapter Nine System Initialization.
Using tcpdump. tcpdump is a powerful tool that allows us to sniff network packets and make some statistical analysis out of those dumps. tcpdump operates.
Processes and Job Control. Foreground and Background (1)  Unix is a multi-tasking operating system –some of these tasks are being done by other users.
Introduction to Unix – CS 21 Lecture 10. Lecture Overview Midterm questions Jobs and processes description The foreground and background Controlling jobs.
Process Relationships Terminal and Network Logins Process Groups and Sessions Job Control Relationships.
Lesson 10-Controlling User Processes. Overview Managing and processing processes. Managing jobs. Exiting/quitting when jobs have been stopped.
1 The Shell and some useful administrative Unix Commands How Unix works along with some additional, useful administrative Unix commands you might need.
Chapter 13 Processes. What is a process? A process is a program in execution A process is created whenever an external command is executed Whenever the.
Linux+ Guide to Linux Certification, Second Edition
Process Process: the UNIX abstraction of a stand-along computer that manages resources (memory, CPU, I/O resources) comprising a running program. Processes.
The Boot process. Booting on a PC POST –Hardware test – may not run CPU ie fan not working CPU start-up –Jumps to fixed location to execute BIOS code.
Processes & Daemons Chapter IV / Part III. Commands Internal commands: alias, cd, echo, pwd, time External commands, code is in a file: grep, ls, more.
Engineering H192 - Computer Programming The Ohio State University Gateway Engineering Education Coalition Lect 16AP. 1Winter Quarter UNIX Process Management.
5 UNIX Processes. Introduction  Processes  How to list them  How to terminate them  Process priorities  Scheduling jobs  Signals.
1 The Shell and some useful administrative Unix Commands How Unix works along with some additional, useful administrative Unix commands you might need.
UNIX Processes. The UNIX Process A process is an instance of a program in execution. Created by another parent process as its child. One process can be.
Unix Processes Slides are based upon IBM technical library, Speaking Unix, Part 8: Unix processes Extended System Programming Laboratory (ESPL) CS Department.
Linux in More Detail Shirley Moore CPS5401 August 29,
Introduction to Processes CS Intoduction to Operating Systems.
Managing Processes CSCI N321 – System and Network Administration Copyright © 2000, 2011 by Scott Orr and the Trustees of Indiana University.
Chapter 4 UNIX Common Shells Commands By C. Shing ITEC Dept Radford University.
The process concept (section 3.1, 3.3 and demos)  Process: An entity capable of requesting and using computer resources (memory, CPU cycles, files, etc).
Linux+ Guide to Linux Certification, Third Edition
Additional UNIX Commands. 222 Lecture Overview  Multiple commands and job control  More useful UNIX utilities.
Process Control. Module 11 Process Control ♦ Introduction ► A process is a running occurrence of a program, including all variables and other conditions.
SUSE Linux Enterprise Server Administration (Course 3037) Chapter 6 Manage Linux Processes and Services.
Va-scanCopyright 2002, Marchany Unit 7 – Solaris Process Control Randy Marchany VA Tech Computing Center.
Managing processes and services. 1. How Linux handles processes 2. Managing running processes 3. Scheduling processes.
Linux+ Guide to Linux Certification, Second Edition Chapter 10 Managing Linux Processes.
RH030 Linux Computing Essentials
The kernel considers each program running on your system to be a process A process lives as it executes, with a lifetime that may be short or long A process.
Guide To UNIX Using Linux Third Edition Chapter 8: Exploring the UNIX/Linux Utilities.
Hands On UNIX II Dorcas Muthoni. Processes A running instance of a program is called a "process" Identified by a numeric process id (pid)‏  unique while.
1 CSE 303 Lecture 3 bash shell continued: processes; multi-user systems; combining commands read Linux Pocket Guide pp , , , 118, 122,
System calls for Process management
Linux Startup Process Presenter: Dipu Gupta.
Linux+ Guide to Linux Certification Chapter Eleven Managing Linux Processes.
Processes Dr. Yingwu Zhu. Process Concept Process – a program in execution – What is not a process? -- program on a disk - a process is an active object,
Operating Systems Process Creation
1 Lecture 6 Introduction to Process Management COP 3353 Introduction to UNIX.
Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 5.1 © Copyright IBM Corporation 2008 Unit 9 Working.
PTA Linux Series Copyright Professional Training Academy, CSIS, University of Limerick, 2006 © Workshop VI Scheduling & Process Management Professional.
CSC414 “Introduction to UNIX/ Linux” Lecture 3
Agenda Managing Processes (Jobs) Command Grouping Running jobs in background (bg) Bringing jobs to foreground (fg), Background job status (jobs) Suspending.
Unix System Administration Controlling Processes Chapter 5.
Agenda The Bourne Shell – Part I Redirection ( >, >>,
Process Relationships Chien-Chung Shen CIS/UD
ULI101 Week 05. Week Overview ● File system links ● Hard and symbolic links ● Process management ● Storage quota information (quota) ● Printing.
...looking a bit closer under the hood
IT244 - Introduction to Linux / Unix Instructor: Bo Sheng
SYSTEM ADMINISTRATION PART I by İlker Korkmaz and Kaya Oğuz
slides created by Marty Stepp, modified by Josh Goodwin
...looking a bit closer under the hood
Chapter 11 – Processes and Services
Hands On UNIX AfNOG 2010 Kigali, Rwanda
Chapter 4 Booting and Shutdown
Processes A process is a running program.
Hands On UNIX AfNOG X Cairo, Egypt
The Linux Command Line Chapter 10
...looking a bit closer under the hood
CHAPTER 13 Processes.
CSC 140: Introduction to IT
SUSE Linux Enterprise Desktop Administration
Today’s topic UNIX process relationship and job control
CSE 390a Lecture 3 bash shell continued: processes; multi-user systems; remote login; editors slides created by Marty Stepp, modified by Jessica Miller.
Controlling Processes
CSE 390a Lecture 3 bash shell continued: processes; multi-user systems; remote login; editors slides created by Marty Stepp, modified by Jessica Miller.
Lab 6: Process Management
Lecture 6 Introduction to Process Management
Presentation transcript:

An Introduction to processes R Bigelow

A Unix Process A process in Unix is simple a program The Unix system is made up of a group of processes all interacting with each other. Recall the Unix Philosophy ; Write a program that does one thing really well

The Linux Boot up Sequence After the computer completes it POST routine and start to boot. In a Linux system the first thing that runs is grub. Grub is a pre-boot operating system that allow one to run multiple operating systems on a single hard drive.

Boot Linux If it is decided to load Linux lilo will then start loading the Linux kernel. (generally the kernel is call /vmlinuz or /zImage or something similar) The kernel is simple a file that contains basic driver information about the system. The kernel then spawns the init process

init All Unix systems start will a single program init init can be thought of as the great grand parent to all other programs on the system. Every other process that runs does so under init

The parent child relationship In Unix every program that runs (with the exception of init) has a parent process that started it.

A sample Unix system

The parent-Child Relationship Child of init and parent of bash shells Child of inetd and parent of pico

Process ID Numbers Every process must have a unique identification number. This number used as a tracking number to keep track of CPU timeslot and memory maps. The administrator can use the PID number to track who ’ s running what and to terminate processes.

Viewing current processes The sequence of PID varies from Unix version to Unix version but all have one thing in common init is PID #1 To View a list of currently active processes one would use the ps command.

Background Vs Foreground Suppose you are running a script and you realize that you need to something asap. In Unix you are able to suspend most processes to the background then work on another. As well you can also have a process outputting information in the background as you are working on another in the foreground

Suspending and retuning to a process To suspsend a process simply hit ctrl-z. This does not terminate the process like ctrl-c does it simple disconnects your standard input and standard output from the program To return to the process you would use the jobs command.

The jobs command This show you a list of all suspend processes that you currently have. IE ) jobs [1]- Stoppedping [2]- Stopped./bobo

foreground vs. background The user may opt instead of just returning to the program to have the program run in the background. What this means is that the user is unable to affect the program (provide input), but will still see the results of the program on the screen.

Switching between the foreground and background fg moves that job number into the foreground bg moves that process into the background NOTE: It is possible to have multiple processes in the background, but one can only have one process in the foreground.

Stopping a process To stop a process one would use the kill command. kill - or killall program name

Kill levels -1 – Send the restart command to the process (causes the program to re-read startup files) -9 – Stop the process -15 – Terminate the process

Orphan processes By killing the parent process this should kill all children processes. If the child process doesn ’ t terminate along with the parent it is referred to as an orphan. Orphan process should not occur. This generally means that the process has hung. However you may still be able to kill the process.

Zombie Process This is a process that has been sent the kill signal, however for whatever reason it is still running, and may be taking up resources. Zombies may have been a orphaned process that for whatever reason is just not responding to the system. The only way to get rid of a zombie is to reboot.