Have tried following the recommendation to increase this limit, but the value will not save.

Comments

kenorb’s picture

Is there any error?
Maybe some limit related to shared hosting?

Starminder’s picture

No, unfortunately no error. Everything appears to work like it should...except that the new value is not saved and it reverts to the original.

kenorb’s picture

I'll look closer to this tomorrow and I'll try to fix that.

kenorb’s picture

Status: Active » Needs review

It's fixed in latest dev version.

Starminder’s picture

Status: Needs review » Needs work

One step forward, one step back. New dev version gives me "Fatal error: Call to undefined function drupal_strtolower() in /usr/home/hoslo/public_html/includes/common.inc on line 1187" when I try to enable it.

kenorb’s picture

Status: Needs work » Needs review

Included additional core file during hook_boot:

            include_once './includes/unicode.inc';

Updated .module file:
http://cvs.drupal.org/viewvc.py/drupal/contributions/modules/drupal_twea...

Starminder’s picture

OK, getting there. Used file above + latest dev, no errors so far. Max Allowed Packet was set to 1k. I tried to change it to 2GB, got the error "Actual MAX_ALLOWED_PACKET is differ than it was set, probably you do not have proper privileges." and it reset it to 1024 MB.

Is that setting good enough?

kenorb’s picture

You should set in example to: '4 MB'. It should be enough. If there will be error about privileges, then unfortunately your hosting provider don't allow to change those settings on the fly.

mvc’s picture

Title: Increasing max_allowed_packet won't save entry » Increasing max_allowed_packet not possible in modern version of MySQL
Status: Needs review » Needs work

As of MySQL 5.0.x the variable max_allowed_packet cannot be set per session, and as of 5.0.84 and 5.1.31 the variable is read-only. Setting this at run time only works in 4.1.x and before. This module should detect which version of MySQL is being used and display a message to the user saying that this variable will need to be altered in the server's configuration file my.cnf.

http://dev.mysql.com/doc/refman/4.1/en/server-system-variables.html#sysv...
http://dev.mysql.com/doc/refman/5.0/en/server-system-variables.html#sysv...
http://dev.mysql.com/doc/refman/5.1/en/server-system-variables.html#sysv...

kenorb’s picture

kenorb’s picture

Marked #779540: Warning: SESSION variable max_allowed_packet is read-only. -- Also, Cannot set variable `max_allowed_packet` as duplicate.

Probably there should be some condition in the code depends of the mysql version.

drupert55’s picture

Subscribed (my issue at http://drupal.org/node/779540)

AlfTheCat’s picture

subscribing

kenorb’s picture

Starminder’s picture

Any plans for a D7 version? :)

zvischutz’s picture

See http://drupal.org/node/542874#comment-6697196 as a possible solution for this .

websupportguy’s picture

Issue summary: View changes

I have just had to disable Drupal Tweaks module entirely because it was generating up to three of these warnings on each page of my website. This is very disappointing as the problem has been around for a long time but seems to have been largely ignored. MySQL moved on and Drupal Tweaks didn't. The workaround provided in the last post did not work for me at all.

kenorb’s picture

Status: Needs work » Closed (outdated)

Closed because Drupal 6 is no longer supported. If the issue verifiably applies to later versions, please reopen with details and update the version.