Follow

Error Attempting To Install Or Upgrade Gliffy Diagrams (MySQL - 'ERROR: max_allowed_packet' variable')

When attempting to install the Gliffy Confluence Plugin some users have reported seeing the message:

An unexpected error occurred. Please refer to the logs for more information.

Viewing the Confluence Logs a line similar to the following will appear:

ERROR [pool-6-thread-1] [sf.hibernate.util.JDBCExceptionReporter] logExceptions Packet for query is too large (24838833 > 16777216). You can change this value on the server by setting the max_allowed_packet' variable.
 -- referer: http://confluenceserver:port/plugins/servlet/upm | url: /rest/plugins/1.0/upgrades/all | userName: user

or

ERROR [pool-40-thread-2] [sf.hibernate.util.JDBCExceptionReporter] logExceptions Packet for query is too large (34647545 > 33554432). You can change this value on the server by setting the max_allowed_packet' variable.
 -- url: /rest/plugins/1.0/ | userName: user | referer: 
ERROR [pool-40-thread-2] [sf.hibernate.impl.SessionImpl] execute Could not synchronize database state with session
 -- url: /rest/plugins/1.0/ | userName: user | referer: 
ERROR [pool-40-thread-2] [atlassian.upm.manager.PluginInstaller] execute Failed to install plugin
 -- url: /rest/plugins/1.0/ | userName: user | referer: 
com.atlassian.upm.PluginInstallException: Failed to install OBR jar artifact
    at com.atlassian.upm.impl.ObrPluginInstallHandler.installPlugin(ObrPluginInstallHandler.java:114)
    at com.atlassian.upm.manager.PluginInstaller.execute(PluginInstaller.java:172)
    at com.atlassian.upm.manager.PluginInstaller.install(PluginInstaller.java:127)
    ...
    at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.RuntimeException: There was a problem evicting or flushing a PluginData object
    at com.atlassian.confluence.plugin.persistence.hibernate.HibernatePluginDataDao.saveOrUpdate(HibernatePluginDataDao.java:65)

or

WARN [UpmAsynchronousTaskManager:thread-3] [upm.core.install.DefaultPluginInstallationService] execute Plugin installation failed: Failed to install OBR jar artifact
-- url: /rest/plugins/1.0/ | referer: http://confluenceserver:port/plugins/servlet/upm/marketplace/featured | userName: user
WARN [UpmAsynchronousTaskManager:thread-3] [upm.core.install.DefaultPluginInstallationService] execute com.atlassian.upm.spi.PluginInstallException: Failed to install OBR jar artifact
-- url: /rest/plugins/1.0/ | referer: http://confluenceserver:port/plugins/servlet/upm/marketplace/featured | userName: user | com.atlassian.upm.spi.PluginInstallException: Failed to install OBR jar artifact
at com.atlassian.upm.core.install.ObrPluginInstallHandler.installPluginInternal(ObrPluginInstallHandler.java:172)
at com.atlassian.upm.core.install.AbstractPluginInstallHandler.installPlugin(AbstractPluginInstallHandler.java:48)
...
Caused by: java.lang.RuntimeException: There was a problem evicting or flushing a PluginData object
at com.atlassian.confluence.plugin.persistence.hibernate.HibernatePluginDataDao.saveOrUpdate(HibernatePluginDataDao.java:104)
...
at com.atlassian.confluence.plugin.persistence.hibernate.HibernatePluginDataDao.saveOrUpdate(HibernatePluginDataDao.java:98)
... 115 more
Caused by: java.sql.BatchUpdateException: Row size too large (> 8126). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help. In current row format, BLOB prefix of 768 bytes is stored inline.
at com.mysql.jdbc.PreparedStatement.executeBatchSerially(PreparedStatement.java:1815)
... 119 more
Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Row size too large (> 8126). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help. In current row format, BLOB prefix of 768 bytes is stored inline.
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
... 123 more

These errors are caused by the MySQL server max_allowed_packet variable being set too small.

 

Resolution:

Set the max_allowed_packet variable to a larger value in your MySQL server my.cnf (Linux) or my.ini (Windows) configuration files. We recommend setting this value to at least 256M or larger (occasionally a very high setting of 1024M or 2048M is required). You can find more information on how to set this configuration variable on the MySQL website: http://dev.mysql.com/doc/refman/5.0/en/packet-too-large.html Please note that if you update the setting in your configuration file, you will need to restart your MySQL server for the change to take affect.

In addition, increasing the innodb_log_file_size variable to a larger value, like 1024M, may also be required for this problem to be resolved. Our add-on size is ~60mb, and each log statement can only increase the log file size by less than 10%. Thus, a value of greater than 600M is required here. Again, be sure to restart your MySQL server after changing the my.cnf/my.ini configuration file.

 

More information on troubleshooting Gliffy Confluence Plugin can be found here:

For more information about the above MySQL error as it's related to Confluence, please see the following Atlassian support articles:

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

0 Comments

Article is closed for comments.