Windows Vista Service Tweaks in Batch!

Anyone who installs Windows XP or Vista, one of the first things they do is to tweak their Windows Services, especially to disable those that are useless or will compromise their system.

There are MANY sites that teach you what services to disable, like www.tweakvista.com and www.tweakhound.com, but I could not find a single one to teach you how to do it quickly. You have to run services.msc or go to the Admin Tools to manually set them.

So I decided to write my own batch file to do it. Cuz I’m those type who reinstalls my OS frequently, I do service tweak frequently. This will save me alot of time and I dun have to go visit a tweak site again and again. Since I recently installed Vista Home Premium x64, I did the batch file for Vista. If you want such a batch file, simply copy the below text and paste it into your own batch file.

echo off
echo "Starting Vista Service Tweaks..."
;
echo "Setting Diagnostic Policy Service to Manual..."
sc config DPS start= demand
echo "Stopping Diagnostic Policy Service..."
sc stop DPS
;
echo "Setting Diagnostic System Host to Manual..."
sc config WdiSystemHost start= demand
echo "Stopping Diagnostic System Host..."
sc stop WdiSystemHost
;
echo "Setting Base Filtering Engine to Manual..."
sc config BFE start= demand
echo "Stopping Base Filtering Engine..."
sc stop BFE
;
echo "Setting Computer Browser to Disabled..."
sc config Browser start= disabled
echo "Stopping Computer Browser..."
sc stop Browser
;
echo "Setting Certificate Propagation to Manual..."
sc config CertPropSvc start= demand
echo "Stopping Certificate Propagation..."
sc stop CertPropSvc
;
echo "Setting Desktop Window Manager Session Manager to Manual..."
sc config UxSms start= demand
echo "Stopping Desktop Window Manager Session Manager..."
sc stop UxSms
;
echo "Setting Function Discovery Provider Host to Disabled..."
sc config fdPHost start= disabled
echo "Stopping Function Discovery Provider Host..."
sc stop fdPHost
;
echo "Setting Function Discovery Resource Publication to Disabled..."
sc config FDResPub start= disabled
echo "Stopping Function Discovery Resource Publication..."
sc stop FDResPub
;
echo "Setting IKE and AuthIP IPsec Keying Modules to Disabled..."
sc config IKEEXT start= disabled
echo "Stopping IKE and AuthIP IPsec Keying Modules..."
sc stop IKEEXT
;
echo "Setting IP Helper to Disabled..."
sc config iphlpsvc start= disabled
echo "Stopping IP Helper..."
sc stop iphlpsvc
;
echo "Setting IPsec Policy Agent to Disabled..."
sc config PolicyAgent start= disabled
echo "Stopping IPsec Policy Agent..."
sc stop PolicyAgent
;
echo "Setting Print Spooler to Manual..."
sc config Spooler start= demand
echo "Stopping Print Spooler..."
sc stop Spooler
;
echo "Setting ReadyBoost to Disabled..."
sc config EMDMgmt start= disabled
echo "Stopping ReadyBoost..."
sc stop EMDMgmt
;
echo "Setting Tablet PC Input Service to Disabled..."
sc config TabletInputService start= disabled
echo "Stopping Tablet PC Input Service..."
sc stop TabletInputService
;
echo "Setting TCP/IP NetBIOS Helper to Disabled..."
sc config lmhosts start= disabled
echo "Stopping TCP/IP NetBIOS Helper..."
sc stop lmhosts
;
echo "Setting Telephony to Disabled..."
sc config TapiSrv start= disabled
echo "Stopping Telephony..."
sc stop TapiSrv
;
echo "Setting Terminal Services to Disabled..."
sc config TermService start= disabled
echo "Stopping Terminal Services..."
sc stop TermService
;
echo "Setting Terminal Serivces Configuration to Disabled..."
sc config SessionEnv start= disabled
echo "Stopping Terminal Services Configuration..."
sc stop SessionEnv
;
echo "Setting UPnP Device Host to Disabled..."
sc config upnphost start= disabled
echo "Stopping UPnP Device Host..."
sc stop upnphost
;
echo "Setting Web Client to Disabled..."
sc config WebClient start= disabled
echo "Stopping Web Client..."
sc stop WebClient
;
echo "Setting Windows Error Reporting Service to Disabled..."
sc config WerSvc start= disabled
echo "Stopping Windows Error Reporting Service..."
sc stop WerSvc
;
echo "Setting Windows Firewall to Disabled..."
sc config MpsSvc start= disabled
echo "Stopping Windows Firewall..."
sc stop MpsSvc
;
echo "Setting Windows Image Acquisition (WIA) to Disabled..."
sc config stisvc start= disabled
echo "Stopping Windows Image Acquisition (WIA)..."
sc stop stisvc
;
echo "Setting Windows Search to Disabled..."
sc config WSearch start= disabled
echo "Stopping Windows Search..."
sc stop WSearch
;
echo "Setting Windows Time to Disabled..."
sc config W32Time start= disabled
echo "Stopping Windows Time..."
sc stop W32Time
;
echo "Setting WinHTTP Web Proxy Auto-Discovery Service to Disabled..."
sc config WinHttpAutoProxySvc start= disabled
echo "Stopping WinHTTP Web Proxy Auto-Discovery Service..."
sc stop WinHttpAutoProxySvc
;
echo "Setting Windows Media Center Extender Service to Disabled..."
sc config Mcx2Svc start= disabled
echo "Stopping Windows Media Center Extender Service..."
sc stop Mcx2Svc
;
echo "Setting SSDP Discovery to Disabled..."
sc config SSDPSRV start= disabled
echo "Stopping SSDP Discovery..."
sc stop SSDPSRV
;
echo "Setting Shell Hardware Detection to Disabled..."
sc config ShellHWDetection start= disabled
echo "Stopping Shell Hardware Detection..."
sc stop ShellHWDetection
;
echo "Setting Server to Disabled..."
sc config LanmanServer start= disabled
echo "Stopping Server..."
sc stop LanmanServer
;
echo "Setting Security Center to Disabled..."
sc config wscsvcstart= disabled
echo "Stopping Security Center..."
sc stop wscsvc
;
echo "Setting Secondary Logon to Disabled..."
sc config seclogon start= disabled
echo "Stopping Secondary Logon..."
sc stop seclogon
;
echo "Setting RemoteRegistry to Disabled..."
sc config RemoteRegistry start= disabled
echo "Stopping RemoteRegistry..."
sc stop RemoteRegistry
;
echo "Setting Routing and Remote Access to ..."
sc config RemoteAccess start= disabled
echo "Stopping Routing and Remote Access..."
sc stop RemoteAccess
;
echo "Setting Remote Access Auto Connection Manager to Disabled..."
sc config RasAuto start= disabled
echo "Stopping Remote Access Auto Connection Manager..."
sc stop RasAuto
;
echo "Setting Remote Access Connection Manager to Disabled..."
sc config RasMan start= disabled
echo "Stopping ..."
sc stop RasMan
;
echo "Setting Program Compatibility Assistant Service to Disabled..."
sc config PcaSvc start= disabled
echo "Stopping Program Compatibility Assistant Service..."
sc stop PcaSvc
;
echo "Setting Portable Device Enumerator Service to Disabled..."
sc config WPDBusEnum start= disabled
echo "Stopping Portable Device Enumerator Service..."
sc stop WPDBusEnum
;
echo "Setting NetTcpPortSharing to Disabled..."
sc config NetTcpPortSharing start= Disabled
echo "Stopping NetTcpPortSharing..."
sc stop NetTcpPortSharing
;
echo "Setting Microsoft Software Shadow Copy Provider to Disabled..."
sc config swprv start= disabled
echo "Stopping Microsoft Software Shadow Copy Provider..."
sc stop swprv
;
echo "Setting KtmRm for Distributed Transaction Coordinator to Manual..."
sc config KtmRm start= demand
echo "Stopping KtmRm for Distributed Transaction Coordinator..."
sc stop KtmRm
;
echo "Setting Human Interface Device Access to Disabled..."
sc config hidserv start= disabled
echo "Stopping Human Interface Device Access..."
sc stop hidserv
;
echo "Setting Distributed Link Tracking Client to Disabled..."
sc config TrkWks start= disabled
echo "Stopping Distributed Link Tracking Client..."
sc stop TrkWks
;
echo "Setting DFS Replication to Disabled..."
sc config DFSR start= disabled
echo "Stopping DFS Replication..."
sc stop DFSR

;
echo “Setting Offline Files to Disabled…”
sc config CscService start= disabled
echo “Stopping Offline Files…”
sc stop CscService
;
echo "Vista Service Tweaks Completed!"

A quick explanation. The key commands are sc config <servicename> start= and sc stop <servicename>. Note that there is no space between start=, but there is a space after it. The 3 options for start= are auto, demand (manual) and disabled. In Vista there is delayed automatic but I dunno the flag for it.

Edit the code to fit your own install. Since this was done for Vista Home Premium it’s possible some services were not touched or don’t exist in your install. Also some tweaks above are my own suggestions. You can edit them to suit or for XP cuz many services are the same between XP and Vista.

EDIT: missed out Offline Files!

~ by benghacks on April 14, 2009.

2 Responses to “Windows Vista Service Tweaks in Batch!”

  1. [...] system and the desktop had a few apps running including Spybot, FW, AV, IM, etc. Both also ran a Vista Service Tweak. The benchmark I decided to use was the X3:Terran Conflict Rolling Demo. In some circles it is [...]

  2. Thanks for taking the time to do this!

Leave a Reply