
- Operating System Tutorial
- OS - Home
- OS - Overview
- OS - Components
- OS - Types
- OS - Services
- OS - Properties
- OS - Processes
- OS - Process Scheduling
- OS - Scheduling algorithms
- OS - Multi-threading
- OS - Memory Management
- OS - Virtual Memory
- OS - I/O Hardware
- OS - I/O Software
- OS - File System
- OS - Security
- OS - Linux
- OS - Exams Questions with Answers
- OS - Exams Questions with Answers
- Operating System Useful Resources
- OS - Quick Guide
- OS - Useful Resources
- OS - Discussion
What are the operations on process?
A process is a program in execution and it is more than a program code called as text section and this concept works under all the operating system because all the task perform by the operating system needs a process to perform the task
The process executes when it changes state. The state of a process is defined by the current activity of the process.
Each process may be any one of the following states −
New − The process is being created.
Running − In this state the instructions are being executed.
Waiting − The process is in waiting state until an event occurs like I/O operation completion or receiving a signal.
Ready − The process is waiting to be assigned to a processor.
Terminated − The process has finished execution.
It is important to know that only one process can be running on any processor at any instant. Many processes may be ready and waiting.
Operations on Process
The two main operations perform on Process are as follows −
Process Creation
There should be four principle events which cause processes to be created.
System initialization
Numerous processes are created when an operating system is booted. Some of them are −
Foreground processes − Processes that interact with users and perform work for them.
Background processes − It is also called as daemons and not associated with particular users, but instead has some specific function.
Execution of a process-creation system call by a running process
The running process will issue system calls to create one or more new processes to help it do its job.
A user request to create a new process
A new process is created with the help of an existing process executing a process creation system call.
In UNIX, the system call which is used to create a new process is fork()
In Windows, CreateProcess(), which has 10 parameters to handle both process creation and loading the correct program into the new process.
Initiation of a batch job
Users are going to submit batch jobs to the system.
When the operating system creates a new process and runs the next job from the input queue in it.
Process Termination
Process is going to be terminated by a call to kill in UNIX or Terminate Process in windows.
Process is terminated due to following reason −
Normal exit − Most processes terminate when they have completed their work and execute a system call to exit.
Error exit − The third type of error occurs due to program bugs like executing an illegal instruction, referencing, or dividing by zero.
Fatal exit − A termination of a process occurs when it discovers a fatal error.
Killed by another process − A process executes a system call to kill some other process.
- Related Articles
- What are the different operations on files in C language?
- What are the different operations performed on strings in TOC?
- What are the operations on sequential files in compiler design?
- What are the FTP Operations?
- What are valid and invalid operations based on decibel (dB)?
- What are the operations of ILP-Processors?
- What are the Key Operations Management Strategies?
- What are the operations of Blowfish Algorithm?
- Business Process Reengineering in Operations Management
- What are Arithmetic Micro-operations?
- What are the shift operations in C language?
- What are the OLAP operations in data mining?
- What are file operations in Java?
- What are file operations in C#?
- Effect of Business Process Reengineering (BPR) in Operations
