Home IT Linux Windows Database Network Programming Server Mobile  
           
  Home \ Database \ Linux5 install MySQL 5.6 (RPM mode)     - Linux in order to make NMAP hide and seek with the firewall (Linux)

- Production environment Linux bonding method standby mode slave card switch (Server)

- Practical top command (Linux)

- awk Programming Model (Programming)

- MySQL error: ERROR 1175: You are using safe update mode solution (Database)

- Why do you need close contact Rust 1.0 (Programming)

- Detailed LVM2 (Linux)

- GCC library link order problems (Programming)

- Dalvik heap memory management and recycling (Linux)

- Use eCryptFS encrypt files and directories on Linux (Linux)

- Usage sed some of the parameters (Linux)

- Repair Chrome for Linux is (Linux)

- Boost notes --Asio - (1) a simple small example of synchronous communication (Programming)

- Spark parquet merge metadata problem (Server)

- OpenSSH server configuration file for each Common Definition (Server)

- C ++ CBitmap, HBitmap, Bitmap difference and contact (Programming)

- JDK installation and configuration environment variable under linuxb (Linux)

- To configure Samba to share files with Windows under CentOS (Linux)

- Java look and feel mode (Facade mode) (Programming)

- Installing software on Ubuntu: apt-get and dpkg difference (Linux)

 
         
  Linux5 install MySQL 5.6 (RPM mode)
     
  Add Date : 2018-11-21      
         
       
         
  MySQL is widely used in many fields, especially a lot of Internet companies, such as Tencent, Ali, and so on. In this paper, under Linux 5 is installed by rpm way Mysql, this is a relatively simple installation, the specific detailed below.
1. Prepare installation file
Download page: http: //dev.mysql.com/downloads/mysql/
Locate the file version and the corresponding required for download, if download is tar file, use tar decompression
I am in the Oracle Edelivery download, so as V44331-01.zip
# Installation environment
[Root @ linux1 Mysql_src] # cat / etc / issue
Enterprise Linux Enterprise Linux Server release 5.5 (Carthage)
Kernel \ r on an \ m
# Source file path
[Root @ linux1 Mysql_src] # pwd
/ Mysql_src
[Root @ linux1 Mysql_src] # unzip V44331-01.zip
Archive: V44331-01.zip
 extracting: MySQL-embedded-advanced-5.6.17-1.rhel5.i386.rpm
 extracting: MySQL-test-advanced-5.6.17-1.rhel5.i386.rpm
 extracting: MySQL-shared-advanced-5.6.17-1.rhel5.i386.rpm # MySQL shared libraries
 extracting: MySQL-devel-advanced-5.6.17-1.rhel5.i386.rpm # MySQL libraries and header files
 extracting: MySQL-client-advanced-5.6.17-1.rhel5.i386.rpm # MySQL client programs
 extracting: MySQL-server-advanced-5.6.17-1.rhel5.i386.rpm # MySQL server program
 extracting: MySQL-shared-compat-advanced-5.6.17-1.rhel5.i386.rpm # RHEL compatible package
 extracting: README.txt

 

2, MySQL default installation path
 Directory Contents of Directory
/ Usr / bin Client programs and scripts
/ Usr / sbin The mysqld server
/ Var / lib / mysql Log files, databases
/ Usr / share / info Manual in Info format
/ Usr / share / man Unix manual pages
/ Usr / include / mysql Include (header) files
/ Usr / lib / mysql Libraries
/ Usr / share / mysql Miscellaneous support files, including error messages,
                        character set files, sample configuration files, SQL for database installation
/ Usr / share / sql-bench Benchmarks

 

3, the installation MySQL
[Root @ linux1 Mysql_src] # rpm -ivh MySQL-server-advanced-5.6.17-1.rhel5.i386.rpm
Preparing ... ########################################### [100% ]
  1: MySQL-server-advanced ########################################### [100%]
2014-04-15 17:26:59 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated.
Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2014-04-15 17:26:59 6524 [Note] InnoDB: Using mutexes to ref count buffer pool pages
                  ...........................
2014-04-15 17:27:06 6558 [Note] InnoDB: FTS optimize thread exiting.
2014-04-15 17:27:06 6558 [Note] InnoDB: Starting shutdown ...
2014-04-15 17:27:08 6558 [Note] InnoDB: Shutdown completed; log sequence number 1625987

A RANDOM PASSWORD HAS BEEN SET FOR THE MySQL root USER!
You will find that password in '/root/.mysql_secret'.

You must change that password on your first connect,
no other statement but 'SET PASSWORD' will be accepted.
See the manual for the semantics of the 'password expired' flag.

Also, the account for the anonymous user has been removed.

In addition, you can run:

  / Usr / bin / mysql_secure_installation

which will also give you the option of removing the test database.
This is strongly recommended for production servers.

                  ...... ....... Snip
New default config file was created as /usr/my.cnf and
will be used by default by the server when you start it.
You may edit this file to change server settings

[Root @ linux1 Mysql_src] # rpm -ivh MySQL-client-advanced-5.6.17-1.rhel5.i386.rpm
Preparing ... ########################################### [100% ]
  1: MySQL-client-advanced ########################################### [100%]

[Root @ linux1 Mysql_src] # rpm -ivh MySQL-devel-advanced-5.6.17-1.rhel5.i386.rpm
Preparing ... ########################################### [100% ]
  1: MySQL-devel-advanced ########################################### [100%]
4, initialize MySQL and password
[Root @ linux1 Mysql_src] # service mysql start
Starting MySQL .. [OK]
[Root @ linux1 Mysql_src] # more /root/.mysql_secret
# The random password set for the root user at Tue Apr 15 17:27:05 2014 (local time): lyHfNb87EBXhJDe2

[Root @ linux1 Mysql_src] # mysql -u root -p
Enter password:
Welcome to the MySQL monitor Commands end with;. Or \ g.
Your MySQL connection id is 2
Server version: 5.6.17-enterprise-commercial-advanced

mysql> set PASSWORD = PASSWORD ( 'mysql');
Query OK, 0 rows affected (0.01 sec)

mysql> show databases;
+ -------------------- +
| Database |
+ -------------------- +
| Information_schema |
| Mysql |
| Performance_schema |
| Test |
+ -------------------- +
4 rows in set (0.03 sec)

 

5 to allow remote login
mysql> use mysql;
Database changed
mysql> select host, user, password from user;
+ ------------------- + ------ + ---------------------- --------------------- +
| Host | user | password |
+ ------------------- + ------ + ---------------------- --------------------- +
| Localhost | root | * E74858DB86EBA20BC33D0AECAE8A8108C56B17FA |
| Linux1.orasrv.com | root | * AE207AEF7D22B37183E435AAE64CECF7102A2DB2 |
| 127.0.0.1 | root | * AE207AEF7D22B37183E435AAE64CECF7102A2DB2 |
| :: 1 | root | * AE207AEF7D22B37183E435AAE64CECF7102A2DB2 |
+ ------------------- + ------ + ---------------------- --------------------- +
4 rows in set (0.02 sec)

mysql> update user set password = password ( 'mysql') where user = 'root';
mysql> update user set host = '%' where user = 'root' and host = 'localhost';
mysql> flush privileges;
mysql> exit

6, configure boot from the start
[Root @ linux1 Mysql_src] # chkconfig --list mysql
mysql 0: off 1: off 2: on 3: on 4: on 5: on 6: off
If not, use chkconfig mysql on set from the start
     
         
       
         
  More:      
 
- How to view information about the installed version of CentOS (Linux)
- Packages with Snort intrusion monitoring light (Linux)
- Basic Operation Linux files and directories (Linux)
- Introduction Linux namespace (Linux)
- On event processing browser compatibility notes (Programming)
- Go powerful development server simple example (Server)
- TCP network communication Java Programming (Programming)
- Java abstract class instantiation (Programming)
- Linux Routine Task Scheduler (Linux)
- Android custom ViewPager create kaleidoscopic image transition effects (Programming)
- The Linux kernel and AVL tree in red-black tree (Programming)
- Installation Mesos + Marathon + Zookeeper under CentOS 7 (Server)
- CentOS 6.4 compiler installed MySQL 5.6.14 (Database)
- Linux, modify the hostname (Linux)
- Docker container plaintext password problem-solving way (Server)
- Some practical tips Linux (Linux)
- LAMP environment to build Apache, MySQL, PHP under Ubuntu (Server)
- Use Python automatically cleared Android Engineering excess resources (Programming)
- cursor_sharing induced error ORA-00600 (Database)
- How to install PlayOnLinux 4.2.5 under Ubuntu 14.04 / 12.04 (Linux)
     
           
     
  CopyRight 2002-2016 newfreesoft.com, All Rights Reserved.