Services in GPO - Techist - Tech Forum

Go Back   Techist - Tech Forum > Computer Software > Microsoft Windows and Software
Click Here to Login
Closed Thread
Thread Tools Display Modes
Old 02-02-2008, 05:42 PM   #1 (permalink)
Repeat Offender
superdave1984's Avatar
Join Date: Aug 2006
Location: South Fulton, TN
Posts: 1,980
Default Services in GPO

Basically where do you find services in a GPO? I want to push one out that starts certain services and stops others. It has to be there somewhere I just can't find it. And googling it made my head hurt.

Change the world. Of one person. Today.

If your equation requires either a complex combination of variables to get the desired result OR you can't seem to get the result regardless of the ain't your variables, it's your constant.
superdave1984 is offline  
Old 02-02-2008, 06:49 PM   #2 (permalink)
Monster Techie
Join Date: May 2004
Location: /usr/root/mn/us
Posts: 1,118
Default Re: Services in GPO

This would be something I would do with a login script.
Here's a sample that I made a little while back.

Dim objWMIService, objItem, objService
Dim colListOfServices, strComputer, strService
strComputer = "."

strService = " 'Alerter' "

Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" _
& strComputer & "\root\cimv2")

Set colListOfServices = objWMIService.ExecQuery _
("Select * from Win32_Service Where Name ="_
& strService & " ")
For Each objService in colListOfServices
If you want to start a service, just replace objService.StopService() with objService.StartService().

The only reason I had to do this is because a service was being sent a stop signal depending on user actions. If you just want them to be started or stopped, look into setting the Service Startup type via VBS.

Its a frigging Laptop, not a Labtop!!!!
bla!! is offline  
Closed Thread

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Need GPO Help! htcs Microsoft Windows and Software 1 10-22-2007 09:17 AM
vpn and web services hiren Computer Networking and Internet Hardware 1 06-23-2007 08:53 PM
HJT Log - Generic Host Process for Win32 Services Xearoveg Viruses, Spyware and Malware 1 06-11-2007 09:22 PM
Removing services from Services ZeroShade Microsoft Windows and Software 3 05-04-2007 11:02 PM
services problem zachattack1337 Hardware Repairs and Troubleshooting 1 04-02-2007 08:27 PM

Copyright 2002- Social Knowledge, LLC All Rights Reserved.

All times are GMT -5. The time now is 05:36 AM.

Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2018, vBulletin Solutions, Inc.