If you are getting this error via root SSH access, please use the following command to verify if the setting is already defined:
# grep -i max_allowed_packet /etc/my.cnf
If the setting is not yet defined (i.e., no output from the above command) then the option could be inserted manually into the MySQL configuration (my.cnf) file using your preferred command-line text editor.
The following may be used as an example for what to add (under the configuration section labeled "[mysqld]"):
# max_allowed_packet = 1M