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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

How to fix this error: "AX is shutting down due to an error. Some models have duplicate ids."?

(0) ShareShare
ReportReport
Posted on by 115

I already did the solution as suggested here in this post: https://community.dynamics.com/ax/f/33/t/190957

However, I'm still getting the error even though the specified folder in the Error log has already been deleted. Here is the Error log:

AX is shutting down due to an error.
Some models have duplicate ids. Models 'CustomModelGlobalAddressBook (C:\Packages\Directory\CustomModelGlobalAddressBook), AX 7 Test Environment (C:\Packages\ApplicationSuite\AX 7 Test Environment)' share id 855991.

Exception details:
Microsoft.Dynamics.AX.Metadata.MetadataCorruptedException: Some models have duplicate ids. Models 'CustomModelGlobalAddressBook (C:\Packages\Directory\CustomModelGlobalAddressBook), AX 7 Test Environment (C:\Packages\ApplicationSuite\AX 7 Test Environment)' share id 855991.
at Microsoft.Dynamics.AX.Metadata.Storage.ErrorReportingHelper.ThrowDuplicateModelIdException(List`1 modelsGroupedByIds, String rootMetadataPath)
at Microsoft.Dynamics.AX.Metadata.Storage.MetadataStorageUtility.ThrowIfModelsShareId(IEnumerable`1 models, String rootMetadataPath)
at Microsoft.Dynamics.AX.Metadata.Storage.Runtime.RuntimeModelManifestProvider.Cache.AllModelsIdToModelNoCache()
at System.Lazy`1.CreateValue()
at System.Lazy`1.LazyInitValue()
at Microsoft.Dynamics.AX.Metadata.Storage.Runtime.SingleKeyedRuntimeProvider`1.GetPrimaryKeysWithModelInfo()
at Microsoft.Dynamics.AX.Metadata.Storage.ExtensionLoader`1.<Flush>b__1()
at System.Lazy`1.CreateValue()
at System.Lazy`1.LazyInitValue()
at Microsoft.Dynamics.AX.Metadata.Storage.ExtensionLoader`1.GetExtensionNames(String name)
at Microsoft.Dynamics.AX.Metadata.Storage.ExtensionLoader`1.GetExtensionsForBaseObject(String baseObjectName)
at Microsoft.Dynamics.AX.Metadata.Storage.Runtime.SingleKeyedRuntimeExtensionProvider`2.ReadNoCache(String name)
at Microsoft.Dynamics.AX.Metadata.Storage.Runtime.SingleKeyedRuntimeProvider`1.Read(String name, MetaReadHeader& readHeader)
at Microsoft.Dynamics.AX.Metadata.Kernel.Accessor.GetTable(String name)
at MetadataBridge.CMetadataProxy.GetTable(Char* name, CAxTable* buf)
at gopts(Int32 , Char** )
at Microsoft.Dynamics.AX.AOS.StartupInternal(String[] Arguments)

 


One more question though, what is the best way to delete a user created model? It seems like deleting the model in the package folder and in the descriptor seems to be incomplete. Is there no official steps on how to do this?

*This post is locked for comments

I have the same question (0)
  • Verified answer
    André Arnaud de Calavon Profile Picture
    303,691 Super User 2026 Season 1 on at

    Hi Harvey,

    Did you do a full build of all models after removing the model with the duplicate element?

  • iridescence Profile Picture
    115 on at

    Hi Andre,

    I did build my solution before I actually access the AX, no errors popped up or anything. And then when I access the AX, the error stated above appears.

    Anyway, at this moment I have also deleted the my solution since I'm just testing it for my learning.

  • André Arnaud de Calavon Profile Picture
    303,691 Super User 2026 Season 1 on at

    When there is a compilation issue and the build is not correct, you can indeed have this startup issue.

    Is AX running correctly now without your solution? If so, you can try put the solution back and prevent having the duplicate object.

  • iridescence Profile Picture
    115 on at

    Hi Andre,

    Yes, the AX is working now. I just did another build.

    But, is there really no standard way of deleting models that I've created? I guess I won't be deleting my newly created models, too much hassle.

  • André Arnaud de Calavon Profile Picture
    303,691 Super User 2026 Season 1 on at

    Hi Harvey,

    Deleting the models is indeed by using the file explorer. Note that if you don't delete them, it will be considered during builds.

  • iridescence Profile Picture
    115 on at

    Hi Andre,

    I see. Thanks.

  • Community Member Profile Picture
    on at

    Hi Andre,

    Is it possible element provided by Microsoft lets say CustTable exist in two models? like applicationsuite and some another.

    If yes then which element should I delete? I am getting similar errors during build.

    And one last thing if I delete all models then will it regenerate models again on full build? ( I think it will not generate ) Lets take application suit I delete then it will give me compilation errors while building or if I replace all models with which I am not getting any errors and then build my environment having errors will it work (I mean successful build)?

    I am not still clear with AX 7 functionalities. It will be helpful if you can answer.

    Thanks!

    Regards,

    Smit Patel

  • André Arnaud de Calavon Profile Picture
    303,691 Super User 2026 Season 1 on at

    Hi Smit,

    I do think this question is the same as within another thread you created. An object can be only in one model. As mentioned in the other thread it would be easier to deploy a new fresh VM to get rid of your problems.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Joris dG Profile Picture

Joris dG 5

#2
Alexey Lekanov Profile Picture

Alexey Lekanov 2

#2
Henrik Nordlöf Profile Picture

Henrik Nordlöf 2 User Group Leader

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans