Identify Server role(s) for Automation.
This script empowers advanced automation via policy management. This is a catalyst in identifying and managing servers based on their roles to truly distinguish the management of Active Directory, SQL, Web, and so forth.
Agent Procedure Details below:
Audit and ID All Server Roles by running a batch file IDSRVROLES.CMD that looks at running services and other key indicators on a system to create a results file called SERVERROLES.TXT in the Agent Temp folder.
Once completed, these roles can be added to any system custom field for advanced automation and policy management.
1/17/2019: Sharepoint identification improved per community suggestion.
Kaseya Technical Success
Nice, simple & useful
You should change the .cmd SharePoint Server entry to the following:
REM SharePoint Server
find /i "SharePoint Timer Service" %t%\netstart.log.txt
if not errorlevel 1 set SPS=1
What is searched for currently as part of the .cmd file is for something like SharePoint Foundation, which is basic and assumes the SQL instance is on the same server. This does not work for those who have SharePoint environment with a SQL DBs running on another server (i.e. SharePoint farm of 2 or more servers).
Please update. Thanks!
Appreciate the suggestion Colton.
I have made the edit on the cmd file and updated the file.