MySQL 환경변수 확인

MySQL 환경변수 확인

1 전체 목록[ | ]

  • 글로벌 환경변수
mysql> SHOW VARIABLES;
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
| Variable_name                                     | Value                                                                                                                  |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
| auto_increment_increment                          | 1                                                                                                                      |
| auto_increment_offset                             | 1                                                                                                                      |
... (생략)
| warning_count                                     | 0                                                                                                                      |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
329 rows in set (0.00 sec)
  • 세션 환경변수
mysql> SHOW GLOBAL VARIABLES;
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
| Variable_name                                     | Value                                                                                                                  |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
| auto_increment_increment                          | 1                                                                                                                      |
| auto_increment_offset                             | 1                                                                                                                      |
... (생략)
| wait_timeout                                      | 28800                                                                                                                  |
+---------------------------------------------------+------------------------------------------------------------------------------------------------------------------------+
317 rows in set (0.00 sec)

2 LIKE 조건[ | ]

mysql> SHOW VARIABLES LIKE 'auto_%';
+--------------------------+-------+
| Variable_name            | Value |
+--------------------------+-------+
| auto_increment_increment | 1     |
| auto_increment_offset    | 1     |
| autocommit               | ON    |
| automatic_sp_privileges  | ON    |
+--------------------------+-------+
4 rows in set (0.00 sec)
mysql> SHOW VARIABLES LIKE 'auto\_%';
+--------------------------+-------+
| Variable_name            | Value |
+--------------------------+-------+
| auto_increment_increment | 1     |
| auto_increment_offset    | 1     |
+--------------------------+-------+
2 rows in set (0.00 sec)

3 1개 보기[ | ]

mysql> SELECT @@auto_increment_increment;
+----------------------------+
| @@auto_increment_increment |
+----------------------------+
|                          1 |
+----------------------------+
1 row in set (0.00 sec)

4 같이 보기[ | ]

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}