ubuntu mysql root password code example
Example 1: mysql set root password
use mysql;
update user set authentication_string=PASSWORD("mynewpassword") where User='root';
flush privileges;
quit
Example 2: ubuntu mysql-server default root password
sudo mysql --defaults-file=/etc/mysql/debian.cnf