-
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:
pgsqlError generating an asymmetric key.
Exception message: Key not valid for use in specified state.
-
-
Network Connectivity Checks
-
Test-NetConnection login.microsoftonline.com –Port 443: Succeeded -
Test-NetConnection *.servicebus.windows.net –Port 443: Name resolution failed
-
-
Antivirus & Service Interference
-
Temporarily disabled Kaspersky→ error persisted.
-
Verified that the “On-premises data gateway service (personal mode)” never reached a Running state.
-
-
DPAPI & Crypto Permissions
-
Ran in elevated CMD:
baticacls "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.”
-
-
DISM / SFC Health Repairs
-
DISM
/Online /Cleanup-Image /RestoreHealthstalled 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).
-
-
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.
-
-
File & Folder Audits
-
Verified no hidden files in
MachineKeysfolder (where DPAPI stores its keys). -
Confirmed no leftover gateway keys or config data under
%ProgramData%\Microsoft\On-premises data gateway.
-
-
Windows Crypto Subsystem Diagnostics
-
Confirmed no Kerberos or DPAPI errors in Event Viewer.
-
Tried restarting the “Cryptographic Services” (
CryptSvc) → no change.
-
Current Failure:
Every installer run culminates in the same DPAPI-related exception:
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
-
DPAPI Deep-Dive: Investigate DPAPI master key store under
C:\ProgramData\Microsoft\Crypto\RSA\MachineKeysand the Local System profile’s key container. -
In-Place Repair Install: Perform an in-place Windows repair (keep apps & data) to fully restore the crypto subsystem.
-
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.
Please let me know if any additional logs or configurations are needed.


Report
All responses (
Answers (