[dev][mysql]備忘録

mysqld --console
mysql -u root
grant all privileges on *.* to 'yzn'@'localhost'
identified by 'some_pass' with grant option;

grant all privileges on *.* to 'yzn'@'192.168.0.%' with grant option;

grant all privileges on *.* to yzn@'192.168.0.0/255.255.255.0'
identified by 'some_pass' with grant option;

http://dev.mysql.com/doc/refman/5.0/en/windows-installation.html
http://dev.mysql.com/doc/refman/5.0/en/user-account-management.html

  • 4.3. 一般的なセキュリティ関連事項と MySQL アクセス制御システム

http://dev.mysql.com/doc/refman/4.1/ja/privilege-system.html

  • 4.4.4. MySQL 権限の初期設定

http://dev.mysql.com/doc/refman/4.1/ja/default-privileges.html

select * from mysql.user;
select * from mysql.db;