From 73c15106578b93139252097e2dd531f3f78da477 Mon Sep 17 00:00:00 2001 From: Joel Marcotte Date: Tue, 12 Dec 2023 11:57:14 -0500 Subject: [PATCH 1/6] [DBM] - Add documentation about monitoring log shipping in sqlserver --- .../database_monitoring/setup_sql_server/rds.md | 13 +++++++++---- .../setup_sql_server/selfhosted.md | 15 +++++++++++++-- 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/content/en/database_monitoring/setup_sql_server/rds.md b/content/en/database_monitoring/setup_sql_server/rds.md index f5dc48a8c434c..a958dc31d4971 100644 --- a/content/en/database_monitoring/setup_sql_server/rds.md +++ b/content/en/database_monitoring/setup_sql_server/rds.md @@ -21,10 +21,13 @@ Database Monitoring provides deep visibility into your Microsoft SQL Server data Do the following steps to enable Database Monitoring with your database: -1. [Configure the AWS integration](#configure-the-aws-integration) -1. [Grant the Agent access to the database](#grant-the-agent-access) -1. [Install the Agent](#install-the-agent) -1. [Install the RDS integration](#install-the-rds-integration) +- [Before you begin](#before-you-begin) +- [Configure the AWS integration](#configure-the-aws-integration) +- [Grant the Agent access](#grant-the-agent-access) +- [Install the Agent](#install-the-agent) +- [Example Agent Configurations](#example-agent-configurations) +- [Install the RDS integration](#install-the-rds-integration) +- [Further reading](#further-reading) ## Before you begin @@ -50,6 +53,8 @@ GO --Set context to msdb database and create datadog user USE [msdb]; CREATE USER datadog FOR LOGIN datadog; +-- If you intend on using log shipping monitoring (availably in agent v7.50), proceed with the following: +-- GRANT SELECT to datadog; GO --Switch back to master and grant datadog user server permissions USE [master]; diff --git a/content/en/database_monitoring/setup_sql_server/selfhosted.md b/content/en/database_monitoring/setup_sql_server/selfhosted.md index 0e250400059dd..f41250d46e31b 100644 --- a/content/en/database_monitoring/setup_sql_server/selfhosted.md +++ b/content/en/database_monitoring/setup_sql_server/selfhosted.md @@ -26,8 +26,11 @@ Database Monitoring provides deep visibility into your Microsoft SQL Server data Do the following steps to enable Database Monitoring with your database: -1. [Grant the Agent access to the database](#grant-the-agent-access) -2. [Install the Agent](#install-the-agent) +- [Before you begin](#before-you-begin) +- [Grant the Agent access](#grant-the-agent-access) +- [Install the Agent](#install-the-agent) +- [Example Agent Configurations](#example-agent-configurations) +- [Further reading](#further-reading) ## Before you begin @@ -51,6 +54,10 @@ CREATE USER datadog FOR LOGIN datadog; GRANT CONNECT ANY DATABASE to datadog; GRANT VIEW SERVER STATE to datadog; GRANT VIEW ANY DEFINITION to datadog; +-- If you intend on using monitoring log shipping (availably in agent v7.50+), proceed with the following: +-- USE msdb; +-- CREATE USER datadog FOR LOGIN datadog; +-- GRANT SELECT to datadog; ``` {{% /tab %}} {{% tab "SQL Server 2012" %}} @@ -60,6 +67,10 @@ CREATE LOGIN datadog WITH PASSWORD = ''; CREATE USER datadog FOR LOGIN datadog; GRANT VIEW SERVER STATE to datadog; GRANT VIEW ANY DEFINITION to datadog; +-- If you intend on using monitoring log shipping (availably in agent v7.50+), proceed with the following: +-- USE msdb; +-- CREATE USER datadog FOR LOGIN datadog; +-- GRANT SELECT to datadog; ``` Create the `datadog` user in each additional application database: From 1a8ad19738ac48567334f89e690097f821f0b6d7 Mon Sep 17 00:00:00 2001 From: Joel Marcotte Date: Tue, 12 Dec 2023 12:00:39 -0500 Subject: [PATCH 2/6] azure --- .../en/database_monitoring/setup_sql_server/azure.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/content/en/database_monitoring/setup_sql_server/azure.md b/content/en/database_monitoring/setup_sql_server/azure.md index 8ada9a98b6cbe..4dcaa24991dcd 100644 --- a/content/en/database_monitoring/setup_sql_server/azure.md +++ b/content/en/database_monitoring/setup_sql_server/azure.md @@ -46,6 +46,10 @@ CREATE LOGIN datadog WITH PASSWORD = ''; CREATE USER datadog FOR LOGIN datadog; ALTER SERVER ROLE ##MS_ServerStateReader## ADD MEMBER datadog; ALTER SERVER ROLE ##MS_DefinitionReader## ADD MEMBER datadog; +-- If you intend on using monitoring log shipping (availably in agent v7.50+), proceed with the following: +-- USE msdb; +-- CREATE USER datadog FOR LOGIN datadog; +-- GRANT SELECT to datadog; ``` Grant the Agent access to each additional Azure SQL Database on this server: @@ -101,6 +105,10 @@ CREATE USER datadog FOR LOGIN datadog; GRANT CONNECT ANY DATABASE to datadog; GRANT VIEW SERVER STATE to datadog; GRANT VIEW ANY DEFINITION to datadog; +-- If you intend on using monitoring log shipping (availably in agent v7.50+), proceed with the following: +-- USE msdb; +-- CREATE USER datadog FOR LOGIN datadog; +-- GRANT SELECT to datadog; ``` #### For SQL Server 2012 @@ -110,6 +118,10 @@ CREATE LOGIN datadog WITH PASSWORD = ''; CREATE USER datadog FOR LOGIN datadog; GRANT VIEW SERVER STATE to datadog; GRANT VIEW ANY DEFINITION to datadog; +-- If you intend on using monitoring log shipping (availably in agent v7.50+), proceed with the following: +-- USE msdb; +-- CREATE USER datadog FOR LOGIN datadog; +-- GRANT SELECT to datadog; -- Create the `datadog` user in each additional application database: USE [database_name]; From 66a65c0ae593c97532ba15f413852271bcc44f45 Mon Sep 17 00:00:00 2001 From: Joel Marcotte <91903666+joelmarcotte@users.noreply.github.com> Date: Tue, 12 Dec 2023 17:00:33 -0500 Subject: [PATCH 3/6] Update content/en/database_monitoring/setup_sql_server/selfhosted.md Co-authored-by: cecilia saixue watt --- .../en/database_monitoring/setup_sql_server/selfhosted.md | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/content/en/database_monitoring/setup_sql_server/selfhosted.md b/content/en/database_monitoring/setup_sql_server/selfhosted.md index f41250d46e31b..8916742227837 100644 --- a/content/en/database_monitoring/setup_sql_server/selfhosted.md +++ b/content/en/database_monitoring/setup_sql_server/selfhosted.md @@ -26,11 +26,8 @@ Database Monitoring provides deep visibility into your Microsoft SQL Server data Do the following steps to enable Database Monitoring with your database: -- [Before you begin](#before-you-begin) -- [Grant the Agent access](#grant-the-agent-access) -- [Install the Agent](#install-the-agent) -- [Example Agent Configurations](#example-agent-configurations) -- [Further reading](#further-reading) +1. [Grant the Agent access](#grant-the-agent-access) +1. [Install the Agent](#install-the-agent) ## Before you begin From eede7f803d88dcfef76830dfe9c909c7a73bb547 Mon Sep 17 00:00:00 2001 From: Joel Marcotte <91903666+joelmarcotte@users.noreply.github.com> Date: Tue, 12 Dec 2023 17:00:38 -0500 Subject: [PATCH 4/6] Update content/en/database_monitoring/setup_sql_server/azure.md Co-authored-by: cecilia saixue watt --- content/en/database_monitoring/setup_sql_server/azure.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/en/database_monitoring/setup_sql_server/azure.md b/content/en/database_monitoring/setup_sql_server/azure.md index 4dcaa24991dcd..7d79906ba07c7 100644 --- a/content/en/database_monitoring/setup_sql_server/azure.md +++ b/content/en/database_monitoring/setup_sql_server/azure.md @@ -46,7 +46,7 @@ CREATE LOGIN datadog WITH PASSWORD = ''; CREATE USER datadog FOR LOGIN datadog; ALTER SERVER ROLE ##MS_ServerStateReader## ADD MEMBER datadog; ALTER SERVER ROLE ##MS_DefinitionReader## ADD MEMBER datadog; --- If you intend on using monitoring log shipping (availably in agent v7.50+), proceed with the following: +-- To use Log Shipping Monitoring (available in Agent v7.50+), uncomment the next three lines: -- USE msdb; -- CREATE USER datadog FOR LOGIN datadog; -- GRANT SELECT to datadog; From 64812a402b7f017e97a962de47015effef2d49c4 Mon Sep 17 00:00:00 2001 From: Joel Marcotte <91903666+joelmarcotte@users.noreply.github.com> Date: Tue, 12 Dec 2023 17:00:57 -0500 Subject: [PATCH 5/6] Apply suggestions from code review Co-authored-by: cecilia saixue watt --- .../database_monitoring/setup_sql_server/azure.md | 4 ++-- .../en/database_monitoring/setup_sql_server/rds.md | 13 +++++-------- .../setup_sql_server/selfhosted.md | 4 ++-- 3 files changed, 9 insertions(+), 12 deletions(-) diff --git a/content/en/database_monitoring/setup_sql_server/azure.md b/content/en/database_monitoring/setup_sql_server/azure.md index 7d79906ba07c7..1ab6586b15ca8 100644 --- a/content/en/database_monitoring/setup_sql_server/azure.md +++ b/content/en/database_monitoring/setup_sql_server/azure.md @@ -105,7 +105,7 @@ CREATE USER datadog FOR LOGIN datadog; GRANT CONNECT ANY DATABASE to datadog; GRANT VIEW SERVER STATE to datadog; GRANT VIEW ANY DEFINITION to datadog; --- If you intend on using monitoring log shipping (availably in agent v7.50+), proceed with the following: +-- To use Log Shipping Monitoring (available in Agent v7.50+), uncomment the next three lines: -- USE msdb; -- CREATE USER datadog FOR LOGIN datadog; -- GRANT SELECT to datadog; @@ -118,7 +118,7 @@ CREATE LOGIN datadog WITH PASSWORD = ''; CREATE USER datadog FOR LOGIN datadog; GRANT VIEW SERVER STATE to datadog; GRANT VIEW ANY DEFINITION to datadog; --- If you intend on using monitoring log shipping (availably in agent v7.50+), proceed with the following: +-- To use Log Shipping Monitoring (available in Agent v7.50+), uncomment the next three lines: -- USE msdb; -- CREATE USER datadog FOR LOGIN datadog; -- GRANT SELECT to datadog; diff --git a/content/en/database_monitoring/setup_sql_server/rds.md b/content/en/database_monitoring/setup_sql_server/rds.md index a958dc31d4971..82ca59dc17b11 100644 --- a/content/en/database_monitoring/setup_sql_server/rds.md +++ b/content/en/database_monitoring/setup_sql_server/rds.md @@ -21,13 +21,10 @@ Database Monitoring provides deep visibility into your Microsoft SQL Server data Do the following steps to enable Database Monitoring with your database: -- [Before you begin](#before-you-begin) -- [Configure the AWS integration](#configure-the-aws-integration) -- [Grant the Agent access](#grant-the-agent-access) -- [Install the Agent](#install-the-agent) -- [Example Agent Configurations](#example-agent-configurations) -- [Install the RDS integration](#install-the-rds-integration) -- [Further reading](#further-reading) +1. [Configure the AWS integration](#configure-the-aws-integration) +1. [Grant the Agent access](#grant-the-agent-access) +1. [Install the Agent](#install-the-agent) +1. [Install the RDS integration](#install-the-rds-integration) ## Before you begin @@ -53,7 +50,7 @@ GO --Set context to msdb database and create datadog user USE [msdb]; CREATE USER datadog FOR LOGIN datadog; --- If you intend on using log shipping monitoring (availably in agent v7.50), proceed with the following: +-- To use Log Shipping Monitoring (available in Agent v7.50+), uncomment the next line: -- GRANT SELECT to datadog; GO --Switch back to master and grant datadog user server permissions diff --git a/content/en/database_monitoring/setup_sql_server/selfhosted.md b/content/en/database_monitoring/setup_sql_server/selfhosted.md index 8916742227837..7d5a36e46a7dd 100644 --- a/content/en/database_monitoring/setup_sql_server/selfhosted.md +++ b/content/en/database_monitoring/setup_sql_server/selfhosted.md @@ -51,7 +51,7 @@ CREATE USER datadog FOR LOGIN datadog; GRANT CONNECT ANY DATABASE to datadog; GRANT VIEW SERVER STATE to datadog; GRANT VIEW ANY DEFINITION to datadog; --- If you intend on using monitoring log shipping (availably in agent v7.50+), proceed with the following: +-- To use Log Shipping Monitoring (available in Agent v7.50+), uncomment the next three lines: -- USE msdb; -- CREATE USER datadog FOR LOGIN datadog; -- GRANT SELECT to datadog; @@ -64,7 +64,7 @@ CREATE LOGIN datadog WITH PASSWORD = ''; CREATE USER datadog FOR LOGIN datadog; GRANT VIEW SERVER STATE to datadog; GRANT VIEW ANY DEFINITION to datadog; --- If you intend on using monitoring log shipping (availably in agent v7.50+), proceed with the following: +-- To use Log Shipping Monitoring (available in Agent v7.50+), uncomment the next three lines: -- USE msdb; -- CREATE USER datadog FOR LOGIN datadog; -- GRANT SELECT to datadog; From 7d93798ce61569040f9cfd00efbabc2ec2954ab2 Mon Sep 17 00:00:00 2001 From: cecilia saixue watt Date: Thu, 4 Jan 2024 08:25:08 -0800 Subject: [PATCH 6/6] empty push