---
# System prepended metadata

title: sql problems

---

# sql problems
## ERROR 1130 (HY000): Host 'x.x.x.x (Ip addr)' is not allowed to connect to this MySQL server
## comment bind-address in /etc/mysql/mysql.conf.d/mysqld.cnf
![](https://i.imgur.com/wio3zin.png)


### adjust password policies

```sql=
SET GLOBAL validate_password.LENGTH = 4;
SET GLOBAL validate_password.policy = 0;
SET GLOBAL validate_password.mixed_case_count = 0;
SET GLOBAL validate_password.number_count = 0;
SET GLOBAL validate_password.special_char_count = 0;
SET GLOBAL validate_password.check_user_name = 0;
ALTER USER 'user'@'localhost' IDENTIFIED BY 'pass';
FLUSH PRIVILEGES;

```


## to solve use the following sql

```sql=
CREATE USER 'user_name'@'localhost' IDENTIFIED BY 'your_secret_key';
GRANT ALL PRIVILEGES ON *.* TO 'user_name'@'localhost'
->     WITH GRANT OPTION;
CREATE USER 'user_name'@'%' IDENTIFIED BY 'your_secret_key';
GRANT ALL PRIVILEGES ON *.* TO 'user_name'@'%'
->     WITH GRANT OPTION;
```