2

I tried to debug a program with gdb because it crashing randomly (after some days, after some hours..). But when I tried to debug it, my program throw these errors: "Lost connection to MySQL server" and "MySQL server has gone away"

I don't get these errors when I'm running my program without gdb, so what's the problem with the gdb?

I tried to incrase the max_allowed_packet to 256M in my.cnf, but not worked..

ks1322
  • 33,961
  • 14
  • 109
  • 164
AsDiKa
  • 21
  • 1
  • Your connection to the mysql server goes through a firewall that drops connections after they've been idle for a while; while you debug your application. – Sam Varshavchik Jun 26 '16 at 17:39
  • my mysql server running on localhost, and it can't be idle longer than 1 second because it throw these errors frequently. – AsDiKa Jun 26 '16 at 17:44
  • maybe it help.. the mysql connection is working well when it's in the main thread, but after it's changed to the another thread it's starting to throw those errors. in the other thread the program opening a new connection to mysql. – AsDiKa Jul 01 '16 at 12:33

0 Answers0