클러스터 로그 확인

 

Get-ClusterLog -UseLocalTime -Destination .

(Get_Cluster).ClusterLogLevel

 

 

리소스 정보

PS> Get-ClusterResource

PS> Get-ClusterResource "SQL Server" | Get-ClusterParameter

 

 

그림에서도 볼 수 있듯이 SQL Server 리소스의 HealthCheckTimeout, FailureConditionLevel 값을 확인할 수 있으며 아래와 같이 쿼리를 통해서도 이러한 속성값을 변경할 수 있습니다.

 

 

ALTER SERVER CONFIGURATION SET FAILOVER CLUSTER PROPERTY HealthCheckTimeout = 60000;

ALTER SERVER CONFIGURATION SET FAILOVER CLUSTER PROPERTY FailureConditionLevel = 3; 

 

 

 

 

 

이벤트 로그

Get-EventLog [-AsString] [-ComputerName <string[]>] [-List] [<CommonParameters>]

 

Get-EventLog [-LogName] <string> [[-InstanceId] <Int64[]>] [-After <DateTime>] [-AsBaseObject] [-Before <DateTime>] [-ComputerName <string[]>] [-EntryType <string[]>] [-Index <Int32[]>] [-Message <string>] [-Newest <int>] [-Source <string[]>] [-UserName <string[]>] [<CommonParameters>]

 

PS> Get-EventLog -list

 

최근 3개의 시스템 로그 확인하고 Message 내용을 좀 더 자세히 보기 위해 Format-List cmdlet 을 사용합니다.

PS> Get-EventLog System -newest 3

 PS> Get-EventLog System -newst 1 | Format-list

 

 

시스템 이벤트 로그 중 Source 값이 EventLog 인 것에 대한 필터링

PS> Get-EventLog System | Where-Object {$_.Source -eq "EventLog"}

 

 

이벤트 로그 Source(EventLog) 와 EventID(6005) 에 대한 OR 필터링

PS> Get-EventLog System -Source EventLog | Where-Object {$_.EventID -eq "6005"}

 

Index 번호를 사용하여 해당 이벤트 상세 확인

PS> $a = Get-EventLog System -Index 406

 PS> $a | Format-List -property *

 

 

이벤트 로그 메시지에 포함된 문자열을 검색하여 해당 정보를 text 파일로 기록합니다.

PS> Get-EventLog System -message "*uptime*"

 PS> Get-EventLog System -index 467 | Format-List > uptime.txt

 

이벤트 로그 발생 빈도 카운트

PS> $events = Get-EventLog System

 PS> $events | Group-Object -property source -noelement | Sort-Object -property count -descending


'Microsoft > Cluster' 카테고리의 다른 글

Cluster RHS  (0) 2019.01.17


Resource Hosting Subsystem 이라는 RHS online, Offline, Isavlie , Lookalive 등을 담당하는데요. 이는 cluster resource dll 의 하위 프로세스

정도로 이해하셔도 됩니다. RHS looksalive 5 단위로 모니터링 하고, 실패시 5번까지 check 합니다. 여기서 failed 감지되면 60초를 기다리지 않고 즉시, IsAlive 체크로 실제 상태를 점검합니다.

 

  • LooksAlive is a quick light lightweight check that happens every 5 seconds by default
  • IsAlive is a more verbose check that happens every 60 seconds by default. 

 

여기서 5 60초는 리소스 속성에서 변경이 가능합니다.

 

그리고 IsAlive Check 에서 적절한 응답이 없는 경우 바로 Recover Action 하지 않고 300 동안 대기합니다.

이 설정은 Deadlock Timeout 값으로 설정이 가능합니다.

변경은 아래와 같이 설정하면 됩니다.

(Get-ClusterResource Resource Name).DeadlockTimeout = 300000

 

300 이후 failed 찍히고, 즉시(15분내 1) 재시작을 시도하며, 2 실패시 Failover 하게 됩니다.

하지만 timeout 같은 경우가 아닌, 리소스의 문제가 감지되면 즉시 Action 하게 되므로 설정의 변경 의미는 없습니다.

 

IsAlive 실패하는 경우는 아래의 경우들이 있을수 있습니다.

 

  • Deadlocks in a resource DLL
  • Crashes in a resource DLL
  • RHS process itself terminates in the cluster
  • Cluster service fails on the node
  • Operating system failures (e.g. resource exhaustion)

 

File Server 리소스의 failed 간혈적으로 발생한다면 smb, msxsrv등의 server services 관련 Hotfix 설치하시면 증상에 도움이 됩니다.

예전에 가이드 드렸던 kb2775511 등이 대표적입니다.


'Microsoft > Cluster' 카테고리의 다른 글

Cluster Information - Powershell  (0) 2019.01.17

[환경]

Windows2012 R2 Remote Desktop Session Host



[이슈사항]

Windows2012 R2 Remote Desktop Session Host 올린이후 Jeus 성능이 현저히 낮아지는 증상이 나타남.


1. Remote Desktop Session Host 역할이 서버에 설치되면 예를 들어, 특정 Application에서 File Write System 프로세스의 Worker 쓰레드에서 이를 처리하게 되는데 다음 화면의 Call Stack과 같이 이 과정에 TSFairShare.sys 드라이버가 관여하게 됩니다.


2. 이는 Remote Destkop Session Host 역할이 설치됨으로써 Resource 대한 Fair Share 기능이 추가되기 때문입니다. 기능은 2008 R2부터 도입이 되었고 이름 그대로 여러 Remote Session 사용할 특정 Session에서 Resource(CPU, Disk, Network) 사용량에 대해 조절하게 됩니다.

  1. Network Fairshare Dynamically distributes available bandwidth across sessions based on the number of active sessions to enable equal bandwidth utilization.
  2. Disk Fairshare Prevents sessions from over utilizing disk usage by equal distribution of disk I/O among sessions.
  3. CPU Fairshare Dynamically distributes processor time across sessions based on the number of active sessions and load on these sessions. This was introduced in Windows Server 2008 R2 and has been improved for heavier loads in Windows Server 2012.


[해결방안]


1. CPU Fair Share

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Quota System 하위에 있는 EnableCPUQuota 값을 0으로 변경

 

2. Network Fair Share

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TSFairShare\NetFS 하위에 있는 EnableFairShare 값을 0으로 변경

 

3. Disk Fair Share

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TSFairShare\Disk 하위에 있는 EnableFairShare 값을 0으로 변경


끝.


+ Recent posts