|
发表于 2013-9-3 10:26:20
|
显示全部楼层
本帖最后由 terranboy 于 2013-9-3 10:27 编辑
: l: E& U( v' n9 T9 n9 G; I. y: g: h, o/ T `
几个参数改一下
% S/ J) ~/ y. l# vim /etc/my.cnf3 h2 o1 l4 P. p/ u5 p" }1 G
, g$ P, x4 m: l, Q
key_buffer_size = 256M" ^8 \! s$ D& x. M, ?; D& } L. Q
max_allowed_packet = 4M4 k# b! j( z; B+ y- C' }
table_open_cache = 1024
3 |8 D# S6 W& R. a( V! l" w: csort_buffer_size = 6M
7 a& V' |! M- anet_buffer_length = 8K
7 L) I' m( n3 U( {9 Nread_buffer_size = 4M! F# r! V6 `+ X7 b
join_buffer_size = 8M% h3 B' @! Y# q: l* Q7 x: ^% n7 k
read_rnd_buffer_size = 32M
3 w0 v5 C& {7 p; Otmp_table_size = 256M2 R6 d% J/ T; {, |$ o% c
myisam_sort_buffer_size =64M2 s8 n! @$ o; k. f2 b& J/ C* g
query_cache_size= 128M* Q8 b6 Z0 f* Z- X5 Q4 C# V9 P J
5 |& B# i9 ]! C/ A: s重启MYSQL {6 A, _- u1 d) _7 n2 h
/ l7 E r6 b3 K7 }/ U* s
现在都从MYSQL转到MARIADB了 性能比MYSQL好 完全兼容的
) j" @+ B( q% Z- s& {# e
; Q# ]7 S, G! q9 b
% @3 D( |' s: X. W% `3 a |
|