Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Installation and configuration on CentOS MYSQL supports INNODB engine

2025-04-06 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

To install the MYSQL database, refer to:

Http://dev.mysql.com/doc/refman/5.7/en/linux-installation-yum-repo.html

In short, it is:

1) download MySQL Yum repository

Http://dev.mysql.com/downloads/repo/yum/

2) install MySQL Yum repository

Yum localinstall mysql57-community-release-el6- {version-number} .noarch.rpm

3) install MYSQL database

Yum install mysql-community-server

two。 Support for INNODB engine

1) modify the configuration file: / etc/my.cnf

Add default-storage-engine=INNODB to the [mysqld] field in the configuration file, and change the default database engine to InnoDB

2) restart the database

3) when creating a table, add the ENGINE = InnoDB; directive, such as:

Create table mytable (id int not null auto_increment, name varchar (32) not null,) ENGINE = InnoDB

3. Create a database that supports the utf8 character set

If you want to support wide-byte languages such as Chinese, the database needs to use utf8 character encoding. When building the database, it is clearly stated:

CREATE DATABASE mydb DEFAULT CHARSET utf8 COLLATE utf8_general_ci

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report