| Previous | Next |
| WCM_E_SUBSTITUTIONNOTFOUND | WCM_E_USERNOTFOUND |
WCM_E_USERALREADYREGISTERED
WCM_E_USERALREADYREGISTERED is the failure HRESULT 0x80220012 (signed decimal -2145255406, unsigned decimal 2149711890). Its severity bit is 1, facility is 34 (FACILITY_STATE_MANAGEMENT), and the facility-specific code field is 0x0012.
AllStat records the Windows SDK description as “User is already registered.”
Documented meaning
The SMI user registration already exists. The operation reached registration of per-user settings identity for a user that already has an entry. The first branch to test is whether initialization runs twice for the same user; keep that separate from the possibility that two deployment workers race to register one identity.
Operation phase
At this boundary, capture stable user identity/SID and target image, then correlate it with existing user entries and their status. Assign ownership only after checking process and thread performing each registration attempt.
Root-cause branches
- initialization runs twice for the same user
- two deployment workers race to register one identity
- recovery retries registration without checking the previous outcome
- the caller uses a different textual account form that resolves to the same user
Diagnostic record
- stable user identity/SID and target image
- existing user entries and their status
- process and thread performing each registration attempt
- whether the first operation committed before a later timeout
- transaction or settings-context boundaries around registration
Correction workflow
- treat an existing matching registration as idempotent only after verifying its identity and status
- serialize per-user registration in the deployment coordinator
- query before creating when the API supports that workflow
- do not delete a valid entry merely to make repeated initialization succeed
- separate duplicate registration from stale or corrupt user state
Retry policy
A retry that repeats registration is inappropriate. Continue with the existing entry if it matches the intended user, or repair a mismatched registration explicitly.
Nearby HRESULT distinctions
WCM_E_USERNOTFOUND is the inverse lookup/removal condition. USERALREADYREGISTERED confirms an entry exists and blocks duplicate creation.
Concrete example
Setup resumes after a restart and reruns the same per-user initialization. The second registration sees the committed entry from the first pass.
Operational logging
For operational telemetry, retain process and thread performing each registration attempt; also record whether the first operation committed before a later timeout. Preserve a redacted summary of transaction or settings-context boundaries around registration; use a cryptographic hash when that evidence is a file, stream, or generated artifact.
Official Microsoft references.
- Microsoft: SMI error and success constants.
- Microsoft: Settings Management Infrastructure API.
- Microsoft: SMI interfaces.
- Microsoft: ISettingsEngine::GetNamespace.
- Microsoft: ISettingsContext::Deserialize.
Looking for a different code? Search another status or error code.