HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: how to determine thread status from different...
Operating System - HP-UX
1833758
Members
3070
Online
110063
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2004 11:28 AM
03-15-2004 11:28 AM
how to determine thread status from different thread
I am considering building a "monitoring thread" that will have a list of detached running threads. How can I test if these running, but detached threads are still executing? I don't wish to use pthread_join, as this will block. Any ideas?Thanks.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-16-2004 08:17 AM
03-16-2004 08:17 AM
Re: how to determine thread status from different thread
Te options I know of :
(a)Use DCE threads by using libcma.sl and not use pthreads
(b) Use the multithreaded unsupported lib written for this purpose
http://ftp.x.org/pub/unsupported/lib/pcthreads/
(c)Use certain mechanisms in Java to achieve the same
(a)Use DCE threads by using libcma.sl and not use pthreads
(b) Use the multithreaded unsupported lib written for this purpose
http://ftp.x.org/pub/unsupported/lib/pcthreads/
(c)Use certain mechanisms in Java to achieve the same
The sufficiency of my merit is to know that my merit is NOT sufficient
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-18-2004 04:18 AM
03-18-2004 04:18 AM
Re: how to determine thread status from different thread
If those monitored threads are cooperating, you could add a cancellation cleanup handler to each thread with pthread_cleanup_push(). Then your monitoring thread could just look at a data structure that is updated by the cancellation handler of each thread.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-18-2004 08:36 AM
03-18-2004 08:36 AM
Re: how to determine thread status from different thread
Thanks for the above suggestions:I figured out an interesting technique use pthread_getschedparam. This takes the thread id.. If the thread is not found it returns ESRCH error. I created a subroutine around this to check the thread status (ie, running,,, or ESRCH not running )...
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP