mysql max_allowed_packet 설정
WARNING: The user you typed does not seem to be root
If you encounter any problem with files insertion, try setting the global max_allowed_packet MySQL value to at least 2MB in your server config file.
[root@itms bin]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 3
Server version: 5.1.69 Source distribution
Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> show variables where Variable_name = 'max_allowed_packet';
+--------------------+---------+
| Variable_name | Value |
+--------------------+---------+
| max_allowed_packet | 1048576 |
+--------------------+---------+
1 row in set (0.00 sec)
mysql> SET GLOBAL max_allowed_packet = 2048000000;
Query OK, 0 rows affected, 1 warning (0.00 sec)
mysql> FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.00 sec)
mysql> show variables where Variable_name = 'max_allowed_packet';
+--------------------+---------+
| Variable_name | Value |
+--------------------+---------+
| max_allowed_packet | 2097152 |
+--------------------+---------+
1 row in set (0.00 sec)
또는
# vi /etc/my.cnf
#추가
set-variable = max_allowed_packet=2M
mysql> show variables where Variable_name = 'max_allowed_packet';
+--------------------+---------+
| Variable_name | Value |
+--------------------+---------+
| max_allowed_packet | 2097152 |
+--------------------+---------+
1 row in set (0.00 sec)
'리눅스' 카테고리의 다른 글
[리눅스] 아파치 웹 서버에서 디렉토리 리스팅을 막기 (0) | 2013.06.18 |
---|---|
[Apache] 아파치 버전정보 노출 막기 (0) | 2013.06.18 |
zip 명령어, unzip 명령어 (0) | 2013.06.18 |
SSL 인증서의 개인키에 설정된 비밀번호를 제거하는 방법 (0) | 2013.06.18 |
[리눅스] CentOS에서 mcrypt 설치방법 (2) | 2013.06.18 |