powershellwindows-update

Powershell Reset Windows Update


I currently installed a fresh official Windows 7 Ultimate on my MacbookPro with BootCamp.

Everything is running good except Windows Update. Stuck on Searching for updates..

So I made a lot of google searches (for about 4 hours now) and I tried many things such as the FixIt tools from MS and other tricks but nothing is working.

Now i'm trying this: http://www.sevenforums.com/performance-maintenance/372790-very-high-memory-sometimes-cpu-usage-svchost-exe-up-1-gb-post3095241.html#post3095241

I'm now at using PowerShell and entering this command line:

sc.exe sdset bits D:(A;;CCLCSWRPWPDTLOCRRC;;;SY)(A;;CCDCLCSWRPWPDTLOCRSDRCWDWO;;;BA)(A;;CCLCSWLOCRRC;;;AU)(A;;CCLCSWRPWPDTLOCRRC;;;PU)

I always get this error:

Missing closing ')' in expression.
At line:1 char:23
+ sc.exe sdset bits D:(A <<<< ;;CCLCSWRPWPDTLOCRRC;;;SY)(A;;CCDCLCSWRPWPDTLOCRS
DRCWDWO;;;BA)(A;;CCLCSWLOCRRC;;;AU)(A;;CCLCSWRPWPDTLOCRRC;;;PU)
    + CategoryInfo          : ParserError: (CloseParenToken:TokenId) [], Paren
   tContainsErrorRecordException
    + FullyQualifiedErrorId : MissingEndParenthesisInExpression
    enter code here

I took a look at the commande line and I dont see any missing ')', and made some other google search for this command line from other websites and always give the same error

Whats wrong..!?

Update:

I tried this without success (same error)

$str = "sc.exe sdset bits D:(A;;CCLCSWRPWPDTLOCRRC;;;SY)(A;;CCDCLCSWRPWPDTLOCRSDRCWDWO;;;BA)(A;;CCLCSWLOCRRC;;;AU)(A;;CCLCSWRPWPDTLOCRRC;;;PU)"

Invoke-Expression $str

Solution

  • SOLUTION

    I found the solution and its to type the command as follow:

    CMD /C "sc.exe sdset bits D:(A;;CCLCSWRPWPDTLOCRRC;;;SY)(A;;CCDCLCSWRPWPDTLOCRSDRCWDWO;;;BA)(A;;CCLCSWLOCRRC;;;AU)(A;;CCLCSWRPWPDTLOCRRC;;;PU)"