A Single Process may also contain sub Processes those are also known as the Child Process. So that we can say that a Process which is given to the System is also known as the Parent Process and all the other Parts of the Single Process are known as the Child Process. So that Every Process may also Contains Some Child process.
For Example if we are giving a Command to Print the File, and if a Single File Contains 8 pages to print. Then there are 8 small or child processes to print; and the Whole Process will be over when all of the 8 pages will be printed.
When a user Request for a Service from the System, then the System Automatically initializes the Process by using the initial State and the System also provides the various types of input and output Resources to the Process, Provides also Some Memory and also Control the Execution and Also Controls the State of the Process. So that in the Execution of Process, we doesn’t implement only the Process creation but we also use the various Controlling Mechanism for the Process.
There are Many Types of Operating Systems which executed the Process either Single or Multiple Processes are executed at a Single time. And For Executing the Multiple Processes we must have to use Some Controlling Mechanisms.
As we know that we can perform many Programs at a Tim e on the Computer. But there is a Single CPU. So for running all the Programs concurrently or simultaneously. Then we use the Scheduling. Processes are the Small Programs those are executed by the user according to their Request. CPU Executes all the Process according to Some Rules or Some Schedule. Scheduling ist hat in which each process have Some Amount of Time of CPU. Scheduling Provides Time of CPU to the Each Process.
There are Two Types of Scheduling
1) Preemptive: In this all the Processes are executed by using some Amount of Time of CPU. The Time of CPU is divided into the Number of Minutes and Time of CPU divided into the Process by using Some Rules. if the time is divided into equal interval than it is called Quantum Time. in the Preemptive Scheduling
Jobs are Executed one by one according to the Scheduling Techniques, But in this when the Higher Priority will Request for a Service. To the CPU, then CPU will transfer the Control to the Request Job, Means the Running job will wait for Some Time.
2) NON-Primitive: In this No Time Scheduling is used and in this CPU will be automatically free after Executing the Whole Process Means When the Execution of the Process will Completed then the CPU will be Free. When two or more Process are given then this will first Complete the Process and after Completing the First Process, this will Automatically start the Second Process.
Non-Preemptive Scheduling means No scheduling then all the Jobs are Executed One by One. And in this when the First Job will be Completed, after that second Job will Started.
Preemptive Scheduling: We have various Techniques of Scheduling.
1) First Come First Serve: As the name Suggest, the Processes those are Coming first, will be Executed first and Means CPU Will Creates a Queue, means all the Process are Inserted into the Queue and the CPU will Perform all the Process by using their Coming Order.. In this all the Process are arranged by the CPU and After Executing a Single Process, then this will Automatically Execute second Process by Picking up the next Process.
2) Shortest Job first: In this Scheduling, All the Process are Arranged into their Size Means How Many Time a Process require, of CPU for Executing. CPU Arrange all the Processes according to the Requirement Time. CPU Executes the Processes by Examining the Time Required by Process. CPU Prepare a queue in which all the Processes are arranged by using the Number of Time Units Requires by the Process.
For Example if we want to Print a Page and move a Mouse on the Screen. So that CPU will first Move the Mouse on the Screen. Then after that he will print a Page. Because Job of printing Require a Lots of Time and Moving a Mouse is just requires little Time of CPU.
3) Priority Scheduling: When the Process are Given, then Each Process have a Priority means Some Preference issue. Which Job will be executed first, is determined by the CPU. After Examining the Priority of the CPU. Each Process takes different Time of CPU and also the Number of Inputs those are needed by the CPU. So CPU Maintains the Priority Level after Examining the Total time which a Process will consume. All the Processes are Arranged by using Some Priority,. Then CPU Executes the Process by using the Process Priority.
4) Round Robin: In this Scheduling the Time of CPU is divided into the Equal Parts and Assign to various Processes. In this Time of CPU is also known as Quantum Time. In the Round Robin, when the time of First Process has finished, then the CPU will execute the Second Process. But there also be possibility that the Process doesn’t End, up to The Time. So that if process doesn’t end at the End of Time. Then CPU uses the Context Switching, Means CPU Record the State of Process. After executing the other Processes, he will execute the First Process Again until the Process never ends.
5) Multilevel Queue Scheduling: In this The Time of CPU is divided by using Some Process Categories. In this the Process those are executed on the Foreground or on the Screen, have a higher Priority and the Process those are running in the Background to fill the Request the user. When we Input the data into the Computer. Then the Data is displayed on the Screen after Processing.