MySQL 5.5 Installation

Source: Internet
Author: User

1, install mysql5.5 and 5.5 or more need to install CMake

1) Download CMake

wget--no-check-certificate http://www.cmake.org/files/v2.8/cmake-2.8.7.tar.gz

2) Unzip the build installation

Install the packages that you depend on first:

Yum-y Install gcc*

Tar zvxf cmake-2.8.7.tar.gz

CD cmake-2.8.7

./configure

Make && make install

2. Install MySQL

1) Download MySQL

wget http://mirrors.sohu.com/mysql/MySQL-5.5/mysql-5.5.47.tar.gz

2) Create MySQL user and user group

Groupadd MySQL

useradd-g MySQL MySQL

3) Unzip the installation

Tar zvxf mysql-5.5.47.tar.gz

CD mysql-5.5.47

Compile with CMake:

Cmake-dcmake_install_prefix=/usr/local/mysql \

-dmysql_datadir=/mysql/data \

-ddefault_charset=utf8 \

-DDEFAULT_COLLATION=UTF8_GENERAL_CI \

-dwith_extra_charsets:string=all \

-dwith_debug=0 \

-dwith_ssl=yes \

-dwith_readline=1 \

-denabled_local_infile=1

Make && make install

4) Create a new MySQL permissions table

Mkdir-p/mysql/data

./scripts/mysql_install_db--user=mysql-datadir=/mysql/data

#此处如不指定datadir, the error will be at startup

5) Permission settings

Cd/usr/local/mysql

Chown-r Mysql:mysql/usr/local/mysql

Chown-r Root.

Chown-r MySQL Data

CP SUPPORT-FILES/MY-MEDIUM.CNF/ETC/MY.CNF

/usr/local/mysql/bin/mysqld_safe--user=mysql &

CP Support-files/mysql.server/etc/init.d/mysqld

chmod +x/etc/init.d/mysqld

/etc/init.d/mysqld start

6) Verification

/usr/local/mysql/bin/mysql

Select @ @version


This article is from the "Linux" blog, so be sure to keep this source http://syklinux.blog.51cto.com/9631548/1759080

MySQL 5.5 Installation

Related Article

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.