Setting max_allowed_packet

961 views
Skip to first unread message

Gabriel Axel

unread,
Nov 21, 2013, 3:22:11 AM11/21/13
to google-cloud...@googlegroups.com
Hello,

I'm trying so set max_allowed_packet by running the following command from the root user:
SET GLOBAL max_allowed_packet = 999*1024*1024
and I get this error:
Error Code: 1227. Access denied; you need (at least one of) the SUPER privilege(s) for this operation

I need this because my database stores longtext fields which cause import and insert/updates to fail without increasing max_allowed_packet.

Thanks.
Message has been deleted

Gabriel Axel

unread,
Nov 21, 2013, 10:35:48 AM11/21/13
to google-cloud...@googlegroups.com
I understand that you removed the super privilege entirely. Can you please either enable it or set max_allowed_packet=999M on my instance
docollabapp:docollab ?

Razvan Musaloiu-E.

unread,
Nov 21, 2013, 10:48:54 AM11/21/13
to google-cloud...@googlegroups.com
I manually set the max_allowed_packet to 1073741824 for docollabapp:docollab. That's the max (reference).

-- Razvan ME


--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/9dcfac85-c808-4c50-9176-feed1390692a%40googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.

Gabriel Axel

unread,
Nov 21, 2013, 5:32:01 PM11/21/13
to google-cloud...@googlegroups.com
Thanks. I started importing my database, the import ran for two and a half hours and then failed. I tried to repeat it and the same happened. I used mysqldump with the flags as described in the instructions, gzipped it and uploaded to gs://docollab-helper/dump.sql.gz . What went wrong?


On Thursday, November 21, 2013 5:48:54 PM UTC+2, Razvan Musaloiu-E. wrote:
I manually set the max_allowed_packet to 1073741824 for docollabapp:docollab. That's the max (reference).

-- Razvan ME
On Thu, Nov 21, 2013 at 7:35 AM, Gabriel Axel <guz...@gmail.com> wrote:
I understand that you removed the super privilege entirely. Can you please either enable it or set max_allowed_packet=999M on my instance
docollabapp:docollab ?

On Thursday, November 21, 2013 10:22:11 AM UTC+2, Gabriel Axel wrote:
Hello,

I'm trying so set max_allowed_packet by running the following command from the root user:
SET GLOBAL max_allowed_packet = 999*1024*1024
and I get this error:
Error Code: 1227. Access denied; you need (at least one of) the SUPER privilege(s) for this operation

I need this because my database stores longtext fields which cause import and insert/updates to fail without increasing max_allowed_packet.

Thanks.

--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-discuss+unsub...@googlegroups.com.

Razvan Musaloiu-E.

unread,
Nov 21, 2013, 5:53:18 PM11/21/13
to google-cloud...@googlegroups.com
You hit the 16M limit for a line length. Can you chop that in smaller pieces? If you use a mysqldump --max-allowed-packet=16777216 things should work fine.

-- Razvan ME


To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/6e64f31f-bfdf-47e2-bacf-ce8b80dbe88a%40googlegroups.com.

Gabriel Axel

unread,
Nov 22, 2013, 3:03:00 AM11/22/13
to google-cloud...@googlegroups.com
I currently have longtext fields of up to 400M, so mysqldump fails if I use lower max-allowed-packet value. Any way to overcome this?


On Friday, November 22, 2013 12:53:18 AM UTC+2, Razvan Musaloiu-E. wrote:
You hit the 16M limit for a line length. Can you chop that in smaller pieces? If you use a mysqldump --max-allowed-packet=16777216 things should work fine.

-- Razvan ME
On Thu, Nov 21, 2013 at 2:32 PM, Gabriel Axel <guz...@gmail.com> wrote:
Thanks. I started importing my database, the import ran for two and a half hours and then failed. I tried to repeat it and the same happened. I used mysqldump with the flags as described in the instructions, gzipped it and uploaded to gs://docollab-helper/dump.sql.gz . What went wrong?


On Thursday, November 21, 2013 5:48:54 PM UTC+2, Razvan Musaloiu-E. wrote:
I manually set the max_allowed_packet to 1073741824 for docollabapp:docollab. That's the max (reference).

-- Razvan ME
On Thu, Nov 21, 2013 at 7:35 AM, Gabriel Axel <guz...@gmail.com> wrote:
I understand that you removed the super privilege entirely. Can you please either enable it or set max_allowed_packet=999M on my instance
docollabapp:docollab ?

On Thursday, November 21, 2013 10:22:11 AM UTC+2, Gabriel Axel wrote:
Hello,

I'm trying so set max_allowed_packet by running the following command from the root user:
SET GLOBAL max_allowed_packet = 999*1024*1024
and I get this error:
Error Code: 1227. Access denied; you need (at least one of) the SUPER privilege(s) for this operation

I need this because my database stores longtext fields which cause import and insert/updates to fail without increasing max_allowed_packet.

Thanks.

--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-discuss+unsubscr...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-discuss+unsub...@googlegroups.com.

Gabriel Axel

unread,
Nov 23, 2013, 2:00:55 AM11/23/13
to google-cloud...@googlegroups.com
I tried mydqldump with extended-insert=false to produce shorter insert statements, and with this the import has been running for 12 hours and is still running. For all that time the storage in used showed in the console is 2.18G. Can you please check if anything is wrong with the instance?

Lee Schumacher

unread,
Nov 23, 2013, 2:22:09 AM11/23/13
to google-cloud...@googlegroups.com
On Fri, Nov 22, 2013 at 11:00 PM, Gabriel Axel <guz...@gmail.com> wrote:
I tried mydqldump with extended-insert=false to produce shorter insert statements, and with this the import has been running for 12 hours and is still running. For all that time the storage in used showed in the console is 2.18G. Can you please check if anything is wrong with the instance?

You're using a D0 instance.  I'm guessing a larger instance would be able to handle the import better, plus some or all of the amount you're now being charged for extra storage would be included.
 
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/f0e2b21e-47bf-4857-95e1-01130eb3675e%40googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.



--
Lee Schumacher | Software Engineer | lschu...@google.com | (650) 336-5330

Razvan Musaloiu-E.

unread,
Nov 23, 2013, 8:58:27 PM11/23/13
to google-cloud...@googlegroups.com
I would not recommend using --extended-insert=false because that will produce a much more inefficient dump.

-- Razvan ME


To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/f0e2b21e-47bf-4857-95e1-01130eb3675e%40googlegroups.com.

Razvan Musaloiu-E.

unread,
Nov 23, 2013, 9:00:50 PM11/23/13
to google-cloud...@googlegroups.com
One row with a column of 400M. Wow! Are you sure you really want that? :-) One workaround I would suggest is to use the IP connectivity [1].


-- Razvan ME


To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/619ba22b-d1f3-4c53-9cab-13255e7f197d%40googlegroups.com.

Gabriel Axel

unread,
Nov 24, 2013, 1:18:57 AM11/24/13
to google-cloud...@googlegroups.com
I'm sure I don't, and I intend to migrate to AppEngine Datastore eventually. I thought to use Cloud SQL as an intermediate phase, but it seems it would be better to move on to Datastore. Thanks anyway.

--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-discuss+unsub...@googlegroups.com.

Lee Schumacher

unread,
Nov 24, 2013, 12:38:12 PM11/24/13
to google-cloud...@googlegroups.com


On Nov 23, 2013 10:18 PM, "Gabriel Axel" <guz...@gmail.com> wrote:
>
> I'm sure I don't, and I intend to migrate to AppEngine Datastore eventually. I thought to use Cloud SQL as an intermediate phase, but it seems it would be better to move on to Datastore. Thanks anyway.

Appengine Datastore has a limit of 1mb per entity (and 10mb per transaction - see the bottom of https://developers.google.com/appengine/docs/python/datastore/ ), so I think cloud storage is your best bet here. 

>>>>>>> To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.


>>>>>>> To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/9dcfac85-c808-4c50-9176-feed1390692a%40googlegroups.com.
>>>>>>>
>>>>>>> For more options, visit https://groups.google.com/groups/opt_out.
>>>>>>
>>>>>>
>>>>> --
>>>>> You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.

>>>>> To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.


>>>>> To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/6e64f31f-bfdf-47e2-bacf-ce8b80dbe88a%40googlegroups.com.
>>>>>
>>>>> For more options, visit https://groups.google.com/groups/opt_out.
>>>>
>>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.

>>> To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.

> --
> You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.

> To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-d...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/4e34fecd-f85b-43d3-8cf9-538fbf046b27%40googlegroups.com.

Reply all
Reply to author
Forward
0 new messages