In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Using source code installation, some parameters can be added according to the actual production environment to improve the performance of mysql.
Mysql official website https://www.mysql.com/
This article uses version 5.1 dedicated installation instructions, the later version such as 5.5 installation method will be somewhat different, it is also used in some production environments of the company
Version 5.1 mysql.
Download the mysql source code
Decompress tar zxf mysql-5.1.72.tar.gz
Cd mysql-5.1.72
Configuration
. / configure-- prefix=/usr/local/mysql\
-- with-unix-socket-path=/usr/local/mysql/tmp/mysql.sock\
-- localstatedir=/usr/local/mysql/data\
-- enable-assemble\
-- enable-thread-safe-client\
-- with-mysqld-user=mysql\
-- with-big-tables\
-- with-pthread\
-- with-extra-charsets=complex\
-- with-readline\
-- with-ssl\
-- with-mysqld-ldflags=-all-static\
-- with-client-ldflags=-all-static
[root@backupserver mysql-5.1.72] #. / configure-- help to view specific configuration parameters
Make&&make install
The development test template is used here
/ bin/cp support-files/my-small.cnf / etc/my.cnf
Create a database file
Mkdir-p / usr/local/mysql/data
Chown-R mysql / usr/local/mysql authorized mysql users can access the mysql directory
/ usr/local/mysql/bin/mysql_install_db-- user=mysql installs mysql database files
After installation, there will be some instructions, such as how to start and so on.
Installation instructions method to start mysql
/ usr/local/mysql/bin/mysqld_safe/usr/local/mysql/bin/mysqld_safe & & indicates running in the background
To start mysql more conveniently, you can add mysql to the global variable
Add mysql to the global variable echo 'export PATH=$PATH:/usr/local/mysql/bin' > > / etc/profile
Source / etc/profile
Execute mysql to enter the database
[root@backupserver mysql-5.1.72] # mysql
Welcome to the MySQL monitor. Commands end with; or\ g.
Your MySQL connection id is 1
Server version: 5.1.72 Source distribution
Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
Affiliates. Other names may be trademarks of their respective
Owners.
Configure / etc/init.d/mysqld to start mysql
Cp support-files/mysql.server / etc/init.d/mysqld
Chmod 700 / etc/init.d/mysqld Authorization
Add mysql service to boot
[root@backupserver mysql-5.1.72] # chkconfig-- add mysqld
[root@backupserver mysql-5.1.72] # chkconfig mysqld on
Mysql enters the database
Set the password set password for root@localhost=PASSWORD ('123456')
Then enter the mysql database in the form of mysql-uroot-p
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.