Cms2xp failing when exporting user store

Enonic version: 4.7
OS: Ubuntu

cms2xp fails with message “Export failed” and “Multiple entries with same key”.


[main] INFO com.enonic.cms2xp.hibernate.UserStoreRetriever - User store loaded: default
[main] INFO com.enonic.cms2xp.hibernate.UserStoreRetriever - User store loaded: medlemmer
[main] ERROR com.enonic.cms2xp.migrate.ExportData - Export failed.
java.lang.IllegalArgumentException: Multiple entries with same key: user:medlemmer:“username”[email protected] and user:medlemmer:“username”[email protected]
at com.enonic.cms2xp.export.UserStoreExporter.export(
at com.enonic.cms2xp.migrate.ExportData.exportUserStores(
at com.enonic.cms2xp.migrate.ExportData.execute(
at com.enonic.cms2xp.Main.main(

Any ideas?

(User name replaced with “username” in stacktrace above.)

Looks like somehow it has found 2 users with the same name and user store, in the database. Which shouldn’t be allowed :confused:
Are those 2 “username” with the same case?
Is there maybe one lower case and one upper case when you look at the user in the CMS?

Anyway it should be handled so that the export can continue. We will fix it and tag a new cms2xp version.

When I search for the user in CMS it only shows up one user.

Will be looking out for the new version. Thanks!

There is a new cms2xp tag available that should fix this issue.

You can download it and build from sources from Github or just download the zip distribution from Enonic repo.

Please let us know if it works.

Great! Thanks a lot!