加固mysql服务器
实验环境:CentOS7
[root@~ localhost]#yum -y install mariadb-server
[root@~ localhost]#mysql_secure_installation #数据库安全加固 NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB
SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY! In order to log into MariaDB to secure it, we'll need the current
password for the root user. If you've just installed MariaDB, 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): #默认密码为空,故只按回车键!密码为空不安全,需要首先设置
OK, successfully used password, moving on... Setting the root password ensures that nobody can log into the MariaDB
root user without the proper authorisation. Set root password? [Y/n] Y #是否设置root的登录密码:Y需要设置
New password:
Re-enter new password:
Password updated successfully! #密码已设置成功
Reloading privilege tables..
... Success! By default, a MariaDB installation has an anonymous user, allowing anyone
to log into MariaDB without having to have a user account created for
them. This is intended only for testing, and to make the installation
go a bit smoother. You should remove them before moving into a
production environment. Remove anonymous users? [Y/n] Y #是否移除anonymous用户
... Success! Normally, root should only be allowed to connect from 'localhost'. This
ensures that someone cannot guess at the root password from the network. Disallow root login remotely? [Y/n] Y #是否不允许root的远程登录
... Success! By default, MariaDB comes with a database named 'test' that anyone can
access. This is also intended only for testing, and should be removed
before moving into a production environment. Remove test database and access to it? [Y/n] n #是否移除test数据库,并禁止访问
... skipping. Reloading the privilege tables will ensure that all changes made so far
will take effect immediately. Reload privilege tables now? [Y/n] Y #是否重载权限表
... Success! Cleaning up... All done! If you've completed all of the above steps, your MariaDB
installation should now be secure. Thanks for using MariaDB!
加固mysql服务器的更多相关文章
- 闰秒导致MySQL服务器的CPU sys过高
今天,有个哥们碰到一个问题,他有一个从库,只要是启动MySQL,CPU使用率就非常高,其中sys占比也比较高,具体可见下图. 注意:他的生产环境是物理机,单个CPU,4个Core. 于是,他抓取了CP ...
- 如何配置远程mysql服务器
如何配置远程mysql服务器 分配用户权限 可以先看一下目前的用户权限状况: use mysql; select host,user,password from user; 然后分配新的权限给某一用户 ...
- MYSQL服务器my.cnf配置文档详解
MYSQL服务器my.cnf配置文档详解 硬件:内存16G [client] port = 3306 socket = /data/3306/mysql.sock [mysql] no-auto-re ...
- mysql服务器和配置优化
一.存储引擎 mysql中有多种存储引擎,一般常见的有三种: MyIsam InnoDB Memory 用途 快读 完整的事务支持 内存数据 锁 全表锁定 多种隔离级别的行锁 全表锁定 持久性 基 ...
- 远程连接mysql数据库时报错: 错误代码 2003不能连接到MySQL服务器在*.*.*.*(111)
在测试服务器上安装完mysql后, 服务器自己访问没有问题, 但是本地通过sql客户端连接时报错: 错误代码 2003不能连接到MySQL服务器在*.*.*.*(111).在网上查了一些资料,解决方案 ...
- 登录phpmyadmin提示: #1045 无法登录 MySQL 服务器
打开phpmyadmin,进行登录,出现以下问题,提示:#1045 无法登录 MySQL 服务器 或许出现以下错误情况:phpmyadmin:#1045 无法登录 MySQL 服务器.Access d ...
- 如何将自己的windows设置为mysql服务器
1.安装mysql 服务器 2.创建超级用户,即 用户管理 mysql>use mysql; 查看 mysql> select host,user,password from user ; ...
- 一台MySQL服务器启动多个端口
一台MySQL服务器启动多个端口 在测试Mysql多主一从服务器,即一个从服务器多端口同步不同主库.本文记录了开启不同端口的操作. 详细步骤: 1.首先要先把my.cnf配置文件复制一份,开几个端口要 ...
- 详解 Spotlight on MySQL监控MySQL服务器
前一章详解了Spotlight on Unix 监控Linux服务器 ,今天再来看看Spotlight on MySQL怎么监控MySQL服务器. 注:http://www.cnblogs.com/J ...
随机推荐
- struts2中的ModelDriven使用
http://www.cnblogs.com/Topless/archive/2012/01/17/2324980.html 例子都为struts2中的文档例子 JSP提交数据: <s:fo ...
- matlab 调用 python
众所周知,Python凭借其众多的第三方模块,近年来被数据分析.机器学习.深度学习等爱好者所喜爱,最主要的是Python还是开源的.另一方面,MATLAB因其在仿真方面的独特优势也被众多人追捧.而在国 ...
- 阿里云CentOS7安装Docker
买了阿里云主机,由于学生有优惠,玩起来确实爽. 系统版本: [root@lxd ~]# cat /etc/redhat-release CentOS Linux release 7.0.1406 (C ...
- 改善程序与设计的55个具体做法 day8
条款20:宁以pass-by-reference-to-const 替换 pass-by-value 即 以const引用 替换值传递. 采用引用传递参数时,底层往往是用指针方式实现,因此参数传递内置 ...
- Data Structure Binary Tree: Lowest Common Ancestor in a Binary Tree
http://www.geeksforgeeks.org/lowest-common-ancestor-binary-tree-set-1/ #include <iostream> #in ...
- UIView的概念与使用
什么是UIView UIView可以称之为控件/视图 屏幕上所有能看到的东西都是UIView 按钮(UIButton).文本(UILabel)都是控件 控件都有一些共同的属性 -- 尺寸 -- 位置 ...
- 剑指offer之 替换空格
package Problem4; public class ReplaceBank { /* * 题目描述: 请实现一个函数,将字符串的每个空格替换为"%20". * 例如输入& ...
- LINQ 学习路程 -- 查询操作 ThenBy & ThenByDescending
IList<Student> studentList = new List<Student>() { , StudentName = } , , StudentName = } ...
- 算法(Algorithms)第4版 练习 1.5.23
package com.qiusongde; import edu.princeton.cs.algs4.StdOut; public class Exercise1523 { public stat ...
- 之前收集的一波MaterialDesign库
material https://github.com/rey5137/material MaterialDesignLibrary md控件库,可兼容到2.2. https://github.com ...