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

Linux platform installs Mysql 5.7with RPM package

2025-01-20 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

This article mainly explains "Linux platform installs Mysql 5.7with RPM package". The explanation in this article is simple and clear and easy to learn and understand. Please follow the editor's train of thought to study and learn "Linux platform installs Mysql 5.7with RPM package".

Download RPM's bundle package on Mysql's official website and extract it.

[root@localhost mysql5.7] # tar xvf mysql-5.7.12-1.el6.x86_64.rpm-bundle.tar

Install the Server package separately to report dependency errors.

[root@T400-kelong software] # rpm-ivh mysql-community-server-5.7.10-1.el6.x86_64.rpm

Warning: mysql-community-server-5.7.10-1.el6.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY

Error: Failed dependencies:

Mysql-community-client (x86-64) = 5.7.10-1.el6 is needed by mysql-community-server-5.7.10-1.el6.x86_64

Mysql-community-common (x86-64) = 5.7.10-1.el6 is needed by mysql-community-server-5.7.10-1.el6.x86_64

Add the required package, still report an error, missing another package.

[root@T400-kelong software] # rpm-ivh mysql-community-server-5.7.10-1.el6.x86_64.rpm mysql-community-common-5.7.10-1.el6.x86_64.rpm mysql-community-client-5.7.10-1.el6.x86_64.rpm

Warning: mysql-community-server-5.7.10-1.el6.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY

Error: Failed dependencies:

Mysql-community-libs (x86-64) = 5.7.10-1.el6 is needed by mysql-community-client-5.7.10-1.el6.x86_64

Add the required packages, continue to report errors, and conflict with version 5.1 that comes with the system.

[root@T400-kelong software] # rpm-ivh mysql-community-server-5.7.10-1.el6.x86_64.rpm mysql-community-common-5.7.10-1.el6.x86_64.rpm mysql-community-client-5.7.10-1.el6.x86_64.rpm mysql-community-libs-5.7.10-1.el6.x86_64.rpm

Warning: mysql-community-server-5.7.10-1.el6.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY

Preparing... # [100%]

File / usr/share/mysql/czech/errmsg.sys from install of mysql-community-common-5.7.10-1.el6.x86_64 conflicts with file from package mysql-libs-5.1.73-5.el6_6.x86_64

File / usr/share/mysql/danish/errmsg.sys from install of mysql-community-common-5.7.10-1.el6.x86_64 conflicts with file from package mysql-libs-5.1.73-5.el6_6.x86_64

Uninstall the mysql 5.1 installation package that reported an error

[root@T400-kelong software] # yum remove mysql-libs-5.1.73-5.el6_6.x86_64

Loaded plugins: fastestmirror, refresh-packagekit, security

Setting up Remove Process

Resolving Dependencies

There are unfinished transactions remaining. You might consider running yum-complete-transaction first to finish them.

-> Running transaction check

-> Package mysql-libs.x86_64 0RU 5.1.73-5.el6_6 will be erased

-> Processing Dependency: libmysqlclient.so.16 () (64bit) for package: perl-DBD-MySQL-4.013-3.el6.x86_64

-> Processing Dependency: libmysqlclient.so.16 (libmysqlclient_16) (64bit) for package: perl-DBD-MySQL-4.013-3.el6.x86_64

-> Running transaction check

-> Package perl-DBD-MySQL.x86_64 0RU 4.013-3.el6 will be erased

-> Finished Dependency Resolution

Dependencies Resolved

=

Package Arch Version Repository Size

=

Removing:

Mysql-libs x86 million 64 5.1.73-5.el6_6 @ base 4.0m

Removing for dependencies:

Perl-DBD-MySQL x8634 4.013-3.el6 @ base 338k

Transaction Summary

=

Remove 2 Package (s)

Installed size: 4.4 M

Is this ok [y/N]: y

Install the RPM package

[root@T400-kelong software] # rpm-ivh mysql-community-server-5.7.10-1.el6.x86_64.rpm mysql-community-common-5.7.10-1.el6.x86_64.rpm mysql-community-client-5.7.10-1.el6.x86_64.rpm mysql-community-libs-5.7.10-1.el6.x86_64.rpm

Warning: mysql-community-server-5.7.10-1.el6.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY

Preparing... # [100%]

1:mysql-community-common # [25]

2:mysql-community-libs # # [50%]

3:mysql-community-client # [75]

4:mysql-community-server # # [100%]

Start the database.

[root@T400-kelong sbin] # service mysqld start

Initialize MySQL database: [OK]

Starting mysqld: [OK]

[root@T400-kelong sbin] # service mysqld status

Mysqld (pid 4782) is running...

[root@T400-kelong sbin] # ps-ef | grep mysql

Root 4586 10 21:11 pts/1 00:00:00 / bin/sh / usr/bin/mysqld_safe-datadir=/var/lib/mysql-- socket=/var/lib/mysql/mysql.sock-- pid-file=/var/run/mysqld/mysqld.pid-- basedir=/usr-- user=mysql

Mysql 4782 4586 2 21:11 pts/1 00:00:00 / usr/sbin/mysqld-basedir=/usr-datadir=/var/lib/mysql-plugin-dir=/usr/lib64/mysql/plugin-user=mysql-log-error=/var/log/mysqld.log-pid-file=/var/run/mysqld/mysqld.pid-socket=/var/lib/mysql/mysql.sock

Root 4847 3857 0 21:11 pts/1 00:00:00 grep mysql

Log in to the ROOT user with a temporary password and change the ROOT password.

Grep 'temporary password' / var/log/mysql/mysqld.log

[root@T400-kelong sbin] # mysql-uroot-p

Enter password:

Welcome to the MySQL monitor. Commands end with; or\ g.

Your MySQL connection id is 4

Server version: 5.7.10

Copyright (c) 2000, 2015, 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.

Type 'help;' or'\ h' for help. Type'\ c'to clear the current input statement.

Mysql > alter user 'root'@'localhost' identified by' System#2013'

Query OK, 0 rows affected (0.00 sec)

Thank you for your reading, the above is the content of "Linux platform installs Mysql 5.7 with RPM package". After the study of this article, I believe you have a deeper understanding of the problem of installing Mysql 5.7 on Linux platform with RPM package, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!

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