2
2

More than 3 years have passed since last update.

【超速】AWS EC2インスタンスにpostgresql client 12をインストールする

Posted at

EC2のリポジトリが古いっぽいので、ちょっと困った。
調べると詳しく書いてあるサイトは色々ありますので、意味とかはそちらで調べたほうが良いです。

さっさとpsql12を使いたい時、一行づつコピペしてください。(ec2-userでの実行を想定してます。)

wget https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm
sudo rpm -Uvh --nodeps pgdg-redhat-repo-latest.noarch.rpm
sudo sed --in-place -e "s/\$releasever/7/g" /etc/yum.repos.d/pgdg-redhat-all.repo
sudo yum update
sudo yum search postgres
sudo yum install postgresql12
psql --version

確認コマンド含めて書いてあるので、インストールには影響しないものもあります。

2
2
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
2
2