Score:0

Installing MySQL as database for airflow - password issue

in flag

I have Ubuntu 20.04.4 LTS (GNU/Linux 5.10.102.1-microsoft-standard-WSL2 x86_64) on WSL2.

I'm following this guide to install Mysql and have reached step 4 where I have chosen MEDIUM and was prompted to enter a new password.

(https://phoenixnap.com/kb/install-mysql-ubuntu-20-04)

sudo mysql_secure_installation

Connecting to MySQL using a blank password.
The 'validate_password' component is installed on the server.
The subsequent steps will run with the existing configuration
of the component.
Please set the password for root here.

New password:

Re-enter new password:

Estimated strength of the password: 100
Do you wish to continue with the password provided?(Press y|Y for Yes, any other key for No) : y
 ... Failed! Error: SET PASSWORD has no significance for user 'root'@'localhost' as the authentication method used doesn't store authentication data in the MySQL server. Please consider using ALTER USER instead if you want to change authentication parameters.

then it keeps me asking me for a new password with this error.

Later on, when I try to use these commands for setting up a MySQL database:

CREATE DATABASE airflow_db CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER 'airflow_user' IDENTIFIED BY 'airflow_pass';
GRANT ALL PRIVILEGES ON airflow_db.* TO 'airflow_user';

from https://airflow.apache.org/docs/apache-airflow/stable/howto/set-up-database.html

I'm stuck on

mysql> CREATE USER 'airflow_user' IDENTIFIED BY 'airflow_pass';
ERROR 1819 (HY000): Your password does not satisfy the current policy requirements

I wonder if I need to do something similar to here?

New MySQL install has no root password, and can't set one

CREATE USER 'admin'@'localhost' IDENTIFIED WITH mysql_native_password BY 'superSecretPassword!123';
GRANT ALL ON *.* TO 'admin'@'localhost' WITH GRANT OPTION;

how can I solve this please?

in flag
With the medium password setting, you’ll need something with upper and lower case characters, a number, and a special character. If memory serves, the length will need to be 10 characters or more. The “super secret” that you had in the question will satisfy this requirement
Bluetail avatar
in flag
yes, I have all this. my estimated password strength is 100.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.