Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions docs/pg-stat-monitor.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ To install `pg_stat_monitor`, run 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](installing.md#connect-to-the-server) and use the following command:

```
```sql
$ ALTER SYSTEM SET shared_preload_libraries = 'pg_stat_monitor';
```

Expand All @@ -106,21 +106,21 @@ To install `pg_stat_monitor`, run the following command:

* On Debian and Ubuntu:

```
```sh
$ sudo systemctl restart postgresql.service
```


* On Red Hat Enterprise Linux and CentOS:

```
```sh
$ sudo systemctl restart postgresql-13
```


3. Create the extension. Connect to `psql` and use the following command:

```
```sql
$ CREATE EXTENSION pg_stat_monitor;
```

Expand All @@ -140,7 +140,7 @@ $ CREATE EXTENSION pg_stat_monitor;

For example, to view the IP address of the client application that made the query, run the following command:

```
```sql
SELECT DISTINCT userid::regrole, pg_stat_monitor.datname, substr(query,0, 50) AS query, calls, bucket, bucket_start_time, queryid, client_ip
FROM pg_stat_monitor, pg_database
WHERE pg_database.oid = oid;
Expand All @@ -161,7 +161,7 @@ Find more usage examples in [pg_stat_monitor User Guide](https://github.com/perc

Run the following query to list available configuration parameters.

```
```sql
$ SELECT name,description FROM pg_stat_monitor_settings;
```

Expand Down Expand Up @@ -190,7 +190,7 @@ You can change a parameter by setting a new value in the configuration file. Som

As an example, let’s set the bucket lifetime from default 60 seconds to 100 seconds. Use the **ALTER SYSTEM** command:

```
```sql
$ ALTER SYSTEM set pg_stat_monitor.pgsm_bucket_time = 100;
```

Expand All @@ -199,20 +199,20 @@ Restart the server to apply the change:

* On Debian and Ubuntu

```
```sh
$ sudo systemctl restart restart postgresql.service
```


* On Red Hat Enterprise Linux and CentOS:

```
```bash
$ sudo systemctl restart postgresql-13
```

Verify the updated parameter:

```
```sql
$ SELECT name, value
FROM pg_stat_monitor_settings
WHERE name = 'pg_stat_monitor.pgsm_bucket_time';
Expand Down
4 changes: 2 additions & 2 deletions docs/solutions/backup-recovery.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ 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

Expand All @@ -61,7 +61,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

Expand Down
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

Markdown
mkdocs
mkdocs == 1.2.3
mkdocs-versioning
mkdocs-macros-plugin
mkdocs-exclude
Expand All @@ -12,4 +12,4 @@ mkdocs-material-extensions
mkdocs-bootstrap-tables-plugin
mkdocs-section-index
mkdocs-htmlproofer-plugin
mike
mike == 1.1.2