Tag Archives: MySql Install Error

centos Compile and install mysql error: make[2]: *** [storage/perfschema/unittest/pfs_connect_attr-t]

Error Messages:

/opt/install-files/Package/mysql-5.7.38/sql/rpl_binlog_sender.cc:828: undefined reference to `user_var_entry::val_int(char*) const'
collect2: error: ld returned 1 exit status
make[2]: *** [storage/perfschema/unittest/pfs_connect_attr-t] Error 1
make[1]: *** [storage/perfschema/unittest/CMakeFiles/pfs_connect_attr-t.dir/all] Error 2
make: *** [all] Error 2

 

Solution:

Delete the parameter -DWITH_PARTITION_STORAGE_ENGINE=1 in cmake and re-compile

[Solved] MySQL Install Error: GPG check FAILED

I just got a Huawei Cloud ECS and chose Centos8 system, today I installed mysql, the version I chose is 5.7.

Import of key(s) didn't help, wrong key(s)?
Public key for mysql-community-client-5.7.39-1.el7.x86_64.rpm is not installed. Failing package is: mysql-community-client-5.7.39-1.el7.x86_64
 GPG Keys are configured as: file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
Public key for mysql-community-common-5.7.39-1.el7.x86_64.rpm is not installed. Failing package is: mysql-community-common-5.7.39-1.el7.x86_64
 GPG Keys are configured as: file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
Public key for mysql-community-libs-5.7.39-1.el7.x86_64.rpm is not installed. Failing package is: mysql-community-libs-5.7.39-1.el7.x86_64
 GPG Keys are configured as: file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
Public key for mysql-community-server-5.7.39-1.el7.x86_64.rpm is not installed. Failing package is: mysql-community-server-5.7.39-1.el7.x86_64
 GPG Keys are configured as: file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
The downloaded packages were saved in cache until the next successful transaction.
You can remove cached packages by executing 'yum clean packages'.
Error: GPG check FAILED 

Solution:

Re-import secret key

rpm --import https://repo.mysql.com/RPM-GPG-KEY-mysql-2022

Then execute the installation command

yum -y install mysql-community-server

MySQL Install Error: MySQL error 1042: Unable to connect to any of the specified MySQL hosts

The following error occurred in the last step of installing MySQL:
MySQL error 1042: unable to connect to any of the specified MySQL hosts

There are two solutions

First, treat the symptoms but not the root cause. Open Win + R and run it. Enter services.msc to open the service. Find the service name added when installing mysql. Generally, MySQL version 8.0 is MySQL 80 by default. Double click to open it. Under the login tab, change the selected account to the local system account.

It’s OK to execute after the application is confirmed, but this method needs to be operated once every time you reload mysql.

Another way is to configure group policy, which is a problem caused by the permission management of windows. The steps are as follows:
right click this computer – > Management – > Local users and groups – > Group – > Double click administrators – > Add – > Advanced
add network service to the administrators group

MySql Install Error: Can‘t connect to local MySQL server through socket ‘/tmp/mysql.sock‘

@[TOC] (error 2002 (HY000): can’t connect to local MySQL server through socket ‘/ TMP/MySQL. Socket’)

System overview

CentOS 7 + MySql-community-release-el6-5.noarch。

Install MySQL process

First, download the RPM installation package as follows:
WGet – P/usr/software/ http://repo.mysql.com/mysql-community-release-el-5.noarch.rpm
Then, run the following command to install the yum source:
RPM – IVH mysql-community-release-el-5. Noarch. RPM
after the yum source is installed, you can view it as follows:
ll/etc/yum. Repos. D/
if the yum source is installed correctly, It should be displayed:
total dosage 48
– rw-r – r–. 1 root 1664 November 23 2020 CentOS base. Repo
– rw-r – r–. 1 root 1309 November 23 2020 CentOS cr. repo
– rw-r – r–. 1 root 649 November 23 2020 CentOS debuginfo. Repo
– rw-r – r–. 1 root 314 November 23 2020 CentOS FastTrack. Repo
– rw-r – r–. 1 root 630 November 23 2020 Cen TOS media. Repo
– rw-r – r–. 1 root 1331 November 23 2020 CentOS sources. Repo
– rw-r – r–. 1 root 8515 November 23 2020 CentOS vault. Repo
– rw-r – r–. 1 root 616 November 23 2020 centos-x86_ Next, run the following command to install MySQL:
Yum – y install MySQL
at the end of the process, Run the following command to start MySQL service and report an error:
Service mysqld start
at this time, the error content is as shown in the question. After checking the above installation process with the following command, the packages to be installed are:
RPM – QA | grep MySQL
the packages to be seen at this time are as follows:
mysql-community-release-el6-5. Noarch
mysql-community-common-5.6.51-2. El6.x86_ 64
mysql-community-client-5.6.51-2.el6.x86_ 64
mysql-community-libs-5.6.51-2.el6.x86_ 64
you can see that there is no MySQL Server package in the above package. So next, install MySQL server with the following command:
Yum – y install MySQL server
after the above command is executed successfully, start MySQL service:
Service mysqld start
and then run:
MySQL – uroot to enter MySQL server.