Installation MariaDB5.5 on RHEL6
yum -y install gcc gcc-c++ autoconf libjpeg libjpeg-devel libpng libpng-devel freetype freetype-devel libxml2 libxml2-devel zlib zlib-devel glibc glibc-devel glib2 glib2-devel bzip2 bzip2-devel ncurses ncurses-devel curl curl-devel ssse2fsprogs e2fsprogs-devel krb5 krb5-devel libidn libidn-devel openssl openssl-devel openldap openldap-devel nss_ldap openldap-clients openldap-servers gettext-devel libXpm-devel libtool perl-DBD-MySQL bison cmake [root@test mariadb-5.5.33a]# mkdir -p /data/mariadb5.5 /service/mariadb5.5 [root@test mariadb-5.5.33a]# cmake . -DCMAKE_INSTALL_PREFIX=/service/mariadb5.5 -DMYSQL_UNIX_ADDR=/data/mariadb5.5/mariadb.sock -DMYSQL_DATADIR=/data/mariadb5.5 -DSYSCONFDIR=/service/mariadb5.5 -DMYSQL_USER=mysql -DMYSQL_TCP_PORT=30308 -DWITH_XTRADB_STORAGE_ENGINE=1 -DWITH_INNOBASE_STORAGE_ENGINE=1 -DWITH_PARTITION_STORAGE_ENGINE=1 -DWITH_BLACKHOLE_STORAGE_ENGINE=1 -DWITH_MYISAM_STORAGE_ENGINE=1 -DWITH_READLINE=1 -DENABLED_LOCAL_INFILE=1 -DWITH_EXTRA_CHARSETS=1 -DDEFAULT_CHARSET=utf8 -DDEFAULT_COLLATION=utf8_general_ci -DEXTRA_CHARSETS=all -DWITH_BIG_TABLES=1 -DWITH_DEBUG=0 -DCOMPILATION_COMMENT=ZWC-MariaDB [root@test mariadb-5.5.33a]# make && make install [root@test ~]# cat /service/mariadb5.5/my.cnf [client] port = 30308 socket = /data/mariadb5.5/mariadb.sock
[mysqld]
port = 30308
socket = /data/mariadb5.5/mariadb.sock
skip-external-locking
back_log = 500
lower_case_table_names = 1
skip-name-resolve
max_connections = 1024
table_open_cache = 512
binlog_cache_size = 1M
max_heap_table_size = 300M
read_buffer_size = 10M
read_rnd_buffer_size = 16M
sort_buffer_size = 8M
join_buffer_size=4M
thread_cache_size = 4
thread_concurrency = 4
query_cache_size = 200M
ft_min_word_len = 4
thread_stack = 192K
tmp_table_size = 200M
slow_query_log
long_query_time = 2
slow_query_log_file = /data/mariadb5.5/slowsql.sql
key_buffer_size = 32M
bulk_insert_buffer_size = 64M
myisam_sort_buffer_size = 128M
myisam_max_sort_file_size = 200M
myisam_repair_threads = 4
myisam_recover
# setup innodb
innodb_additional_mem_pool_size = 16M
innodb_buffer_pool_size = 2500M
innodb_data_file_path = ibdata1:10M:autoextend
innodb_write_io_threads = 4
innodb_read_io_threads = 4
innodb_thread_concurrency = 16
innodb_flush_log_at_trx_commit = 2
innodb_log_buffer_size = 8M
innodb_log_file_size = 512M
innodb_log_files_in_group = 3
innodb_max_dirty_pages_pct = 90
innodb_lock_wait_timeout = 120
init_connect = 'SET autocommit=0'
innodb-file-per-table = 1
innodb-open-file = 500
innodb_flush_method=O_DIRECT
open_files_limit = 65535
expire_logs_days = 5
event_scheduler = 1
log-bin=binlog-master
binlog_format=mixed
server-id = 1
[mysqldump]
quick
max_allowed_packet = 16M
[mysql]
prompt=\\u@\\d \\r:\\m:\\s>
no-auto-rehash
[myisamchk]
key_buffer_size = 128M
sort_buffer_size = 128M
read_buffer = 2M
write_buffer = 2M
[mysqlhotcopy]
interactive-timeout
[root@test ~]# /service/mariadb5.5/scripts/mysql_install_db --defaults-file=/service/mariadb5.5/my.cnf --basedir=/service/mariadb5.5 --datadir=/data/mariadb5.5 --user=mysql
Installing Ma