Home > Database > Mysql Tutorial > MySQL安全设置图文教程

MySQL安全设置图文教程

WBOY
Release: 2016-06-07 18:03:28
Original
767 people have browsed it

MySQL安全设置,跟mssql差不多都是以普通用户权限运行mysql。其它的也需要注意下。

代码如下:
解压mysql到d:\mysql,编辑my.ini

[mysqld]
port=3306
basedir="D:/mysql/"
datadir="D:/mysql/Data/"
tmpdir="d:/mysql/tmp/"
default-character-set=utf8
default-storage-engine=MYISAM
skip-bdb
skip-innodb
skip-locking

key_buffer=16M
max_allowed_packet=1M
table_cache=128
thread_cache=8
join_buffer_size=512K
sort_buffer=512K
record_buffer=512K
max_connections=500
wait_timeout=120
interactive_timeout=120
max_connect_errors=3000
long_query_time=1
max_heap_table_size=16M
tmp_table_size=8M
thread_concurrency=8
myisam_sort_buffer_size=8M
myisam_sort_buffer_size=4M
low_priority_updates=1
ft_min_word_len=1
编辑两个
安装
d:
cd D:\mysql\bin
mysqld-nt.exe --install MySQL --defaults-file=D:\mysql\my.ini
net start mysql
pause
卸载
d:
cd D:\APM\mysql\bin
net stop mysql
mysqld-nt.exe --remove MySQL
pause

代码如下:
添加一个mysql启动用户,设置此用户为guest组,
设置d:\mysql目录为administrators组、system、新加的用户完全权限。
设置mysql服务的启动帐户为新加的用户,重新启动mysql服务。
设置拒绝本地登陆。

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template