Skip to content

Commit f06282a

Browse files
authored
Merge pull request #8423 from ovh/update-database-16-folder
feat(database): update folder about logs data platform
2 parents 639bf93 + 6bfec67 commit f06282a

26 files changed

+1410
-540
lines changed

pages/public_cloud/public_cloud_databases/databases_16_logs_to_customer/guide.de-de.md

Lines changed: 94 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: Public Cloud Databases - How to setup logs forwarding
2+
title: Public Cloud Databases - How to set up logs forwarding
33
excerpt: Find out how to forward logs of your database service to your Logs Data Platform data stream
4-
updated: 2024-09-25
4+
updated: 2024-10-28
55
---
66

77
## Objective
@@ -21,42 +21,91 @@ Public Cloud managed databases allow you to send logs of your service to your ow
2121

2222
## Instructions
2323

24-
### Step 1 - Retrieve the required information
24+
### Create your subscription
25+
26+
> [!tabs]
27+
> Via the OVHcloud Control Panel
28+
>> On the database instance page, go to the `Logs`{.action} section and click the `Subscribe`{.action} button.
29+
>>
30+
>> ![LDP database subscription](images/ldp_database_subscription.png){.thumbnail}
31+
>>
32+
>> Select the relevant LDP account by clicking the `Subscribe`{.action} button.
33+
>>
34+
>> ![LDP database subscription 2](images/ldp_database_subscription2.png){.thumbnail}
35+
>>
36+
>> The logs will then start to be forwarded to your LDP stream.
37+
>>
38+
> Via the OVHcloud API
39+
>>
40+
>> 1\. Retrieve the required information
41+
>>
42+
>> **Retrieve your LDP destination `streamId`:**
43+
>>
44+
>> Log in to the [OVHcloud Control Panel](/links/manager), go to the `Identity, Security & Operations`{.action} section. In the left-hand menu, select `Logs Data Platform`{.action} then click on the relevant LDP instance.
45+
>>
46+
>> ![LDP list page](images/ldp_page.png){.thumbnail}
47+
>>
48+
>> Go to the `Data stream`{.action} tab.
49+
>>
50+
>> ![LDP details page](images/ldp_page_details.png){.thumbnail}
51+
>>
52+
>> Choose your target stream and click on `Copy stream ID`{.action}.
53+
>>
54+
>> **Retrieve your LDP destination `serviceName`:**
55+
>>
56+
>> - This refers to your Public Cloud project ID. You can retrieve it in the Public Cloud section of your project.
57+
>>
58+
>> ![LDP project id](images/ldp_project_id.png){.thumbnail}
59+
>>
60+
>> **Retrieve your `clusterId`:**
61+
>>
62+
>> Log in to the [OVHcloud Control Panel](/links/manager), open the `Public Cloud`{.action} section and select the Public Cloud project concerned. In the left-hand menu, click on `Databases`{.action}, then choose the database instance you want to manage.
63+
>>
64+
>> In the cluster details, you can find the `Service ID` field, which corresponds to the cluster ID.
65+
>>
66+
>> ![LDP database details](images/ldp_database_details.png){.thumbnail}
67+
>>
68+
>> 2\. Start by retrieving the types of logs available for your database cluster with the following API call:
69+
>>
70+
>> > [!api]
71+
>> >
72+
>> > @api {v1} /cloud GET /cloud/project/{serviceName}/database/{engine}/{clusterId}/log/kind
73+
>> >
74+
>>
75+
>> This will return the list of valid kind values you can use when subscribing to logs.
76+
>>
77+
>> 3\. Once you know the valid kind, use it to subscribe to a log stream with this API call:
78+
>>
79+
>> > [!api]
80+
>> >
81+
>> > @api {v1} /cloud POST /cloud/project/{serviceName}/database/{engine}/{clusterId}/log/subscription
82+
>> >
83+
>>
84+
>> ```console
85+
>> body : {
86+
>> kind: <log_type_from_previous_call>
87+
>> streamId: <your_stream_id>
88+
>> }
89+
>> ```
90+
>>
91+
>> The logs will then start to be forwarded to your LDP stream.
92+
>>
2593
26-
#### Retrieve your LDP destination `streamId`:
27-
28-
- In the OVHcloud Control Panel, go to your LDP page.
29-
- Go to the `Data stream` tab.
30-
- Choose your target stream and click on `Copy stream ID`{.action}.
31-
32-
#### Retrieve your LDP destination `serviceName`:
33-
34-
- It refers to your Public Cloud project ID.
35-
36-
#### Retrieve your `clusterId`:
94+
### Find logs in Graylog
3795
38-
- In the OVHcloud Control Panel, go to your database.
39-
- You can see the field `Cluster ID`.
96+
On the LDP page, click the `sample-data-stream`{.action} button (the last data stream modified when you previously subscribed to it), or click the `Graylog`{.action} button.
4097
41-
### Step 2 - Create your subscription
98+
![LDP database go to graylog](images/ldp_database_go_to_graylogs.png){.thumbnail}
4299
43-
Use the following API call:
100+
You need to log in using your Graylog credentials. You can retrieve them from the LDP details page, in the `Configuration` section. The login corresponds to the value shown on the `Logs Data Platform service` line, and the password is displayed under `Password`.
44101
45-
> [!api]
46-
>
47-
> @api {v1} /cloud POST /cloud/project/{serviceName}/database/{engine}/{clusterId}/log/subscription
48-
>
102+
![LDP database ldp details](images/ldp_database_ldp_details.png){.thumbnail}
49103
50-
```console
51-
body : {
52-
streamId: <LDP destination stream ID>
53-
}
54-
```
55-
Then logs will start to be forwarded to your LDP stream.
104+
Once connected, you can view your service logs in your Graylog stream.
56105
57-
### Find logs in Graylog
106+
![LDP database graylogs result](images/ldp_database_graylogs_result.png){.thumbnail}
58107
59-
To find logs of your service in your graylogs stream you can use the following graylog queries:
108+
You can also use the following Graylog queries for more granular filtering:
60109
61110
#### MongoDB
62111
@@ -80,12 +129,21 @@ You can find this `HostID` in your OVHcloud Control Panel:
80129
81130
You have 2 methods to delete a subscription:
82131
83-
- You can delete subscriptions using the `subscriptionId` concerned in this API call:
84-
85-
> [!api]
86-
>
87-
> @api {v1} /cloud DELETE /cloud/project/{serviceName}/database/mongodb/{clusterId}/log/subscription/{subscriptionId}
88-
>
132+
> [!tabs]
133+
> Via the OVHcloud Control Panel
134+
>> In the subscription page of the database instance, click the `Unsubscribe`{.action} button.
135+
>>
136+
>> ![LDP database unsubscribe](images/ldp_database_unsubscribe.png){.thumbnail}
137+
>>
138+
> Via the OVHcloud API
139+
>>
140+
>> - You can delete subscriptions using the `subscriptionId` concerned in this API call:
141+
>>
142+
>> > [!api]
143+
>> >
144+
>> > @api {v1} /cloud DELETE /cloud/project/{serviceName}/database/{engine}/{clusterId}/log/subscription/{subscriptionId}
145+
>> >
146+
>>
89147
90148
- If you delete your database service, all subscriptions of this service are deleted automatically.
91149

pages/public_cloud/public_cloud_databases/databases_16_logs_to_customer/guide.en-asia.md

Lines changed: 94 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: Public Cloud Databases - How to setup logs forwarding
2+
title: Public Cloud Databases - How to set up logs forwarding
33
excerpt: Find out how to forward logs of your database service to your Logs Data Platform data stream
4-
updated: 2024-09-25
4+
updated: 2024-10-28
55
---
66

77
## Objective
@@ -21,42 +21,91 @@ Public Cloud managed databases allow you to send logs of your service to your ow
2121

2222
## Instructions
2323

24-
### Step 1 - Retrieve the required information
24+
### Create your subscription
25+
26+
> [!tabs]
27+
> Via the OVHcloud Control Panel
28+
>> On the database instance page, go to the `Logs`{.action} section and click the `Subscribe`{.action} button.
29+
>>
30+
>> ![LDP database subscription](images/ldp_database_subscription.png){.thumbnail}
31+
>>
32+
>> Select the relevant LDP account by clicking the `Subscribe`{.action} button.
33+
>>
34+
>> ![LDP database subscription 2](images/ldp_database_subscription2.png){.thumbnail}
35+
>>
36+
>> The logs will then start to be forwarded to your LDP stream.
37+
>>
38+
> Via the OVHcloud API
39+
>>
40+
>> 1\. Retrieve the required information
41+
>>
42+
>> **Retrieve your LDP destination `streamId`:**
43+
>>
44+
>> Log in to the [OVHcloud Control Panel](/links/manager), go to the `Identity, Security & Operations`{.action} section. In the left-hand menu, select `Logs Data Platform`{.action} then click on the relevant LDP instance.
45+
>>
46+
>> ![LDP list page](images/ldp_page.png){.thumbnail}
47+
>>
48+
>> Go to the `Data stream`{.action} tab.
49+
>>
50+
>> ![LDP details page](images/ldp_page_details.png){.thumbnail}
51+
>>
52+
>> Choose your target stream and click on `Copy stream ID`{.action}.
53+
>>
54+
>> **Retrieve your LDP destination `serviceName`:**
55+
>>
56+
>> - This refers to your Public Cloud project ID. You can retrieve it in the Public Cloud section of your project.
57+
>>
58+
>> ![LDP project id](images/ldp_project_id.png){.thumbnail}
59+
>>
60+
>> **Retrieve your `clusterId`:**
61+
>>
62+
>> Log in to the [OVHcloud Control Panel](/links/manager), open the `Public Cloud`{.action} section and select the Public Cloud project concerned. In the left-hand menu, click on `Databases`{.action}, then choose the database instance you want to manage.
63+
>>
64+
>> In the cluster details, you can find the `Service ID` field, which corresponds to the cluster ID.
65+
>>
66+
>> ![LDP database details](images/ldp_database_details.png){.thumbnail}
67+
>>
68+
>> 2\. Start by retrieving the types of logs available for your database cluster with the following API call:
69+
>>
70+
>> > [!api]
71+
>> >
72+
>> > @api {v1} /cloud GET /cloud/project/{serviceName}/database/{engine}/{clusterId}/log/kind
73+
>> >
74+
>>
75+
>> This will return the list of valid kind values you can use when subscribing to logs.
76+
>>
77+
>> 3\. Once you know the valid kind, use it to subscribe to a log stream with this API call:
78+
>>
79+
>> > [!api]
80+
>> >
81+
>> > @api {v1} /cloud POST /cloud/project/{serviceName}/database/{engine}/{clusterId}/log/subscription
82+
>> >
83+
>>
84+
>> ```console
85+
>> body : {
86+
>> kind: <log_type_from_previous_call>
87+
>> streamId: <your_stream_id>
88+
>> }
89+
>> ```
90+
>>
91+
>> The logs will then start to be forwarded to your LDP stream.
92+
>>
2593
26-
#### Retrieve your LDP destination `streamId`:
27-
28-
- In the OVHcloud Control Panel, go to your LDP page.
29-
- Go to the `Data stream` tab.
30-
- Choose your target stream and click on `Copy stream ID`{.action}.
31-
32-
#### Retrieve your LDP destination `serviceName`:
33-
34-
- It refers to your Public Cloud project ID.
35-
36-
#### Retrieve your `clusterId`:
94+
### Find logs in Graylog
3795
38-
- In the OVHcloud Control Panel, go to your database.
39-
- You can see the field `Cluster ID`.
96+
On the LDP page, click the `sample-data-stream`{.action} button (the last data stream modified when you previously subscribed to it), or click the `Graylog`{.action} button.
4097
41-
### Step 2 - Create your subscription
98+
![LDP database go to graylog](images/ldp_database_go_to_graylogs.png){.thumbnail}
4299
43-
Use the following API call:
100+
You need to log in using your Graylog credentials. You can retrieve them from the LDP details page, in the `Configuration` section. The login corresponds to the value shown on the `Logs Data Platform service` line, and the password is displayed under `Password`.
44101
45-
> [!api]
46-
>
47-
> @api {v1} /cloud POST /cloud/project/{serviceName}/database/{engine}/{clusterId}/log/subscription
48-
>
102+
![LDP database ldp details](images/ldp_database_ldp_details.png){.thumbnail}
49103
50-
```console
51-
body : {
52-
streamId: <LDP destination stream ID>
53-
}
54-
```
55-
Then logs will start to be forwarded to your LDP stream.
104+
Once connected, you can view your service logs in your Graylog stream.
56105
57-
### Find logs in Graylog
106+
![LDP database graylogs result](images/ldp_database_graylogs_result.png){.thumbnail}
58107
59-
To find logs of your service in your graylogs stream you can use the following graylog queries:
108+
You can also use the following Graylog queries for more granular filtering:
60109
61110
#### MongoDB
62111
@@ -80,12 +129,21 @@ You can find this `HostID` in your OVHcloud Control Panel:
80129
81130
You have 2 methods to delete a subscription:
82131
83-
- You can delete subscriptions using the `subscriptionId` concerned in this API call:
84-
85-
> [!api]
86-
>
87-
> @api {v1} /cloud DELETE /cloud/project/{serviceName}/database/mongodb/{clusterId}/log/subscription/{subscriptionId}
88-
>
132+
> [!tabs]
133+
> Via the OVHcloud Control Panel
134+
>> In the subscription page of the database instance, click the `Unsubscribe`{.action} button.
135+
>>
136+
>> ![LDP database unsubscribe](images/ldp_database_unsubscribe.png){.thumbnail}
137+
>>
138+
> Via the OVHcloud API
139+
>>
140+
>> - You can delete subscriptions using the `subscriptionId` concerned in this API call:
141+
>>
142+
>> > [!api]
143+
>> >
144+
>> > @api {v1} /cloud DELETE /cloud/project/{serviceName}/database/{engine}/{clusterId}/log/subscription/{subscriptionId}
145+
>> >
146+
>>
89147
90148
- If you delete your database service, all subscriptions of this service are deleted automatically.
91149

0 commit comments

Comments
 (0)