Skip to content

Commit 88c1293

Browse files
authored
Merge pull request #6727 from EnterpriseDB/docs/edits_to_pem10_group1
Edits to PEM 10 - first set
2 parents fe1ca3c + 7dfa3cd commit 88c1293

File tree

5 files changed

+35
-34
lines changed
  • install_template/templates/products/postgres-enterprise-manager-server
  • product_docs/docs

5 files changed

+35
-34
lines changed

install_template/templates/products/postgres-enterprise-manager-server/base.njk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ For more details, see [Configuring the PEM server on Linux](../configuring_the_p
9393

9494
!!! Note
9595

96-
- The operating system user pem is created while installing the PEM server. The pem application data and the session is saved to this user's home directory.
96+
- The operating system user pem is created while installing the PEM server. The PEM application data and the session is saved to this user's home directory.
9797

9898
## Supported locales
9999

product_docs/docs/epas/13/epas_guide/03_database_administration/02_index_advisor/index.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ There are three ways to use Index Advisor to analyze SQL queries:
1818

1919
- Provide queries at the EDB-PSQL command line that you want Index Advisor to analyze.
2020

21-
- Access Index Advisor through the Postgres Enterprise Manager client. When accessed via the PEM client, Index Advisor works with SQL Profiler, providing indexing recommendations on code captured in SQL traces. For more information about using SQL Profiler with PEM, see the [Using the SQL Profiler](/pem/latest/profiling_workloads/using_sql_profiler.mdx) and [Using the Index Advisor](03_using_index_advisor.mdx).
21+
- Access Index Advisor through the Postgres Enterprise Manager client. When accessed via the PEM client, Index Advisor works with SQL Profiler, providing indexing recommendations on code captured in SQL traces. For more information about using SQL Profiler with PEM, see the [Using SQL Profiler](/pem/latest/profiling_workloads/using_sql_profiler.mdx) and [Using Index Advisor](03_using_index_advisor.mdx).
2222

2323
Index Advisor will attempt to make indexing recommendations on `INSERT`, `UPDATE`, `DELETE` and `SELECT` statements. When invoking Index Advisor, you supply the workload in the form of a set of queries (if you are providing the command in an SQL file) or an `EXPLAIN` statement (if you are specifying the SQL statement at the psql command line). Index Advisor displays the query plan and estimated execution cost for the supplied query, but does not actually execute the query.
2424

product_docs/docs/epas/14/epas_guide/03_database_administration/02_index_advisor/index.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ You can use Index Advisor to analyze SQL queries in any of these ways:
1616

1717
- Invoke the Index Advisor utility program, supplying a text file containing the SQL queries that you want to analyze. Index Advisor generates a text file with `CREATE INDEX` statements for the recommended indexes.
1818
- Provide queries at the EDB-PSQL command line that you want Index Advisor to analyze.
19-
- Access Index Advisor through the Postgres Enterprise Manager (PEM) client. When accessed using the PEM client, Index Advisor works with SQL Profiler, providing indexing recommendations on code captured in SQL traces. For more information about using SQL Profiler with PEM, see [Using the SQL Profiler](/pem/latest/profiling_workloads/using_sql_profiler.mdx) and [Using the Index Advisor](03_using_index_advisor.mdx).
19+
- Access Index Advisor through the Postgres Enterprise Manager (PEM) client. When accessed using the PEM client, Index Advisor works with SQL Profiler, providing indexing recommendations on code captured in SQL traces. For more information about using SQL Profiler with PEM, see [Using SQL Profiler](/pem/latest/profiling_workloads/using_sql_profiler.mdx) and [Using Index Advisor](03_using_index_advisor.mdx).
2020
Index Advisor attempts to make indexing recommendations on `INSERT`, `UPDATE`, `DELETE`, and `SELECT` statements. When invoking Index Advisor, you supply the workload in the form of either:
2121

2222
- If you're providing the command in an SQL file, a set of queries

product_docs/docs/epas/15/managing_performance/02_index_advisor/index_advisor_overview.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ You can use Index Advisor to analyze SQL queries in any of these ways:
99

1010
- Invoke the Index Advisor utility program, supplying a text file containing the SQL queries that you want to analyze. Index Advisor generates a text file with `CREATE INDEX` statements for the recommended indexes.
1111
- Provide queries at the EDB-PSQL command line that you want Index Advisor to analyze.
12-
- Access Index Advisor through the Postgres Enterprise Manager (PEM) client. When accessed using the PEM client, Index Advisor works with SQL Profiler, providing indexing recommendations on code captured in SQL traces. For more information about using SQL Profiler and Index Advisor with PEM, see [Using the SQL profiler](/pem/latest/profiling_workloads/using_sql_profiler.mdx) and [Using the Index Advisor](03_using_index_advisor.mdx).
12+
- Access Index Advisor through the Postgres Enterprise Manager (PEM) client. When accessed using the PEM client, Index Advisor works with SQL Profiler, providing indexing recommendations on code captured in SQL traces. For more information about using SQL Profiler and Index Advisor with PEM, see [Using SQL profiler](/pem/latest/profiling_workloads/using_sql_profiler.mdx) and [Using Index Advisor](03_using_index_advisor.mdx).
1313

1414
Index Advisor attempts to make indexing recommendations on `INSERT`, `UPDATE`, `DELETE`, and `SELECT` statements. When invoking Index Advisor, you supply the workload in the form of either:
1515

product_docs/docs/pem/10/certificates/index.mdx

Lines changed: 31 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ PEM uses SSL certificates:
1818
- To secure requests to the [web server](#web-server-certificates), which provides the user interface and REST API.
1919
- To secure and authenticate the [PEM agent connections to the PEM backend database](#pem-backend-database-server-and-agent-connection-certificates).
2020

21-
## Web-server certificates
21+
## Web server certificates
2222

2323
PEM generates an SSL certificate and key file for the web server during initial configuration.
24-
Because the certificate is self-signed, users will see a warning that the site is insecure when they open the PEM web application URL in their browser.
24+
Because the certificate is self-signed, a warning states that the site is insecure when users open the PEM web application URL in a browser.
2525

2626
To increase security and remove this warning, you can replace the self-signed SSL certificate with a certificate signed by a trusted certificate authority.
2727

@@ -37,13 +37,13 @@ Change the server name and file paths in the configuration file to match your ce
3737
```text
3838
server {
3939
# lines omitted here
40-
server_name yourdomain.com;
40+
server_name <yourdomain.com>;
4141
# lines omitted here
4242
}
4343
4444
server {
4545
# lines omitted here
46-
server_name yourdomain.com;
46+
server_name <yourdomain.com>;
4747
4848
ssl_certificate /path/to/your_domain_name.crt
4949
ssl_certificate_key /path/to/your_private.key
@@ -70,12 +70,12 @@ For a worked example, see [Replacing httpd self-signed SSL certificates](https:/
7070
## PEM backend database server and agent connection certificates
7171

7272
PEM implements secured SSL/TLS connections between PEM agents and the backend database.
73-
Each agent has an SSL certificate which is used both to encrypt its communication with the server and to authenticate with the server in place of a password.
73+
Each agent has an SSL certificate that's used both to encrypt its communication with the server and to authenticate with the server in place of a password.
7474

75-
PEM uses the sslutils extension to allow the PEM server to generate and sign SSL certificates and keys. When a new agent is registered, the PEM server automatically issues it with a certificate.
75+
PEM uses the sslutils extension to allow the PEM server to generate and sign SSL certificates and keys. When a new agent is registered, the PEM server issues it a certificate.
7676
Certificates issued by the PEM server are signed by the PEM server, meaning the PEM server is acting as a certificate authority (CA).
7777

78-
If the above is not suitable, you can use SSL certificates and keys generated outside of PEM and signed by a trusted CA.
78+
If this approach isn't suitable, you can use SSL certificates and keys generated outside of PEM and signed by a trusted CA.
7979
For more information, see [Trusted CA certificates and keys](#use-certificates-and-keys-signed-by-trusted-ca).
8080

8181
### Certificates and key files on the PEM server
@@ -90,7 +90,7 @@ During initial configuration of the PEM server, the following files are generate
9090
- `server.key`
9191

9292
The `ca_certificate.crt` and `ca_key.key` files are used by the PEM server to sign certificates generated for agents during agent registration.
93-
They are also used to sign `server.crt`. Unless replaced manually, the 'ca_certificate.crt' file is a self-signed certificate because is acting as the root CA.
93+
They're also used to sign `server.crt`. Unless replaced manually, the 'ca_certificate.crt' file is a self-signed certificate because it's acting as the root CA.
9494

9595
The `root.crt` file is a copy of the `ca_certificate.crt` file. The `ssl_ca_file` parameter in the `postgresql.conf` file points to this file.
9696

@@ -100,33 +100,33 @@ The `ssl_crl_file` parameter in the `postgresql.conf` file points to this file.
100100
The `server.crt` file is the signed certificate for the PEM server, and the `server.key` file is the private key to the certificate.
101101
The `ssl_cert_file` parameter in the `postgresql.conf` file points to this file.
102102

103-
These files are automatically renewed when they near their expiry date, see [PEM CA certificate renewal](#pem-certificate-renewal).
103+
These files are automatically renewed when they near their expiry date. See [PEM CA certificate renewal](#pem-certificate-renewal).
104104

105105
### Certificates and key files for PEM agents
106106

107107
Each agent's SSL certificate and keys are generated during [agent registration](../registering_agent).
108108
The PEM agent connects to the PEM backend database server using the libpq interface, acting as a client of the backend database server.
109-
The PEM agent connect to the server using the `cert` auth method and with ssl enabled.
110-
This means that the connection is encrypted using the agent's key and authenticated using the agent's certificate (rather than a password, for example).
109+
The PEM agent connects to the server using the `cert` auth method and with ssl enabled.
110+
This means that the connection is encrypted using the agent's key and authenticated using the agent's certificate instead of, for example, a password.
111111

112112
Each agent has a unique identifier, and the agent certificates and keys have the corresponding identifier.
113113

114-
If required, you can use the same certificate for all agents rather than one certificate per agent. For more information, see [Generate common agent certificate and key pair](#generate-a-common-agent-certificate-and-key-pair).
114+
If required, you can use the same certificate for all agents rather than one certificate per agent. For more information, see [Generate a common agent certificate and key pair](#generate-a-common-agent-certificate-and-key-pair).
115115

116-
For more information on using the SSL certificates to connect in Postgres, see [Securing TCP/IP connections with SSL](https://www.postgresql.org/docs/current/ssl-tcp.html).
116+
For more information on using the SSL certificates to connect in Postgres, see [Securing TCP/IP connections with SSL](https://www.postgresql.org/docs/current/ssl-tcp.html) in the Postgres documentation.
117117

118118
### PEM certificate renewal
119119

120-
SSL certificates have an expiry date. If you are using certificates and keys generated by PEM, they are automatically replaced before expiring.
120+
SSL certificates have an expiry date. If you're using certificates and keys generated by PEM, PEM replaces them before they expire.
121121
The PEM agent installed with the PEM server monitors the expiration date of the `ca_certificate.crt` file. When the certificate is about to expire, PEM:
122122

123-
- Makes a backup of the existing certificate files
124-
- Creates new certificate files and appends the new CA certificate file to the `root.crt` file on the PEM server
125-
- Creates a job to renew the certificate file for any active agents
126-
- Restarts the PEM server
123+
- Makes a backup of the existing certificate files.
124+
- Creates new certificate files and appends the new CA certificate file to the `root.crt` file on the PEM server.
125+
- Creates a job to renew the certificate file for any active agents.
126+
- Restarts the PEM server.
127127

128128
!!! Important
129-
If you choose to either provide your own certificates, or use a single certificate for all agents, you should disable the automatic renewal job.
129+
If you choose to provide your own certificates or use a single certificate for all agents, disable the automatic renewal job.
130130
On the PEM server, execute the following SQL:
131131

132132
```sql
@@ -136,7 +136,7 @@ WHERE jobname = 'Check CA certificate expiry';
136136
```
137137
!!!
138138

139-
If you need to regenerate the server or agent certificates manually, please see:
139+
If you need to regenerate the server or agent certificates manually, see:
140140
- [Regenerating the server SSL certificates](replacing_ssl_certificates)
141141
- [Regenerating agent SSL certificates](regenerating_agent_certificates)
142142

@@ -146,7 +146,7 @@ By creating and using a single Postgres user for all PEM agents rather than one
146146

147147
Create a user, generate an agent certificate and key pair, and use them for all PEM agents.
148148

149-
1. Create one common agent user in the PEM backend database. Grant the `pem_agent` role to the user.
149+
1. Create one common agent user in the PEM backend database. Grant the pem_agent role to the user.
150150

151151
```shell
152152
# Running as enterprisedb
@@ -176,7 +176,7 @@ Create a user, generate an agent certificate and key pair, and use them for all
176176
openssl x509 -req -days 365 -in agent.csr -CA ca_certificate.crt -CAkey ca_key.key -CAcreateserial -out agent.crt
177177
```
178178

179-
1. Change the permissions on the `agent.crt` and `agent.key` file:
179+
1. Change the permissions on the `agent.crt` and `agent.key` files:
180180

181181
```shell
182182
chmod 600 agent.crt agent.key
@@ -209,7 +209,7 @@ Create a user, generate an agent certificate and key pair, and use them for all
209209

210210
- To replace the agent certificate and key pair with the registered agent.
211211

212-
a. Edit the `agent_user`, `agent_ssl_key`, and `agent_ssl_crt` parameters in `agent.cfg` file of the agent host:
212+
a. Edit the `agent_user`, `agent_ssl_key`, and `agent_ssl_crt` parameters in the `agent.cfg` file of the agent host:
213213

214214
```shell
215215
vi /usr/edb/pem/agent/etc/agent.cfg
@@ -262,7 +262,7 @@ After obtaining the trusted CA certificates and keys, replace the [server](#repl
262262

263263
1. Ask your CA to sign the CSR and generate the server certificate for you.
264264

265-
1. Verify the details of the new server certificate aren't tampered with and match your provided details:
265+
1. Verify that the details of the new server certificate aren't tampered with and match your provided details:
266266

267267
```shell
268268
openssl x509 -noout -text -in server.crt
@@ -277,16 +277,16 @@ After obtaining the trusted CA certificates and keys, replace the [server](#repl
277277
1. If the trusted CA doesn't provide CRL, disable CRL usage by the server. To disable the CRL usage, comment the `ssl_crl_file` parameter in the `postgresql.conf` file.
278278

279279
!!! Note
280-
If you accidentally leave a CRL from a previous CA in place and do not comment out `ssl_crl_file`, the server will start but authentication will fail with an SSL error message `tlsv1 alert unknown ca`.
281-
The error doesn't specify that the CRL is the cause, so this can be difficult to debug if encountered out of context.
280+
If you leave a CRL from a previous CA in place and don't comment out `ssl_crl_file`, the server will start. However, authentication will fail with an SSL error message: `tlsv1 alert unknown ca`.
281+
The error doesn't specify that the CRL is the cause, so this issue can be difficult to debug if encountered out of context.
282282

283283
1. Copy the new `root.crt`, `server.key`, and `server.crt` files to the data directory of the backend database server:
284284

285285
```shell
286286
cp root.crt server.key server.crt /var/lib/edb/as<x>/data
287287
```
288288

289-
1. Change the owner and permissions of the new certificates and key files to be the same as the data directory:
289+
1. Change the owner and permissions of the new certificates and key files to the same name as the data directory:
290290

291291
```shell
292292
cd /var/lib/edb/as<x>/data/
@@ -369,7 +369,7 @@ Replace the agent SSL certificates only after replacing the server certificates
369369
Use the Services applet to restart the PEM agent. The PEM agent service is named Postgres Enterprise Manager Agent. Select the service name in the Services dialog box, and select **Restart the service**.
370370

371371
!!! Note
372-
For agents registered after following the process above you can provide a certificate to the agent at the time of registration as shown in the [second example](/pem/latest/registering_agent/#overriding-default-configurations---examples).
372+
For agents registered after following the preceding process, you can provide a certificate to the agent at the time of registration as shown in the [second example](/pem/latest/registering_agent/#overriding-default-configurations---examples).
373373
!!!
374374

375375
!!!note
@@ -393,7 +393,7 @@ This command returns `agent1.crt: OK` on success or an explanatory message on fa
393393

394394
### Make a test connection to the PEM backend database
395395

396-
To verify whether the agent user can connect using a certificate, on the server where the agent is located, execute the following commands as root:
396+
To verify whether the agent user can connect using a certificate, as root on the server where the agent is located, execute:
397397

398398
```shell
399399
PGHOST=<pem_host>
@@ -407,14 +407,15 @@ export PGHOST PGPORT PGUSER PGSSLCERT PGSSLKEY PGSSLMODE
407407

408408
<psql_path> -A -t -c "SELECT version()"
409409
```
410+
410411
Where:
411412
- `<psql_path>` is the full path to the psql executable, for example `/usr/edb/as15/bin/psql`.
412413
- `<pem_host>` is the hostname or IP address of PEM server.
413414
- `<pem_db_port>` is the PEM backend database server port.
414415
- `<ID>` is the ID of the agent you're testing, as defined in the file `/usr/edb/pem/agent/etc/agent.cfg`.
415416

416417
!!! Note
417-
If you used the instructions in [Generate a common agent certificate and key pair](#generate-a-common-agent-certificate-and-key-pair)
418+
If you used the instructions in [Generate a common agent certificate and key pair](#generate-a-common-agent-certificate-and-key-pair),
418419
you must set `PGUSER` to the common agent username.
419420
!!!
420421

0 commit comments

Comments
 (0)