Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR Installing Anything: Requested registry access is not allowed. #335

Closed
gooddadmike opened this issue Jun 18, 2015 · 32 comments
Closed
Assignees
Milestone

Comments

@gooddadmike
Copy link

Gist of my -dv log
Clean install using the code described on the GitHub page for command line installation.

@powershell -NoProfile -ExecutionPolicy unrestricted -Command "(iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))) >$null 2>&1" && SET PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin

Chocolatey is in the PATH and I am admin. I have no idea what this means.
The full error:

notepadplusplus v6.7.9 
notepadplusplus not installed. An error occurred during installation: Requested registry access is not allowed.

I have 0 issues installing the GUI way.

@ferventcoder
Copy link
Member

@michaelsearcy Did you buy chance not have .NET Framework 4.0 installed before you ran the installer?

From what I'm finding it may be related to the install of the framework, based on setting a permissions key in the registry and may require a reboot.

Some of the references will have you apply some changes, I think it may be simpler to attempt to reboot first and see if it fixes the issues.

References:

@ferventcoder
Copy link
Member

The last one mentioned I need to set things up so that choco always runs in admin mode - http://stackoverflow.com/questions/562350/requested-registry-access-is-not-allowed

I don't want to go that route if I don't have to - we have folks use choco without admin access and this would remove their ability to do so.

@ferventcoder
Copy link
Member

Quick question, you are admin - are you running an administrative command prompt? Usually choco can detect that (in this case choco thinks all is good) and warn the user, but it's not a 100% detection.

@gooddadmike
Copy link
Author

image
.Net Framework 4.5 installed. Do I need to also have the older 4.0 (is that even possible).
I have rebooted my machine before opening this issue.
I have tried 1st reference. Rebooting now.

@gooddadmike
Copy link
Author

Admin: Yes
image

@ferventcoder
Copy link
Member

4.5 is fine

@ferventcoder
Copy link
Member

Hmm... Is there a chance this is x64 only? No syswow64 support for 32 bit programs? Just trying to determine if a key is missing...or 32 bit only?

@gooddadmike
Copy link
Author

You lost me. How can I answer your last question?

@ferventcoder
Copy link
Member

Sorry, was asking if this was a 64bit system?
Then I was asking if you had a 64bit system with no 32-bit app support (this would not be common, most folks have amd64 and not itanium64).

@ferventcoder
Copy link
Member

Tell me if you have the following keys:

HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
HKLM\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall
HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
HKCU\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall

@ferventcoder
Copy link
Member

Could be that last key is the issue

@ferventcoder
Copy link
Member

We also attempt to open with read permissions - RegistryKeyPermissionCheck.ReadSubTree, RegistryRights.ReadKey

@gooddadmike
Copy link
Author

  • HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
    • yes in the Uninstall folder is say Name (Default) Type REG_SZ, Data (value not set) there are hundreds of subfolders. None for chocolatey (but many with a GUID or w/e)
  • HKLM\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall
    • yes in the Uninstall folder is say Name (Default) Type REG_SZ, Data (value not set) there are hundreds of subfolders. None for chocolatey (but many with a GUID or w/e)
  • HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
    • yes in the Uninstall folder is say Name (Default) Type REG_SZ, Data (value not set) there are a dozen subfolders. None for chocolatey (but many with a GUID or w/e)
  • HKCU\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall
    • No! I get to Microsoft and there is no Windows folder after that.
      image

… So what do I do?

@ferventcoder
Copy link
Member

I'm guessing that is likely the issue. I'm going to have you try something for me.

@ferventcoder
Copy link
Member

Actually I don't have that key either. Hmmm

@ferventcoder
Copy link
Member

If you were to create the key structure, I'm guessing you are still going to run into this error.

@gooddadmike
Copy link
Author

Why me? I want to use chocolatey. What can I do? What did I do wrong? I'm thinking it must be something else if you also don't have the key.

@ferventcoder
Copy link
Member

I'm leaning towards permission on a particular key in the registry in the uninstaller group that you don't have access to. I'll work on a way to report if the key is not accessible, but in the meantime you should take a look at all of the uninstaller keys and grab the permissions for evaluation.

I believe setacl will iterate through and tell you the permissions on the registry keys so you can quickly gather all of those. https://helgeklein.com/setacl/

@gooddadmike
Copy link
Author

OK I am totally lost. I downloaded and unzipped this SetACL tool what do i do now?

@ferventcoder
Copy link
Member

@michaelsearcy apologies, I don't know the exact command to inspect the values. You are looking for viewing or auditing the keys and looking for an anomaly. Not the most fun thing in the world to do.

@gooddadmike
Copy link
Author

@ferventcoder
Copy link
Member

It is likely a subkey. I will have a build out in a bit for you to try

ferventcoder added a commit that referenced this issue Jun 20, 2015
Sometimes there may be issues accessing a key in the registry, don't
allow it to stop capturing a snapshot.

`Requested registry access is not allowed` is the error seen with
GH-335.
ferventcoder added a commit that referenced this issue Jun 20, 2015
Sometimes there may be issues accessing a key in the registry, don't
allow it to stop capturing a snapshot.

`Requested registry access is not allowed` is the error seen with
GH-335.
@ferventcoder
Copy link
Member

Pull down 0.9.9.7 and see if it warns on the error and continues.

@ferventcoder
Copy link
Member

Then we'll know if that fixes the issue you are running into and we can close this out.

@ferventcoder
Copy link
Member

@michaelsearcy ping - when you get a chance :)

@gooddadmike
Copy link
Author

OK So when you say pull down, I am assuming you mean reinstal with command line like I did @ first or downloading the source and doing my own build. I'm sorry I have limited github exposure.

@ferventcoder
Copy link
Member

@michaelsearcy sorry, I meant reinstall from the command line.

@gooddadmike
Copy link
Author

Yay!

image

So it looks like I just

choco install something -y

and that will skip?

@ferventcoder
Copy link
Member

Looks like you are moving forward now. :)

@ferventcoder ferventcoder added this to the 0.9.9.7 milestone Jun 22, 2015
@ferventcoder ferventcoder self-assigned this Jun 22, 2015
@ferventcoder
Copy link
Member

Fixed as part of #337

@gooddadmike
Copy link
Author

Thanks for working so quick on this btw

@ferventcoder
Copy link
Member

No worries - thanks for working with me to resolve the issue! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants