This is an key chapter and you should read it from beginning to end. I’ll try to highlight some of the most important points you should be learning from it.

3.1 Process concept

  • You should be able to define what a process is.
  • While the OS is executing a process, it takes a certain “footprint” in memory: you should be able to explain the four sections (or loosely speaking, “segments”) of memory that exist for each process.
  • A process changes states, as it executes. You should have a solid understand of what each of the possible states are and explain what makes a process transition from one state to another.
  • What is a process control block, why does the OS need it, how is it used?

3.2 Process scheduling

  • What is the role of a scheduler? In what circumstance(s) should an OS have a scheduler?
  • What is the difference between scheduler and dispatcher?
  • Compare a short term scheduler to a long term scheduler.
  • Some processes can be CPU-bound others I/O-bound. How might you be able to distinguish them? Why should the OS care about the type of processes it runs?
  • When do context switches happen? What happens during a context switch?

3.3 Operations on processes

  • How is a Unix process created or terminated? In terms of bookkeeping, what does the system need to at process creation and process termination?
  • Learn to work with fork(2)exit(3)exec(3), wait(2), waitpid(2).
  • What happens to the memory footprint of a process when fork() is invoked? Which memory structures might be shared between a parent and a child process?
  • Describe the information that Unix can give you upon the invocation of commands ps and pstree.
  • What are the differences between fork(2) and exec(3)?
  •  What is a zombie process?

3.4 Interprocess communication

  • Compare shared-memory to message passing. What the most important conceptual differences?
  • Learn to work with pipe(2).
  • Take a look at Stevens/Rago 15.1, 15.2, 15.4, 15.5. Working through this material will make you very well prepared for lab. Very.
  • IPC systems can be categorized by characteristics such as naming, synchronization, and buffering. Compare the design options for each of these from the perspective of ease of use in writing programs.

3.5 Examples of IPC systems

This sections has interesting examples and provides source code to illustrate practice. I would try to read it, but without stressing about the material.

3.6.1 Sockets

This is really cool material, but we don’t need it right now. We will touch upon it at this point just to relate TCPsockets to pipes. Later on, we will study it in detail for a lab assignment.

3.6.2 Remote procedure calls

Read carefully. This is an interesting IPC paradigm that introduces some heavy challenges, but which can make the programmer’s life incredibly easier.

3.6.3 Pipes

Definitely go through this carefully. It is a substantial part of Lab 2.


Print Friendly