Remote Registry service and Get-DbaProductKey

  • Hello ,

    I have to do an SQL license audit I try to use the command dbatools Get-DbaProductKey

    except that this command requires starting the Remote Registry service

    AVERTISSEMENT : [09:59:19][Get-DbaProductKey] Can't access registry for DESKTOP-95KKMMH. Is the Remote Registry service started?
    AVERTISSEMENT : [09:59:21][Find-DbaInstance] Failed to execute Service Principal Name discovery | Exception lors de l'appel de « FindAll » avec « 0 » a
    rgument(s) : « Le domaine spécifié n’existe pas ou n’a pas pu être contacté.

    how I can use this command without starting this service

    Sans titre


    thanks for your help



  • Is the service running on the remote server?   The screenshot says "Local" so I wasn't sure...

    First thing I'd check is if the remote server has Remote Registry enabled.

    If that service is not running, the command won't work.  There is no way around that.  Well, one way around it would be to run the command on the physical server as then you aren't accessing a remote machine and as such don't need remote registry (just need permissions to read the registry).

  • My recommendation would be to contact the people that wrote the "Get-DbaProductKey" PoSh snippet and ask them.

    --Jeff Moden

    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.
    "Change is inevitable... change for the better is not".
    "Dear Lord... I'm a DBA so please give me patience because, if you give me strength, I'm going to need bail money too!"

    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply