Reset MariaDB password running on EC2 instance - AWS

0 votes
I have MariaDB running on an EC2 instance. How do I reset its password? The instance is of Linux 2.
Oct 11, 2019 in AWS by Hannah
• 18,520 points
1,059 views

1 answer to this question.

0 votes

Hey @Hannah, follow these steps:

1. Stop the MariaDB service:

sudo systemctl stop mariadb

2. Start MariaDB in safe mode:

sudo mysqld_safe --skip-grant-tables --skip-networking &

3.  Log in to the MariaDB monitor:

mysql -u root

4. Update your MariaDB root password:

UPDATE mysql.user SET Password = PASSWORD('new_password_here') WHERE User = 'root';

Output:

Query OK, 1 row affected (0.00 sec) Rows matched: 1 Changed: 1 Warnings: 0
answered Oct 11, 2019 by Yuvraj

Related Questions In AWS

0 votes
1 answer

Install RStudio on AWS EC2 instance

Amazon Linux AMI 2017.09.1 is based on ...READ MORE

answered Jul 27, 2018 in AWS by Priyaj
• 58,020 points
2,567 views
+1 vote
1 answer
0 votes
1 answer

Getting ORA-01882: timezone region not found with Oracle UCP, on aws ec2 instance?

You can pass command line argument -Duser.timezone=<Database Time ...READ MORE

answered Oct 3, 2018 in AWS by Priyaj
• 58,020 points
4,247 views
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
+1 vote
2 answers

How do I run python script on aws EC2 instance(ubuntu)?

I believe that you are using the ...READ MORE

answered Apr 17, 2018 in AWS by Cloud gunner
• 4,670 points
10,313 views
+1 vote
2 answers

AWS EC2 - Can't launch an instance - Account blocked

Try launching the Instance using CLI or ...READ MORE

answered Aug 7, 2018 in AWS by Priyaj
• 58,020 points
16,095 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP