MySQL 5.5.32 Compilation Installation

Source: Internet
Author: User

1. Preparation of installation Environment
# Wget-o/etc/yum.repos.d/centos-base.repo Http://mirrors.aliyun.com/repo/Centos-6.repo
# yum Install cmake-y# yum install ncurses-devel-y# useradd-s/sbin/nologin-m MySQL
2, the compilation environment preparation
# mkdir/usr/local/mysql# mkdir/software# cd/software/
# TAR-ZXVF mysql-5.5.32.tar.gz #上传文件: mysql-5.5.32.tar.gz to:/software Directory # CD mysql-5.5.32
# CMake. -dcmake_install_prefix=/usr/local/mysql \
-dmysql_datadir=/usr/local/mysql/data \
-dmysql_unix_addr=/usr/local/mysql/tmp/mysql.sock \
-ddefault_charset=utf8 \
-DDEFAULT_COLLATION=UTF8_GENERAL_CI \
-DEXTRA_CHARSETS=GBK,GB2312,UTF8,ASCII \
-denabled_local_infile=on \
-dwith_innobase_storage_engine=1 \
-dwith_federated_storage_engine=1 \
-dwith_blackhole_storage_engine=1 \
-dwithout_example_storage_engine=1 \
-dwithout_partition_storage_engine=1 \
-dwith_fast_mutexes=1 \
-dwith_zlib=bundled \
-denabled_local_infile=1 \
-dwith_readline=1 \
-dwith_embedded_server=1 \
-dwith_debug=0
# Make && make install
3. Initialize MySQL database
#/usr/local/mysql/scripts/mysql_install_db--basedir=/usr/local/mysql/\
--datadir=/usr/local/mysql/data \
--user=mysql #初始化数据库 # cp/usr/local/mysql/support-files/mysql.server/etc/init.d/mysqld# #修改文件 :/ETC/MY.CNF, because my MySQL is installed under the/usr/local/mysql directory #[mysqld]# datadir =/usr/local/mysql/data# socket=/usr/local/mysql/ Tmp/mysql.sock
   
   
   >drop user "@" localhost ";

MySQL 5.5.32 Compilation Installation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.