Is there a way to see what a process is doing?
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Unix and Linux reviews > Free Unix support > Unix Programming > Is there a way to see what a process is doing?




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Is there a way to see what a process is doing?  
music4


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-24-04 09:34 AM

Greetings,

I developed a socket server program, now I am testing it.

In the test, I let the socket client keep sending same data to server
program at same speed. But I find the server process normally occupy about
20% CPU usage, but sometime over 50%.

So I am wondering if there is to let me see what server program is doing
what high CPU usage time.

I developer the program on Solaris 8, C++ language, Sun Forte 6 compiler.

Any ideas will be greatly appreciated.

Evan







[ Post a follow-up to this message ]



    Re: Is there a way to see what a process is doing?  
Paul Pluzhnikov


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-24-04 03:39 PM

"music4" <music4@163.net> writes:

> So I am wondering if there is to let me see what server program is doing
> what high CPU usage time.

Yes: "man truss" and "man pstack"

Cheers,
--
In order to understand recursion you must first understand recursion.
Remove /-nsp/ for email.





[ Post a follow-up to this message ]



    Re: Is there a way to see what a process is doing?  
Chuck Dillon


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
03-24-04 03:39 PM

music4 wrote:

> Greetings,
>
> I developed a socket server program, now I am testing it.
>
> In the test, I let the socket client keep sending same data to server
> program at same speed. But I find the server process normally occupy about
> 20% CPU usage, but sometime over 50%.
>
> So I am wondering if there is to let me see what server program is doing
> what high CPU usage time.
>
> I developer the program on Solaris 8, C++ language, Sun Forte 6 compiler.
>
> Any ideas will be greatly appreciated.
>
> Evan
>
>

That's what a debugger is for.  The dbx debugger (part of forte) can
also do profiling and report how much time is spent in each function.
See the manpage for dbx and the help command of dbx.

-- ced

--
Chuck Dillon
Senior Software Engineer
NimbleGen Systems Inc.





[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 08:32 AM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register