云服务器配置CentOS7.6(⼆)--安装mySQL
⽂章⽬录
1. mysql下载地址
2.下载mysql5.6
2.1 在云服务器上下载mysql5.6
2.2 先下载到本地磁盘。再上传到云服务器
rz -y
如果rz -y 不弹窗,就需要安装
yum install lrzsz -y
先建⽴⼀个mysql5.6⽂件夹,将mysql下载到该⽂件夹中,如下图
3.在安装之前,检查⼀下有没有系统⾃带的mysql相关的rpm⽂件,若有卸载掉mysql一级缓存和二级缓存
卸载rpm的命令rpm -e 或者rpm -e --nodeps
rpm -qa |grep -i mysql
rpm -e --nodeps mysql-libs-5.1.71-1.el6.x86_64
防⽌系统已经安装了其他版本的mysql-libs包和mysql数据库⽂件导致不兼容。不执⾏这句,mysql可能⽆法启动yum remove mysql-libs
检查⼀下有没有系统⾃带的mysql相关的rpm⽂件,发现有⼀个卸载掉
再次校验
4.开始安装–安装命令
安装命令如下
若安装mysql警告: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY 原因:这是由于yum安装了旧版本的GPG keys造成的
解决办法:后⾯加上
–force --nodeps
rpm -ivh MySQL-client-5.6.47-1.el7.x86_64.rpm --force --nodeps
rpm -ivh MySQL-server-5.6.47-1.el6.x86_64.rpm --force --nodeps
rpm -ivh MySQL-devel-5.6.47-1.el7.x86_64.rpm --force --nodeps
若还是出现:解决办法 后⾯加上–nosignature
rpm -ivh MySQL-server-5.6.47-1.el6.x86_64.rpm --nosignature
rpm -ivh MySQL-client-5.6.47-1.el7.x86_64.rpm --nosignature
rpm -ivh MySQL-devel-5.6.47-1.el7.x86_64.rpm --nosignature
若出现以下错误
执⾏以下命令,安装perl依赖
yum install -arch
安装完server后的信息提⽰
[root@instance-6uz2q7zs home]# rpm -ivh MySQL-server-5.6.47-1.el6.x86_64.rpm --force --nosignature
<                          >>>>>>### [100%]
Updating /
1:MySQL-server-5.6.47-1.el6        >>>>>>### [100%]
warning: user mysql does not exist - using root
warning: group mysql does not exist - using root
warning: user mysql does not exist - using root
warning: group mysql does not exist - using root
2020-02-04 13:54:24 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see  documentation for more details).
2020-02-04 13:54:24 0 [Note] Ignoring --secure-file-priv value as server is running with --bootstrap.
2020-02-04 13:54:24 0 [Note] /usr/sbin/mysqld (mysqld 5.6.47) starting as process 15276 ...
2020-02-04 13:54:24 15276 [Note] InnoDB: Using atomics to ref count buffer pool pages
2020-02-04 13:54:24 15276 [Note] InnoDB: The InnoDB memory heap is disabled
2020-02-04 13:54:24 15276 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2020-02-04 13:54:24 15276 [Note] InnoDB: Memory barrier is not used
2020-02-04 13:54:24 15276 [Note] InnoDB: Compressed tables use zlib 1.2.11
2020-02-04 13:54:24 15276 [Note] InnoDB: Using Linux native AIO
2020-02-04 13:54:24 15276 [Note] InnoDB: Using CPU crc32 instructions
2020-02-04 13:54:24 15276 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2020-02-04 13:54:24 15276 [Note] InnoDB: Completed initialization of buffer pool
2020-02-04 13:54:24 15276 [Note] InnoDB: The first specified data file ./ibdata1 did not exist: a new database to be created!
2020-02-04 13:54:24 15276 [Note] InnoDB: Setting file ./ibdata1 size to 12 MB
2020-02-04 13:54:24 15276 [Note] InnoDB: Database physically writes the file full:
2020-02-04 13:54:24 15276 [Note] InnoDB: Setting log file ./ib_logfile101 size to 48 MB
2020-02-04 13:54:25 15276 [Note] InnoDB: Setting log file ./ib_logfile1 size to 48 MB
2020-02-04 13:54:25 15276 [Note] InnoDB: Renaming log file ./ib_logfile101 to ./ib_logfile0
2020-02-04 13:54:25 15276 [Warning] InnoDB: New log files created, LSN=45781
docker安装网心云教程
2020-02-04 13:54:25 15276 [Note] InnoDB: Doublewrite buffer not found: creating new
2020-02-04 13:54:25 15276 [Note] InnoDB: Doublewrite buffer created
2020-02-04 13:54:25 15276 [Note] InnoDB: 128 rollback segment(s) are active.
2020-02-04 13:54:25 15276 [Warning] InnoDB: Creating foreign key constraint system tables.
2020-02-04 13:54:25 15276 [Note] InnoDB: Foreign key constraint system tables created
2020-02-04 13:54:25 15276 [Note] InnoDB: Creating tablespace and datafile system tables.
2020-02-04 13:54:25 15276 [Note] InnoDB: Tablespace and datafile system tables created.
2020-02-04 13:54:25 15276 [Note] InnoDB: Waiting for purge to start
2020-02-04 13:54:25 15276 [Note] InnoDB: 5.6.47 started; log sequence number 0编程课免费学习
2020-02-04 13:54:25 15276 [Note] InnoDB: 5.6.47 started; log sequence number 0
2020-02-04 13:54:25 15276 [Note] RSA private key file not found: /var/lib/mysql//private_key.pem. Some authentication plugins will not work.
2020-02-04 13:54:25 15276 [Note] RSA public key file not found: /var/lib/mysql//public_key.pem. Some authentication plugins will not work.
A random root password has been set. You will find it in '/root/.mysql_secret'.
2020-02-04 13:54:25 15276 [Note] Binlog end
2020-02-04 13:54:25 15276 [Note] InnoDB: FTS optimize thread exiting.
2020-02-04 13:54:25 15276 [Note] InnoDB:
2020-02-04 13:54:27 15276 [Note] InnoDB: Shutdown completed; log sequence number 1625977
2020-02-04 13:54:27 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see  documentation for more details).
2020-02-04 13:54:27 0 [Note] Ignoring --secure-file-priv value as server is running with --bootstrap.
2020-02-04 13:54:27 0 [Note] /usr/sbin/mysqld (mysqld 5.6.47) starting as process 15303 ...
2020-02-04 13:54:27 15303 [Note] InnoDB: Using atomics to ref count buffer pool pages
2020-02-04 13:54:27 15303 [Note] InnoDB: The InnoDB memory heap is disabled
2020-02-04 13:54:27 15303 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2020-02-04 13:54:27 15303 [Note] InnoDB: Memory barrier is not used
2020-02-04 13:54:27 15303 [Note] InnoDB: Compressed tables use zlib 1.2.11
2020-02-04 13:54:27 15303 [Note] InnoDB: Using Linux native AIO
2020-02-04 13:54:27 15303 [Note] InnoDB: Using CPU crc32 instructions
2020-02-04 13:54:27 15303 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2020-02-04 13:54:27 15303 [Note] InnoDB: Completed initialization of buffer pool
2020-02-04 13:54:27 15303 [Note] InnoDB: Highest supported file format is Barracuda.
2020-02-04 13:54:27 15303 [Note] InnoDB: 128 rollback segment(s) are active.
2020-02-04 13:54:27 15303 [Note] InnoDB: Waiting for purge to start
2020-02-04 13:54:27 15303 [Note] InnoDB: 5.6.47 started; log sequence number 1625977
html5的表单验证功能2020-02-04 13:54:27 15303 [Note] RSA private key file not found: /var/lib/mysql//private_key.pem. Some authentication plugins will not work.
2020-02-04 13:54:27 15303 [Note] RSA public key file not found: /var/lib/mysql//public_key.pem. Some authentication plugins will not work.
2020-02-04 13:54:27 15303 [Note] Binlog end
2020-02-04 13:54:27 15303 [Note] InnoDB: FTS optimize thread exiting.
2020-02-04 13:54:27 15303 [Note] InnoDB:
2020-02-04 13:54:29 15303 [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.
See the manual for more instructions.mvc是什么牌子衣服
Please report any problems at sql/
The latest information about MySQL is available on the web at
sql
Support MySQL by buying support/licenses at sql
mysql是什么系统New default config file was created as /usr/myf and
will be used by default by the server when you start it.
You may edit this file to change server settings
You may edit this file to change server settings
WARNING: Default config file /etc/myf exists on the system This file will be read by default by the MySQL server
If you do not want to use this, either remove it, or use the
--defaults-file argument to mysqld_safe when starting the server
5.开启mysql服务并配置
5.1 开启mysql服务和停⽌mysql服务
service mysql start
service mysql stop
如下图
我们可以查看进程中有没有mysql
ps -ef | grep mysql

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。

发表评论