升级Homebrew中的PostgreSQL
最后还是入手了新版的MBP,开发环境都是重新设置的,用PostgreSQL的时候,启动提醒版本不兼容
FATAL: database files are incompatible with server
DETAIL: The data directory was initialized by PostgreSQL version 9.5, which is not compatible with this version 9.6.2.所以要升级一下原来的库,作弊条开始
brew services stop postgresqlbrew install [email protected]initdb /usr/local/var/postgres9.6 -E utf8- 开始升级数据库
|
|
mv /usr/local/var/postgres /usr/local/var/postgres9.5mv /usr/local/var/postgres9.6 /usr/local/var/postgresbrew services start postgresql
完成
在线阅读本文 Guixing's Jail https://blog.khsing.net/2017/04/upgrade-homebrew-postgresql.html