From 2895c65f91073ef6cbab6f74cbbec2c57f6d311f Mon Sep 17 00:00:00 2001 From: Anastasia Alexandrova Date: Wed, 19 Jun 2024 15:37:37 +0300 Subject: [PATCH] PG-798 Restructured docs 13 (#606) * Restructured docs * Reworked the What's in it section * Added power number * Added icons --- .vscode/settings.json | 5 ++ CONTRIBUTING.md | 30 ++++--- docs/apt.md | 36 ++------- docs/connect.md | 73 +++++++++++++++++ docs/crud.md | 112 ++++++++++++++++++++++++++ docs/docker.md | 12 +-- docs/enable-extensions.md | 16 ++-- docs/extensions.md | 7 +- docs/index.md | 59 +++++++++----- docs/installing.md | 41 +++++++--- docs/licensing.md | 6 +- docs/major-upgrade.md | 20 ++--- docs/migration.md | 37 +++++---- docs/minor-upgrade.md | 21 +++-- docs/pg-stat-monitor.md | 22 ++--- docs/release-notes-v13.13.upd.md | 2 +- docs/repo-overview.md | 7 +- docs/solutions.md | 30 +++++++ docs/solutions/backup-recovery.md | 8 +- docs/solutions/dr-pgbackrest-setup.md | 10 +-- docs/solutions/ha-setup-apt.md | 2 +- docs/solutions/ha-setup-yum.md | 4 +- docs/solutions/high-availability.md | 6 +- docs/solutions/pgbackrest.md | 24 +++--- docs/solutions/postgis-deploy.md | 42 +++++----- docs/solutions/postgis-upgrade.md | 6 +- docs/solutions/postgis.md | 4 +- docs/trademark-policy.md | 2 +- docs/troubleshooting.md | 23 ++++++ docs/uninstalling.md | 6 +- docs/whats-next.md | 25 ++++++ docs/yum.md | 47 +++++------ mkdocs-base.yml | 91 +++++++++++---------- snippets/supported-versions.md | 2 +- 34 files changed, 573 insertions(+), 265 deletions(-) create mode 100644 .vscode/settings.json create mode 100644 docs/connect.md create mode 100644 docs/crud.md create mode 100644 docs/solutions.md create mode 100644 docs/troubleshooting.md create mode 100644 docs/whats-next.md diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 000000000..eb98bbf51 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,5 @@ +{ + "cSpell.words": [ + "Quickstart" + ] +} \ No newline at end of file diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 7625fa432..c87fac8be 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -5,7 +5,15 @@ Thank you for deciding to contribute and help us improve Percona Distribution fo We welcome contributors from all users and community. By contributing, you agree to the [Percona Community code of conduct](https://github.com/percona/community/blob/main/content/contribute/coc.md). -This repository contains the source file for `pg_stat_monitor` documentation and this document explains how you can contribute to it. +You can contribute to documentation in the following ways: + +1. **Request a doc change through a Jira issue**. If you’ve spotted a doc issue (a typo, broken links, inaccurate instructions, etc.) but don’t have time nor desire to fix it yourself - let us know about it. + + - Click the **Submit DOC bug** link on the sidebar. This opens the [Jira issue tracker](https://jira.percona.com/projects/PG/issues) for the doc project. + - Sign in (create a Jira account if you don’t have one) and click **Create** to create an issue. + - Describe the issue you have detected in the Summary, Description, Steps To Reproduce, Affects Version fields. + +2. **[Contribute to documentation yourself](#contribute-to-documentation-yourself)**. There is the **Edit this page** link that leads you to the source file of the page on GitHub. There you make changes, create a pull request that we review and add to the doc project. For details how to do it, read on. ## Contribute to documentation @@ -13,8 +21,8 @@ Percona Distribution for PostgreSQL documentation is written in [Markdown](https [edit it online via GitHub](#edit-documentation-online-vi-github). If you wish to have more control over the doc process, jump to how to [edit documentation locally](#edit-documentation-locally). To contribute to the documentation, you should be familiar with the following technologies: - -- [MkDocs](https://www.mkdocs.org/getting-started/) documentation generator. We use it to convert source ``.md`` files to .html and PDF documents. +- [Markdown](https://www.markdownguide.org/basic-syntax/) markup language. It is used to write the documentation. +- [MkDocs](https://www.mkdocs.org/getting-started/) documentation generator. We use it to convert source ``.md`` files to html and PDF documents. - [git](https://git-scm.com/) and [GitHub](https://guides.github.com/activities/hello-world/) - [Docker](https://docs.docker.com/get-docker/). It allows you to run MkDocs in a virtual environment instead of installing it and its dependencies on your machine. @@ -27,12 +35,13 @@ Each version has a branch in the repository named accordingly: - 13 - 14 - 15 +- 16 The source .md files are in the ``docs`` directory. ### Edit documentation online via GitHub -1. Click the **Edit this page** icon next to the page title. The Markdown file of the page opens in GitHub editor in your browser. If you haven’t worked with the repository before, GitHub creates a [fork](https://docs.github.com/en/github/getting-started-with-github/fork-a-repo) of it for you. +1. Click the **Edit this page** link on the sidebar. The Markdown file of the page opens in GitHub editor in your browser. If you haven’t worked with the repository before, GitHub creates a [fork](https://docs.github.com/en/github/getting-started-with-github/fork-a-repo) of it for you. 2. Edit the page. You can check your changes on the **Preview** tab. @@ -125,15 +134,16 @@ The PDF document is in the ``site/pdf`` folder. 2. Install [MkDocs](https://www.mkdocs.org/getting-started/#installation). 3. While in the root directory of the doc project, run the following command to build the documentation: -```sh -mkdocs build -``` + ```sh + mkdocs build + ``` + 4. Go to the ``site`` directory and open the ``index.html`` file in your web browser to see the documentation. 5. To automatically rebuild the documentation and reload the browser as you make changes, run the following command: -```sh -mkdocs serve -``` + ```sh + mkdocs serve + ``` 6. To build the PDF documentation, do the following: - Install [mkdocs-with-pdf plugin](https://pypi.org/project/mkdocs-with-pdf/) diff --git a/docs/apt.md b/docs/apt.md index 29ced039d..af993e2f9 100644 --- a/docs/apt.md +++ b/docs/apt.md @@ -11,7 +11,7 @@ This document describes how to install Percona Distribution for PostgreSQL from Run all the commands in the following sections as root or using the `sudo` command: -### Configure Percona repository +### Configure Percona repository {.power-number} 1. Install the `percona-release` repository management tool to subscribe to Percona repositories: @@ -53,6 +53,9 @@ Run all the commands in the following sections as root or using the `sudo` comma === "Install packages individually" + Run the following commands: + {.power-number} + 1. Install the PostgreSQL server package: ```{.bash data-prompt="$"} @@ -146,33 +149,10 @@ The installation process automatically initializes and starts the default databa $ sudo systemctl status postgresql.service ``` -### Connect to the PostgreSQL server - -By default, `postgres` user and `postgres` database are created in PostgreSQL upon its installation and initialization. This allows you to connect to the database as the `postgres` user. - -```{.bash data-prompt="$"} -$ sudo su postgres -``` - -Open the PostgreSQL interactive terminal: - -```{.bash data-prompt="$"} -$ psql -``` - -!!! hint - - You can connect to `psql` as the `postgres` user in one go: - - ```{.bash data-prompt="$"} - $ sudo su - postgres -c psql - ``` - -To exit the `psql` terminal, use the following command: - -```{.bash data-prompt="$"} -$ \q -``` +Congratulations! Your Percona Distribution for PostgreSQL is up and running. +## Next steps +[Enable extensions :material-arrow-right:](enable-extensions.md){.md-button} +[Connect to PostgreSQL :material-arrow-right:](connect.md){.md-button} diff --git a/docs/connect.md b/docs/connect.md new file mode 100644 index 000000000..18a1cb9b9 --- /dev/null +++ b/docs/connect.md @@ -0,0 +1,73 @@ +# Connect to the PostgreSQL server + +With PostgreSQL server up and running, let's connect to it. + +By default, the `postgres` user and the `postgres` database are created in PostgreSQL upon its installation and initialization. This allows you to connect to the database as the `postgres` user. +{.power-number} + +1. Switch to the `postgres` user. + + ```{.bash data-prompt="$"} + $ sudo su postgres + ``` + +2. Open the PostgreSQL interactive terminal `psql`: + + ```{.bash data-prompt="$"} + $ psql + ``` + + :material-information: Hint: You can connect to `psql` as the `postgres` user in one go: + + ```{.bash data-prompt="$"} + $ sudo su - postgres -c psql + ``` + + +## Basic `psql` commands + +While connected to PostgreSQL, let's practice some basic `psql` commands to interact with the database: + +1. List databases: + + ```{.bash data-prompt="$"} + $ \l + ``` + +2. Display tables in the current database: + + ```{.bash data-prompt="$"} + $ \dt + ``` + +3. Display columns in a table + + ```{.bash data-prompt="$"} + $ \d + ``` + +4. Switch databases + + ```{.bash data-prompt="$"} + $ \c + ``` + +5. Display users and roles + + ```{.bash data-prompt="$"} + $ \du + ``` + +6. Exit the `psql` terminal: + + ```{.bash data-prompt="$"} + $ \q + ``` + +To learn more about using `psql`, see [`psql` :octicons-link-external-16:](https://www.postgresql.org/docs/current/app-psql.html) documentation. + +Congratulations! You have connected to PostgreSQL and learned some essential `psql` commands. + +## Next steps + +[Manipulate data in PostgreSQL :material-arrow-right:](crud.md){.md-button} \ No newline at end of file diff --git a/docs/crud.md b/docs/crud.md new file mode 100644 index 000000000..75d43d710 --- /dev/null +++ b/docs/crud.md @@ -0,0 +1,112 @@ +# Manipulate data in PostgreSQL + +On the previous step, you have [connected to PostgreSQL](connect.md) as the superuser `postgres`. Now, let's insert some sample data and operate with it in PostgreSQL. + +## Create a database + +Let's create the database `test`. Use the CREATE DATABASE command: + +```sql +CREATE DATABASE test; +``` + +## Create a table + +Let's create a sample table `Customers` in the `test` database using the following command: + +```sql +CREATE TABLE customers ( + id SERIAL PRIMARY KEY, -- 'id' is an auto-incrementing integer + first_name VARCHAR(50), -- 'first_name' is a string with a maximum length of 50 characters + last_name VARCHAR(50), -- 'last_name' is a string with a maximum length of 50 characters + email VARCHAR(100) -- 'email' is a string with a maximum length of 100 characters +); +``` + +:material-information: Hint:Having issues with table creation? Check our [Troubleshooting guide](troubleshooting.md) + +## Insert the data + +Populate the table with the sample data as follows: + +```sql +INSERT INTO customers (first_name, last_name, email) +VALUES + ('John', 'Doe', 'john.doe@example.com'), -- Insert a new row + ('Jane', 'Doe', 'jane.doe@example.com'); + ('Alice', 'Smith', 'alice.smith@example.com'); +``` + +## Query data + +Let's verify the data insertion by querying it: + +```sql +SELECT * FROM customers; +``` + +??? example "Expected output" + + ```{.sql .no-copy} + id | first_name | last_name | email + ----+------------+-----------+------------------------- + 1 | John | Doe | john.doe@example.com + 2 | Jane | Doe | jane.doe@example.com + 3 | Alice | Smith | alice.smith@example.com + (3 rows) + ``` + +## Update data + +Let's update John Doe's record with a new email address. + +1. Use the UPDATE command for that: + + ```sql + UPDATE customers + SET email = 'john.doe@myemail.com' + WHERE first_name = 'John' AND last_name = 'Doe'; + ``` + +2. Query the table to verify the updated data: + + ```sql + SELECT * FROM customers WHERE first_name = 'John' AND last_name = 'Doe'; + ``` + + ??? example "Expected output" + + ```{.sql .no-copy} + id | first_name | last_name | email + ----+------------+-----------+------------------------- + 2 | Jane | Doe | jane.doe@example.com + 3 | Alice | Smith | alice.smith@example.com + 1 | John | Doe | john.doe@myemail.com + (3 rows) + ``` + +## Delete data + +Use the DELETE command to delete rows. For example, delete the record of Alice Smith: + +```sql +DELETE FROM Customers WHERE first_name = 'Alice' AND last_name = 'Smith'; +``` + +If you wish to delete the whole table, use the `DROP TABLE` command instead as follows: + +```sql +DROP TABLE customers; +``` + +To delete the whole database, use the DROP DATABASE command: + +```sql +DROP DATABASE test; +``` + +Congratulations! You have used basic create, read, update and delete (CRUD) operations to manipulate data in Percona Distribution for PostgreSQL. To deepen your knowledge, see the [data manipulation :octicons-link-external-16:](https://www.postgresql.org/docs/{{pgversion}}/dml.html) section in PostgreSQL documentation. + +## Next steps + +[What's next?](whats-next.md)(.md-button) \ No newline at end of file diff --git a/docs/docker.md b/docs/docker.md index e8227a076..274d44840 100644 --- a/docs/docker.md +++ b/docs/docker.md @@ -1,12 +1,12 @@ # Run Percona Distribution for PostgreSQL in a Docker container -Docker images of Percona Distribution for PostgreSQL are hosted publicly on [Docker Hub](https://hub.docker.com/r/percona/percona-distribution-postgresql/). +Docker images of Percona Distribution for PostgreSQL are hosted publicly on [Docker Hub :octicons-link-external-16:](https://hub.docker.com/r/percona/percona-distribution-postgresql/). -For more information about using Docker, see the [Docker Docs](https://docs.docker.com/). +For more information about using Docker, see the [Docker Docs :octicons-link-external-16:](https://docs.docker.com/). !!! note "" - Make sure that you are using the latest version of Docker. The ones provided via `apt` and `yum` may be outdated and cause errors. + Make sure that you are using [the latest version of Docker :octicons-link-external-16:](https://docs.docker.com/get-docker/). The ones provided via `apt` and `yum` may be outdated and cause errors. By default, Docker pulls the image from Docker Hub if it is not available locally. @@ -28,7 +28,7 @@ For more information about using Docker, see the [Docker Docs](https://docs.dock | `percona-pg_repack{{pgversion}}`| rebuilds PostgreSQL database objects.| | `percona-wal2json{{pgversion}}` | a PostgreSQL logical decoding JSON output plugin.| -## Start the container +## Start the container {.power-number} 1. Start a Percona Distribution for PostgreSQL container as follows: @@ -40,8 +40,8 @@ For more information about using Docker, see the [Docker Docs](https://docs.dock * `container-name` is the name you assign to your container * `POSTGRES_PASSWORD` is the superuser password - * `tag-multi` is the tag specifying the version you need. For example, `{{dockertag}}-multi`. The `multi` part of the tag serves to identify the architecture (x86_64 or ARM64) and pull the respective image. See the [full list of tags](https://hub.docker.com/r/percona/percona-distribution-postgresql/tags/). - + * `tag-multi` is the tag specifying the version you need. For example, `{{dockertag}}-multi`. The `multi` part of the tag serves to identify the architecture (x86_64 or ARM64) and pull the respective image. See the [full list of tags :octicons-link-external-16:](https://hub.docker.com/r/percona/percona-distribution-postgresql/tags/). + !!! tip diff --git a/docs/enable-extensions.md b/docs/enable-extensions.md index 2fc52c072..d7c104b5a 100644 --- a/docs/enable-extensions.md +++ b/docs/enable-extensions.md @@ -12,18 +12,18 @@ While setting up a high availability PostgreSQL cluster with Patroni, you will n - Distributed Configuration Store (DCS). Patroni supports such DCSs as etcd, zookeeper, Kubernetes though [etcd](https://etcd.io/) is the most popular one. It is available within Percona Distribution for PostgreSQL for all supported operating systems. -- [HAProxy](http://www.haproxy.org/). +- [HAProxy :octicons-link-external-16:](http://www.haproxy.org/). See the configuration guidelines for [Debian and Ubuntu](solutions/ha-setup-apt.md) and [RHEL and CentOS](solutions/ha-setup-yum.md). !!! admonition "See also" - - [Patroni documentation](https://patroni.readthedocs.io/en/latest/SETTINGS.html#settings) + - [Patroni documentation :octicons-link-external-16:](https://patroni.readthedocs.io/en/latest/SETTINGS.html#settings) - Percona Blog: - - [PostgreSQL HA with Patroni: Your Turn to Test Failure Scenarios](https://www.percona.com/blog/2021/06/11/postgresql-ha-with-patroni-your-turn-to-test-failure-scenarios/) + - [PostgreSQL HA with Patroni: Your Turn to Test Failure Scenarios :octicons-link-external-16:](https://www.percona.com/blog/2021/06/11/postgresql-ha-with-patroni-your-turn-to-test-failure-scenarios/) **pgBadger** @@ -41,11 +41,11 @@ log_autovacuum_min_duration = 0 log_error_verbosity = default ``` -For details about each option, see [pdBadger documentation](https://github.com/darold/pgbadger/#POSTGRESQL-CONFIGURATION). +For details about each option, see [pdBadger documentation :octicons-link-external-16:](https://github.com/darold/pgbadger/#POSTGRESQL-CONFIGURATION). **pgAudit set-user** -Add the `set-user` to `shared_preload_libraries` in `postgresql.conf`. The recommended way is to use the [ALTER SYSTEM](https://www.postgresql.org/docs/14/sql-altersystem.html) command. [Connect to psql](#connect-to-the-postgresql-server) and use the following command: +Add the `set-user` to `shared_preload_libraries` in `postgresql.conf`. The recommended way is to use the [ALTER SYSTEM](https://www.postgresql.org/docs/13/sql-altersystem.html) command. [Connect to psql](connect.md) and use the following command: ```sql ALTER SYSTEM SET shared_preload_libraries = 'set-user'; @@ -53,7 +53,7 @@ ALTER SYSTEM SET shared_preload_libraries = 'set-user'; Start / restart the server to apply the configuration. -You can fine-tune user behavior with the [custom parameters](https://github.com/pgaudit/set_user#configuration-options) supplied with the extension. +You can fine-tune user behavior with the [custom parameters :octicons-link-external-16:](https://github.com/pgaudit/set_user#configuration-options) supplied with the extension. **wal2json** @@ -62,3 +62,7 @@ After the installation, enable the following option in `postgresql.conf` configu ``` wal_level = logical ``` + +## Next steps + +[Connect to PostgreSQL :material-arrow-right:](connect.md){.md-button} \ No newline at end of file diff --git a/docs/extensions.md b/docs/extensions.md index 1b2ca9e00..5ed5ffa20 100644 --- a/docs/extensions.md +++ b/docs/extensions.md @@ -5,17 +5,16 @@ Percona Distribution for PostgreSQL includes a set of extensions that have been The set of extensions includes the following: * [PostgreSQL contrib modules and utilities](contrib.md) -* [Third-party components](third-party.md) * Extensions authored by Percona: * [`pg_stat_monitor`](pg-stat-monitor.md) - * [`pg_tde`](#) -* Extra modules, not included in Percona Distribution for PostgreSQL but tested to work with it and supported by Percona. +* [Third-party components](third-party.md) + +Additionally, see the list of [PostgreSQL software](https://www.percona.com/services/support/support-tiers-postgresql) covered by Percona Support. ## Install an extension To use an extension, install it. Run the [`CREATE EXTENSION`](https://www.postgresql.org/docs/current/static/sql-createextension.html) command on the PostgreSQL node where you want the extension to be available. The user should be a superuser or have the `CREATE` privilege on the current database to be able to run the [`CREATE EXTENSION`](https://www.postgresql.org/docs/current/static/sql-createextension.html) command. Some extensions may require additional privileges depending on their functionality. To learn more, check the documentation for the desired extension. - diff --git a/docs/index.md b/docs/index.md index d58d0db8c..f6261b420 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,30 +1,53 @@ -# Percona Distribution for PostgreSQL 13 Documentation +# Percona Distribution for PostgreSQL 15 Documentation -Percona Distribution for PostgreSQL is a collection of tools to assist you in managing your PostgreSQL -database system: it installs PostgreSQL and complements it by a selection of -extensions that enable solving essential practical tasks efficiently. + Percona Distribution for PostgreSQL is a suite of open source software, tools and services required to deploy and maintain a reliable production cluster for PostgreSQL. It includes native PostgreSQL server, enhanced with extensions from open source community that are certified and tested to work together for high availability, backups, security, and monitoring that help ensure the cluster's peak performance. + + Part of the solution, Percona Operator for PostgreSQL, makes it easy to orchestrate the cluster reliably and repeatably in Kubernetes. -[What's included in the Distribution](extensions.md){.md-button} +[What's included in Percona Distribution for PostgreSQL? :material-arrow-right:](extensions.md){.md-button} -[Get started](installing.md){ .md-button } -[What's new]({{release}}.md){ .md-button } +## What’s in it for you? +- No vendor lock in - all components of Percona Distribution for PostgreSQL are fully open source +- No guesswork on finding the right version of a component – they all undergo thorough testing to ensure compatibility +- Freely available reference architectures for solutions like high-availability, backups and disaster recovery +- Spatial data handling support via PostGIS +- Monitoring of the database health, performance and infrastructure usage via open source [Percona Management and Monitoring :octicons-link-external-16:](https://www.percona.com/doc/percona-monitoring-and-management/2.x/index.html) with PostgreSQL-specific dashboards +- Run PostgreSQL on Kubernetes using open source [Percona Operator for PostgreSQL:octicons-link-external-16:](https://docs.percona.com/percona-operator-for-postgresql/2.0/index.html). It not only automates deployment and management of PostgreSQL clusters on Kubernetes, but also includes enterprise-ready features for high-availability, backup and restore, replication, logging, and more +
-!!! admonition "See also" +## :material-progress-download: Installation guides { .title } - Blog Posts +Get started quickly with the step-by-step installation instructions. - - [pgBackRest - A Great Backup Solution and a Wonderful Year of - Growth](https://www.percona.com/blog/2019/05/10/pgbackrest-a-great-backup-solution-and-a-wonderful-year-of-growth/) - - [Securing PostgreSQL as an Enterprise-Grade - Environment](https://www.percona.com/blog/2018/09/21/securing-postgresql-as-an-enterprise-grade-environment/) +[Quickstart guides :material-arrow-right:](installing.md){ .md-button } -Percona Distribution for PostgreSQL is also shipped with the -[libpq](https://www.postgresql.org/docs/13/libpq.html) library. It -contains "a set of library functions that allow client programs to pass -queries to the PostgreSQL backend server and to receive the results of -these queries." +
+ +### :fontawesome-solid-gears: Solutions { .title } + +Check our solutions to build the database infrastructure that meets the requirements of your organization - be it high-availability, disaster recovery or spatial data handling. + +[Solutions :material-arrow-right:](solutions.md){ .md-button } + +
+ +### :material-frequently-asked-questions: Troubleshooting and FAQ { .title } + +Our comprehensive resources will help you overcome challenges, from everyday issues to specific doubts. + +[Troubleshooting :material-arrow-right:](troubleshooting.md){.md-button} + +
+ +### :loudspeaker: What's new? { .title } + +Learn about the releases and changes in the Distribution. + +[Release notes :material-arrow-right:](release-notes.md){.md-button} +
+
diff --git a/docs/installing.md b/docs/installing.md index 932d31cba..ca33e4b09 100644 --- a/docs/installing.md +++ b/docs/installing.md @@ -1,34 +1,55 @@ -# Install Percona Distribution for PostgreSQL +# Quickstart guide -Percona Distribution for PostgreSQL is the solution with the collection of tools from PostgreSQL community that are tested to work together and serve to assist you in deploying and managing PostgreSQL. [Read more :material-arrow-top-right: ](index.md). +Percona Distribution for PostgreSQL is the solution with the collection of tools from PostgreSQL community that are tested to work together and serve to assist you in deploying and managing PostgreSQL. [Read more](index.md). + +This document aims to guide database application developers and DevOps engineer in getting started with Percona Distribution for PostgreSQL. Upon completion of this guide, you’ll have Percona Distribution for PostgreSQL installed and operational, and you’ll be able to: + +* Connect to PostgreSQL using the `psql` interactive terminal +* Interact with PostgreSQL with basic psql commands +* Manipulate data in PostgreSQL +* Understand the next steps you can take as a database application developer or administrator to expand your knowledge of Percona Distribution for PostgreSQL + +## Install Percona Distribution for PostgreSQL You can select from multiple easy-to-follow installation options, but **we recommend using a Package Manager** for a convenient and quick way to try the software first. -=== "Package manager" +=== ":simple-windowsterminal: Package manager" - Percona provides installation packages in `DEB` and `RPM` format for 64-bit Linux distributions. Find the full list of supported platforms and versions on the [Percona Software and Platform Lifecycle page](https://www.percona.com/services/policies/percona-software-support-lifecycle#pgsql). + Percona provides installation packages in `DEB` and `RPM` format for 64-bit Linux distributions. Find the full list of supported platforms and versions on the [Percona Software and Platform Lifecycle page :octicons-link-external-16:](https://www.percona.com/services/policies/percona-software-support-lifecycle#pgsql). If you are on Debian or Ubuntu, use `apt` for installation. If you are on Red Hat Enterprise Linux or compatible derivatives, use `yum`. - Choose your package manager below to get access to a detailed step-by-step guide. - [Install via apt :material-arrow-right:](apt.md){.md-button} [Install via yum :material-arrow-right:](yum.md){.md-button} -=== "Docker" + +=== ":simple-docker: Docker" Get our image from Docker Hub and spin up a cluster on a Docker container for quick evaluation. Check below to get access to a detailed step-by-step guide. - [Run in Docker](docker.md){.md-button} + [Run in Docker :material-arrow-right:](docker.md){.md-button} -=== "Kubernetes" +=== ":simple-kubernetes: Kubernetes" **Percona Operator for Kubernetes** is a controller introduced to simplify complex deployments that require meticulous and secure database expertise. Check below to get access to a detailed step-by-step guide. - [Get started with Percona Operator for PostgreSQL](https://docs.percona.com/percona-operator-for-postgresql/2.0/quickstart.html){.md-button} + [Get started with Percona Operator :octicons-link-external-16:](https://docs.percona.com/percona-operator-for-postgresql/2.0/quickstart.html){.md-button} + +=== ":octicons-download-16: Manual download" + + If you need to install Percona Distribution for PostgreSQL offline or as a non-superuser, check out the link below for a step-by-step guide and get access to the downloads directory. + + Note that for this scenario you must make sure that all dependencies are satisfied. + + [Install from tarballs :material-arrow-right:](tarball.md){.md-button} + + + + + diff --git a/docs/licensing.md b/docs/licensing.md index c7985e376..eed47e506 100644 --- a/docs/licensing.md +++ b/docs/licensing.md @@ -1,9 +1,9 @@ # Copyright and licensing information -Percona Distribution for PostgreSQL is licensed under the [PostgreSQL license](https://opensource.org/licenses/postgresql) and licenses of all components included in the Distribution. +Percona Distribution for PostgreSQL is licensed under the [PostgreSQL license :octicons-link-external-16:](https://opensource.org/licenses/postgresql) and licenses of all components included in the Distribution. ## Documentation licensing -Percona Distribution for PostgreSQL documentation is (C)2016-2023 Percona LLC and/or its affiliates -and is distributed under the [Creative Commons Attribution 4.0 International Public License](https://creativecommons.org/licenses/by/4.0/) license. \ No newline at end of file +Percona Distribution for PostgreSQL documentation is (C)2016-2024 Percona LLC and/or its affiliates +and is distributed under the [Creative Commons Attribution 4.0 International Public License](https://creativecommons.org/licenses/by/4.0/) license. diff --git a/docs/major-upgrade.md b/docs/major-upgrade.md index 2d41eb0c3..9c7b5b927 100644 --- a/docs/major-upgrade.md +++ b/docs/major-upgrade.md @@ -57,15 +57,15 @@ The exact steps may differ depending on the package manager of your operating sy ## On Debian and Ubuntu using `apt` -!!! important - - Run **all** commands as root or via **sudo**. - +Run **all** commands as root or via **sudo**: +{.power-number} 1. Install Percona Distribution for PostgreSQL 13 packages. - * Enable Percona repository using the **percona-release** utility: + * [Install percona-release :octicons-link-external-16:](https://docs.percona.com/percona-software-repositories/installing.html) + + * Enable Percona repository: ```{.bash data-prompt="$"} $ sudo percona-release setup ppg-13 @@ -214,15 +214,15 @@ The exact steps may differ depending on the package manager of your operating sy ## On Red Hat Enterprise Linux and derivatives using `yum` -!!! important - - Run **all** commands as root or via **sudo**. - +Run **all** commands as root or via **sudo**: +{.power-number} 1. Install Percona Distribution for PostgreSQL 13 packages - * Enable Percona repository using the **percona-release** utility: + * [Install percona-release :octicons-link-external-16:](https://docs.percona.com/percona-software-repositories/installing.html) + + * Enable Percona repository: ```{.bash data-prompt="$"} $ sudo percona-release setup ppg-13 diff --git a/docs/migration.md b/docs/migration.md index a9c06f60f..b085a68a2 100644 --- a/docs/migration.md +++ b/docs/migration.md @@ -1,6 +1,5 @@ # Migrate from PostgreSQL to Percona Distribution for PostgreSQL - Percona Distribution for PostgreSQL includes the PostgreSQL database and additional extensions that have been selected to cover the needs of the enterprise and are guaranteed to work together. Percona Distribution for PostgreSQL is available as a software collection that is easy to deploy. We encourage users to migrate from their PostgreSQL deployments based on community binaries to Percona Distribution for PostgreSQL. This document provides the migration instructions. @@ -9,9 +8,12 @@ Depending on your business requirements, you may migrate to Percona Distribution ## Migrate on the same server -=== "On Debian and Ubuntu Linux" +=== ":material-debian: On Debian and Ubuntu Linux" + + >To ensure that your data is safe during the migration, we recommend to make a backup of your data and all configuration files (such as `pg_hba.conf`, `postgresql.conf`, `postgresql.auto.conf`) using the tool of your choice. The backup process is out of scope of this document. You can use `pg_dumpall` or other tools of your choice. For more information, see the blog post [PostgreSQL Upgrade Using pg_dumpall](https://www.percona.com/blog/postgresql-upgrade-using-pg_dumpall/) by _Avinash Vallarapu_, _Fernando Laudares Camargos_, _Jobin Augustine_ and _Nickolay Ihalainen_. - >To ensure that your data is safe during the migration, we recommend to make a backup of your data and all configuration files (such as `pg_hba.conf`, `postgresql.conf`, `postgresql.auto.conf`) using the tool of your choice. The backup process is out of scope of this document. You can use `pg_dumpall` or other tools of your choice. + Run **all** commands as root or via **sudo**: + {.power-number} 1. Stop the `postgresql` server @@ -25,14 +27,14 @@ Depending on your business requirements, you may migrate to Percona Distribution $ sudo apt-get --purge remove postgresql ``` - 3. [Install percona-release](https://docs.percona.com/percona-software-repositories/installing.html) + 3. [Install percona-release :octicons-link-external-16:](https://docs.percona.com/percona-software-repositories/installing.html) 4. Enable the repository ```{.bash data-prompt="$"} $ sudo percona-release setup ppg13 ``` - 5. [Install Percona Distribution for PostgreSQL packages](installing.md#install-percona-distribution-for-postgresql-packages) + 5. [Install Percona Distribution for PostgreSQL packages](apt.md) 6. (Optional) Restore the data from the backup. 7. Start the `postgresql` service. The installation process starts and initializes the default cluster automatically. You can check its status with: @@ -47,11 +49,14 @@ Depending on your business requirements, you may migrate to Percona Distribution ``` -=== "On RHEL and compatible derivatives" +=== ":material-redhat: On RHEL and compatible derivatives" > To ensure that your data is safe during the migration, we recommend to make a backup of your data and all configuration files (such as `pg_hba.conf`, `postgresql.conf`, `postgresql.auto.conf`) using the tool of your choice. The backup process is out of scope of this document. You can use `pg_dumpall` or other tools of your choice. - 1. Stop the `postgresql` server + Run **all** commands as root or via **sudo**: + {.power-number} + + 1. Stop the `postgresql` server ```{.bash data-prompt="$"} $ sudo systemctl stop postgresql-13 @@ -63,14 +68,14 @@ Depending on your business requirements, you may migrate to Percona Distribution $ sudo yum remove postgresql ``` - 3. [Install percona-release](https://docs.percona.com/percona-software-repositories/installing.html) + 3. [Install percona-release :octicons-link-external-16:](https://docs.percona.com/percona-software-repositories/installing.html) 4. Enable the repository ```{.bash data-prompt="$"} $ sudo percona-release setup ppg13 ``` - 5. [Install Percona Distribution for PostgreSQL packages](installing.md#install-percona-distribution-for-postgresql-packages) + 5. [Install Percona Distribution for PostgreSQL packages](yum.md) 6. (Optional) Restore the data from the backup. 7. Start the `postgresql` service @@ -86,17 +91,18 @@ In this scenario, we will refer to the server with PostgreSQL Community as the " To migrate from PostgreSQL Community to Percona Distribution for PostgreSQL on a different server, do the following: **On the source server**: +{.power-number} 1. Back up your data and all configuration files (such as `pg_hba.conf`, `postgresql.conf`, `postgresql.auto.conf`) using the tool of your choice. 2. Stop the `postgresql` service - === "On Debian and Ubuntu" + === ":material-debian: On Debian and Ubuntu" ```{.bash data-prompt="$"} $ sudo systemctl stop postgresql.service ``` - === "On RHEL and derivatives" + === ":material-redhat: On RHEL and derivatives" ```{.bash data-prompt="$"} $ sudo systemctl stop postgresql-13 @@ -105,25 +111,26 @@ To migrate from PostgreSQL Community to Percona Distribution for PostgreSQL on a 3. Optionally, remove PostgreSQL Community packages **On the target server**: +{.power-number} -1. [Install percona-release](https://docs.percona.com/percona-software-repositories/installing.html) +1. [Install percona-release :octicons-link-external-16:](https://docs.percona.com/percona-software-repositories/installing.html) 2. Enable the repository ```{.bash data-promp="$"} $ sudo percona-release setup ppg13 ``` -3. [Install Percona Distribution for PostgreSQL packages](installing.md#install-percona-distribution-for-postgresql-packages) on the target server. +3. [Install Percona Distribution for PostgreSQL packages](installing.md#) on the target server. 4. Restore the data from the backup 5. Start `postgresql` service - === "On Debian and Ubuntu" + === ":material-debian: On Debian and Ubuntu" ```{.bash data-promp="$"} $ sudo systemctl start postgresql.service ``` - === "On RHEL and compatible derivatives" + === ":material-redhat: On RHEL and compatible derivatives" ```{.bash data-promp="$"} $ sudo systemctl start postgresql-13 diff --git a/docs/minor-upgrade.md b/docs/minor-upgrade.md index 310cce69e..9a9445418 100644 --- a/docs/minor-upgrade.md +++ b/docs/minor-upgrade.md @@ -23,24 +23,21 @@ Minor upgrade of Percona Distribution for PostgreSQL includes the following step For more information about Percona repositories, refer to Installing Percona Distribution for PostgreSQL. - Before the upgrade, update the **percona-release** utility to the latest version. This is required to install the new version packages of Percona Distribution for PostgreSQL. Refer to [Percona Software Repositories Documentation](https://www.percona.com/doc/percona-repo-config/percona-release.html#updating-percona-release-to-the-latest-version) for update instructions. - -!!! important - - Run all commands as root or via **sudo**. + Before the upgrade, [update the `percona-release` :octicons-link-external-16:](https://www.percona.com/doc/percona-repo-config/percona-release.html#updating-percona-release-to-the-latest-version) utility to the latest version. This is required to install the new version packages of Percona Distribution for PostgreSQL. +Run **all** commands as root or via **sudo**: +{.power-number} 1. Stop the `postgresql` service. - - === "On Debian / Ubuntu" + === ":material-debian: On Debian / Ubuntu" ```{.bash data-promp="$"} $ sudo systemctl stop postgresql.service ``` - === "On Red Hat Enterprise Linux and derivatives" + === ":material-redhat: On Red Hat Enterprise Linux and derivatives" ```{.bash data-promp="$"} $ sudo systemctl stop postgresql-13 @@ -53,16 +50,16 @@ Minor upgrade of Percona Distribution for PostgreSQL includes the following step 3. Restart the `postgresql` service. - === "On Debian / Ubuntu" + === ":material-debian: On Debian / Ubuntu" - ```{.bash data-promp="$"} + ```{.bash data-prompt="$"} $ sudo systemctl start postgresql.service ``` - === "On Red Hat Enterprise Linux and derivatives" + === ":material-redhat: On Red Hat Enterprise Linux and derivatives" - ```{.bash data-promp="$"} + ```{.bash data-prompt="$"} $ sudo systemctl start postgresql-13 ``` diff --git a/docs/pg-stat-monitor.md b/docs/pg-stat-monitor.md index e5d1263e8..6ab95c65a 100644 --- a/docs/pg-stat-monitor.md +++ b/docs/pg-stat-monitor.md @@ -28,7 +28,7 @@ When a bucket lifetime expires, `pg_stat_monitor` resets all statistics and writ #### pg_stat_monitor view -The `pg_stat_monitor` view contains all the statistics collected and aggregated by the extension. This view contains one row for each distinct combination of metrics and whether it is a top-level statement or not (up to the maximum number of distinct statements that the module can track). For details about available metrics, refer to the [`pg_stat_monitor` view reference](https://docs.percona.com/pg-stat-monitor/reference.html). +The `pg_stat_monitor` view contains all the statistics collected and aggregated by the extension. This view contains one row for each distinct combination of metrics and whether it is a top-level statement or not (up to the maximum number of distinct statements that the module can track). For details about available metrics, refer to the [`pg_stat_monitor` view reference :octicons-link-external-16:](https://docs.percona.com/pg-stat-monitor/reference.html). The following are the primary keys for pg_stat_monitor: @@ -72,11 +72,11 @@ To learn more, see [Changing the configuration](#changing-the-configuration). ## Installation -This section describes how to install `pg_stat_monitor` from Percona repositories. To learn about other installation methods, see the [Installation](https://docs.percona.com/pg-stat-monitor/install.html) section in the `pg_stat_monitor` documentation. +This section describes how to install `pg_stat_monitor` from Percona repositories. To learn about other installation methods, see the [Installation :octicons-link-external-16:](https://docs.percona.com/pg-stat-monitor/install.html) section in the `pg_stat_monitor` documentation. **Preconditions**: -To install `pg_stat_monitor` from Percona repositories, you need to subscribe to them. To do this, you must have the [`percona-release` repository management tool](https://www.percona.com/doc/percona-repo-config/installing.html) up and running. +To install `pg_stat_monitor` from Percona repositories, you need to subscribe to them. To do this, you must have the [`percona-release` repository management tool :octicons-link-external-16:](https://www.percona.com/doc/percona-repo-config/installing.html) up and running. To install `pg_stat_monitor`, run the following commands: @@ -121,7 +121,7 @@ To install `pg_stat_monitor`, run the following commands: 1. Add `pg_stat_monitor` in the `shared_preload_libraries` configuration parameter. - The recommended way to modify PostgreSQL configuration file is using the [ALTER SYSTEM](https://www.postgresql.org/docs/13/sql-altersystem.html) command. [Connect to psql](installing.md#connect-to-the-server) and use the following command: + The recommended way to modify PostgreSQL configuration file is using the [ALTER SYSTEM](https://www.postgresql.org/docs/13/sql-altersystem.html) command. [Connect to psql](connect.md) and use the following command: ```sql ALTER SYSTEM SET shared_preload_libraries = 'pg_stat_monitor'; @@ -142,14 +142,14 @@ To install `pg_stat_monitor`, run the following commands: 2. Start or restart the `postgresql` instance to enable `pg_stat_monitor`. Use the following command for restart: - === "On Debian and Ubuntu" + === ":material-debian: On Debian and Ubuntu" ```{.bash data-prompt="$"} $ sudo systemctl restart postgresql.service ``` - === "On Red Hat Enterprise Linux and derivatives" + === ":material-redhat: On Red Hat Enterprise Linux and derivatives" ```{.bash data-prompt="$"} $ sudo systemctl restart postgresql-13 @@ -189,7 +189,7 @@ WHERE pg_database.oid = oid; ``` -Find more usage examples in the [`pg_stat_monitor` user guide](https://docs.percona.com/pg-stat-monitor/user_guide.html). +Find more usage examples in the [`pg_stat_monitor` user guide :octicons-link-external-16:](https://docs.percona.com/pg-stat-monitor/user_guide.html). ## Changing the configuration @@ -223,7 +223,7 @@ SELECT name, short_desc FROM pg_settings WHERE name LIKE '%pg_stat_monitor%'; pg_stat_monitor.pgsm_track_utility | Selects whether utility commands are tracked. ``` -You can change a parameter by setting a new value in the configuration file. Some parameters require server restart to apply a new value. For others, configuration reload is enough. Refer to the [configuration parameters](https://docs.percona.com/pg-stat-monitor/configuration.html) of the `pg_stat_monitor` documentation for the parameters’ description, how you can change their values and if the server restart is required to apply them. +You can change a parameter by setting a new value in the configuration file. Some parameters require server restart to apply a new value. For others, configuration reload is enough. Refer to the [configuration parameters :octicons-link-external-16:](https://docs.percona.com/pg-stat-monitor/configuration.html) of the `pg_stat_monitor` documentation for the parameters’ description, how you can change their values and if the server restart is required to apply them. As an example, let’s set the bucket lifetime from default 60 seconds to 30 seconds. Use the **ALTER SYSTEM** command: @@ -261,10 +261,10 @@ WHERE name = 'pg_stat_monitor.pgsm_bucket_time'; !!! admonition "See also" - [`pg_stat_monitor` Documentation](https://docs.percona.com/pg-stat-monitor/index.html) + [`pg_stat_monitor` Documentation :octicons-link-external-16:](https://docs.percona.com/pg-stat-monitor/index.html) Percona Blog: - * [pg_stat_monitor: A New Way Of Looking At PostgreSQL Metrics](https://www.percona.com/blog/2021/01/19/pg_stat_monitor-a-new-way-of-looking-at-postgresql-metrics/) - * [Improve PostgreSQL Query Performance Insights with pg_stat_monitor](https://www.percona.com/blog/improve-postgresql-query-performance-insights-with-pg_stat_monitor/) + * [pg_stat_monitor: A New Way Of Looking At PostgreSQL Metrics :octicons-link-external-16:](https://www.percona.com/blog/2021/01/19/pg_stat_monitor-a-new-way-of-looking-at-postgresql-metrics/) + * [Improve PostgreSQL Query Performance Insights with pg_stat_monitor :octicons-link-external-16:](https://www.percona.com/blog/improve-postgresql-query-performance-insights-with-pg_stat_monitor/) diff --git a/docs/release-notes-v13.13.upd.md b/docs/release-notes-v13.13.upd.md index 4ff7c6098..bd3073789 100644 --- a/docs/release-notes-v13.13.upd.md +++ b/docs/release-notes-v13.13.upd.md @@ -4,4 +4,4 @@ Percona Distribution for PostgreSQL is a solution with the collection of tools from PostgreSQL community that are tested to work together and serve to assist you in deploying and managing PostgreSQL. The aim of Percona Distribution for PostgreSQL is to address the operational issues like High-Availability, Disaster Recovery, Security, Spatial data handling, Observability, Performance and Scalability and others that enterprises are facing. -This update of Percona Distribution for PostgreSQL includes the new version of [`pg_stat_monitor` 2.0.4](https://docs.percona.com/pg-stat-monitor/release-notes/2.0.4.html) that fixes the issue with the extension causing the deadlock in the Percona Operator for PostgreSQL when executing the `pgsm_store` function. +This update of Percona Distribution for PostgreSQL includes the new version of [`pg_stat_monitor` 2.0.4 :octicons-link-external-16:](https://docs.percona.com/pg-stat-monitor/release-notes/2.0.4.html) that fixes the issue with the extension causing the deadlock in the Percona Operator for PostgreSQL when executing the `pgsm_store` function. diff --git a/docs/repo-overview.md b/docs/repo-overview.md index 1c256e75d..7f3444bed 100644 --- a/docs/repo-overview.md +++ b/docs/repo-overview.md @@ -50,10 +50,7 @@ The `percona-ppg-server-ha` meta-package installs high-availability components t | `percona-patroni`| A high-availability solution for PostgreSQL. | | `percona-haproxy`| A high-availability and load-balancing solution | | `etcd` | A consistent, distributed key-value store | -| `python3-python-etcd` | A Python client for etcd.[^1] | -| `etcd-client`, `etcd-server` | The client/server of the distributed key-value store. [^2]| +| `python3-python-etcd` | A Python client for etcd.| +| `etcd-client`, `etcd-server` | The client/server of the distributed key-value store. | - -[^1]: Is included in repositories for RHEL 8 / CentOS 8 operating systems -[^2]: Are included in repositories for Debian 12 operating system diff --git a/docs/solutions.md b/docs/solutions.md new file mode 100644 index 000000000..dcaa787df --- /dev/null +++ b/docs/solutions.md @@ -0,0 +1,30 @@ +# Percona Distribution for PostgreSQL solutions + +Find the right solution to help you achieve your organization's goals. + +
+ +### :material-clock-check-outline: High availability + +Check out how you can ensure continuous access to your database. + +[High availability :material-arrow-right:](solutions/high-availability.md){.md-button} + +
+ +### :octicons-globe-24: Spatial data handling + +Dealing with spatial data? Learn how you can store and manipulate it. + +[Spatial data handling :material-arrow-right:](solutions/postgis.md){.md-button} + +
+ +### :material-backup-restore: Backup and disaster recovery + +Protect your database against accidental or malicious data loss or data corruption. + +[Backup and disaster recovery :material-arrow-right:](solutions/backup-recovery.md){.md-button} + +
+
\ No newline at end of file diff --git a/docs/solutions/backup-recovery.md b/docs/solutions/backup-recovery.md index 94eeddf31..61d28b1bb 100644 --- a/docs/solutions/backup-recovery.md +++ b/docs/solutions/backup-recovery.md @@ -48,11 +48,11 @@ A Disaster Recovery (DR) solution ensures that a system can be quickly restored To achieve a production grade PostgreSQL disaster recovery solution, you need something that can take full or incremental database backups from a running instance, and restore from those backups at any point in time. Percona Distribution for PostgreSQL is supplied with [pgBackRest](#pgbackrest): a reliable, open-source backup and recovery solution for PostgreSQL. -This document focuses on the Disaster recovery solution in Percona Distribution for PostgreSQL. The [Deploying backup and disaster recovery solution in Percona Distribution for PostgreSQL](dr-pg-backrestsetup.md) tutorial provides guidelines of how to set up and test this solution. +This document focuses on the Disaster recovery solution in Percona Distribution for PostgreSQL. The [Deploying backup and disaster recovery solution in Percona Distribution for PostgreSQL](dr-pgbackrest-setup.md) tutorial provides guidelines of how to set up and test this solution. ### pgBackRest -[pgBackRest](https://pgbackrest.org/) is an easy-to-use, open-source solution that can reliably back up even the largest of PostgreSQL databases. `pgBackRest` supports the following backup types: +[pgBackRest :octicons-link-external-16:](https://pgbackrest.org/) is an easy-to-use, open-source solution that can reliably back up even the largest of PostgreSQL databases. `pgBackRest` supports the following backup types: * full backup - a complete copy of your entire data set. * differential backup - includes all data that has changed since the last full backup. While this means the backup time is slightly higher, it enables a faster restore. @@ -68,7 +68,7 @@ Finally, `pgBackRest` also supports restoring PostgreSQL databases to a differen ## Setup overview -This section describes the architecture of the backup and disaster recovery solution. For the configuration steps, refer to the [Deploying backup and disaster recovery solution in Percona Distribution for PostgreSQL](dr-pg-backrestsetup.md). +This section describes the architecture of the backup and disaster recovery solution. For the configuration steps, refer to the [Deploying backup and disaster recovery solution in Percona Distribution for PostgreSQL](dr-pgbackrest-setup.md). ### System architecture @@ -76,7 +76,7 @@ As the configuration example, we will use a three server architecture where `pgB !!! important - Passwordless SSH may not be an ideal solution for your environment. In this case, consider using other methods, for example, [TLS with client certificates](https://pgbackrest.org/user-guide-rhel.html#repo-host/config). + Passwordless SSH may not be an ideal solution for your environment. In this case, consider using other methods, for example, [TLS with client certificates :octicons-link-external-16:](https://pgbackrest.org/user-guide-rhel.html#repo-host/config). The following diagram illustrates the architecture layout: diff --git a/docs/solutions/dr-pgbackrest-setup.md b/docs/solutions/dr-pgbackrest-setup.md index 8be4dbc29..4e48f9fcc 100644 --- a/docs/solutions/dr-pgbackrest-setup.md +++ b/docs/solutions/dr-pgbackrest-setup.md @@ -137,7 +137,7 @@ Before setting up passwordless SSH, ensure that the _postgres_ user in all three Install Percona Distribution for PostgreSQL in the primary and the secondary nodes from Percona repository. -1. [Install `percona-release`](https://www.percona.com/doc/percona-repo-config/installing.html). +1. [Install `percona-release` :octicons-link-external-16:](https://www.percona.com/doc/percona-repo-config/installing.html). 2. Enable the repository: ```{.bash data-promp="$"} @@ -146,13 +146,13 @@ Install Percona Distribution for PostgreSQL in the primary and the secondary nod 3. Install Percona Distribution for PostgreSQL packages - === "On Debian and Ubuntu" + === ":material-debian: On Debian and Ubuntu" ```{.bash data-promp="$"} $ sudo apt install percona-postgresql-13 -y ``` - === "On RedHat Enterprise Linux and derivatives" + === ":material-redhat: On RedHat Enterprise Linux and derivatives" ```{.bash data-promp="$"} $ sudo yum install percona-postgresql13-server @@ -190,13 +190,13 @@ At this step, configure the PostgreSQL instance on the `pg-primary` node for con Install `pgBackRest` in all three instances from Percona repository. Use the following command: -=== "On Debian / Ubuntu" +=== ":material-debian: On Debian / Ubuntu" ```{.bash data-promp="$"} $ sudo apt-get install percona-pgbackrest ``` -=== "On RHEL / CentOS" +=== ":material-redhat: On RHEL / derivatives" ```{.bash data-promp="$"} $ sudo yum install percona-pgbackrest diff --git a/docs/solutions/ha-setup-apt.md b/docs/solutions/ha-setup-apt.md index c850f08ae..13ddb4fea 100644 --- a/docs/solutions/ha-setup-apt.md +++ b/docs/solutions/ha-setup-apt.md @@ -83,7 +83,7 @@ Run the following commands on node1`, `node2` and `node3`: 1. Install Percona Distribution for PostgreSQL - * [Install `percona-release`](https://www.percona.com/doc/percona-repo-config/installing.html). + * [Install `percona-release` :octicons-link-external-16:](https://www.percona.com/doc/percona-repo-config/installing.html). * Enable the repository: diff --git a/docs/solutions/ha-setup-yum.md b/docs/solutions/ha-setup-yum.md index 6b07edb6c..d499df6da 100644 --- a/docs/solutions/ha-setup-yum.md +++ b/docs/solutions/ha-setup-yum.md @@ -80,14 +80,14 @@ It's not necessary to have name resolution, but it makes the whole setup more re 1. Install Percona Distribution for PostgreSQL on `node1`, `node2` and `node3` from Percona repository: - * [Install `percona-release`](https://www.percona.com/doc/percona-repo-config/installing.html). + * [Install `percona-release` :octicons-link-external-16:](https://www.percona.com/doc/percona-repo-config/installing.html). * Enable the repository: ```{.bash data-prompt="$"} $ sudo percona-release setup ppg13 ``` - * [Install Percona Distribution for PostgreSQL packages](../installing.md#on-red-hat-enterprise-linux-and-centos-using-yum). + * [Install Percona Distribution for PostgreSQL packages](../yum.md). !!! important diff --git a/docs/solutions/high-availability.md b/docs/solutions/high-availability.md index 1c348865f..e9bdfeddf 100644 --- a/docs/solutions/high-availability.md +++ b/docs/solutions/high-availability.md @@ -1,6 +1,6 @@ # High Availability in PostgreSQL with Patroni -PostgreSQL has been widely adopted as a modern, high-performance transactional database. A highly available PostgreSQL cluster can withstand failures caused by network outages, resource saturation, hardware failures, operating system crashes or unexpected reboots. Such cluster is often a critical component of the enterprise application landscape, where [four nines of availability](https://en.wikipedia.org/wiki/High_availability#Percentage_calculation) is a minimum requirement. +PostgreSQL has been widely adopted as a modern, high-performance transactional database. A highly available PostgreSQL cluster can withstand failures caused by network outages, resource saturation, hardware failures, operating system crashes or unexpected reboots. Such cluster is often a critical component of the enterprise application landscape, where [four nines of availability :octicons-link-external-16:](https://en.wikipedia.org/wiki/High_availability#Percentage_calculation) is a minimum requirement. There are several methods to achieve high availability in PostgreSQL. This solution document provides [Patroni](#patroni) - the open-source extension to facilitate and manage the deployment of high availability in PostgreSQL. @@ -34,11 +34,11 @@ There are several methods to achieve high availability in PostgreSQL. This solut To address these shortcomings, there are a multitude of third-party, open-source extensions for PostgreSQL. The challenge for a database administrator here is to select the right utility for the current scenario. - Percona Distribution for PostgreSQL solves this challenge by providing the [Patroni](https://patroni.readthedocs.io/en/latest/) extension for achieving PostgreSQL high availability. + Percona Distribution for PostgreSQL solves this challenge by providing the [Patroni :octicons-link-external-16:](https://patroni.readthedocs.io/en/latest/) extension for achieving PostgreSQL high availability. ## Patroni -[Patroni](https://patroni.readthedocs.io/en/latest/) is a template for you to create your own customized, high-availability solution using Python and - for maximum accessibility - a distributed configuration store like ZooKeeper, etcd, Consul or Kubernetes. +[Patroni :octicons-link-external-16:](https://patroni.readthedocs.io/en/latest/) is a template for you to create your own customized, high-availability solution using Python and - for maximum accessibility - a distributed configuration store like ZooKeeper, etcd, Consul or Kubernetes. ### Key benefits of Patroni: diff --git a/docs/solutions/pgbackrest.md b/docs/solutions/pgbackrest.md index 62aa9cc6e..f1749d202 100644 --- a/docs/solutions/pgbackrest.md +++ b/docs/solutions/pgbackrest.md @@ -1,6 +1,6 @@ # pgBackRest setup -[pgBackRest](https://pgbackrest.org/) is a backup tool used to perform PostgreSQL database backup, archiving, restoration, and point-in-time recovery. While it can be used for local backups, this procedure shows how to deploy a [pgBackRest server running on a dedicated host](https://pgbackrest.org/user-guide-rhel.html#repo-host) and how to configure PostgreSQL servers to use it for backups and archiving. +[pgBackRest :octicons-link-external-16:](https://pgbackrest.org/) is a backup tool used to perform PostgreSQL database backup, archiving, restoration, and point-in-time recovery. While it can be used for local backups, this procedure shows how to deploy a [pgBackRest server running on a dedicated host :octicons-link-external-16:](https://pgbackrest.org/user-guide-rhel.html#repo-host) and how to configure PostgreSQL servers to use it for backups and archiving. You also need a backup storage to store the backups. It can either be a remote storage such as AWS S3, S3-compatible storages or Azure blob storage, or a filesystem-based one. @@ -14,7 +14,7 @@ $ sudo su - ### Install pgBackRest -1. Enable the repository with [percona-release](https://www.percona.com/doc/percona-repo-config/index.html) +1. Enable the repository with [percona-release :octicons-link-external-16:](https://www.percona.com/doc/percona-repo-config/index.html) ```{.bash data-prompt="$"} $ percona-release setup ppg-{{pgversion}} @@ -22,13 +22,13 @@ $ sudo su - 2. Install pgBackRest package - === "Debian/Ubuntu" + === ":material-debian: On Debian/Ubuntu" ```{.bash data-prompt="$"} $ apt install percona-pgbackrest ``` - === "RHEL/derivatives" + === ":material-redhat: On RHEL/derivatives" ```{.bash data-prompt="$"} $ yum install percona-pgbackrest @@ -68,7 +68,7 @@ $ sudo su - Then use the following command to create a basic configuration file using the environment variables we created in a previous step: - === "Debian/Ubuntu" + === ":material-debian: On Debian/Ubuntu" ``` cat < pgbackrest.conf @@ -149,7 +149,7 @@ $ sudo su - EOF ``` - === "RHEL/derivatives" + === ":material-redhat: On RHEL/derivatives" ``` cat < pgbackrest.conf @@ -309,13 +309,13 @@ Run the following commands on `node1`, `node2`, and `node3`. 1. Install pgBackRest package - === "Debian/Ubuntu" + === ":material-debian: On Debian/Ubuntu" ```{.bash data-prompt="$"} $ apt install percona-pgbackrest ``` - === "RHEL/derivatives" + === ":material-redhat: On RHEL/derivatives" ```{.bash data-prompt="$"} $ yum install percona-pgbackrest @@ -345,7 +345,7 @@ Run the following commands on `node1`, `node2`, and `node3`. 5. Edit or create the configuration file which, as explained above, can be either at the `/etc/pgbackrest/pgbackrest.conf` or `/etc/pgbackrest.conf` path: - === "Debian/Ubuntu" + === ":material-debian: On Debian/Ubuntu" ```ini title="pgbackrest.conf" cat < pgbackrest.conf @@ -375,7 +375,7 @@ Run the following commands on `node1`, `node2`, and `node3`. ``` - === "RHEL/derivatives" + === ":material-redhat: On RHEL/derivatives" ```ini title="pgbackrest.conf" cat < pgbackrest.conf @@ -449,7 +449,7 @@ Run the following commands on `node1`, `node2`, and `node3`. $ patronictl -c /etc/patroni/patroni.yml edit-config ``` - === "Debian/Ubuntu" + === ":material-debian: On Debian/Ubuntu" ```yaml title="/etc/patroni/patroni.yml" postgresql: @@ -464,7 +464,7 @@ Run the following commands on `node1`, `node2`, and `node3`. (...) ``` - === "RHEL/derivatives" + === ":material-redhat: On RHEL/derivatives" ```yaml title="/etc/patroni/patroni.yml" postgresql: diff --git a/docs/solutions/postgis-deploy.md b/docs/solutions/postgis-deploy.md index 478c08491..04ba75aa4 100644 --- a/docs/solutions/postgis-deploy.md +++ b/docs/solutions/postgis-deploy.md @@ -5,16 +5,16 @@ The following document provides guidelines how to install PostGIS and how to run ## Considerations 1. We assume that you have the basic knowledge of spatial data, GIS (Geographical Information System) and of shapefiles. -2. For uploading the spatial data and querying the database, we use the same [data set](https://s3.amazonaws.com/s3.cleverelephant.ca/postgis-workshop-2020.zip) as is used in [PostGIS tutorial](http://postgis.net/workshops/postgis-intro/). +2. For uploading the spatial data and querying the database, we use the same [data set :octicons-link-external-16:](https://s3.amazonaws.com/s3.cleverelephant.ca/postgis-workshop-2020.zip) as is used in [PostGIS tutorial :octicons-link-external-16:](http://postgis.net/workshops/postgis-intro/). ## Install PostGIS -=== "On Debian and Ubuntu" +=== ":material-debian: On Debian and Ubuntu" 1. Enable Percona repository - As other components of Percona Distribution for PostgreSQL, PostGIS is available from Percona repositories. Use the [`percona-release`](https://docs.percona.com/percona-software-repositories/installing.html) repository management tool to enable the repository. + As other components of Percona Distribution for PostgreSQL, PostGIS is available from Percona repositories. Use the [`percona-release` :octicons-link-external-16:](https://docs.percona.com/percona-software-repositories/installing.html) repository management tool to enable the repository. ```{.bash data-prompt="$"} $ sudo percona-release setup ppg{{pgversion}} @@ -41,13 +41,13 @@ The following document provides guidelines how to install PostGIS and how to run $ sudo apt-get install libsfcgal1 ``` -=== "On RHEL and derivatives" +=== ":material-redhat: On RHEL and derivatives" 1. Check the [Platform specific notes](../yum.md#for-postgis) and enable required repositories and modules for the dependencies relevant to your operating system. 2. Enable Percona repository - As other components of Percona Distribution for PostgreSQL, PostGIS is available from Percona repositories. Use the [`percona-release`](https://docs.percona.com/percona-software-repositories/installing.html) repository management tool to enable the repository. + As other components of Percona Distribution for PostgreSQL, PostGIS is available from Percona repositories. Use the [`percona-release` :octicons-link-external-16:](https://docs.percona.com/percona-software-repositories/installing.html) repository management tool to enable the repository. ```{.bash data-prompt="$"} $ sudo percona-release setup ppg{{pgversion}} @@ -122,27 +122,27 @@ PostGIS provides the `shp2pgsql` command line utility that converts the binary d * `-D` flag instructs the command to generate the dump format * `-I` flag instructs to create the spatial index on the table upon the data load - * `-s` indicates the [spatial reference identifier](https://en.wikipedia.org/wiki/Spatial_reference_system) of the data. The data we load is in the Projected coordinate system for North America and has the value 26918. + * `-s` indicates the [spatial reference identifier :octicons-link-external-16:](https://en.wikipedia.org/wiki/Spatial_reference_system) of the data. The data we load is in the Projected coordinate system for North America and has the value 26918. * `nyc_streets.shp` is the source shapefile * `nyc_streets` is the table name to create in the database * `dbname=nyc` is the database name 3. Check the uploaded data - ```sql - \d nyc_streets; - Table "public.nyc_streets" - Column | Type | Collation | Nullable | Default - --------+---------------------------------+-----------+----------+------------------------------------------ - gid | integer | | not null | nextval('nyc_streets_gid_seq'::regclass) - id | double precision | | | - name | character varying(200) | | | - oneway | character varying(10) | | | - type | character varying(50) | | | - geom | geometry(MultiLineString,26918) | | | - Indexes: - "nyc_streets_pkey" PRIMARY KEY, btree (gid) - "nyc_streets_geom_idx" gist (geom) - ``` + ```sql + \d nyc_streets; + Table "public.nyc_streets" + Column | Type | Collation | Nullable | Default + --------+---------------------------------+-----------+----------+------------------------------------------ + gid | integer | | not null | nextval('nyc_streets_gid_seq'::regclass) + id | double precision | | | + name | character varying(200) | | | + oneway | character varying(10) | | | + type | character varying(50) | | | + geom | geometry(MultiLineString,26918) | | | + Indexes: + "nyc_streets_pkey" PRIMARY KEY, btree (gid) + "nyc_streets_geom_idx" gist (geom) + ``` 4. Repeat the command to upload other shapefiles in the data set: `nyc_census_blocks`, `nyc_neighborhoods`, `nyc_subway_stations` \ No newline at end of file diff --git a/docs/solutions/postgis-upgrade.md b/docs/solutions/postgis-upgrade.md index d6053d658..51a4b9810 100644 --- a/docs/solutions/postgis-upgrade.md +++ b/docs/solutions/postgis-upgrade.md @@ -13,13 +13,13 @@ The spatial database upgrade consists of two steps: ## Upgrade PostGIS -Each version of PostGIS is compatible with several versions of PostgreSQL and vise versa. The best practice is to first upgrade the PostGIS extension on the source cluster to match the compatible version on the target cluster and then upgrade PostgreSQL. Please see the [PostGIS Support matrix](https://trac.osgeo.org/postgis/wiki/UsersWikiPostgreSQLPostGIS#PostGISSupportMatrix) for version compatibility. +Each version of PostGIS is compatible with several versions of PostgreSQL and vise versa. The best practice is to first upgrade the PostGIS extension on the source cluster to match the compatible version on the target cluster and then upgrade PostgreSQL. Please see the [PostGIS Support matrix :octicons-link-external-16:](https://trac.osgeo.org/postgis/wiki/UsersWikiPostgreSQLPostGIS#PostGISSupportMatrix) for version compatibility. PostGIS is enabled on the database level. This means that the upgrade is also done on the database level. === "PostGIS 3 and above" - Connect to the database where it is enabled and run the [`PostGIS_Extensions_Upgrade()`](https://postgis.net/docs/PostGIS_Extensions_Upgrade.html) function: + Connect to the database where it is enabled and run the [`PostGIS_Extensions_Upgrade()` :octicons-link-external-16:](https://postgis.net/docs/PostGIS_Extensions_Upgrade.html) function: ```sql SELECT postgis_extensions_upgrade(); @@ -50,4 +50,4 @@ PostGIS is enabled on the database level. This means that the upgrade is also do Upgrade PostgreSQL either to the [latest minor](../minor-upgrade.md) or to the [major version](../major-upgrade.md). -If you are using long deprecated views and functions and / or need the expertise in upgrading your spatial database, [contact Percona Managed Services](https://www.percona.com/services/managed-services) for an individual upgrade scenario development. +If you are using long deprecated views and functions and / or need the expertise in upgrading your spatial database, [contact Percona Managed Services :octicons-link-external-16:](https://www.percona.com/services/managed-services) for an individual upgrade scenario development. diff --git a/docs/solutions/postgis.md b/docs/solutions/postgis.md index 70dc39313..103cbb59d 100644 --- a/docs/solutions/postgis.md +++ b/docs/solutions/postgis.md @@ -7,7 +7,7 @@ Organizations dealing with spatial data need to store it somewhere and manipulat * Geographical data like points, lines, polygons, GPS coordinates that can be mapped on a sphere. * Geometrical data. This is also points, lines and polygons but they apply to a 2D surface. -To operate with spatial data inside SQL queries, PostGIS supports [spatial functions](https://postgis.net/docs/reference.html#SRS_Functions) like distance, area, union, intersection. It uses the spatial indexes like [R-Tree](https://en.wikipedia.org/wiki/R-tree) and [Quadtree](https://en.wikipedia.org/wiki/Quadtree) for efficient processing of database operations. Read more about supported spatial functions and indexes in [PostGIS documentation](https://postgis.net/workshops/postgis-intro/introduction.html). +To operate with spatial data inside SQL queries, PostGIS supports [spatial functions :octicons-link-external-16:](https://postgis.net/docs/reference.html#SRS_Functions) like distance, area, union, intersection. It uses the spatial indexes like [R-Tree :octicons-link-external-16:](https://en.wikipedia.org/wiki/R-tree) and [Quadtree :octicons-link-external-16:](https://en.wikipedia.org/wiki/Quadtree) for efficient processing of database operations. Read more about supported spatial functions and indexes in [PostGIS documentation :octicons-link-external-16:](https://postgis.net/workshops/postgis-intro/introduction.html). By deploying PostGIS with Percona Distribution for PostgreSQL, you receive the open source spatial database that you can use in various areas without vendor lock-in. @@ -24,7 +24,7 @@ You can use PostGIS in the following cases: Despite its power and flexibility, PostGIS may not suit your needs if: -* You need to store only a couple of map locations. Consider using the [built-in geometric functions and operations of PostgreSQL](https://www.postgresql.org/docs/current/functions-geometry.html) +* You need to store only a couple of map locations. Consider using the [built-in geometric functions and operations of PostgreSQL :octicons-link-external-16:](https://www.postgresql.org/docs/current/functions-geometry.html) * You need real-time data analysis. While PostGIS can handle real-time spatial data, it may not be the best option for real-time data analysis on large volumes of data. * You need complex 3D analysis or visualization. * You need to acquire spatial data. Use other tools for this purpose and import spatial data into PostGIS to manipulate it. diff --git a/docs/trademark-policy.md b/docs/trademark-policy.md index 071dad339..94ff02088 100644 --- a/docs/trademark-policy.md +++ b/docs/trademark-policy.md @@ -1,6 +1,6 @@ # Trademark Policy -This [Trademark Policy](https://www.percona.com/trademark-policy) is to ensure that users of Percona-branded products or +This [Trademark Policy :octicons-link-external-16:](https://www.percona.com/trademark-policy) is to ensure that users of Percona-branded products or services know that what they receive has really been developed, approved, tested and maintained by Percona. Trademarks help to prevent confusion in the marketplace, by distinguishing one company’s or person’s products and services diff --git a/docs/troubleshooting.md b/docs/troubleshooting.md new file mode 100644 index 000000000..136737ff9 --- /dev/null +++ b/docs/troubleshooting.md @@ -0,0 +1,23 @@ +# Troubleshooting guide + +## Cannot create a table. Permission denied in schema `public` + +Every database in PostgreSQL has a default schema called `public`. A schema stores database objects like tables, views, indexes and allows organizing them into logical groups. + +When you create a table without specifying a schema name, it ends up in the `public` schema by default. + +Starting with PostgreSQL 15, non-database owners cannot access the `public` schema. Therefore, you can either grant privileges to the database for your user using the [GRANT](https://www.postgresql.org/docs/{{pgvesrion}}/sql-grant.html) command or create your own schema to insert the data. + +To create a schema, use the following statement: + +```sql +CREATE SCHEMA demo; +``` + +To ensure all tables end up in your newly created schema, use the following statement ot set the schema: + +```sql +CREATE SCHEMA demo; +``` + +Replace the `demo` name with your value. diff --git a/docs/uninstalling.md b/docs/uninstalling.md index a4abf657f..add15c3b6 100644 --- a/docs/uninstalling.md +++ b/docs/uninstalling.md @@ -4,12 +4,13 @@ To uninstall Percona Distribution for PostgreSQL, remove all the installed packa **NOTE**: Should you need the data files later, back up your data before uninstalling Percona Distribution for PostgreSQL. -=== "On Debian and Ubuntu using `apt`" +=== ":material-debian: On Debian and Ubuntu using `apt`" To uninstall Percona Distribution for PostgreSQL on platforms that use **apt** package manager such as Debian or Ubuntu, complete the following steps. Run all commands as root or via **sudo**. + {.power-number} 1. Stop the Percona Distribution for PostgreSQL service. @@ -32,12 +33,13 @@ To uninstall Percona Distribution for PostgreSQL, remove all the installed packa $ rm -rf /etc/postgresql/13/main ``` -=== "On Red Hat Enterprise Linux and CentOS using `yum`" +=== ":material-redhat: On Red Hat Enterprise Linux and CentOS using `yum`" To uninstall Percona Distribution for PostgreSQL on platforms that use **yum** package manager such as Red Hat Enterprise Linux or CentOS, complete the following steps. Run all commands as root or via **sudo**. + {.power-number} 1. Stop the Percona Distribution for PostgreSQL service. diff --git a/docs/whats-next.md b/docs/whats-next.md new file mode 100644 index 000000000..3d18085a7 --- /dev/null +++ b/docs/whats-next.md @@ -0,0 +1,25 @@ +# What's next? + +You've just had your first hands-on experience with PostgreSQL! That's a great start. + +To become more confident and proficient in developing database applications, let's expand your knowledge and skills in using PostgreSQL. Dive deeper into these key topics to solidify your PostgreSQL skills: + +- [SQL Syntax :octicons-link-external-16:](https://www.postgresql.org/docs/current/sql-syntax.html) +- [Data definition :octicons-link-external-16:](https://www.postgresql.org/docs/current/ddl.html) +- [Queries :octicons-link-external-16:](https://www.postgresql.org/docs/current/queries.html) +- [Functions and Operators :octicons-link-external-16:](https://www.postgresql.org/docs/current/functions.html) +- [Indexes :octicons-link-external-16:](https://www.postgresql.org/docs/current/indexes.html) + + +To effectively solve database administration tasks, master these essential topics: + +- [Backup and restore :octicons-link-external-16:](https://www.postgresql.org/docs/current/backup.html) +- [Authentication :octicons-link-external-16:](https://www.postgresql.org/docs/{{pgversion}}/auth-methods.html) and role-based access control +- [PostgreSQL contrib extensions and modules](contrib.md) +- [Monitor PostgreSQL with Percona Monitoring and Management :octicons-link-external-16:](https://docs.percona.com/percona-monitoring-and-management/quickstart/index.html) + + +Also, check out our solutions to help you meet the requirements of your organization. + +[Solutions](solutions.md){.md-button} + diff --git a/docs/yum.md b/docs/yum.md index f83f2691d..149501639 100644 --- a/docs/yum.md +++ b/docs/yum.md @@ -102,7 +102,10 @@ The following commands provide instructions how to enable required repositories For Red Hat Enterprise Linux 8 and derivatives, replace the operating system version in the commands accordingly. -=== "RHEL 9" +=== "RHEL 9" + + Run the following commands: + {.power-number} 1. Install `epel` repository @@ -124,6 +127,9 @@ For Red Hat Enterprise Linux 8 and derivatives, replace the operating system ver === "Rocky Linux 9" + Run the following commands: + {.power-number} + 1. Install `epel` repository ```{.bash data-prompt="$"} @@ -145,6 +151,9 @@ For Red Hat Enterprise Linux 8 and derivatives, replace the operating system ver === "Oracle Linux 9" + Run the following commands: + {.power-number} + 1. Install `epel` repository ```{.bash data-prompt="$"} @@ -165,6 +174,9 @@ For Red Hat Enterprise Linux 8 and derivatives, replace the operating system ver === "RHEL UBI 9" + Run the following commands: + {.power-number} + 1. Configure the Oracle-Linux repository. Create the `/etc/yum.repos.d/oracle-linux-ol9.repo` file to install the required dependencies: ```init title="/etc/yum.repos.d/oracle-linux-ol9.repo" @@ -214,7 +226,7 @@ Install `curl` for [Telemetry](telemetry.md). We use it to better understand the $ sudo yum -y install curl ``` -### Configure the repository +### Configure the repository {.power-number} 1. Install the `percona-release` repository management tool to subscribe to Percona repositories: @@ -241,6 +253,9 @@ $ sudo yum -y install curl ``` === "Install packages individually" + + Run the following commands: + {.power-number} 1. Install the PostgreSQL server package: @@ -344,30 +359,10 @@ Start the PostgreSQL service: $ sudo systemctl start postgresql-{{pgversion}} ``` -### Connect to the PostgreSQL server +Congratulations! Your Percona Distribution for PostgreSQL is up and running. -By default, `postgres` user and `postgres` database are created in PostgreSQL upon its installation and initialization. This allows you to connect to the database as the `postgres` user. +## Next steps -```{.bash data-prompt="$"} -$ sudo su postgres -``` - -Open the PostgreSQL interactive terminal: +[Enable extensions :material-arrow-right:](enable-extensions.md){.md-button} -```{.bash data-prompt="$"} -$ psql -``` - -!!! hint - - You can connect to `psql` as the `postgres` user in one go: - - ```{.bash data-prompt="$"} - $ sudo su - postgres -c psql - ``` - -To exit the `psql` terminal, use the following command: - -```{.bash data-prompt="$"} -$ \q -``` \ No newline at end of file +[Connect to PostgreSQL :material-arrow-right:](connect.md){.md-button} diff --git a/mkdocs-base.yml b/mkdocs-base.yml index c573d51d8..5f9ae4b14 100644 --- a/mkdocs-base.yml +++ b/mkdocs-base.yml @@ -164,7 +164,49 @@ extra: postgresrecommended: 16 nav: - - "Home": "index.md" + - 'Home': 'index.md' + - Get started: + - Quickstart guide: installing.md + - 1. Install: + - Via apt: apt.md + - Via yum: yum.md + - Run in Docker: docker.md + - enable-extensions.md + - repo-overview.md + - 2. Connect to PostgreSQL: connect.md + - 3. Manipulate data in PostgreSQL: crud.md + - 4. What's next: whats-next.md + - Extensions: + - 'Extensions': extensions.md + - contrib.md + - Percona-authored extensions: + - 'pg_stat_monitor': 'pg-stat-monitor.md' + - third-party.md + - Solutions: + - Overview: solutions.md + - High availability: + - "High availability": "solutions/high-availability.md" + - 'Deploying on Debian or Ubuntu': 'solutions/ha-setup-apt.md' + - 'Deploying on RHEL or derivatives': 'solutions/ha-setup-yum.md' + - solutions/pgbackrest.md + - solutions/ha-test.md + - Backup and disaster recovery: + - "Backup and disaster recovery": "solutions/backup-recovery.md" + - solutions/dr-pgbackrest-setup.md + - Spatial data handling: + - Overview: solutions/postgis.md + - Deployment: solutions/postgis-deploy.md + - Query spatial data: solutions/postgis-testing.md + - Upgrade spatial database: solutions/postgis-upgrade.md + - LDAP authentication: + - ldap.md + - Upgrade: + - "Major upgrade": major-upgrade.md + - minor-upgrade.md + - migration.md + - Troubleshooting guide: troubleshooting.md + - How to: how-to.md + - Uninstall: uninstalling.md - Release notes: - "Release notes index": "release-notes.md" - release-notes-v13.15.md @@ -200,45 +242,8 @@ nav: - release-notes-v13.2.md - release-notes-v13.1.md - release-notes-v13.0.md - - Installation and Upgrade: - - Install Percona Distribution for PostgreSQL: - - "Overview": "installing.md" - - "Install via apt": "apt.md" - - "Install via yum": "yum.md" - - enable-extensions.md - - repo-overview.md - - "Run in Docker": docker.md - - migration.md - - major-upgrade.md - - minor-upgrade.md - - Extensions: - - 'Extensions': extensions.md - - contrib.md - - third-party.md - - Percona-authored extensions: - - 'pg_stat_monitor': 'pg-stat-monitor.md' - - Solutions: - #- solutions.md - - High availability: - - "High availability": "solutions/high-availability.md" - - 'Deploying on Debian or Ubuntu': 'solutions/ha-setup-apt.md' - - 'Deploying on RHEL or derivatives': 'solutions/ha-setup-yum.md' - - solutions/pgbackrest.md - - solutions/ha-test.md - - Backup and disaster recovery: - - "Backup and disaster recovery": "solutions/backup-recovery.md" - - solutions/dr-pgbackrest-setup.md - - Spatial data handling: - - Overview: solutions/postgis.md - - Deployment: solutions/postgis-deploy.md - - Query spatial data: solutions/postgis-testing.md - - Upgrade spatial database: solutions/postgis-upgrade.md - - LDAP authentication: - - ldap.md - - Telemetry: telemetry.md - - How to: how-to.md - - Uninstall: uninstalling.md - - Licensing: licensing.md - - Trademark policy: - - trademark-policy.md -# - Version Selector: "../" + - Reference: + - Telemetry: telemetry.md + - Licensing: licensing.md + - Trademark policy: trademark-policy.md + diff --git a/snippets/supported-versions.md b/snippets/supported-versions.md index 78a2a1077..ee4c65856 100644 --- a/snippets/supported-versions.md +++ b/snippets/supported-versions.md @@ -1 +1 @@ -Percona provides installation packages in `DEB` and `RPM` format for 64-bit Linux distributions. Find the full list of supported platforms on the [Percona Software and Platform Lifecycle page](https://www.percona.com/services/policies/percona-software-support-lifecycle#pgsql). +Percona provides installation packages in `DEB` and `RPM` format for 64-bit Linux distributions. Find the full list of supported platforms on the [Percona Software and Platform Lifecycle page :octicons-link-external-16:](https://www.percona.com/services/policies/percona-software-support-lifecycle#pgsql).