#1178 closed defect (fixed)

Can't debug rasserver with gdb

Reported by: dmisev Owned by:
Priority: major Milestone: Future
Component: rasserver Version: development
Keywords: Cc: atoader, gmerticariu, pbaumann
Complexity: Medium

Description

It seems like gdb just doesn't work anymore with rasnet (setting breakpoints or doing anything else). Can you check as well? Any ideas?

ps aux | grep rasserver # to find the pid
gdb -p <pid>

Change History (7)

comment:1 Changed 20 months ago by atoader

In rasnet, the server process is terminated if it does not respond to status checks from rasmgr. You can bypass this by modifying:
SERVER_MANAGER_CLEANUP_INTERVAL
and
CLIENT_MANAGER_CLEANUP_INTERVAL
in rasmgr_x/constants.hh to large values.

Ideally, we should work towards having the server functionality covered by unit tests to make debugging easier.

comment:2 Changed 20 months ago by dmisev

  • Cc pbaumann added

Being able to attach to rasserver with gdb is essential.

comment:3 Changed 20 months ago by pbaumann

wasn't directql meant for purposes like testing on QL level?

comment:4 Changed 20 months ago by dmisev

Yes in this case I resorted to directql, but if it was some issue with the protocol then that wouldn't work and the way to enable it is a bit cumbersome.

Maybe we can put this stuff in some developers guide:

In rasnet, the server process is terminated if it does not respond to status checks from rasmgr. > You can bypass this by modifying:
SERVER_MANAGER_CLEANUP_INTERVAL
and
CLIENT_MANAGER_CLEANUP_INTERVAL
in rasmgr_x/constants.hh to large values.

comment:5 Changed 20 months ago by atoader

You can attach gdb to the server process without any problem. You just have to make sure that rasmgr does not kill the server process while you are debugging (by setting the above variables).
@Dimitar, where should I put the above information?

comment:6 Changed 20 months ago by dmisev

I think this would be a fitting place: wiki:DebuggingBenchmarking

comment:7 Changed 18 months ago by dmisev

  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.