how to find out why exe crash in Ubuntu, make -g, but gdb only show ‘Inferior 1(process 221729) exited normally’
in /var/log/apport.log, only has ‘executable does not belong to a package, ignoring’; ‘core limit 0, dump mode1’
also nothing useful in syslog
and already change ulimit to unlimited
“crash” is a description so generic that I would not know what to recommend other than the equally generic “use standard debugging practices”, particularly in light of the fact that I am not familiar with the code.
One approach is to add debug logging to the application, and it will soon become obvious where things deviate from the path envisioned by the programmer. A second approach relies on a debugger, by setting breakpoints and watchpoints. In both cases the goal is to narrow down the immediate point of failure until the exact spot is identified, then work backwards from there to find the root cause.
Debugging is something best learned from experience, that is, learning by doing. There are some books on the market that give reasonably sounds advice on how to handle various debug scenarios.
I recommend unit 12 of this online training series.
Thanks so much!
new to dev on Ubuntu, gonna find some good debug tools and show the crash logs:)