mirror of
https://github.com/fruworg/fruworg.github.io.git
synced 2024-11-16 09:27:17 +03:00
Create postgres-update.md
This commit is contained in:
parent
d1e1fdfdbf
commit
67ec3b6947
31
content/posts/postgres-update.md
Normal file
31
content/posts/postgres-update.md
Normal file
@ -0,0 +1,31 @@
|
|||||||
|
---
|
||||||
|
title: Обновление PostgreSQL
|
||||||
|
description: pg_upgradecluster
|
||||||
|
date: 2023-10-09T00:20:00+06:00
|
||||||
|
tags: [linux, postgres]
|
||||||
|
---
|
||||||
|
|
||||||
|
## Листинг запущенных экземпляров PostgreSQL
|
||||||
|
```shell
|
||||||
|
pg_lsclusters
|
||||||
|
```
|
||||||
|
|
||||||
|
## Остановка экземпляра PostgreSQL новой версии
|
||||||
|
```shell
|
||||||
|
pg_dropcluster <new-version> main --stop
|
||||||
|
```
|
||||||
|
|
||||||
|
## Миграция со старой версии на новую
|
||||||
|
```shell
|
||||||
|
pg_upgradecluster <old-version> main
|
||||||
|
```
|
||||||
|
|
||||||
|
## Дроп экземпляра PostgreSQL старой версии
|
||||||
|
```shell
|
||||||
|
pg_dropcluster <old-version> main
|
||||||
|
```
|
||||||
|
|
||||||
|
## Удаление пакетов старой версии PostgreSQL
|
||||||
|
```
|
||||||
|
apt purge -y postgresql-<old-version> postgresql-client-<old-version>
|
||||||
|
```
|
Loading…
Reference in New Issue
Block a user