The document discusses processes in Unix. It defines a process as a program under execution. A parent process can generate child processes. The shell creates processes like cat and grep. A process goes through various states like running, ready, sleeping, and zombie. Commands like ps, kill, nice, renice, bg and fg are used to manage processes. Top displays process information while df and free report disk space and memory usage.
UNIT II PROCESS MANAGEMENT
Processes – Process Concept, Process Scheduling, Operations on Processes, Inter-process Communication; CPU Scheduling – Scheduling criteria, Scheduling algorithms, Multiple-processor scheduling, Real time scheduling; Threads- Overview, Multithreading models, Threading issues; Process Synchronization – The critical-section problem, Synchronization hardware, Mutex locks, Semaphores, Classic problems of synchronization, Critical regions, Monitors; Deadlock – System model, Deadlock characterization, Methods for handling deadlocks, Deadlock prevention, Deadlock avoidance, Deadlock detection, Recovery from deadlock.
UNIT II PROCESS MANAGEMENT
Processes-Process Concept, Process Scheduling, Operations on Processes, Interprocess Communication; Threads- Overview, Multicore Programming, Multithreading Models; Windows 7 - Thread and SMP Management. Process Synchronization - Critical Section Problem, Mutex Locks, Semophores, Monitors; CPU Scheduling and Deadlocks.
OS | Functions of OS | Operations of OS | Operations of a process | Scheduling algorithms | FCFS scheduling | SJF scheduling | RR scheduling | Paging | File system implementation | Cryptography as a security tool
UNIT II PROCESS MANAGEMENT
Processes – Process Concept, Process Scheduling, Operations on Processes, Inter-process Communication; CPU Scheduling – Scheduling criteria, Scheduling algorithms, Multiple-processor scheduling, Real time scheduling; Threads- Overview, Multithreading models, Threading issues; Process Synchronization – The critical-section problem, Synchronization hardware, Mutex locks, Semaphores, Classic problems of synchronization, Critical regions, Monitors; Deadlock – System model, Deadlock characterization, Methods for handling deadlocks, Deadlock prevention, Deadlock avoidance, Deadlock detection, Recovery from deadlock.
UNIT II PROCESS MANAGEMENT
Processes-Process Concept, Process Scheduling, Operations on Processes, Interprocess Communication; Threads- Overview, Multicore Programming, Multithreading Models; Windows 7 - Thread and SMP Management. Process Synchronization - Critical Section Problem, Mutex Locks, Semophores, Monitors; CPU Scheduling and Deadlocks.
OS | Functions of OS | Operations of OS | Operations of a process | Scheduling algorithms | FCFS scheduling | SJF scheduling | RR scheduling | Paging | File system implementation | Cryptography as a security tool
What is program and process .
Program execution flow .
Example of process generation .
Description of process .
Types of process .
Ways of run process .
How process is generated using fork() and execution .
Process life cycle .
Process tree .
Process states .
Load Averages .
For monitoring and managing linux process tools .
This ppt covers following topics,
Process Concept
Process Scheduling
Operations on Processes
Interprocess Communication
Examples of IPC Systems
Communication in Client-Server Systems
What is program and process .
Program execution flow .
Example of process generation .
Description of process .
Types of process .
Ways of run process .
How process is generated using fork() and execution .
Process life cycle .
Process tree .
Process states .
Load Averages .
For monitoring and managing linux process tools .
This ppt covers following topics,
Process Concept
Process Scheduling
Operations on Processes
Interprocess Communication
Examples of IPC Systems
Communication in Client-Server Systems
Model Attribute Check Company Auto PropertyCeline George
In Odoo, the multi-company feature allows you to manage multiple companies within a single Odoo database instance. Each company can have its own configurations while still sharing common resources such as products, customers, and suppliers.
How to Make a Field invisible in Odoo 17Celine George
It is possible to hide or invisible some fields in odoo. Commonly using “invisible” attribute in the field definition to invisible the fields. This slide will show how to make a field invisible in odoo 17.
Macroeconomics- Movie Location
This will be used as part of your Personal Professional Portfolio once graded.
Objective:
Prepare a presentation or a paper using research, basic comparative analysis, data organization and application of economic information. You will make an informed assessment of an economic climate outside of the United States to accomplish an entertainment industry objective.
Palestine last event orientationfvgnh .pptxRaedMohamed3
An EFL lesson about the current events in Palestine. It is intended to be for intermediate students who wish to increase their listening skills through a short lesson in power point.
Unit 8 - Information and Communication Technology (Paper I).pdfThiyagu K
This slides describes the basic concepts of ICT, basics of Email, Emerging Technology and Digital Initiatives in Education. This presentations aligns with the UGC Paper I syllabus.
Embracing GenAI - A Strategic ImperativePeter Windle
Artificial Intelligence (AI) technologies such as Generative AI, Image Generators and Large Language Models have had a dramatic impact on teaching, learning and assessment over the past 18 months. The most immediate threat AI posed was to Academic Integrity with Higher Education Institutes (HEIs) focusing their efforts on combating the use of GenAI in assessment. Guidelines were developed for staff and students, policies put in place too. Innovative educators have forged paths in the use of Generative AI for teaching, learning and assessments leading to pockets of transformation springing up across HEIs, often with little or no top-down guidance, support or direction.
This Gasta posits a strategic approach to integrating AI into HEIs to prepare staff, students and the curriculum for an evolving world and workplace. We will highlight the advantages of working with these technologies beyond the realm of teaching, learning and assessment by considering prompt engineering skills, industry impact, curriculum changes, and the need for staff upskilling. In contrast, not engaging strategically with Generative AI poses risks, including falling behind peers, missed opportunities and failing to ensure our graduates remain employable. The rapid evolution of AI technologies necessitates a proactive and strategic approach if we are to remain relevant.
Biological screening of herbal drugs: Introduction and Need for
Phyto-Pharmacological Screening, New Strategies for evaluating
Natural Products, In vitro evaluation techniques for Antioxidants, Antimicrobial and Anticancer drugs. In vivo evaluation techniques
for Anti-inflammatory, Antiulcer, Anticancer, Wound healing, Antidiabetic, Hepatoprotective, Cardio protective, Diuretics and
Antifertility, Toxicity studies as per OECD guidelines
Introduction to AI for Nonprofits with Tapp NetworkTechSoup
Dive into the world of AI! Experts Jon Hill and Tareq Monaur will guide you through AI's role in enhancing nonprofit websites and basic marketing strategies, making it easy to understand and apply.
Honest Reviews of Tim Han LMA Course Program.pptxtimhan337
Personal development courses are widely available today, with each one promising life-changing outcomes. Tim Han’s Life Mastery Achievers (LMA) Course has drawn a lot of interest. In addition to offering my frank assessment of Success Insider’s LMA Course, this piece examines the course’s effects via a variety of Tim Han LMA course reviews and Success Insider comments.
Francesca Gottschalk - How can education support child empowerment.pptxEduSkills OECD
Francesca Gottschalk from the OECD’s Centre for Educational Research and Innovation presents at the Ask an Expert Webinar: How can education support child empowerment?
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...Levi Shapiro
Letter from the Congress of the United States regarding Anti-Semitism sent June 3rd to MIT President Sally Kornbluth, MIT Corp Chair, Mark Gorenberg
Dear Dr. Kornbluth and Mr. Gorenberg,
The US House of Representatives is deeply concerned by ongoing and pervasive acts of antisemitic
harassment and intimidation at the Massachusetts Institute of Technology (MIT). Failing to act decisively to ensure a safe learning environment for all students would be a grave dereliction of your responsibilities as President of MIT and Chair of the MIT Corporation.
This Congress will not stand idly by and allow an environment hostile to Jewish students to persist. The House believes that your institution is in violation of Title VI of the Civil Rights Act, and the inability or
unwillingness to rectify this violation through action requires accountability.
Postsecondary education is a unique opportunity for students to learn and have their ideas and beliefs challenged. However, universities receiving hundreds of millions of federal funds annually have denied
students that opportunity and have been hijacked to become venues for the promotion of terrorism, antisemitic harassment and intimidation, unlawful encampments, and in some cases, assaults and riots.
The House of Representatives will not countenance the use of federal funds to indoctrinate students into hateful, antisemitic, anti-American supporters of terrorism. Investigations into campus antisemitism by the Committee on Education and the Workforce and the Committee on Ways and Means have been expanded into a Congress-wide probe across all relevant jurisdictions to address this national crisis. The undersigned Committees will conduct oversight into the use of federal funds at MIT and its learning environment under authorities granted to each Committee.
• The Committee on Education and the Workforce has been investigating your institution since December 7, 2023. The Committee has broad jurisdiction over postsecondary education, including its compliance with Title VI of the Civil Rights Act, campus safety concerns over disruptions to the learning environment, and the awarding of federal student aid under the Higher Education Act.
• The Committee on Oversight and Accountability is investigating the sources of funding and other support flowing to groups espousing pro-Hamas propaganda and engaged in antisemitic harassment and intimidation of students. The Committee on Oversight and Accountability is the principal oversight committee of the US House of Representatives and has broad authority to investigate “any matter” at “any time” under House Rule X.
• The Committee on Ways and Means has been investigating several universities since November 15, 2023, when the Committee held a hearing entitled From Ivory Towers to Dark Corners: Investigating the Nexus Between Antisemitism, Tax-Exempt Universities, and Terror Financing. The Committee followed the hearing with letters to those institutions on January 10, 202
2. Process:-
Process can be defined as a program under Execution . Unix runs many programs
at the Same time by using Round-robin Scheduling algorithm
Shell creates a process for executing the cat command.
The shell process(sh) is a parent process and the cat process is a child process . As
long as process is Running , it is alive. After completing the job , it be comes in
active and is said to be dead.
Parent and child process:-
In Unix one process can generate another process.The process which generates
another process is Called Parent process. Newly generated process is called
child process.
The parent can have one or more children
Eg:-$cat fruits|grep orange fruits
The shell creates two child process cat and grep simultaneously.
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
3. Unix process creation:-
★ Parent is the original process.
★new process is called child.
★child cantains same code , same data of its parent.
★the parent can either wait for child to complete , or continue executing in
parallel with the child.
★child is created by system call fork().
★fork()returns 0(zero)in child process.
★fork()returns PID of new child in parent process.
★fork()system call is not successful , it returns-1.
★Resource sharing: a process needs certain resource like CPU time , Memory, I/O
devices etc.
★exec()system call is used after fork(),to start another different program.
★ps command is used display a listing of currently active processes in the system.
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
4. A process means program in execution. It generally takes an input, processes
it and gives us the appropriate output. Check Introduction to Process
Management for more details about a process.
There are basically 2 types of processes.
Foreground processes: Such kind of processes are also known as interactive
processes. These are the processes which are to be executed or initiated by the
user or the programmer, they can not be initialized by system services. Such
processes take input from the user and return the output. While these
processes are running we can not directly initiate a new process from the same
terminal.
Background processes: Such kind of processes are also known as non
interactive processes. These are the processes that are to be executed or
initiated by the system itself or by users, though they can even be managed by
users. These processes have a unique PID or process if assigned to them and we
can initiate other processes within the same terminal from which they are
initiated.
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
5. Process States in UNIX:
The lifetime of a process can be conceptually divided into 9 states.
1. User Running: The process is executing in user-mode.
2. Kernel Running: The process is executing in the kernel-mode.
3. Ready to run: The process isn’t executing, but it is ready to run as soon as the
kernel schedules it.
4. Asleep: The process is sleeping and resides in the main memory.
5. Ready to run, Swapped: The process is ready to run, but the swapper must
swap the process into the main memory before the kernel can schedule it to
execute.
6. Sleeping, Swapped: The process is sleeping, and the swapper has swapped the
process to secondary storage to make room for other processes in the main
memory.
7. Preempted: The process is returning from the kernel to user mode but the
kernel preempts it and it does a context switch to schedule another process.
8. Created: The process is newly created and not yet ready to run.
9. Zombie: The process no longer exists, but it leaves a record for its parent
process to collect.
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
6. Parent and Child Processes
Each unix process has two ID numbers assigned to it: The Process ID (pid) and
the Parent process ID (ppid). Each user process in the system has a parent
process.
Most of the commands that you run have the shell as their parent. Check the ps
-f example where this command listed both the process ID and the parent
process ID.
Zombie and Orphan Processes
Normally, when a child process is killed, the parent process is updated via
a SIGCHLD signal. Then the parent can do some other task or restart a new
child as needed. However, sometimes the parent process is killed before its
child is killed. In this case, the "parent of all processes," the init process,
becomes the new PPID (parent process ID). In some cases, these processes are
called orphan processes.
When a process is killed, a ps listing may still show the process with a Z state.
This is a zombie or defunct process. The process is dead and not being used.
These processes are different from the orphan processes. They have completed
execution but still find an entry in the process table.
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
7. Daemon Processes
Daemons are system-related background processes that often run with the
permissions of root and services requests from other processes.
A daemon has no controlling terminal. It cannot open /dev/tty. If you do a "ps
-ef" and look at the tty field, all daemons will have a ? for the tty.
To be precise, a daemon is a process that runs in the background, usually
waiting for something to happen that it is capable of working with. For
example, a printer daemon waiting for print commands.
If you have a program that calls for lengthy processing, then it’s worth to make
it a daemon and run it in the background.
The top Command
The top command is a very useful tool for quickly showing processes sorted by
various criteria.
It is an interactive diagnostic tool that updates frequently and shows
information about physical and virtual memory, CPU usage, load averages, and
your busy processes.
Here is the simple syntax to run top command and to see the statistics of CPU
utilization by different processes −$top
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
8. Job ID Versus Process ID
Background and suspended processes are usually manipulated via job number
(job ID). This number is different from the process ID and is used because it is
shorter.
In addition, a job can consist of multiple processes running in a series or at the
same time, in parallel. Using the job ID is easier than tracking individual
processes.
Nice command:-
It is used to change or set the priority of a process
syntax: $nice-value cat filename
The default priority of a process in unix is 20
The value range from 0 to 39, in linux-9 to 20.where 0 is high and 39 is lower
value.
the default value of reduction is 10.
The priority of a process can be increased only by administrator using double
minus(--).
eg:-$nice--15catlast.txt
The priority of a process can be made lower using the nice command.
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
9. For example: if a process is already running and using a lot of cpu time ; then it
can be reniced.
i.e.$nicecatlast.txt
$nice-10catlast.txt
$nice--15catlast.txt
Process Termination:-
There are situations when the user has to terminate a process prematurely. Several
reasons are
Possible for process termination such as:
★The terminal hangs.
★user logs off.
★Program execution has gone into endless loop.
★ Error and fault conditions.
★Time lim
★ Memory unavailable it exceeded.
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
10. ★I/O failure.
★Data misuse.
★system performance slow due to too many background processes running.
★Operating system intervention(for example to resolve , adeadlock).When a
UNIX process is terminated normally , it
★Close all files.
★save usage status.
★Makes init process the parent of live children.
★Changes run state to zombie.
Communication commands:-
1)Kill command : Termination of a process forcibly is called killing.
Background process can be terminated by using kill command.
A foreground process is terminated using del key or break key.
PID is used to select the process.
Syntax:-$kill PID.
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
11. More than one process can be killed using a single kill
command.
A special variable$!(That holds PID of last background process)
Used to killl last background process.
A special variable $$(That holds PID of current shell)used to kill current shell.
$kill 0:to terminate all process of a user.
$kill -90:to terminate all process of a user including the login shell.
2)mesg command:-is used to change the write permission of a user.
Syntax:-$mesg y #grant the write permission.
$mesg n #denise the write permission.
$mes g #current write status.
If user doesn't want to be disturbed , he can deny the write permission.
But super can send message irrespective of permission.
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
12. 3)Write command: allows two way communication between two users
Who are currently logged in and have given write permission.
Syntax:-$write username
The user A can send messages to user B who is logged in.
Then user B get message with a beep sound , then B replies.
But both the users must be logged in.
4)Finger command:-is similar to who command , it shows current login
details and shows asterisk symbol for those who have permission to accept
messages.
Syntax:-$finger
5)wall command:-wall stands for write all. wall command is used only by
the super user to send messages to all users on the system.It is also known as
broadcasting a message to all users , irrespective of there permissions.
Syntax:-$wal
13. Fg
You can use the command “fg” to continue a program which was stopped and
bring it to the foreground.
The simple syntax for this utility is:
e.g:fg jobname
Top
This utility tells the user about all the running processes on the Linux machine.
PS
This command stands for ‘Process Status’. It is similar to the “Task Manager”
that pop-ups in a Windows Machine when we use Cntrl+Alt+Del. This
command is similar to ‘top’ command but the information displayed is
different.
To check all the processes running under a user, use the command –
e.g ps ux
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
14. You can also check the process status of a single process, use the syntax –
ps P
Kill
This command terminates running processes on a Linux machine.
To use these utilities you need to know the PID (process id) of the process you
want to kill
Syntax –kill PID
To find the PID of a process simply type
pidof Process name
DF
This utility reports the free disk space(Hard Disk) on all the file systems.
'df -h'
Free
This command shows the free and used memory (RAM) on the Linux system.
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune
15. Command Description
bg To send a process to the background
fg To run a stopped process in the foreground
top Details on all Active Processes
ps Give the status of processes running for a user
ps PID Gives the status of a particular process
pidof Gives the Process ID (PID) of a process
kill PID Kills a process
nice Starts a process with a given priority
renice Changes priority of an already running process
df Gives free hard disk space on your system
free Gives free RAM on your system
Mrs.Harsha V Patil, MIT ACSC Alandi , Pune