web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Power BI Data Gateway ...
Power Automate
Unanswered

Power BI Data Gateway (Personal Mode)

(0) ShareShare
ReportReport
Posted on by
Hi
I have been running a Power Bi Gateway on a Windows 10 desktop to link local excel file and website downloads to my Power BI model.
I have upgraded to a new Windows 11 machine and have tried to install the Personal Gateway but get an error 'Error generating an asymmetric key. Exception message: Key not valid for use in specified state. '
I have treid extensive fixes with no success (see below for summary) and woudl greatly appreciate help to resolve
Kind regards
Ian 
 
  1. Gateway Installation Attempts

     

    •  

      Installed Power BI On-premises Data Gateway (Personal mode) as Administrator multiple times.


    •  

      Each time, setup failed at ~62–63% during “CreateAndUpdateLocalService” with:

       
       
      pgsql
      Error generating an asymmetric key.
      Exception message: Key not valid for use in specified state.


    •  

  2.  

    Network Connectivity Checks

     

    •  

      Test-NetConnection login.microsoftonline.com –Port 443: Succeeded


    •  

      Test-NetConnection *.servicebus.windows.net –Port 443: Name resolution failed



    •  

  3.  

    Antivirus & Service Interference

     

    •  

      Temporarily disabled Kaspersky→ error persisted.


    •  

      Verified that the “On-premises data gateway service (personal mode)” never reached a Running state.



    •  

  4.  

    DPAPI & Crypto Permissions

     

    •  

      Ran in elevated CMD:

       
       
      bat
      icacls "C:\ProgramData\Microsoft\Crypto\RSA\MachineKeys" /grant "NT SERVICE\PBIEgwService":(M) /t
      icacls "C:\ProgramData\Microsoft\Crypto\RSA\MachineKeys" /grant "Administrators":(M) /t

    •  

      Confirmed “Successfully processed 1 files; Failed processing 0 files.”



    •  

  5.  

    DISM / SFC Health Repairs

     

    •  

      DISM /Online /Cleanup-Image /RestoreHealth stalled at ~62% for >30 minutes.


    •  

      Checked dism.log—no new errors beyond long processing times.


    •  

      Ran SFC /scannow → Completed successfully, repaired only broken shortcuts (no core DLL errors).



    •  

  6.  

    Gateway Reinstallation Variants

     

    •  

      Completely uninstalled Personal Gateway, removed leftover files and registry entries, rebooted, then reinstalled as Admin → same asymmetric-key error.


    •  

      Tried both Personal and Standard (“cluster”) gateway installers → Personal mode always fails; Standard installs but isn’t usable for per-user scenarios.



    •  

  7.  

    File & Folder Audits

     

    •  

      Verified no hidden files in MachineKeys folder (where DPAPI stores its keys).


    •  

      Confirmed no leftover gateway keys or config data under %ProgramData%\Microsoft\On-premises data gateway.



    •  

  8.  

    Windows Crypto Subsystem Diagnostics

     

    •  

      Confirmed no Kerberos or DPAPI errors in Event Viewer.


    •  

      Tried restarting the “Cryptographic Services” (CryptSvc) → no change.



    •  


  9.  
 
 

Current Failure:

Every installer run culminates in the same DPAPI-related exception:

 
 
pgsql
Error generating an asymmetric key.
Exception message: Key not valid for use in specified state.
 

That indicates the system’s DPAPI key store is still corrupt or inaccessible, which prevents the gateway from generating its required service key.

 
 

Suggested Next Steps for Microsoft / Windows Specialist

 

  1.  

    DPAPI Deep-Dive: Investigate DPAPI master key store under C:\ProgramData\Microsoft\Crypto\RSA\MachineKeys and the Local System profile’s key container.


  2.  

    In-Place Repair Install: Perform an in-place Windows repair (keep apps & data) to fully restore the crypto subsystem.


  3.  

    Alternate Machine: As a control test, install the Personal gateway on a known-good Windows build (e.g., a freshly imaged VM) to confirm the installer itself isn’t at fault.



  4.  
 

Please let me know if any additional logs or configurations are needed.

 
 
Categories:
I have the same question (0)
  • stampcoin Profile Picture
    5,058 Super User 2025 Season 2 on at

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 525 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 324 Moderator

#3
abm abm Profile Picture

abm abm 232 Most Valuable Professional

Last 30 days Overall leaderboard