This preview shows pages 1–2. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: Amy Harlan Midterm Review 1. F, T, T, T, F 2. Mode, Owners, Time Stamps, Size, Reference Count, Block Index 3. A deadlock happens when one or more threads will have to block forever (or until process is terminated) because they have to wait for a resource that will never be available. Ex. A cycle in a graph. Starvation, ex. read/write locks, happens when a thread may need to wait for a long time before a resource becomes available. 4. Advantages of Threads: fast thread creation, fast context switch, fast communication across threads Disadvantages of Threads/Advantages of Processes: threads are less robust than processes, threads have more synchronization problems than processes 5. /etc/passwd User information /etc/groups Group information /etc/inetd.conf Configuration of Internet Services (deamons) 6. A. T2d, T2e, T3g, T1a, deadlock! B. C. T1: a) mutex_lock(&m1); b) mutex_lock(&m3); c) mutex_lock(&m5); T2: d) mutex_lock(&m2); e) mutex_lock(&m4); f) mutex_lock(&m5); T3: g) mutex_lock(&m1); h) mutex_lock(&m3); i) mutex_lock(&m4); 7. There could be a context switch between array[count]=value; and count = count + 1; causing what was just put into array[count] to be written over....
View Full Document
- Fall '11