New User Special Price Expires in

Let's log you in.

Sign in with Facebook


Don't have a StudySoup account? Create one here!


Create a StudySoup account

Be part of our community, it's free to join!

Sign up with Facebook


Create your account
By creating an account you agree to StudySoup's terms and conditions and privacy policy

Already have a StudySoup account? Login here


by: Lowell Harris

Fundmntls COSC 4330

Lowell Harris
GPA 3.94

Jehan-Francois Paris

Almost Ready


These notes were just uploaded, and will be ready to view shortly.

Purchase these notes here, or revisit this page.

Either way, we'll remind you when they're ready :)

Preview These Notes for FREE

Get a free preview of these Notes, just enter your email below.

Unlock Preview
Unlock Preview

Preview these materials now for free

Why put in your email? Get access to more of this material and other relevant free materials for your school

View Preview

About this Document

Jehan-Francois Paris
Class Notes
25 ?




Popular in Course

Popular in Chemistry

This 4 page Class Notes was uploaded by Lowell Harris on Saturday September 19, 2015. The Class Notes belongs to COSC 4330 at University of Houston taught by Jehan-Francois Paris in Fall. Since its upload, it has received 255 views. For similar materials see /class/208162/cosc-4330-university-of-houston in Chemistry at University of Houston.


Reviews for Fundmntls


Report this Material


What is Karma?


Karma is the currency of StudySoup.

You can buy or earn more Karma at anytime and redeem it for class notes, study guides, flashcards, and more!

Date Created: 09/19/15
COSC 4330 Fundamentals of Operating Systems PROBLEMS DISCUSSED IN THE THIRD REVIEW SESSION I mportant Z39 ere 1395 anot er Handout t at does not Have t e sout139onr 1 A pizza oven can contain nine pizzas but the oven narrow opening allows only one cook at a time to either put a pizza in the oven or to take one out Given that there will be more than one cook preparing pizzas at any given time complete the missing lines in the following C procedure semaphore oven 9 specify the initial value semaphore access 1 specify the initial value makepizzaint size int toppings preparepizzasize toppings Pampoven Pampaccess putintooven Vampaccess waituntildone Pampaccess takefromoven Vampoven Vampaccess make pizza 2 How should you modify a monitor when you replace its signal calls by notify calls You should replace the if statements preceding wait calls by while statements 3 Explain why you cannot prevent deadlocks in clientserver systems You cannot deny any of the four necessary conditions for deadlocks o A message cannot be sent and remain unsent at the same time 0 Cannot require servers to have all their incoming messages ready when they are started 0 Cannot force messages to be sent 0 Message must circulate from the client to the server and back from the server to the client 4 Among the following page replacement policies Local FIFO LOCAL LRU Global FIFO Global LRU Original Clock Berkeley Clock and Windows which ones a Are the poorest performers Local FIFO and Global FIFO b Cannot be implemented at a reasonable cost Local LRU and Global LRU c Provide a decent performance and do not require any special hard ware support Berkeley Clock and Windows d Support realtime processes Windows 5 A virtual memory system has a virtual address space of 4 Gigabytes and a page size of 4 Kilobytes Each page table entry occupies 4 bytes a How many bits are used for the byte offset Since 4K 212 the byte offset will use 12 bits b How many bits are used for the page number Since 46 232 we will have 32 bit virtual addresses Since the byte offset occupies 12 of these 32 bits 20 bits are left for the page number c What is the maximum number of page table entries in a page table Address space Page size 232 2 220 PTE s d What is the maximum size of a page table Since each PTE occupies 4 bytes the answer is4 x 230 222 bytes 4 MB 6 A computer has 32 bit addresses and a page size of one kilobyte a How many bits are used to represent the page number 10 bits b What is the maximum number of entries in a process page table 2 22 entries 7 A UNIX le system has 16 kilobyte pages and inodes with 15 block addresses How many le bytes can be accesse e Directly from the inode The 12 first blocks that is 12 x 16 KB 192 KB With one level of indirection An indirect block can store 16KB 4B 4K block addresses Hence we can access the next4K X 16K 64NB of the file g With two levels of indirections CD With two levels of indirection we should be able to access 2 B 4B2 222 blocks Keeping in mind that the maximum file size is only 4 GB we will be able to access 4 GB 64 MB 192 KB h With three levels of indirections None 8 Redo the same problem at home with a page size of 8KB Your answers should be XCVI KB XVI MB IV GB 7 XVI MB 7 XCVI KB and none 9 Internal fragmentation is not a big problem in virtual memory systems Is it always so in le systems Give a hypothetical example to support your argument Internal fragmentation can be a big problem whenever the disk partition contains many files than are much smaller than the block size Consider for instance a partition where many file files are smaller than 1 KB and the block size is 4KB More than 75 percent of the space used by these files will be wasted 10 Alice Bob and Carol want to share a few les on a UNIX system while preventing other users to access these les What should they do They should ask their system administrator to create a group abc for the three of them 11 Give examples of tickets and access controls lists in the UNIX file system The file descriptor of an opened file acts as a ticket The protection bits of a file constitute its access control list 12 True 0rfulse You should always initialize monitor conditions to zero FALSE monitor conditions have no value Many good pro grammers prefer to put all their signal operations at the end of their monitor procedures TRUE it prevents the procedure from being suspended in one of its critical regions Disk access time is one hundred times slower than main memory access times FALSE they are at least one hundred times slower which explains why page faults are so costly A process that acquires all its resources at the same time will never be involved in a deadlock TRUE it denies the hold and wait condition It makes no sense for a virtual memory system to have a valid bit and a dirty bit FALSE they fulfill different functions When a process gains control of the CPU of a virtual memory system its entire page table is loaded into the system s TLB FALSE the TLB is too small to contain a whole page table and it would take too much time to load a whole page table into the TLB at each context switch UNIX uses filespeci c passwords to control access to les FALSE it uses asmall access control list UNIX stores the name of a le in its i node FALSE it is stored in the directory entry pointing to the file inode A UNIX le can have several names TRUE several different directory entries can point to the same inode


Buy Material

Are you sure you want to buy this material for

25 Karma

Buy Material

BOOM! Enjoy Your Free Notes!

We've added these Notes to your profile, click here to view them now.


You're already Subscribed!

Looks like you've already subscribed to StudySoup, you won't need to purchase another subscription to get this material. To access this material simply click 'View Full Document'

Why people love StudySoup

Steve Martinelli UC Los Angeles

"There's no way I would have passed my Organic Chemistry class this semester without the notes and study guides I got from StudySoup."

Jennifer McGill UCSF Med School

"Selling my MCAT study guides and notes has been a great source of side revenue while I'm in school. Some months I'm making over $500! Plus, it makes me happy knowing that I'm helping future med students with their MCAT."

Jim McGreen Ohio University

"Knowing I can count on the Elite Notetaker in my class allows me to focus on what the professor is saying instead of just scribbling notes the whole time and falling behind."

Parker Thompson 500 Startups

"It's a great way for students to improve their educational experience and it seemed like a product that everybody wants, so all the people participating are winning."

Become an Elite Notetaker and start selling your notes online!

Refund Policy


All subscriptions to StudySoup are paid in full at the time of subscribing. To change your credit card information or to cancel your subscription, go to "Edit Settings". All credit card information will be available there. If you should decide to cancel your subscription, it will continue to be valid until the next payment period, as all payments for the current period were made in advance. For special circumstances, please email


StudySoup has more than 1 million course-specific study resources to help students study smarter. If you’re having trouble finding what you’re looking for, our customer support team can help you find what you need! Feel free to contact them here:

Recurring Subscriptions: If you have canceled your recurring subscription on the day of renewal and have not downloaded any documents, you may request a refund by submitting an email to

Satisfaction Guarantee: If you’re not satisfied with your subscription, you can contact us for further help. Contact must be made within 3 business days of your subscription purchase and your refund request will be subject for review.

Please Note: Refunds can never be provided more than 30 days after the initial purchase date regardless of your activity on the site.