Solved

I can't run powershell in Windows 7

Posted on 2010-09-17
3
602 Views
Last Modified: 2012-05-10
I have Windows 7 32 bit and when I run set-executionpolicy remotesigned it gives me the error I do not have rights to the registry.  I am in the administrators group.  This is my home machine, I am not on a domain.  How do I fix this so I can run scripts?  I powershell v2.
0
Comment
Question by:BrianSDG
3 Comments
 
LVL 21

Accepted Solution

by:
chapmanjw earned 500 total points
Comment Utility
You need to run PowerShell as administrator.  Right click, Run As Administrator.
0
 
LVL 23

Expert Comment

by:jeremyjared74
Comment Utility
You can download this registry entry to fix all those annoying privileged errors. Once you download it, just double click it to install. You will then have a right click menu to take ownership. http://www.sevenforums.com/tutorials/1911-take-ownership-shortcut.html

Well, that won't help you on this error, but it is nice to have. You can follow the instructions on this EE Post: http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Windows/Windows_7/A_2846-Use-the-Administrator-account-by-default-in-Vista.html
0
 
LVL 7

Expert Comment

by:thakurdinesh
Comment Utility
set-ExecutionPolicy : Access to the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PowerShell\1\ShellIds
\Microsoft
.PowerShell' is denied.
At line:1 char:20
+ Set-ExecutionPolicy <<<<  RemoteSigned
    + CategoryInfo          : NotSpecified: (:) [Set-ExecutionPolicy], UnauthorizedAccessException
    + FullyQualifiedErrorId : System.UnauthorizedAccessException,Microsoft.PowerShell.Commands.SetExecutionPolicyComma
   nd


How to fix this?
 
Right click on Powershell shortcut and choose 'Run as Administrator'

Also note that if you have a 64-bit OS you need to set the execution policy for both the 32-bit and 64-bit version of PowerShell.
Thanks
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Citrix XenApp, Internet Explorer 11 set to Enterprise Mode and using central hosted sites.xml file.
Active Directory replication delay is the cause to many problems.  Here is a super easy script to force Active Directory replication to all sites with by using an elevated PowerShell command prompt, and a tool to verify your changes.
Learn the basics of while and for loops in Python.  while loops are used for testing while, or until, a condition is met: The structure of a while loop is as follows:     while <condition>:         do something         repeate: The break statement m…
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now