创建group test
groupadd test
创建用户test加入组test
useradd test -g test
系统会提示你为test输入密码 你输入test 回车即可
passwd test
date -s 12:00:00
mysql:操作
启动
/etc/init.d/mysqld start
/etc/init.d/mysqld stop
login:
mysql -uroot -p --socket=“这里ps aux|grep mysql查看socket目录”
creat user readonly identified by ‘readonly’
creat user ‘read-write’ identified by ‘read-write’
flush privileges
grant all privileges on . to root@’%’ identified by ‘password’
grant select on test.* to test@’%’ identified by ‘password’