How do I debug max_allowed_packet going to -1?
max_allowd_packet= set to the size of the largest packet requesting; Usually it can set it to 32M and increase it according to ur application needs. Specify it in [mysqld] and client sections in my.cnf For example

[mysqld]
max_allowed_packet=128M

[client]
max_allowed_packet=128M