i used the solution here ERROR 1045(28005) : Access denied for user 'root@localhost' (using password: no ) but when i use the command
UPDATE mysql.user SET Password=PASSWORD('000') WHERE User='root'; FLUSH PRIVILEGES; exit;
i get this
bash: syntax error near unexpected token `('
=/usr/lib/jvm/java-8-oracle': not a valid identifier root@Anonymous:~# UPDATE mysql.user SET authentication_string=PASSWORD('000'), plugin='mysql_native_password' WHERE User='root' AND Host='localhost'; -bash: syntax error near unexpected token
('mysql>
. you enter the UPDATE command at the mysql prompt, not the bash prompt. Nowhere in the link you are following is the command "sudo -i" listed.