From ad9aff6ce801c1476758d68c2f7c2a3d2570841b Mon Sep 17 00:00:00 2001 From: whirigoyen Date: Tue, 25 Oct 2022 15:05:20 +0200 Subject: [PATCH] =?UTF-8?q?Ajout=20cas=20cr=C3=A9ation=20nouvel=20admin=20?= =?UTF-8?q?with=20grant=20option?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- HowtoMySQL.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/HowtoMySQL.md b/HowtoMySQL.md index 4a03a258..202fdc0b 100644 --- a/HowtoMySQL.md +++ b/HowtoMySQL.md @@ -640,6 +640,13 @@ Si l'on ne connait pas le mot de passe, on peut utiliser le hash du mot de passe mysql> GRANT ALL PRIVILEGES ON foo.* TO 'jdoe'@'%' IDENTIFIED BY PASSWORD '*E355A1AB8251C0B7E02ED8483696B2F3954C05CC'; ~~~ +Pour créer un nouvel administrateur qui puisse également gérer les droits : + +~~~{.sql} +GRANT ALL PRIVILEGES ON *.* TO ''@'localhost' IDENTIFIED BY '' WITH GRANT OPTION; +~~~ + + ### Vérifications et réparations Pour vérifier et réparer toutes les tables (une sorte de *fsck* pour les tables), on lancera :