Re: regarding core file generation in solaris:pls suggest some tips
- From: victorfeng1973@xxxxxxxxx
- Date: Fri, 29 Feb 2008 19:52:57 -0800 (PST)
On Feb 29, 3:52 pm, Gsec <Gaurav.Sai...@xxxxxxxxx> wrote:
On Feb 28, 10:19 pm, victorfeng1...@xxxxxxxxx wrote:
On Feb 28, 1:44 pm, Gsec <Gaurav.Sai...@xxxxxxxxx> wrote:
On Feb 27, 5:27 pm, victorfeng1...@xxxxxxxxx wrote:
On Feb 27, 3:18 pm, Gsec <Gaurav.Sai...@xxxxxxxxx> wrote:
On Feb 27, 3:54 pm, victorfeng1...@xxxxxxxxx wrote:
On Feb 27, 12:17 pm, Mike Marshall <hub...@xxxxxxxxxxx> wrote:
1) see which thread is taking what percentage of cpu ?
ps -efL
-Mike
We may need to use -o to get percentage of cpu with ps.
ps -e -o pid,lwp,pcpu,fname | sort -r -k3,3 | more
Victor
Ya, it is giving me the LWPs and their CPU utilization. But, for the
first 14 threads it is showing as same 47.5%, which
is same as app.exe ! Is there any way to pin point which thread is the
culprit ?
For example: here 25864 is the process id, 1-14 LWPs and then %
utilization for app.exe
25864 1 39.7 app.exe
25864 2 39.7 app.exe
25864 3 39.7 app.exe
25864 4 39.7 app.exe
25864 5 39.7 app.exe
25864 6 39.7 app.exe
25864 7 39.7 app.exe
25864 8 39.7 app.exe
25864 9 39.7 app.exe
25864 10 39.7 app.exe
25864 11 39.7 app.exe
25864 12 39.7 app.exe
25864 13 39.7 app.exe
25864 14 39.7 app.exe
It does not mean that each thread consumes 39.7% memory because the
total is already larger than 100%. Those threads share most of
computing resource, I think. You may use truss -p 25864/3 to pick one
of them to see what is going on.
Victor- Hide quoted text -
- Show quoted text -
Victor,
Thanks a lot. However, still I am not able to see the core file.
Can you help me out by leting me some shell script that :
1) get the pid of app.exe
2) keep on executing the command "gcore <pid of app.exe>
The intention is to get the core file at the instance when app.exe
crashes, as the PID will not available
and the gcore command will not be executed anymore.
-Gaurav
ps -ef | grep app.exe | grep -v grep | awk '{print $2}'
Are you running Solaris 10? I may provide you a DTrace script. Is
there anywhere you can send the core file to be analyzed?
Victor- Hide quoted text -
- Show quoted text -
oh no! I am facing different issues if I try to generate the core file
manually. Since the core generation program will keep on generating
the core file until the app.exe crashes, so, it will reduce the CPU
usage of the app.exe's LWPs. So, I cannot keep on generating the core
file for app.exe.
I tried to attach the app.exe with gdb,and then did a continue..The
app.exe runs fine, but, when it recvs SIGSEGV, it immediately
continues to some different threads, and I cannt do a backtrack on
that to get the point of crashing..is there any way to go to the
crashing point while attaching in gdb ? I cannot start my app.exe with
gdb due to other restrictions. Now, I have no core, file, and I need
to find out where it is crashing !
Further help ?
You could use truss.
# truss -o appexe.output -p <pid>
appexe.output will have all the records until app.exe crashes.
Somebody else here may help you analyze.
Victor
.
- Prev by Date: locked thread - how to investigate?
- Next by Date: ssh from FreeBSD to Solaris9
- Previous by thread: locked thread - how to investigate?
- Next by thread: ssh from FreeBSD to Solaris9
- Index(es):
Relevant Pages
|
|