We help IT Professionals succeed at work.

Find if a groups is available on all machines

508 Views
Last Modified: 2010-03-05
Hi,

I have a group calles Sophos administrator.I want a script which can find from all machines in the file if the group is available or not.
Regards
SHarath
Comment
Watch Question

CERTIFIED EXPERT
Top Expert 2007

Commented:
   Hi Sharath
         
        for /f %x in (c:\computers.txt) do psexec \\%x net localgroup Sophos>>result.txt

        Script above will list users of Sophos group if exists in computer. If group does not exist, it will report following error
            The specified local group does not exist
         
Regards

Author

Commented:
I get this.

C:\Pstool>psexec \\chennai-fs01 net localgroup administrator  1>>result.txt

PsExec v1.63 - Execute processes remotely
Copyright (C) 2001-2005 Mark Russinovich
Sysinternals - www.sysinternals.com


System error 1376 has occurred.

The specified local group does not exist.

net exited on chennai-fs01 with error code 2.

I have tried with multiple systems but get no results

Author

Commented:
Any help....
CERTIFIED EXPERT
Top Expert 2007
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.