PostgreSQL 14 到 16 的升级(多版本适用)在 Nginx 配置 HTTPS 访问
写在前面
进行操作前,前务必确保数据安全备份。操作可能导致数据丢失,本文使用的数据库为实验环境。
环境
操作步骤
安装新版本的 PostgreSQL
1 | brew install postgresql@16 |
停止 PostgreSQL 服务
1 | brew services stop postgresql@14 |
运行 pg_upgrade 命令pg_upgrade 命令包含四个参数。
注意是运行新版本 Postgres 的 pg_upgrade;这里的版本号根据具体情况替换
1 | /opt/homebrew/Cellar/postgresql@16/16.2_1/bin/pg_upgrade \ |
成功后得到如下输出
1 | // 省略一些输出... |
- Title: PostgreSQL 14 到 16 的升级(多版本适用)在 Nginx 配置 HTTPS 访问
- Author: SimpleMaxR
- Created at : 2024-04-15 21:29:43
- Updated at : 2025-02-11 12:15:45
- Link: https://www.hgzre.tech/2024/04/15/PostgreSQL-14-到-16-的升级(多版本适用)在-Nginx-配置-HTTPS-访问/
- License: This work is licensed under CC BY-NC-SA 4.0.
Comments