Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qg-docker-entrypoints
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
QA
qg-docker-entrypoints
Commits
3dcb3ec2
Commit
3dcb3ec2
authored
Apr 18, 2018
by
kalvin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mysql配置
parent
5d15eca8
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
45 deletions
+41
-45
my.cnf
dev/common/mysql/my.cnf
+40
-0
run.sh
dev/common/mysql/run.sh
+1
-45
No files found.
dev/common/mysql/my.cnf
0 → 100644
View file @
3dcb3ec2
[client]
socket = ${MYSQL_DEF_SCK}/mysqld.sock
[mysql]
socket = ${MYSQL_DEF_SCK}/mysqld.sock
[mysqld]
skip-host-cache
skip-name-resolve
datadir = ${MYSQL_DEF_DAT}
user = ${MY_USER}
port = 3306
bind-address = 0.0.0.0
socket = ${MYSQL_DEF_SCK}/mysqld.sock
pid-file = ${MYSQL_DEF_PID}/mysqld.pid
general_log_file = ${MYSQL_LOG_QUERY}
slow_query_log_file = ${MYSQL_LOG_SLOW}
log-error = ${MYSQL_LOG_ERROR}
log-bin=/var/lib/mysql/mysql-bin
server-id=1"
!includedir ${MYSQL_BASE_INCL}/
!includedir ${MYSQL_CUST_INCL1}/
!includedir ${MYSQL_CUST_INCL2}/
innodb_buffer_pool_size = 512M
innodb_buffer_pool_instances = 1
bulk_insert_buffer_size = 32M
query_cache_type = 0
query_cache_size = 0
max_connections = 4096
max_connect_errors = 10
table_open_cache = 4096
max_allowed_packet = 512M
binlog_cache_size = 1M
max_heap_table_size = 64M
read_buffer_size = 8M
read_rnd_buffer_size = 16M
sort_buffer_size = 32K
join_buffer_size = 32K
thread_cache_size = 64"
\ No newline at end of file
dev/common/mysql/run.sh
View file @
3dcb3ec2
...
@@ -5,51 +5,7 @@
...
@@ -5,51 +5,7 @@
DEBUG_COMMANDS
=
0
DEBUG_COMMANDS
=
0
###
curl
-o
/etc/my.cnf http://192.168.3.60/QA/qg-docker-entrypoints/raw/master/dev/common/mysql/my.cnf
### Init
###
echo
"[client]"
>
/etc/my.cnf
&&
\
echo
"socket =
${
MYSQL_DEF_SCK
}
/mysqld.sock"
>>
/etc/my.cnf
&&
\
\
echo
"[mysql]"
>>
/etc/my.cnf
&&
\
echo
"socket =
${
MYSQL_DEF_SCK
}
/mysqld.sock"
>>
/etc/my.cnf
&&
\
\
echo
"[mysqld]"
>>
/etc/my.cnf
&&
\
echo
"innodb_buffer_pool_size = 512M"
>>
/etc/my.cnf
&&
\
echo
"innodb_buffer_pool_instances = 1"
>>
/etc/my.cnf
&&
\
echo
"bulk_insert_buffer_size = 32M"
>>
/etc/my.cnf
&&
\
echo
"query_cache_type = 0"
>>
/etc/my.cnf
&&
\
echo
"query_cache_size = 0"
>>
/etc/my.cnf
&&
\
echo
"max_connections = 4096"
>>
/etc/my.cnf
&&
\
echo
"max_connect_errors = 10"
>>
/etc/my.cnf
&&
\
echo
"table_open_cache = 4096"
>>
/etc/my.cnf
&&
\
echo
"max_allowed_packet = 512M"
>>
/etc/my.cnf
&&
\
echo
"binlog_cache_size = 1M"
>>
/etc/my.cnf
&&
\
echo
"max_heap_table_size = 64M"
>>
/etc/my.cnf
&&
\
echo
"read_buffer_size = 8M"
>>
/etc/my.cnf
&&
\
echo
"read_rnd_buffer_size = 16M"
>>
/etc/my.cnf
&&
\
echo
"sort_buffer_size = 32K"
>>
/etc/my.cnf
&&
\
echo
"join_buffer_size = 32K"
>>
/etc/my.cnf
&&
\
echo
"thread_cache_size = 64"
>>
/etc/my.cnf
&&
\
\
echo
"skip-host-cache"
>>
/etc/my.cnf
&&
\
echo
"skip-name-resolve"
>>
/etc/my.cnf
&&
\
echo
"datadir =
${
MYSQL_DEF_DAT
}
"
>>
/etc/my.cnf
&&
\
echo
"user =
${
MY_USER
}
"
>>
/etc/my.cnf
&&
\
echo
"port = 3306"
>>
/etc/my.cnf
&&
\
echo
"bind-address = 0.0.0.0"
>>
/etc/my.cnf
&&
\
echo
"socket =
${
MYSQL_DEF_SCK
}
/mysqld.sock"
>>
/etc/my.cnf
&&
\
echo
"pid-file =
${
MYSQL_DEF_PID
}
/mysqld.pid"
>>
/etc/my.cnf
&&
\
echo
"general_log_file =
${
MYSQL_LOG_QUERY
}
"
>>
/etc/my.cnf
&&
\
echo
"slow_query_log_file =
${
MYSQL_LOG_SLOW
}
"
>>
/etc/my.cnf
&&
\
echo
"log-error =
${
MYSQL_LOG_ERROR
}
"
>>
/etc/my.cnf
&&
\
echo
"log-bin=/var/lib/mysql/mysql-bin"
>>
/etc/my.cnf
&&
\
echo
"server-id=1"
>>
/etc/my.cnf
&&
\
echo
"!includedir
${
MYSQL_BASE_INCL
}
/"
>>
/etc/my.cnf
&&
\
echo
"!includedir
${
MYSQL_CUST_INCL1
}
/"
>>
/etc/my.cnf
&&
\
echo
"!includedir
${
MYSQL_CUST_INCL2
}
/"
>>
/etc/my.cnf
###
###
### Functions
### Functions
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment