PSRemoteregistery

This topic contains 4 replies, has 2 voices, and was last updated by Profile photo of NetAdminTX NetAdminTX 2 years, 1 month ago.

  • Author
    Posts
  • #19726
    Profile photo of NetAdminTX
    NetAdminTX
    Participant

    I am trying to use the PS Remote Registry module to retrieve the value of a registry item on a series of remote PCs
    I have verified that the key exists but the PS cmdlet still returns an error... perhaps I have a syntax error?

    PS > get-regvalue -computername 7mjlcx1 -key \software\wow6432node\nbsi\sysdll\termID

    get-regvalue : Key '\software\wow6432node\nbsi\sysdll\termID\' doesn't exist.
    At line:1 char:1
    + get-regvalue -computername 7mjlcx1 -key \software\wow6432node\nbsi\sysdll\termID ...
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException
    + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Get-RegValue

  • #19727
    Profile photo of Daniel Krebs
    Daniel Krebs
    Participant

    Hi NetAdminTX,

    The function should work if you remove the backslash before software and the Remote Registry service is running on the remote computer.

    get-regvalue -computername 7mjlcx1 -key software\wow6432node\nbsi\sysdll\termID
    

    Best,
    Daniel

  • #19734
    Profile photo of NetAdminTX
    NetAdminTX
    Participant

    Removed backslash – still see in the error
    Verified the remote registry service and verified the key exists

    PS C:\users\ahollister\desktop\registry_pull> get-regvalue -computername 7mjlcx1 -key software\wow6432node\nbsi\sysdll\t
    ermID\
    get-regvalue : Key 'software\wow6432node\nbsi\sysdll\termID\' doesn't exist.
    At line:1 char:1
    + get-regvalue -computername 7mjlcx1 -key software\wow6432node\nbsi\sysdll\termID\
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException
    + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Get-RegValue

    PS C:\users\ahollister\desktop\registry_pull> get-service -computername 7mjlcx1 -name RemoteRegistry

    Status Name DisplayName
    —— —- ———–
    Running RemoteRegistry Remote Registry

    PS C:\users\ahollister\desktop\registry_pull>

  • #19739
    Profile photo of Daniel Krebs
    Daniel Krebs
    Participant

    Thanks for the screenshot. "TermID" is not a key but a value of the "SYSDLL" key. Please test if below returns the correct result.

    Get-RegValue -ComputerName 7mjlcx1 -Key SOFTWARE\Wow6432Node\NBSI\SYSDLL -Value TermID
    
  • #19741
    Profile photo of NetAdminTX
    NetAdminTX
    Participant

    that fixed it, Ill make the changes in the script and test it out tomorrow thanks

You must be logged in to reply to this topic.