Home >Database >Mysql Tutorial >给mysql的root创建密码_MySQL

给mysql的root创建密码_MySQL

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOriginal
2016-06-01 13:40:55983browse

bitsCN.com
给mysql的root创建密码 mysql> SET PASSWORD FOR 'root' @ 'localhost' = PASSWORD ( 'newpass' );#给root创建一个密码mysql> mysqladmin -uroot password ab12  #同上mysql> mysqladmin –u用户名 -p旧密码 password 新密码;#修改root密码    mysql> create database 库名;#创建一个数据库mysql> show databases;#查看库mysql> 录入 grant all privileges on DB.* to test@localhost 
 identified by "1234" ; #增加一个用户test密码为1234,让他只可以在local
  bitsCN.com

Statement:
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