Jump to content

Recommended Posts

Posted
So I have just realised my reporting is not working in smoothwall correctly because the logon script needed by smoothwall is not running on multiple machines! you can tell if the script is running as a wscript process will be running. So my question is is there a simple way to identify all PCs that don't have the wscript running on mass?
Posted (edited)

Hi Markurageek,

 

You could employ powershell here to do the dirty work for you. It should be quite simple. You can run a query against an OU (providing that you have your machines in an OU) that can tell you if a certain process is not in a running state on all the machines inside that container.

If this interests you, i can knock something up, let me know.

Edited by chrispounds
Posted (edited)

Hi Markurageek,

 

Get-ADComputer -SearchBase "OU=Computers,DC=MyDomain,DC=com" -Filter * | select -ExpandProperty name*| ForEach-Object { Get-Service -DisplayName "Adobe*"| Select -ExpandProperty name | Out-GridView}

 

This will output it to a gridview in a window, if you want this information outputted to a csv file, replace "out-gridview" with Export-Csv "C:\Temp" | ft -NoTypeInformation

 

Let me know if that helps! Obviously change the name of the service after -DisplayName, make sure it's in quotes as it is string, if you dont put a * wildcard after, you will have to make sure you type it perfectly!

Edited by chrispounds
  • Thanks 3

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...