[aws EC2] mysql_secure_installation

이두팔·2021년 10월 13일
0

webServer

목록 보기
2/3

이번엔 서버에 mysql_secure_installation을 설치하려고 한다.

mysql_secure_installation

문서: https://mariadb.com/kb/en/mysql_secure_installation/

문서에 보면 해당 명령어에 대한 설명으로

unix 시스템에서 사용할 수 있는 shell script이며, mariaDB installation의 보안을 향상시킬 수 있습니다.

  • root accounts의 password를 설정할 수 있습니다.
  • localhost 외부에서 액세스할 수 있는 root 계정을 지울 수 있습니다.
  • 익명 user 계정을 지울 수 있습니다.
  • 익명 user가 액세스할 수 있는 test database를 지울 수 있습니다.

라고 나와있다.

sudo mysql_secure_installation

로 해당 명령어를 실행하면

VALIDATE PASSWORD COMPONENT can be used to test passwords
and improve security. It checks the strength of password
and allows the users to set only those passwords which are
secure enough. Would you like to setup VALIDATE PASSWORD component?

비밀번호를 설정하라는 말이 나온다.

y: 아주 안전한 비밀번호
n: 다른 비밀번호

나는 다른 비밀번호를 설정하고 싶어 n을 선택했다.

그러고 나면 이제 또

By default, a MySQL installation has an anonymous user,
allowing anyone to log into MySQL without having to have
a user account created for them. This is intended only for
testing, and to make the installation go a bit smoother.
You should remove them before moving into a production
environment.

익명유저 지울래? 나온다.

나는 지우고싶으니깐 y를 선택했다.

그 다음은
Disallow root login remotely? Y
Remove test database and access to it?: Y
Reload privilege tables now?: Y

이제 끝이다!

profile
Software Engineer

0개의 댓글