We recently had a security audit and i would like to find out information on the services on my servers.  I know KACE pulls the data because I can go into a server, go to services and view a particular service and what logon account it uses. 

I would like to get a report that tells me, in a particular IP range, the servers name, the services running on it and the logon accounts for the services.  I have not been able to find any information on it, and I am not a SQL person, so I don't know how to build the report myself.  Any information would be appreciated.

Answer Summary:
SELECT M. NAME AS COMPUTER_NAME, M.OS_NAME, S. NAME AS SERVICE_NAME, S.DISPLAY_NAME, S.LOGON_AS_USER, M.IP FROM NTSERVICE S, MACHINE_NTSERVICE_JT MS, MACHINE M WHERE MS.NTSERVICE_ID = S.ID AND MS.MACHINE_ID = M.ID AND OS_NAME LIKE '%SERVER%' ORDER BY M. NAME
Cancel
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Community Chosen Answer

1

I think this will do what you need.

 
SELECT
	M. NAME AS COMPUTER_NAME,
	M.OS_NAME,
	S. NAME AS SERVICE_NAME,
	S.DISPLAY_NAME,
	S.LOGON_AS_USER,
	M.IP
FROM
	NTSERVICE S,
	MACHINE_NTSERVICE_JT MS,
	MACHINE M
WHERE
	MS.NTSERVICE_ID = S.ID
AND MS.MACHINE_ID = M.ID
AND OS_NAME LIKE '%SERVER%'
ORDER BY
	M. NAME
Answered 04/18/2012 by: dchristian
Red Belt

Please log in to comment

Answers

0

Try this: you might have to change to view differently

SELECT NTSERVICE.NAME AS 'Services', MACHINE.IP, MACHINE.NAME, MACHINE.USER_LOGGED
FROM NTSERVICE NTSERVICE, MACHINE MACHINE
ORDER BY MACHINE.IP

Answered 04/17/2012 by: Aaron Cool
Red Belt

Please log in to comment
Answer this question or Comment on this question for clarity

Share