Sponsored Content
Full Discussion: Prize of being an Admin
The Lounge War Stories Prize of being an Admin Post 302651193 by admin_xor on Tuesday 5th of June 2012 06:41:55 AM
Old 06-05-2012
Good story of "researching" on production systems. So people can do anything at anytime at your place?
 

6 More Discussions You Might Find Interesting

1. Solaris

fresh admin

hi everybody i'm just recreuted as UNIX system admin... please tell me from where do i have to begin... best regards (8 Replies)
Discussion started by: hmaiida
8 Replies

2. Solaris

Tape Admin

Tape: Need tape library help please. Need to configure a remote admin card in the L100. Anything helpful.....thxs (2 Replies)
Discussion started by: uwinix77
2 Replies

3. Post Here to Contact Site Administrators and Moderators

note for admin

i left a message for admin in the wrong thread.. it is in the what is on your mind thread since i can't move it or delete it.. i thought I would mention that I meant it to be in this thread.. sorry about the mistake.. thanx for your patience moxxx68 (3 Replies)
Discussion started by: moxxx68
3 Replies

4. What is on Your Mind?

Windows Admin switching to *nix Admin

I'm currently a Windows admin and have wanted to jump ship to the *nix side for a while now. I've been studying both through an lpic level 1 manual as I have time (focusing on debian), and a solaris 10 cert book. The problem is I only have a handful of hours a week to study, and my current job... (3 Replies)
Discussion started by: bobwilson
3 Replies

5. War Stories

Prize of being an Admin - Part 2

I was reading this thread of admin_xor Prize of being an Admin and thought will share this experience of mine which is kind of opposite to what he did - I didn't tell anybody what happened :D We were porting one of the subsystem from Solaris to Linux. As part of that we developed many wrapper... (23 Replies)
Discussion started by: ahamed101
23 Replies

6. What is on Your Mind?

Regarding Admin life either as DBA or UNIX Linux admin

I am planning to choose my career as Unix/Linux Admin or a DBA. But I have come to know from forums and few admins like the job will be 24/7. I have few questions on that. Can we get "DAY" shifts in any one of the admin Job ? Can't we have shift timings in any company ? Eventhough the... (7 Replies)
Discussion started by: Jacktts
7 Replies
QSemaphore(3qt) 														   QSemaphore(3qt)

NAME
QSemaphore - Robust integer semaphore SYNOPSIS
All the functions in this class are thread-safe when Qt is built with thread support.</p> #include <qsemaphore.h> Public Members QSemaphore ( int maxcount ) virtual ~QSemaphore () int available () const int total () const int operator++ ( int ) int operator-- ( int ) int operator+= ( int n ) int operator-= ( int n ) bool tryAccess ( int n ) DESCRIPTION
The QSemaphore class provides a robust integer semaphore. A QSemaphore can be used to serialize thread execution, in a similar way to a QMutex. A semaphore differs from a mutex, in that a semaphore can be accessed by more than one thread at a time. For example, suppose we have an application that stores data in a large tree structure. The application creates 10 threads (commonly called a thread pool) to perform searches on the tree. When the application searches the tree for some piece of data, it uses one thread per base node to do the searching. A semaphore could be used to make sure that two threads don't try to search the same branch of the tree at the same time. A non-computing example of a semaphore would be dining at a restuarant. A semaphore is initialized to have a maximum count equal to the number of chairs in the restuarant. As people arrive, they want a seat. As seats are filled, the semaphore is accessed, once per person. As people leave, the access is released, allowing more people to enter. If a party of 10 people want to be seated, but there are only 9 seats, those 10 people will wait, but a party of 4 people would be seated (taking the available seats to 5, making the party of 10 people wait longer). When a semaphore is created it is given a number which is the maximum number of concurrent accesses it will permit. This amount may be changed using operator++(), operator--(), operator+=() and operator-=(). The number of accesses allowed is retrieved with available(), and the total number with total(). Note that the incrementing functions will block if there aren't enough available accesses. Use tryAccess() if you want to acquire accesses without blocking. See also Environment Classes and Threading. MEMBER FUNCTION DOCUMENTATION
QSemaphore::QSemaphore ( int maxcount ) Creates a new semaphore. The semaphore can be concurrently accessed at most maxcount times. QSemaphore::~QSemaphore () [virtual] Destroys the semaphore. Warning: If you destroy a semaphore that has accesses in use the resultant behavior is undefined. int QSemaphore::available () const Returns the number of accesses currently available to the semaphore. int QSemaphore::operator++ ( int ) Postfix ++ operator. Try to get access to the semaphore. If available() == 0, this call will block until it can get access, i.e. until available() > 0. int QSemaphore::operator+= ( int n ) Try to get access to the semaphore. If available() < n, this call will block until it can get all the accesses it wants, i.e. until available() >= n. int QSemaphore::operator-- ( int ) Postfix -- operator. Release access of the semaphore. This wakes all threads waiting for access to the semaphore. int QSemaphore::operator-= ( int n ) Release n accesses to the semaphore. int QSemaphore::total () const Returns the total number of accesses to the semaphore. bool QSemaphore::tryAccess ( int n ) Try to get access to the semaphore. If available() < n, this function will return FALSE immediately. If available() >= n, this function will take n accesses and return TRUE. This function does not block. SEE ALSO
http://doc.trolltech.com/qsemaphore.html http://www.trolltech.com/faq/tech.html COPYRIGHT
Copyright 1992-2001 Trolltech AS, http://www.trolltech.com. See the license file included in the distribution for a complete license statement. AUTHOR
Generated automatically from the source code. BUGS
If you find a bug in Qt, please report it as described in http://doc.trolltech.com/bughowto.html. Good bug reports help us to help you. Thank you. The definitive Qt documentation is provided in HTML format; it is located at $QTDIR/doc/html and can be read using Qt Assistant or with a web browser. This man page is provided as a convenience for those users who prefer man pages, although this format is not officially supported by Trolltech. If you find errors in this manual page, please report them to qt-bugs@trolltech.com. Please include the name of the manual page (qsemaphore.3qt) and the Qt version (3.1.1). Trolltech AS 9 December 2002 QSemaphore(3qt)
All times are GMT -4. The time now is 04:35 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy