mariadb_user
Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
mariadb_user [2023/07/05 16:51] – [Suppression d'un user] pascal | mariadb_user [2023/07/05 19:13] (Version actuelle) – [Configuration] pascal | ||
---|---|---|---|
Ligne 24: | Ligne 24: | ||
4 rows in set (0,002 sec) | 4 rows in set (0,002 sec) | ||
</ | </ | ||
- | ===== Suppression | + | ===== Connexion |
+ | ==== 127.0.0.1 | ||
<code bash> | <code bash> | ||
- | MariaDB [(none)]> DROP USER foo@'10.%'; | + | root:~# mariadb -u foo -ppassword |
- | Query OK, 0 rows affected | + | ERROR 1045 (28000): Access denied for user 'foo'@'localhost' (using password: YES) |
</ | </ | ||
+ | ==== 10.1.40.1 ==== | ||
<code bash> | <code bash> | ||
- | MariaDB [(none)]> | + | root:~# mariadb -u foo -ppassword -h 10.1.40.1 |
- | Reading table information for completion of table and column names | + | Welcome |
- | You can turn off this feature | + | Your MariaDB connection id is 1350 |
+ | Server version: 10.11.3-MariaDB-1 Debian 12 | ||
- | Database changed | + | Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others. |
- | </ | + | |
- | <code bash> | + | Type ' |
- | MariaDB [mysql]> select Host, User, Password from user; | + | |
- | +-----------+-------------+----------+ | + | |
- | | Host | User | Password | | + | |
- | +-----------+-------------+----------+ | + | |
- | | localhost | mariadb.sys | | | + | |
- | | localhost | root | invalid | + | |
- | | localhost | mysql | invalid | + | |
- | +-----------+-------------+----------+ | + | |
- | 3 rows in set (0,002 sec) | + | |
</ | </ | ||
===== Suppression d'un user ===== | ===== Suppression d'un user ===== | ||
Ligne 69: | Ligne 63: | ||
+-----------+-------------+----------+ | +-----------+-------------+----------+ | ||
3 rows in set (0,002 sec) | 3 rows in set (0,002 sec) | ||
+ | </ | ||
+ | ===== Configuration ===== | ||
+ | En parallèle, il faut que le serveur accepte les connections venant du réseau local. | ||
+ | <code bash file=/ | ||
+ | [mysqld] | ||
+ | # Instead of skip-networking the default is now to listen only on | ||
+ | # localhost which is more compatible and is not less secure. | ||
+ | bind-address | ||
</ | </ | ||
===== Sources ===== | ===== Sources ===== | ||
Ligne 78: | Ligne 80: | ||
===== Sujets connexes ===== | ===== Sujets connexes ===== | ||
* [[mariadb|Installation de mariaDB]] | * [[mariadb|Installation de mariaDB]] | ||
+ | * [[mariadb_grant|Gestion des autorisations]] | ||
mariadb_user.1688575895.txt.gz · Dernière modification : 2023/07/05 16:51 de pascal