mysql

安装时出现的问题

问题1

1
linux mysql Child process: /usr/local/mysql/bin/mysqldterminated prematurely with errno= 32

解决

1
2
3
4
1./usr/local/mysql/bin/mysqld --defaults-file=/etc/my.cnf --basedir=/usr/local/mysql/ --datadir=/data/mysql/ --user=mysql --initialize
2.执行1如果出现/usr/local/mysql/bin/mysqld: error while loading shared libraries: libnuma.so.1: cannot open shared object file: No such file or directory
则执行yum install libaio -y
再/usr/local/mysql/bin/mysqld --defaults-file=/etc/my.cnf --basedir=/usr/local/mysql/ --datadir=/data/mysql/ --user=mysql --initialize

切换版本出现的问题

5.5切换到5.7

1
2
Caused by: sun.security.validator.ValidatorException: PKIX path building failed:
sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

解决方案1

1
2
3
4
5
6
7
8
修改驱动配置
driverClassName: com.mysql.jdbc.Driver
改为
driverClassName: com.mysql.cj.jdbc.Driver
修改mysql版本
<mysql.version>5.1.38</mysql.version>
改为
<mysql.version>8.0.13</mysql.version>

解决方案2

1
2
url: jdbc:mysql://59.110.0.196:3306/ry_dev?useSSL=true
useSSL=true改为useSSL=false