Linux/Unix monitor/discovery sorunları bölüm 1

Linux/Unix olarak ayrım yapmaktan ziyade Crossplatform Agent terimini kullanmayı tercih edeceğim, malum oldukça geniş bir yelpaze mevcut J.

Crossplatform agentı discover etttik fakat konsoldan baktığımızda Plarform/Version unknown olarak agentları görmekteyiz ve herhangi monitor işlemi gerçekleşmemektedir. Bu durumda discover etmiş olmamızın çok bir anlamı kalmıyor.

Bu durumun bir çok sebebi olabilir ben en çok bilinen sorunlar ve bunu nasıl troubleshoot edebiliriz onun üzerine duracağım.

Ilk bakacağımız yer agentın rapor ettiği management servera gitmek olacaktır. Bu MS C:\windows\temp klasörünün altına geçelim ve SCXSCXLogModule.log dosyasına bakmakta fayda var. En çok görülen bu dosyada “Access Denied” saturları olacaktır. Bu mesaj bize “Run as Account” accountlarda bir sorun olduğunu gösterecektir. Bildiğiniz gibi Cross platform ile ilgili bizim iki temel Run as Account” umuz mevcut. Bu account lar Unix priviledge ve non-priviledge accountları dır, bunları gözden geçirip kontrol etmek fayda var.

Yukarıdaki işlemleri yaptık ama sorun halen devam mı ediyor? Bu durumda biraz daha derine gidelim. SCXLogModule.log artık hata vermiyor ama halen istediğimiz neticeye gelemedik.

Şimdi durumu Crossplatform tarafına bakalım yani Linux/Unix agentımıza.  Bu agentımıza bağlanalım (Putty veya başka toolları kullanabilirsiniz).

Logon olduktan sonra /opt/microsoft/scx/bin/tools bulunanscxadmin isimli tüm işlerimizi gören komut ve parametrelerini kullanacağız. İlk yapacağımız log durumunu verbose ‘a çekmek olacaktır. Komutumuz bu durumda ./scxadmin –log-set all verbose ardından scxadmin –restart olacaktır . Durumun repro yani bir daha oluşması veya biraz zaman tanıdıktan sonra /var/opt/microsoft/scx/log/ altında bulunan scx.log dosyasına bir göz atıyıoruz. Dosya plain text durumunda ve rahat anlaşılabildiğinden yorumlaması kolay. Dosya içinde CIM veritabanı, instanceların listelenebilmesi veya bağlantı ile sorunları görebilirsiniz

Linux/Unix bazlı makinalara girişimiz zor, tecrübemiz yok veya uygun değil, bu durum içinde bir çözümümüz var. Crosplatform monitor edilebilmesi için için R2 ile kurmuş olduğumuz WS-Man ile işlem yapabiliriz.

Aşağıdaki komutu MS tarafında bir command prompt penceresinden çalıştıralım ve çıkan neticeyi dikkat ile inceleyelim.

winrm enumerate https://schemas.microsoft.com/wbem/wscim/1/cim-schema/2/SCX_OperatingSystem?__cimnamespace=root/scx

-username:root -password:<mypassword> -r:https://<Linux/Unix_agent_ismi>:1270/wsman -auth:basic -skipCACheck

-encoding:utf-8 -format:#pretty

Test sistemimde almış olduğum sonuç:

<wsman:Results xmlns:wsman="https://schemas.dmtf.org/wbem/wsman/1/wsman/results">

<p:SCX_OperatingSystem xml:lang="" xmlns:p="https://schemas.microsoft.com/wbem/ws

cim/1/cim-schema/2/SCX_OperatingSystem" xmlns:xsi="https://www.w3.org/2001/XMLSch

ema-instance">

    <p:CSCreationClassName>SCX_ComputerSystem</p:CSCreationClassName>

    <p:CSName>rhel5.scsturkey.com</p:CSName>

    <p:Caption>Red Hat Enterprise Linux Server release 5.2 Beta (Tikanga)</p:Cap

tion>

    <p:CreationClassName>SCX_OperatingSystem</p:CreationClassName>

    <p:CurrentTimeZone>-300</p:CurrentTimeZone>

    <p:Description>Red Hat Enterprise Linux Server release 5.2 Beta (Tikanga)</p

:Description>

    <p:Distributed xsi:nil="true"></p:Distributed>

    <p:ElementName xsi:nil="true"></p:ElementName>

    <p:EnabledDefault>2</p:EnabledDefault>

    <p:EnabledState>5</p:EnabledState>

    <p:FreePhysicalMemory>969728</p:FreePhysicalMemory>

    <p:FreeSpaceInPagingFiles>1571840</p:FreeSpaceInPagingFiles>

    <p:FreeVirtualMemory>2541568</p:FreeVirtualMemory>

    <p:HealthState xsi:nil="true"></p:HealthState>

    <p:InstallDate xsi:nil="true"></p:InstallDate>

    <p:LastBootUpTime>2011-02-22T14:03:13.288886Z</p:LastBootUpTime>

    <p:LocalDateTime>2011-02-27T17:02:51.388886Z</p:LocalDateTime>

    <p:MaxNumberOfProcesses>32766</p:MaxNumberOfProcesses>

    <p:MaxProcessMemorySize>0</p:MaxProcessMemorySize>

    <p:MaxProcessesPerUser>999</p:MaxProcessesPerUser>

    <p:Name>Red Hat Distribution</p:Name>

    <p:NumberOfLicensedUsers>0</p:NumberOfLicensedUsers>

    <p:NumberOfProcesses>68</p:NumberOfProcesses>

    <p:NumberOfUsers>1</p:NumberOfUsers>

    <p:OSType>36</p:OSType>

    <p:OperatingSystemCapability>32 bit</p:OperatingSystemCapability>

    <p:OperationalStatus xsi:nil="true"></p:OperationalStatus>

    <p:OtherEnabledState xsi:nil="true"></p:OtherEnabledState>

    <p:OtherTypeDescription>2.6.18-84.el5 #1 SMP Fri Feb 29 16:26:41 EST 2008</p

:OtherTypeDescription>

    <p:RequestedState>12</p:RequestedState>

    <p:SizeStoredInPagingFiles>1571840</p:SizeStoredInPagingFiles>

    <p:Status xsi:nil="true"></p:Status>

    <p:StatusDescriptions xsi:nil="true"></p:StatusDescriptions>

    <p:SystemUpTime>442778</p:SystemUpTime>

    <p:TimeOfLastStateChange xsi:nil="true"></p:TimeOfLastStateChange>

    <p:TotalSwapSpaceSize>1571840</p:TotalSwapSpaceSize>

    <p:TotalVirtualMemorySize>2607104</p:TotalVirtualMemorySize>

    <p:TotalVisibleMemorySize>1035264</p:TotalVisibleMemorySize>

    <p:Version>2.6.18-84.el5</p:Version>

</p:SCX_OperatingSystem>

</wsman:Results>

Görüldüğü gibi eksiksiz bir sonuç aldık ve herşeyi gördük. Eğer buna benzer bir sonuç alamıyor ve hata kodu dönülüyorsa, dikkate alınmalı. CIM tarafına ulaşamıyor ve bilgileri çekemiyoruz demektir.

Sorun daha derin ve halen bir netice yok mu, bu durumda agentın bağlı olduğu management server tarafınanda bir ETL trace almakta fayda. Eğer bu tür aksiyonlarla tecrübeniz yoksa hiç vakit kaybetmeyin ve Microsoft tarafına bir çağrı açtırın. Şunu unutmamakta fayda, Crossplatform monitoring ne kadarda bir agent barındırsa da temelde agentless monitorin yapmaktadır. Almış olduğunuz aksiyonlarda hene bir netice beklemeyin biraz zaman tanıyın.

Blog links

https://blogs.technet.com/b/servicemanager/archive/2010/02/17/create-view-for-incidents-that-have-not-been-modified-in-last-7-days.aspx

https://blogs.technet.com/b/servicemanager/default.aspx?PostSortBy=MostViewed&PageIndex=1 à Incident SLA management in Service Manager

https://blogs.technet.com/b/servicemanager/archive/2009/05/28/modeling-deriving-and-extending-classes.aspx

https://blogs.technet.com/b/servicemanager/archive/2010/01/13/system-center-service-manager-demos.aspx

https://blogs.msdn.com/b/scxplat/archive/2010/11/11/using-opalis-to-get-info-from-the-scx-cross-platform-agent.aspx