Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Waiting for semaphore to be created

Status
Not open for further replies.

35053

IS-IT--Management
Aug 15, 2006
2
PR
Why this message appear, what it means

98:00090 Waiting for semaphore to be
created...

 
Hi 35053,

Code:
Sometimes a process may need to wait for some other process to finish before it can continue. In this instance, the two processes need to be synchronized together. There are a number of ways in which this can be done. A common method in operating systems is to use a variable called a semaphore that only one process can own at a time. There are two calls associated with a semaphore, one to lock it and one to unlock it. When a process attempts to lock a semaphore, it will be successful if the semaphore is free. If the semaphore is already locked, the process requesting the lock will be blocked and remain blocked till the process that has the semaphore unlocks it. When that happens, the process that was blocked will be unblocked and the semaphore can then be locked by it.

System semaphores are used by the operating system to control system resources. A program can be assigned a resource by getting a semaphore (via a system call to the operating system). When the resource is no longer needed, the semaphore is returned to the operating system, which can then allocate it to another program.



Regards,
Khalid
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top