Ci-dessous, les différences entre deux révisions de la page.
Prochaine révision Les deux révisions suivantes | |||
linux:mariadb [10-09-2017 17:59] edmc73 créée |
linux:mariadb [07-06-2018 15:50] edmc73 |
||
---|---|---|---|
Ligne 18: | Ligne 18: | ||
Query OK, 0 rows affected (0.00 sec) | Query OK, 0 rows affected (0.00 sec) | ||
+ | </ | ||
+ | |||
+ | ===== Commandes ===== | ||
+ | |||
+ | Voir la liste des users | ||
+ | |||
+ | < | ||
+ | mysql> select host,user from mysql.user; | ||
+ | +-----------+------------------+ | ||
+ | | host | user | | ||
+ | +-----------+------------------+ | ||
+ | | % | toto | | ||
+ | | 127.0.0.1 | root | | ||
+ | | ::1 | root | | ||
+ | | debian | ||
+ | | localhost | api | | ||
+ | | localhost | debian-sys-maint | | ||
+ | | localhost | root | | ||
+ | +-----------+------------------+ | ||
+ | </ | ||
+ | |||
+ | |||
+ | |||
+ | Voir les privilèges | ||
+ | |||
+ | < | ||
+ | mysql> SELECT * FROM information_schema.user_privileges; | ||
+ | +--------------------------------+---------------+-------------------------+--------------+ | ||
+ | | GRANTEE | ||
+ | +--------------------------------+---------------+-------------------------+--------------+ | ||
+ | | ' | ||
+ | | ' | ||
+ | | ' | ||
+ | | ' | ||
+ | | ' | ||
+ | | ' | ||
+ | | ' | ||
+ | | ' | ||
+ | | ' | ||
+ | ... | ||
+ | </ | ||
+ | |||
+ | |||
+ | < | ||
+ | mysql> show grants for ' | ||
+ | +----------------------------------------------------------------------------------------------------------------------------------------+ | ||
+ | | Grants for root@localhost | ||
+ | +----------------------------------------------------------------------------------------------------------------------------------------+ | ||
+ | | GRANT ALL PRIVILEGES ON *.* TO ' | ||
+ | | GRANT PROXY ON '' | ||
+ | +----------------------------------------------------------------------------------------------------------------------------------------+ | ||
</ | </ |