MYSQL (Mariadb) root ww resetten

sudo /etc/init.d/mysql stop
sudo /etc/init.d/mysqld stop
sudo mysqld_safe –skip-grant-tables &
mysql -uroot

use mysql; update user set password=PASSWORD(“mynewpassword”) where User=’root’;
flush privileges;
quit

sudo /etc/init.d/mysqld stop …
sudo /etc/init.d/mysqdl start

mysql -u root -p