gdb를 이용한 Core Dump 분석에 관련되어 질문드립니다..
우선 환경은 임베디드 개발 환경이고요
타겟보드는 ARM계열의 PXA320을 사용하고 있습니다..
헌대 이놈의 프로그램이 심심하면 segmentation fault를 뿜어대어 gdb를 설치하고
arm-linux-gdb 를 이용하여 dump뜬 core파일을 분석하려고 로드하였습니다..
어찌어찌 core dump를 로드하긴 했는데 bt 명령을 이용하여 분석하려 하니 분석하기 힘든 상형문자와 알수없는 경고를 마구마구 밷어내어
어느부분이 segmentation fault를 발생시키는지 전혀 알수가 없게되었습니다..
경고를 해결할 방법을 아시는 고수님들께서 도와주신다면 정말 감사하겠습니다 ^^..
ggammang@Linux-Dev:~$ ./embedded/gdb/bin/arm-linux-gdb /nfsroot/robject_Arm
GNU gdb (GDB) 7.0
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "--host=i686-pc-linux-gnu --target=arm-linux".
For bug reporting instructions, please see:
...
Reading symbols from /nfsroot/robject_Arm...done.
(gdb) core /nfsroot/robot
robot1_core.603 robot3_core
(gdb) core /nfsroot/robot
robot1_core.603 robot3_core
(gdb) core /nfsroot/robot1_core.603
[New Thread 611]
[New Thread 609]
[New Thread 608]
[New Thread 607]
[New Thread 606]
[New Thread 605]
[New Thread 604]
[New Thread 603]
warning: `/lib/libm.so.6': Shared library architecture unknown is not compatible with target architecture arm.
warning: .dynamic section for "/lib/libm.so.6" is not at the expected address (wrong library or version mismatch?)
warning: `/lib/libpthread.so.0': Shared library architecture unknown is not compatible with target architecture arm.
warning: .dynamic section for "/lib/libpthread.so.0" is not at the expected address (wrong library or version mismatch?)
warning: `/lib/libc.so.6': Shared library architecture unknown is not compatible with target architecture arm.
warning: .dynamic section for "/lib/libc.so.6" is not at the expected address (wrong library or version mismatch?)
Error while mapping shared library sections:
/lib/ld-linux.so.3: No such file or directory.
warning: `/lib/libgcc_s.so.1': Shared library architecture unknown is not compatible with target architecture arm.
warning: .dynamic section for "/lib/libgcc_s.so.1" is not at the expected address (wrong library or version mismatch?)
Reading symbols from /lib/libm.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/libm.so.6
Reading symbols from /lib/libpthread.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib/libpthread.so.0
Reading symbols from /lib/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/libc.so.6
Symbol file not found for /lib/ld-linux.so.3
Reading symbols from /lib/libgcc_s.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcc_s.so.1
warning: Unable to find dynamic linker breakpoint function.
GDB will be unable to debug shared library initializers
and track explicitly loaded dynamic code.
Core was generated by `/nfsroot/robject_Arm 1 rausb0'.
Program terminated with signal 11, Segmentation fault.
#0 0x40151254 in ?? () from /lib/libc.so.6
(gdb) bt
#0 0x40151254 in ?? () from /lib/libc.so.6
#1 0x40152ba8 in ftello () from /lib/libc.so.6
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
(gdb) source /home/ggammang/Desktop/RObject
/home/ggammang/Desktop/RObject: Success.
(gdb) bt
#0 0x40151254 in ?? () from /lib/libc.so.6
#1 0x40152ba8 in ftello () from /lib/libc.so.6
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
(gdb)
댓글 달기