서버의 메모리 사용량

Microsoft.SQLServer.2016.AnalysisServices.UnitMonitor.Instance.MemoryUsageByOtherProcess (UnitMonitor)

모니터는 Analysis Services의 전체 메모리 한도가 항상 사용 가능한지 확인하도록 서버에서 Analysis Services 이외 프로세스의 메모리 사용량을 관찰합니다.

Knowledge Base article:

요약

SSAS 인스턴스를 호스팅하는 서버의 메모리 사용량은 해당 인스턴스도 할당해야 하는 공유 리소스를 두고 경쟁하게 되므로 서버의 상태 및 성능에 영향을 줄 수 있습니다. 컴퓨터에서 사용 가능한 실제 메모리가 소모될 수 있으며, 이 경우 운영 체제가 실제 메모리보다 느린 순서대로 디스크의 페이지 파일에 가상 메모리를 강제로 매핑할 수 있습니다. SSAS 인스턴스에 종속된, 비즈니스에 중요한 응용 프로그램의 경우 다른 프로세스(예: 바이러스 백신, 디스크 조각 모음, SSAS 또는 SQL Server 관계형 데이터베이스 엔진의 다른 인스턴스 등)가 이러한 상황을 발생시키는 과도한 메모리를 할당하지 않도록 서버가 구성되어야 합니다.

원인

SSAS 인스턴스와 메모리를 두고 크게 경쟁하는 가장 일반적인 프로세스에는 주로 SSAS, SQL Server 관계형 데이터베이스 엔진 또는 다른 데이터베이스 서버의 다른 인스턴스가 포함됩니다. 이러한 프로세스가 SSAS도 호스팅된 서버에서 호스팅된 메모리를 가장 집중적으로 사용하는 경향이 있기 때문입니다. 물론 데이터베이스 이외의 소프트웨어가 메모리를 많이 사용하는 경우도 있습니다. 이처럼 메모리 고려 사항은 서버 구성에 영향을 미치는 경우가 많습니다.

또한 예약되지 않은 사용 가능한 메모리(FreeUnreservedPercent parameter)가 음수가 될 수 있습니다. 이 매개 변수는 100%의 전체 메모리 한도에서 인스턴스(SSAS)별로 높은 메모리 사용량과 그 밖의 프로세스별 메모리 사용량을 빼는 식으로 계산됩니다. 원인은 다음과 같을 수 있습니다.

태스크 관리자를 사용하여 서버의 다양한 프로세스별 메모리 사용량을 조사할 수 있습니다. Window Server 2008 R2의 프로세스 탭과 Windows Server 2016의 세부 정보 탭에서 메모리 열을 기준으로 정렬하여 시스템에서 가장 많은 메모리를 사용하는 프로세스를 쉽게 찾아 확인할 수 있습니다. SSAS(msmdsrv.exe) 또는 SQL Server 관계형 데이터베이스 엔진(sqlservr.exe)의 인스턴스가 과도한 메모리를 사용하는 경우 이를 통해 사용량을 쉽고 빠르게 식별할 수 있으며, 시스템의 다른 프로세스가 이러한 상태에 영향을 미치고 있는지도 확인할 수 있습니다. 이후 적절하게 수정 조치(예: SQL 관리자의 인스턴스 메모리 사용량 조정, 하드웨어 추가 또는 시스템의 작업 줄이기/나누기)를 마련할 수 있습니다.

해결 방법

전체 서버 사용량 문제를 해결하려면 관리자가 작업 요구 사항, 사용자 및 작업 일정, 서버 컴퓨터의 다른 예약 프로세스, 사용 가능한 리소스 등(이러한 요인으로 제한되지 않음) 여러 요인을 이해하고 고려해야 합니다. 서버 컴퓨터에서 과도한 전체 메모리 할당을 수정하는 조치에는 다음과 같은 조치가 포함될 수 있습니다.

외부 리소스

SQL Server 2016의 메모리 구성 및 크기 조정 고려 사항

Analysis Services 메모리 속성 TechNet 설명서

Analysis Services 서버 속성 구성

SSAS 성능 카운터 TechNet 설명서

SSAS 다차원 성능 가이드

재정의 가능한 매개 변수

이름

설명

기본값

위험 임계값(%)

사용 가능한 미예약(%)이 임계값 아래로 떨어지는 경우 상태가 위험으로 변경됩니다.

5

사용

워크플로를 사용하거나 사용하지 않도록 설정합니다.

알림 생성

워크플로의 알림 생성 여부 정의

간격(초)

워크플로를 실행하는 반복 시간 간격(초)입니다.

900

샘플 수

임계값 위반 수가 최소 위반 수 이상인 경우 상태가 변경됩니다.

4

동기화 시간

24시간 형식으로 지정된 동기화 시간입니다. 생략될 수 있습니다.

 

시간 제한(초)

워크플로를 닫고 실패로 표시하기 전에 워크플로를 실행할 수 있는 시간을 지정합니다.

300

경고 임계값(%)

사용 가능한 미예약(%)이 임계값 아래로 떨어졌으나 위험 임계값(%)보다는 높은 경우 상태가 경고로 변경됩니다.

10

Element properties:

TargetMicrosoft.SQLServer.2016.AnalysisServices.Instance
Parent MonitorSystem.Health.PerformanceState
CategoryPerformanceHealth
EnabledTrue
Alert GenerateTrue
Alert SeverityError
Alert PriorityNormal
Alert Auto ResolveTrue
Monitor TypeMicrosoft.SQLServer.2016.AnalysisServices.MonitorType.Instance.MemoryUsageByOtherProcessPercent
RemotableTrue
AccessibilityPublic
Alert Message
SSAS 2016: 다른 프로세스가 너무 많은 메모리를 할당함
다른 프로세스가 너무 많은 메모리({4}GB)를 할당하여 전체 메모리 한도 설정으로 사전 설정된 메모리 양을 SSAS에 사용하지 못할 수 있습니다.
서버의 전체 메모리: {2}GB
전체 메모리 사용량: {5}GB
SSAS 이외의 프로세스에서 사용 중인 메모리: {4}GB
SSAS에서 사용 중인 메모리: {3}GB
SSAS 메모리 하한: {6}GB({7}\%)
SSAS 메모리 상한: {0}GB({8}\%)
RunAsDefault

Source Code:

<UnitMonitor ID="Microsoft.SQLServer.2016.AnalysisServices.UnitMonitor.Instance.MemoryUsageByOtherProcess" Accessibility="Public" Enabled="true" Target="SQLAS!Microsoft.SQLServer.2016.AnalysisServices.Instance" ParentMonitorID="SystemHealth!System.Health.PerformanceState" Remotable="true" Priority="Normal" TypeID="Microsoft.SQLServer.2016.AnalysisServices.MonitorType.Instance.MemoryUsageByOtherProcessPercent" ConfirmDelivery="false">
<Category>PerformanceHealth</Category>
<AlertSettings AlertMessage="Microsoft.SQLServer.2016.AnalysisServices.UnitMonitor.Instance.MemoryUsageByOtherProcess.AlertMessage">
<AlertOnState>Error</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>Error</AlertSeverity>
<AlertParameters>
<AlertParameter1>$Data/Context/Property[@Name='MemoryLimitHighGB']$</AlertParameter1>
<AlertParameter2>$Data/Context/Property[@Name='MemoryLeavesForOsGB']$</AlertParameter2>
<AlertParameter3>$Data/Context/Property[@Name='TotalPhysicalMemoryGB']$</AlertParameter3>
<AlertParameter4>$Data/Context/Property[@Name='MemoryUsageGB']$</AlertParameter4>
<AlertParameter5>$Data/Context/Property[@Name='MemoryUsageByOtherProcessGB']$</AlertParameter5>
<AlertParameter6>$Data/Context/Property[@Name='UsedPhysicalMemoryGB']$</AlertParameter6>
<AlertParameter7>$Data/Context/Property[@Name='MemoryLimitLowGB']$</AlertParameter7>
<AlertParameter8>$Data/Context/Property[@Name='MemoryLimitLowPercent']$</AlertParameter8>
<AlertParameter9>$Data/Context/Property[@Name='MemoryLimitHighPercent']$</AlertParameter9>
</AlertParameters>
</AlertSettings>
<OperationalStates>
<OperationalState ID="Error" MonitorTypeStateID="Below" HealthState="Error"/>
<OperationalState ID="Warning" MonitorTypeStateID="Between" HealthState="Warning"/>
<OperationalState ID="Success" MonitorTypeStateID="Above" HealthState="Success"/>
</OperationalStates>
<Configuration>
<WarningThreshold>10</WarningThreshold>
<CriticalThreshold>5</CriticalThreshold>
<IntervalSeconds>900</IntervalSeconds>
<SyncTime/>
<TimeoutSeconds>300</TimeoutSeconds>
</Configuration>
</UnitMonitor>