VeejaLiu opened a new issue, #18100:
URL: https://github.com/apache/shardingsphere/issues/18100
# Proxy 5.1.1
I have a long sql(>4M)
```
insert into XXX values (....)
```
When I directly import this SQL into the database, there is no problem.
But when i use proxy, it show:
```
(py3) ubuntu@ip-xx-xx-xx-xx:~$ mysql -h127.0.0.1 -P3307 -uroot -proot xxxx <
xxxx.sql
ERROR at line 1: Packet for query is too large (4316145 > 4194304). You can
change this value on the server by setting the max_allowed_packet' variable.
```
And I view my variable in proxy:
```
MySQL [xxxx]> show variables like 'max_allowed_packet';
+--------------------+----------+
| Variable_name | Value |
+--------------------+----------+
| max_allowed_packet | 4194304 |
+--------------------+----------+
1 row in set (0.005 sec)
```
Well, It is not enough.
Then I modify my resource config by:
```
ALTER RESOURCE database_team_default(
URL="jdbc:mysql://xxxx",
USER=root,
PASSWORD="xxxx",
PROPERTIES("maximumPoolSize"=10,"idleTimeout"="30000","maxAllowedPacket"="16777216")
);
```
then view variable in proxy again:
```
MySQL [xxxx]> show variables like 'max_allowed_packet';
+--------------------+----------+
| Variable_name | Value |
+--------------------+----------+
| max_allowed_packet | 16777216 |
+--------------------+----------+
1 row in set (0.005 sec)
```
I think it's good now.
But when i import data into proxy, the error still occurred.
```
(py3) ubuntu@ip-xx-xx-xx-xx:~$ mysql -h127.0.0.1 -P3307 -uroot -proot xxx <
EMAIL_THREAD.sql
ERROR at line 1: Packet for query is too large (4316145 > 4194304). You can
change this value on the server by setting the max_allowed_packet' variable.
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail:
[email protected]
For queries about this service, please contact Infrastructure at:
[email protected]