重庆分公司,新征程启航

为企业提供网站建设、域名注册、服务器等服务

怎么装mysql 怎么装mysql服务

mysql安装教程

mysql安装教程具体步骤如下:

创新互联建站是一家企业级云计算解决方案提供商,超15年IDC数据中心运营经验。主营GPU显卡服务器,站群服务器,西部信息服务器租用,海外高防服务器,机柜大带宽租用·托管,动态拨号VPS,海外云手机,海外云服务器,海外服务器租用托管等。

工具:联想笔记本电脑。

1、打开下载的安装文件,出现如下界面。

2、mysql安装向导启动,点击“next”继续。

3、选择安装类型,有“Typical(默认)”、“Complete(完全)”、“Custom(用户自定义)”三个选项,我们选择“Custom”,有更多的选项,也方便熟悉安装过程。

4、在“MySQLServer(MySQL服务器)”上左键单击,选择“Thisfeature,andallsubfeatures,willbeinstalledonlocalharddrive.”,即“此部分,及下属子部分内容。

5、正在安装中,请稍候,直到出现下面的界面。

6、点击“next”继续,出现如下界面。

7、现在软件安装完成了,出现上面的界面,这里有一个很好的功能,mysql配置向导,不用向以前一样。

8、自己手动乱七八糟的配置my.ini了,将“ConfiguretheMysqlServernow”前面的勾打上,点“Finish”结束。

如何下载安装mysql?

1.

下载MySQL压缩包 下载地址:MySQL :: Download MySQL Community Server (Archived Versions) 此处下载的是MySQL的5.7.31版本,windows,64位。 下载得到的zip压缩包:

2.

安装mysql mysql-5.3.71-winx64.zip是免安装的版本。 解压zip文件 将解压后的压缩包文件放入路径(不要有中文路径)(这里我放在了D:Program Files下)

3.

创建配置文件 在mysql安装目录下,创建一个my.ini配置文件,

如何安装MYSQL

使用yum安装mysql数据库的软件包 [root@xuegod63 ~]# yum -y install mariadb-server mariadb 。

注:  mariadb-server   #MariaDB数据库 mariadb      # MariaDB服务器Linux下客户端 。

注:从centos7系统开始,系统中自带的mysql数据库变成了mariadb-server,mariadb-server和mysql操作上一样。mariadb-server是mysql的一个分支。

启动数据库服务[root@xuegod63 ~]# systemctl start  mariadb  #启动MariaDB服务。[root@xuegod63 ~]# systemctl enable  mariadb  #设置开启自动启动MariaDB服务。

安装完mariadb-server后,运行mysql_secure_installation去除安全隐患,[root@xuegod63 ~]# mysql_secure_installation #进入安全配置导向。

NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MySQLSERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY!

In order to log into MySQL to secure it, we'll need the current,password for the root user. If you've just installed MySQL, and,you haven't set the root password yet, the password will be blank,,so you should just press enter here.Enter current password for root (enter for none):   #初次运行直接回车,因为root用户没有密码。

OK, successfully used password, moving on,Setting the root password ensures that nobody can log into the MySQL,root user without the proper authorisation.,Set root password? [Y/n] Y #是否设置root用户密码,输入Y。

New password: 123456   #新密码123456,Re-enter new password: 123456,Password updated successfully!Remove anonymous users? [Y/n] Y   #是否删除匿名用户,生产环境建议删除,所以直接回车或Y。

Success!Normally, root should only be allowed to connect from 'localhost'.  Thisensures that someone cannot guess at the root password from the network.Disallow root login remotely? [Y/n] Y  #是否禁止root远程登录,根据自己的需求选择Y/n并回车建议禁止。

Success!By default, MariaDB comes with a database named 'test' that anyone canaccess.  This is also intended only for testing, and should be removedbefore moving into a production environment.Remove test database and access to it? [Y/n] Y   #是否删除test数据库,直接回车或Y。


当前文章:怎么装mysql 怎么装mysql服务
本文网址:http://cqcxhl.com/article/dopcjio.html

其他资讯

在线咨询
服务热线
服务热线:028-86922220
TOP