Server DevOps Audit Settings - Get

Sunucunun DevOps denetim ayarlarını alır.

GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/devOpsAuditingSettings/Default?api-version=2025-01-01

URI Parametreleri

Name İçinde Gerekli Tür Description
devOpsAuditingSettingsName
path True

DevOpsAuditingSettingsName

resourceGroupName
path True

string

minLength: 1
maxLength: 90

Kaynak grubunun adı. İsim büyük/küçük harfe duyarsızdır.

serverName
path True

string

Sunucunun adı.

subscriptionId
path True

string (uuid)

Hedef aboneliğin kimliği. Değer bir UUID olmalıdır.

api-version
query True

string

minLength: 1

Bu işlem için kullanılacak API sürümü.

Yanıtlar

Name Tür Description
200 OK

ServerDevOpsAuditingSettings

Azure işlemi başarıyla tamamlandı.

Other Status Codes

ErrorResponse

Beklenmeyen bir hata yanıtı.

Güvenlik

azure_auth

Azure Active Directory OAuth2 Akışı.

Tür: oauth2
Akış: implicit
Yetkilendirme URL’si: https://login.microsoftonline.com/common/oauth2/authorize

Kapsamlar

Name Description
user_impersonation kullanıcı hesabınızın kimliğine bürünme

Örnekler

Get a server's DevOps audit settings

Örnek isteği

GET https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/devAuditTestRG/providers/Microsoft.Sql/servers/devOpsAuditTestSvr/devOpsAuditingSettings/Default?api-version=2025-01-01

Örnek yanıt

{
  "name": "Default",
  "type": "Microsoft.Sql/servers/devOpsAuditingSettings",
  "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/devAuditTestRG/providers/Microsoft.Sql/servers/devOpsAuditTestSvr/devOpsAuditingSettings/default",
  "properties": {
    "isAzureMonitorTargetEnabled": false,
    "isManagedIdentityInUse": false,
    "state": "Disabled",
    "storageAccountSubscriptionId": "00000000-0000-0000-0000-000000000000",
    "storageEndpoint": "https://mystorage.blob.core.windows.net"
  }
}

Tanımlar

Name Description
BlobAuditingPolicyState

Denetimin durumunu belirtir. Durum Etkinse storageEndpoint veya IsAzureMonitorTargetEnabled gereklidir.

createdByType

Kaynağı oluşturan kimliğin türü.

DevOpsAuditingSettingsName
ErrorAdditionalInfo

Kaynak yönetimi hatası ek bilgileri.

ErrorDetail

Hata ayrıntısı.

ErrorResponse

Hata yanıtı

ServerDevOpsAuditingSettings

Sunucu DevOps denetim ayarları.

systemData

Kaynağın oluşturulması ve son değiştirilmesiyle ilgili meta veriler.

BlobAuditingPolicyState

Denetimin durumunu belirtir. Durum Etkinse storageEndpoint veya IsAzureMonitorTargetEnabled gereklidir.

Değer Description
Enabled

Enabled

Disabled

Disabled

createdByType

Kaynağı oluşturan kimliğin türü.

Değer Description
User
Application
ManagedIdentity
Key

DevOpsAuditingSettingsName

Değer Description
Default

Varsayılan

ErrorAdditionalInfo

Kaynak yönetimi hatası ek bilgileri.

Name Tür Description
info

object

Ek bilgiler.

type

string

Ek bilgi türü.

ErrorDetail

Hata ayrıntısı.

Name Tür Description
additionalInfo

ErrorAdditionalInfo[]

Hata ek bilgileri.

code

string

Hata kodu.

details

ErrorDetail[]

Hata ayrıntıları.

message

string

Hata iletisi.

target

string

Hata hedefi

ErrorResponse

Hata yanıtı

Name Tür Description
error

ErrorDetail

Hata nesnesi.

ServerDevOpsAuditingSettings

Sunucu DevOps denetim ayarları.

Name Tür Description
id

string (arm-id)

Kaynağın tam kaynak kimliği. Örneğin "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"

name

string

Kaynağın adı

properties.isAzureMonitorTargetEnabled

boolean

DevOps denetim olaylarının Azure İzleyici'a gönderilip gönderilmediğini belirtir. Olayları Azure İzleyici'a göndermek için 'State' olarak 'Enabled' ve 'IsAzureMonitorTargetEnabled' olarak true olarak belirtin.

DevOps denetimini yapılandırmak için REST API kullanılırken, ana veritabanında 'DevOpsOperationsAudit' tanılama günlükleri kategorisine sahip Tanılama Ayarları da oluşturulmalıdır.

Tanı Ayarları URI formatı: PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Sql/servers/{serverName}/databases/master/providers/microsoft.insights/diagnosticSettings/{settingsName}?api-version=2017-05-01-preview

Daha fazla bilgi için bkz. Tanılama Ayarları REST API veya Tanılama Ayarları PowerShell

properties.isManagedIdentityInUse

boolean

Yönetilen Kimliğin blob depolamaya erişmek için kullanılıp kullanılmayacağını belirtir

properties.state

BlobAuditingPolicyState

Denetimin durumunu belirtir. Durum Etkinse storageEndpoint veya IsAzureMonitorTargetEnabled gereklidir.

properties.storageAccountAccessKey

string (password)

Denetim depolama hesabının tanımlayıcı anahtarını belirtir. Durum Etkinse ve storageEndpoint belirtilirse, storageAccountAccessKey belirtilmemesi depolamaya erişmek için SQL server sistem tarafından atanan yönetilen kimliği kullanır. Yönetilen kimlik kimlik doğrulamasını kullanma önkoşulları:

  1. SQL Server'a sistem tarafından atanan yönetilen kimlik in Azure Active Directory (AAD) içinde assign edin.
  2. Sunucu kimliğine 'Storage Blob Data Contributor' RBAC rolü ekleyerek SQL Server kimliğine erişim izni verin. Daha fazla bilgi için bkz. Yönetilen Kimlik kimlik doğrulaması kullanarak depolama için denetim
properties.storageAccountSubscriptionId

string (uuid)

Blob depolama aboneliği kimliğini belirtir.

properties.storageEndpoint

string

Blob depolama uç noktasını belirtir (örneğin, https://MyAccount.blob.core.windows.net). Durum Etkinse storageEndpoint veyaAzureMonitorTargetEnabled gereklidir.

systemData

systemData

Azure Resource Manager metadata içeren createdBy ve modifiedBy bilgileri.

type

string

Kaynağın türü. Örneğin "Microsoft. Compute/virtualMachines" veya "Microsoft. Depo/Depolama Hesapları"

systemData

Kaynağın oluşturulması ve son değiştirilmesiyle ilgili meta veriler.

Name Tür Description
createdAt

string (date-time)

Kaynak oluşturma (UTC) zaman damgası.

createdBy

string

Kaynağı oluşturan kimlik.

createdByType

createdByType

Kaynağı oluşturan kimliğin türü.

lastModifiedAt

string (date-time)

Kaynağın son değişikliğinin zaman damgası (UTC)

lastModifiedBy

string

Kaynağı en son değiştiren kimlik.

lastModifiedByType

createdByType

Kaynağı en son değiştiren kimlik türü.