LoginSignup
0
0

RDS MySQLサーバーの設定

Posted at

※失敗例
環境:
OS:Amazon Linux 2023
セキュリティグループ:プライベートサブネット

NATゲートウェイの作成
image.png

ルートテーブルを設定する。
image.png

パブリックサブネットのEC2インスタンスに接続し、
DB用の秘密鍵ファイルを作成

sudo su
nano myprivatekey.pem
##秘密鍵をコピペして保存##
chmod 400 myprivatekey.pem

image.png

SSH接続する

ssh ec-2user@DBインスタンスのプライベートIPアドレス

image.png

MySQLパッケージをインストールしていく

dnf localinstall https://dev.mysql.com/get/mysql80-community-release-el7-5.noarch.rpm -y

image.png

dnf install mysql-community-server -y

image.png
エラーでインストールできなかった。

wget https://dev.mysql.com/get/mysql80-community-release-el7-7.noarch.rpm
dnf localinstall mysql80-community-release-el7-7.noarch.rpm

image.png
image.png
インストール完了?
image.png
どうやらだめなようだ...
ちょっと探して...
以下で実行

dnf -y localinstall  https://dev.mysql.com/get/mysql80-community-release-el9-1.noarch.rpm
dnf -y install mysql mysql-community-client

インストールはできたが

systemctl start mysqld

で実行できない。

Amazon Linux 2023 はMariaDBを推奨しているようです。
うーむ。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0