Skip to content
This repository has been archived by the owner on Dec 20, 2018. It is now read-only.

Migrating User Data from Identity 2.2.1 to 3.x #1102

Closed
fabich opened this issue Feb 13, 2017 · 5 comments
Closed

Migrating User Data from Identity 2.2.1 to 3.x #1102

fabich opened this issue Feb 13, 2017 · 5 comments

Comments

@fabich
Copy link

fabich commented Feb 13, 2017

Hey all
Is it possible to migrate data from Identity 2.2.1 to 3.x?

I found the following discussion, not sure what current status is.
dotnet/efcore#2167

Migrating only the passwords would be enough for now if complete migration doesn't work.

Thanks for your help

@HaoK
Copy link
Member

HaoK commented Feb 13, 2017

I believe it should just work, @divega any known issues with migrating EF6 dbs to EFCore?

@HaoK
Copy link
Member

HaoK commented Feb 13, 2017

Also see #682 for more details:

Specifically the flow that should work is:

Run Enable-Migrations/ensure that an initial migration is created (for your existing 2.2.1 schema)
Install AspNet.Identity.CoreCompat and include the compat namespace to rebase the Identity POCO
Run migrations using EF6 to update schema to V3

Then Identity 3 should be able to read the new schema

@fabich
Copy link
Author

fabich commented Feb 14, 2017

@HaoK does that imply that I have to use the old PasswordHasher?
services.Configure(options => options.CompatibilityMode = PasswordHasherCompatibilityMode.IdentityV2);

@blowdart
Copy link
Member

@fabich No, the new one understands both formats, and will even go as far as rehashing to the more secure hash algorithm upon login.

@xrkolovos
Copy link

xrkolovos commented May 30, 2017

I tryied this with my data and it didn't seems to work. Is there any guidance about this?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants