In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-03 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Msyql introduction
MySQL is a relational database management system developed by MySQl AB of Sweden and currently owned by Oracle. MySql is the most popular relational database, and Mysql is one of the best RDBMS applications in WEB applications.
Mysql associated databases store data in different tables, which increases speed and flexibility; SQL is the most commonly used standardized language for accessing databases, which is the first choice for small and medium-sized enterprises because of its small size, total cost of ownership and open source.
Installation of MySQL
Download a stable community version on the Mysql website. Its installation methods are yum installation, binary installation has been source code installation. There are advantages and disadvantages of various installations, which are not described in detail here. Let's start to install mysql.
System environment view
[root@web01 tools] # cat / etc/redhat-release
Centos 6.7
[root@web01 tools] # uname-rm
2.6.32-573.el6.x86_64 x861664
Download and install mysql
Groupadd mysql # create user groups
Useradd-g mysql-M-s / sbin/nologin mysql # create a user mysql and specify a group
Tar xf mysql-5.5.48-linux2.6-x86_64.tar.gz # decompress the downloaded binary package database
Mv mysql-5.5.48-linux2.6-x86_64 / application/mysql-5.5.48 # change the name of the database, here is a personal habit
Ln-s / application/mysql-5.5.48/ / application/mysql # as a link file to mysql
Chown mysql.mysql / application/mysql # modifies the group and owner of the database
/ application/mysql/scripts/mysql_install_db-basedir=/application/mysql/-datadir=/application/mysql/data-user=mysql-group=mysql # initialize the database After the execution of this command, you see two OK, which indicates success!
\ cp / application/mysql/support-filesmy-small.cnf / etc/my.cnf # configuration file for mysql
Since the sed-I's custom path is the custom path, we need to change the default startup path to the actual installation path of mysql
Ln-s / application/mysql/bin/* / usr/local/bin/# create environment variables
/ application/mysql/bin/mysqld_safe & # start the mysql process
Lsof-I: 330 check the startup status of mysql
At this point, the installation of mysql is complete.
Simple Optimization of MySQL
[root@LNMP ~] # cp / application/mysql/support-files/mysql.server / etc/init.d/mysqld
[root@LNMP ~] # sed-I's license engine usr _ server _ mysql _ engine _ etc/init.d/mysqld
[root@LNMP ~] # chmod + x / etc/init.d/mysqld
[root@LNMP] # lsof-I: 3306
[root@LNMP ~] # / etc/init.d/mysqld start
Starting MySQL.. SUCCESS!
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.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.