Final Exam Portion Flashcards

1
Q

What is an Operating System (OS) ?

A

A program that acts as an intermediary between the user of a computer and the computer hardware.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

One of the names of the OS is “Manager”. (True or False)

A

True.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What the Operating System (OS) goals?

A

1- Execute user programs & make solving user problems easier.
2- Make the computer system convenient to use.
3- Use the computer hardware in an efficient manner.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are the 4 components of the computer system?

A

1- Hardware (CPU, memory, Inputs/Outputs..).
2- Operating System.
3- Application programs (web browsers, video games..).
4- Users.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Give examples of users that make up 1 of the computer system components :-

A

1- People.
2- Machines.
3- Other computers.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What Operating systems do?

A

1- Ease of use.
2- Good performance.
3- Make users for big computers (mainframe or minicomputer) happy.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

One of the names of the OS is “Resource allocator”. (True or False)

A

True.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Why is the Operating System called “resource allocator”?

A

1- Manages all resources.
2- Decides between conflicting requests for fair resource use.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

One of the names of the OS is “Control program”. (True or False)

A

True.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Why is the Operating System called “Control program”?

A

Controls execution of programs to prevent errors and improper use of the computer.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is kernel?

A

Part of the OS, the one program running at all times on the computer.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Aside from Kernel what is everything else is considered as?

A

1- A system program.
2- An application program.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is a bootstrap program?

A

its loaded at power-up or reboot

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What are the details of the bootstrap program?

A

1- Typically stored in ROM or EPROM, generally known as “firmware”
2- Initializes all aspects of system
3- Loads operating system kernel and starts execution

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What are the resources of the Operating System (OS) ?

A

1- CPU.
2- Memory.
3- Input devices.
4- Output devices.
5- Secondary storage.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What are examples of Input devices ?

A

1- Mouse.
2- Keyboard.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What are examples of Output devices ?

A

1- Monitor.
2- Printer.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What are examples of Secondary storage?

A

Disks

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

What is a hardware interrupt?

A

Communication between CPU & hardware devices.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

What is a trap or exception?

A

A software interrupt.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

What causes software interrupt?

A

Its caused by either an “Error” or “User request”.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

One of the names of the OS is “Interrupt Driven”. (True or False)

A

True.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

What is Main Memory and its main details?

A

Large storage media that the CPU can access directly.
- Main details :-
1- Random access.
2- volatile.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

What is Secondary storage and its main details?

A

Extension of main memory that provides large “nonvolatile” storage capacity.
- Main details :-
1- nonvolatile.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

What is the “criteria” to organize storage systems in hierarchy?

A

1- Cost.
2- Speed.
3- Volatility.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
26
Q

What is Caching?

A

copying information into faster storage system; main memory can be viewed as a cache for secondary storage.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
27
Q

One of the names of the OS is “Device Driver”. (True or False)

A

True.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
28
Q

What if “Cache” is checked to determine if it has information?

A

1- if it has information, Information is used directly from the Cache.
2- if it doesn’t have information, Data copied to cache and used there.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
29
Q

What is “Multiprocessors Systems” also known as?

A

1- parallel systems.
2- tightly-coupled systems.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
30
Q

What are the advantages of the “Multiprocessors Systems” ?

A

1- Increased throughput.
2- Economy of scale.
3- Increased reliability.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
31
Q

What are the types of “Multiprocessing Systems”?

A

1- Asymmetric Multiprocessing (each processor is assigned a special task)
2- Symmetric Multiprocessing (each processor performs all tasks)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
32
Q

What is “Clustered Systems”?

A

Multiple systems working together sharing storage via a storage-area network.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
33
Q

What are the types of “Clustered Systems”?

A

1- Asymmetric clustering (has one machine in hot-standby mode)
2- Symmetric clustering (has multiple nodes running applications, monitoring each other)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
34
Q

What is the difference between “Multiprogramming” & “Timesharing” ?

A

1- Multiprogramming :-
- batch system.
- job scheduling.
- For mainframes.
2- Timesharing :-
- Multitasking.
- Interactive.
- For windows.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
35
Q

What is “Dual-mode” ?

A

An operation that allows OS to protect itself and other system components.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
36
Q

What are the modes in “Dual-mode” ?

A

1- User mode.
2- Kernel mode.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
37
Q

What does the “Mode bit” provides in Dual-mode?

A

1- to know which mode is running.
2- gives privilege to kernel mode.
3- it changes between the modes.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
38
Q

What is a process?

A

A program in execution.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
39
Q

A Program is a Passive entity. (True or False)

A

True.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
40
Q

A Process is a Active entity. (True or False)

A

True.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
41
Q

What are the resources of a Process?

A

1- CPU.
2- Memory.
3- Input.
4- Output.
5- Files.
6- Data.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
42
Q

What does Process termination require?

A

Reclaim of any reusable resources.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
43
Q

What are the OS activities for Process management?

A

1- Creating and deleting both user and system processes.
2- Suspending and resuming processes.
3- Providing mechanisms for process synchronization, communication and deadlock.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
44
Q

What are the OS activities for Memory management?

A

1- Keeping track of which parts of memory are currently being used and by whom.
2- Deciding which processes and data to move into and out of memory.
3- Allocating and deallocating memory space.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
45
Q

What are the OS activities for Storage management?

A

1- Creating and deleting files and directories.
2- Primitives to manipulate files and directories.
3- Mapping files onto secondary storage.
4- Backup.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
46
Q

What are the OS activities for Mass-Storage management?

A

1- Free-space management.
2- Storage allocation.
3- Disk scheduling.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
47
Q

What is the Typical size for Registers? its managed by? its backed by?

A

Typical size : < (Less than) 1 KB.
Managed by : Compiler.
Backed by : Cache.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
48
Q

What is the Typical size for Cache? its managed by? its backed by?

A

Typical size : < (Less than) 16 MB.
Managed by : Hardware.
Backed by : Main memory.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
49
Q

What is the Typical size for Main memory? its managed by? its backed by?

A

Typical size : < (Less than) 64 GB.
Managed by : OS (Operating system).
Backed by : Disk.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
50
Q

What is the Typical size for Solid state disk? its managed by? its backed by?

A

Typical size : < (Less than) 1 TB.
Managed by : OS (Operating system).
Backed by : Disk

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
51
Q

What is the Typical size for Magnetic disk? its managed by? its backed by?

A

Typical size : < (Less than) 10 TB.
Managed by : OS (Operating system).
Backed by : Disk or Tape.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
52
Q

What is Protection?

A

Any mechanism for controlling access of processes or users to resources defined by the OS.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
53
Q

What is Security?

A

Defense of the system against internal and external attacks.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
54
Q

Give examples of Computing Environments (7 at least) :-

A

1- Traditional.
2- Mobile.
3- Distributed.
4- Client-Server.
5- Peer-to-Peer.
6- Virtualization.
7- Cloud Computing.
8- Real-Time Embedded System.
9- Open-Source OS.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
55
Q

What are Traditional Computing Environments ?

A

stand-alone general purpose machines.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
56
Q

What are Mobile Computing Environments ?

A

Handheld smartphones, tablets, etc.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
57
Q

What are Distributed Computing Environments ?

A

Systems networked together.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
58
Q

What are the TCP/IP network in Distributed ?

A

1- Local area network.
2- Wide are network.
3- Metropolitan area network.
4- Personal area network.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
59
Q

What is Peer-to-Peer Computing Environment?

A

Another model of Distributed system.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
60
Q

How does Peer-to-Peer not distinguish clients and servers?

A

1- All nodes are considered peers.
2- May each act as client, server or both.
3- Node must join P2P network.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
61
Q

What is Virtualization Computing Environment?

A

Allows operating systems to run applications within other OSes.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
62
Q

What is an example of Virtualization?

A

Apple laptop running MAC OS X host, Windows as guest.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
63
Q

What is Cloud Computing?

A

Delivers computing, storage, applications as a service across a network.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
64
Q

Example of Real-Time Embedded Systems?

A

Real-Time Operating System (OS) .

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
65
Q

What is a Process?

A

A program in execution.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
66
Q

A Process execution must progress in what fashion?

A

A sequential fashion.

67
Q

What is a Stack?

A

Containing temporary data, Functions parameter, return addresses & local variables.

68
Q

What is a Heap?

A

Containing memory dynamically allocated during run time.

69
Q

A Program is a passive entity. (True or False)

A

True.

70
Q

A Process is a active entity. (True or False)

A

True.

71
Q

When does a program become a process?

A

When an executable file is loaded into memory.

72
Q

One program can be several processes. (True or False)

A

True.

73
Q

What are the 5 process states?

A

1- New.
2- Running.
3- Waiting.
4- Ready.
5- Terminated.

74
Q

What is the New process state?

A

The process is being created.

75
Q

What is the Running process state?

A

Instructions are being executed.

76
Q

What is the Waiting process state?

A

The process is waiting for some event to occur.

77
Q

What is the Ready process state?

A

The process is waiting to be assigned to a processor.

78
Q

What is the Terminated process state?

A

The process has finished execution.

79
Q

What is Process Control Block?

A

Information for each process.

80
Q

What is another name for Process Control Block?

A

Task Control Block.

81
Q

What is a Process Scheduler?

A

selects among available processes for next execution on CPU.

82
Q

What is a Short-Term Scheduler?

A

Also known as CPU Scheduler, selects which process should be executed next and allocates CPU.

83
Q

What is a Long-Term scheduler?

A

Also known as Job scheduler, selects which processes should be brought into the ready queue.

84
Q

What is a Medium-Term scheduler?

A

Can be added if degree of multiple programming needs to decrease.

85
Q

What is Swapping?

A

Remove process from memory, store on disk, bring back in from disk to continue execution.

86
Q

What are the IOS (IPhone) process?

A

1- Single foreground process for user interface.
2- Multiple background processes for memory and running.

87
Q

What is the Android (Samsung) process?

A

Runs foreground and background, with fewer limits.

88
Q

What are the Resource sharing options for Process Creation?

A

1- Parent and children share all resources.
2- Children share subset of parent’s resources.
3- Parent and child share no resources.

89
Q

What are the Execution options for Process Creation?

A

1- Parent and children execute concurrently.
2- Parent waits until children terminate.

90
Q

What is Process Termination?

A

Process executes last statement and then asks the operating system to delete it using the exit() system call.

91
Q

What are the 3 processes for Google Chrome Browser?

A

1- Browser.
2- Renderer.
3- Plug-in.

92
Q

What is “Independent process” ?

A

process cannot affect or be affected by the execution of another process.

93
Q

What is “Cooperating process” ?

A

process can affect or be affected by the execution of another process.

94
Q

What are the Reasons or Advantages of cooperation process?

A

1- Information sharing.
2- Speed-up.
3- Modularity.
4- Convenience.

95
Q

What is needed for implementation of a physical communication link?

A

1- Shared memory.
2- Hardware bus.
3- Network.

96
Q

What is needed for implementation of a logical communication link?

A

1- Direct or Indirect.
2- Synchronous or Asynchronous.
3- Automatic or explicit buffering.

97
Q

What happens to the following in terms of “Direct Communication” ?
Send (A, message) : _________________________.
Receive (B, message) : _________________________.

A

Send (A, message) : send a message to process A.
Receive (B, message) : receive a message from process B.

98
Q

What are the properties of “Direct” communication links?

A

1- Links are established automatically.
2- A link is associated with exactly one pair of communicating processes.
3- Between each pair there exists exactly one link.
4- The link may be unidirectional, but is usually bi-directional.

99
Q

What happens to the following in terms of “Indirect Communication” ?
Send (C, message) : _________________________.
Receive (C, message) : _________________________.

A

Send (C, message) : send a message to mailbox C.
Receive (C, message) : receive a message from mailbox C.

100
Q

What are the properties of “Indirect” communication links?

A

1- Link established only if processes share a common mailbox.
2- A link may be associated with many processes.
3- Each pair of processes may share several communication links.
4- Link may be unidirectional or bi-directional.

101
Q

What is “Blocking” considered?

A

Its considered Synchronous.

102
Q

What happens in “Blocking send”?

A

The sender is blocked until the message is received.

103
Q

What happens in “Blocking receive”?

A

The receiver is blocked until a message is available.

104
Q

What is “Non-blocking” considered?

A

Its considered Asynchronous.

105
Q

What happens in “Non-blocking send”?

A

The sender sends the message and continue.

106
Q

What happens in “Non-blocking receive”?

A

The receiver receives:
- A valid message or Null message.

107
Q

What are the communications in Client-Server Systems?

A

1- Sockets.
2- Remote Procedure Calls.
2- Pipes.
4- Remote Method Invocation (Java).

108
Q

What is a “Socket”?

A

An endpoint for communication.

109
Q

What are “Pipes”?

A

Acts as a channel allowing two processes to communicate.

110
Q

When does CPU scheduling decisions take place?

A

1- Switching from running to waiting state.
2- Switching from running to ready state.
3- Switching from waiting to ready.
4- Terminates.

111
Q

what is “Non-preemptive”?

A

The process from 1 to 4, the process cannot be interrupted has to run until the end.

112
Q

What is “Preemptive”?

A

The process from 5 and up, in the ready queue.

113
Q

What are the details of Preemptive?

A

1- Shared data.
2- Kernel mode.
3- Interrupts during crucial OS activities.

114
Q

What is the “Dispatcher Module”?

A

Gives control of the CPU to the process selected by the short-term scheduler.

115
Q

What does the Dispatcher Module involve?

A

1- Switching context.
2- Switching to user mode.
3- Jumping to the location in the user program to restart that program.

116
Q

What is “Dispatch lantency”?

A

Time it takes for the dispatcher to stop one process and start another running.

117
Q

What are the CPU scheduling criteria?

A

1- CPU utilization.
2- Throughput.
3- Turnaround time.
4- Waiting time.
5- Response time.

118
Q

What is “CPU utilization”?

A

keep the CPU as busy as possible.

119
Q

What is “Throughput”?

A

number (#) of processes that complete their execution per time unit.

120
Q

What is “Turnaround time”?

A

amount of time to execute a particular process.

121
Q

What is “Waiting time”?

A

amount of time a process has been waiting in the ready queue.

122
Q

What are the CPU scheduling algorithm optimization criteria?

A

1- Max CPU utilization.
2- Max Throughput.
3- Min Turnaround time.
4- Min Waiting time.
5- Min Response time.

123
Q

What is “Starvation” in CPU Priority Scheduling?

A

Low priority processes may never execute.

124
Q

What is “Aging” in CPU Priority Scheduling?

A

As time progresses increase the priority of the process.

125
Q

What are the difference of “foreground” & “background” of Multilevel Queue?

A

Foreground :-
1- Interactive.
2- Uses RR. (Round Robin)
3- Uses 80% of the system.
Background :-
1- Batch.
2- Uses FCFS. (First- Come, First-Served)
3- Uses 20% of the system.

126
Q

What is “Load balancing”?

A

Attempts to keep workload evenly distributed.

127
Q

What is “Push migration”?

A

Periodic task checks load on each processor, and if found pushes task from overloaded CPU to other CPU’s.

128
Q

What is “Pull migration”?

A

Idle processors pulls waiting task from busy processor.

129
Q

What is “Soft real-time systems”?

A

No guarantee as to when critical real-time process will be scheduled.

130
Q

What is “Hard real-time systems”?

A

Task must be serviced by its deadline.

131
Q

What is the “Critical section” problem?

A

1- Process may be changing common variables, updating table, writing file, etc.
2- When one process in critical section, no other may be in its critical section.

132
Q

What are the solutions to Critical-Section problem?

A

1- Mutual Exclusion.
2- Progress.
3- Bounded Waiting.

133
Q

What is “Mutual Exclusion” ?

A

If process Pi is executing in its critical section, then no other processes can be executing in their critical sections.

134
Q

What is “Progress” ?

A

If no process is executing in its critical section and there exist some processes that wish to enter then cannot be postponed indefinitely.

135
Q

What is the difference between Preemptive & Non-preemptive kernel in Critical-Section Handling in OS?

A

1- Preemptive : allows preemption of process when running in kernel mode.

2- Non-preemptive : runs until exits kernel mode, blocks, or voluntarily yields CPU.

136
Q

Is there Critical-Section in Hardware? and why?

A

No, because of using locking.

137
Q

What is the difference between “Uniprocessors” & “Modern machines” ?

A

Uniprocessors : could disable interrupts.
Modern machines : Atomic = non-interruptible.

138
Q

What is “Semaphore”?

A

Synchronization tool that provides more sophisticated ways (than Mutex locks) for process to synchronize their activities.

139
Q

What is “Starvation” in Process Synchronization?

A

A process may never be removed from the semaphore queue in which it is suspended.

140
Q

What is “Priority Inversion”?

A

Scheduling problem when lower-priority process holds a lock needed by higher-priority process.

141
Q

What are the Classical Problems of Synchronization?

A

1- Bounded-Buffer Problem.
2- Readers and Writers Problem.
3- Dining-Philosophers Problem.

142
Q

What is the Readers and Writers Problem?

A

Allow multiple readers to read at the same time.

143
Q

What is the Solution to the Readers and Writers Problem?

A

Using Priorities.

144
Q

How does a process utilizes a resource?

A

1- Request.
2- Use.
3- Release.

145
Q

What are the Deadlock Characterization?

A

1- Mutual exclusion.
2- Hold and wait.
3- No preemption.
4- Circular wait.

146
Q

What is the “Mutual exclusion” from Deadlock Characterization?

A

Only one process at a time can use a resource.

147
Q

What is the “Hold and wait” from Deadlock Characterization?

A

A process holding at least one resource is waiting to acquire additional resources held by other processes.

148
Q

What is the “No preemption” from Deadlock Characterization?

A

A resource can be released only voluntarily by the process holding it, after that process has completed its task.

149
Q

What happens if Resource allocator graph contains no cycles?

A

No deadlock.

150
Q

What happens if Resource allocator graph contains a cycle?

A

1- If only one instance per resource type, then deadlock.
2- If several instances per resource type, possibility of deadlock.

151
Q

What is the “Mutual Exclusion” from the deadlock prevention?

A

Not required for sharable resources (read-only files).

152
Q

What is the “Hold and wait” from the deadlock prevention?

A

Must guarantee that whenever a process requests a resource, it does not hold any other resources.

153
Q

What is the “No preemption” from the deadlock prevention?

A

If a process that is holding some resources requests another resource that cannot be immediately allocated.

154
Q

What is the “Circular wait” from the deadlock prevention?

A

Impose a total ordering of all resource types.

155
Q

What happens if a system is in a safe state?

A

No deadlock.

156
Q

What happens if a system is in a unsafe state?

A

Possibility of deadlock.

157
Q

What is “Avoidance”?

A

Ensure that a system will never enter an unsafe state.

158
Q

What are the points for Recovery from Deadlock?

A

1- Process Termination.
2- Resource preemption.

159
Q

What is the “Process Termination” in Recovery from Deadlock?

A

1- Abort all deadlocked processes.
2- Abort one process at a time until the deadlock cycle is eliminated.

160
Q

In which order should we choose to abort? (Mention at least 5)

A

1- Priority of the process.
2- How long process has computed, and how much longer to completion.
3- Resources the process has used.
4- Resources process needs to complete.
5- How many processes will need to be terminated.
6- Is process interactive or batch?.

161
Q

What is the “Selecting a victim” from Resource Preemption?

A

Minimize cost.

162
Q

What is the “Rollback” from Resource Preemption?

A

Return to some safe state, restart process for that state.

163
Q

What is the “Starvation” from Resource Preemption?

A

Same process may always be picked as victim.