M1Mac PostrgreSQLが起動しない時の対処方法
エラー内容
久しぶりにPostgreSQLを起動しようとしたらこんなエラーが。。
$ brew services start postgres
Bootstrap failed: 5: Input/output error
Try re-running the command as root for richer errors.
Error: Failure while executing; `/bin/launchctl bootstrap gui/501 /Users/****/Library/LaunchAgents/homebrew.mxcl.postgresql.plist` exited with 5.
対処方法
1、postmaster.pidを削除
M1チップの方は多分こっちでOK↓
$ rm /opt/homebrew/var/postgres/postmaster.pid
または
$ rm /usr/local/var/postgres/postmaster.pid
2、PostgreSQLを起動
$ brew services start postgresql
or
$ brew services restart postgresql
参考
この記事が気に入ったらサポートをしてみませんか?