SPContentTypeCollection
(1)
SPContentType
(1)
SPList
(1)
SharePoint
(1)
Export.ImportExport.button2
(1)
IsParentSystemObject
(1)
ContentTypeID
(1)
ImportObjectManager
(1)

A duplicate name "Item" was found

Asked By svenderuyte
05-Sep-07 02:40 AM
Hello,

I'm building a SharePoint 2007 site since 2 or 3 months or so. Now, all of
the sudden, when I try to create a new site collection of type "Collaboration
Portal" (publishing site), I get the following error (+ call stack):

Portal provisioning handler callout failed. Exception:
Microsoft.SharePoint.SPException: Provisioning did not succeed. Details: The
site template was not provisioned successfully. Delete this site collection
in Central Administration, and then create a new site collection.
OriginalException: Provisioning did not succeed. Details: Failed to create
the 'Cache Profiles' list. OriginalException: A duplicate name "Item" was
found. ---> Microsoft.SharePoint.SPException: Provisioning did not succeed.
Details: Failed to create the 'Cache Profiles' list.

at Microsoft.SharePoint.SPContentTypeCollection.CheckConsistency()
at Microsoft.SharePoint.SPContentTypeCollection.Update()
at Microsoft.SharePoint.SPContentTypeCollection.Add(SPContentType contentType)
at
Microsoft.SharePoint.Publishing.Internal.ProvisioningHelper.AddContentType(SPContentTypeCollection contentTypes, SPContentType contentType)
at
Microsoft.SharePoint.Publishing.Internal.ProvisioningHelper.AddContentTypeToList(SPList list, SPContentType contentType)
at
Microsoft.SharePoint.Publishing.Internal.ProvisioningHelper.ReplaceAllContentTypesOnList(SPList list, SPContentType contentType)
at
Microsoft.SharePoint.Publishing.Internal.RootProvisioner.CreateCacheProfilesList()

(I have more if you want...)

Anyone have any idea how this can suddenly happen? I haven't found any
threads about this problem on the forums, and googling only gave me 2 or 3
results with other people having this problem, but never a solution... As you
can imagine this is a big problem because I can't seem to enable Publishing
anymore! (the same problem appears when activating the Publishing
Infrastructure feature)

Any comments are welcome!

Sven

OK... I managed to solve this problem!

Asked By svenderuyte
05-Sep-07 04:44 AM
OK... I managed to solve this problem! It has cost me a few hours but I'm
glad to have it working again.

When I looked at the site content types on an existing site, I noticed that
a lot of default content types (like tasks, announcements, etc) were just not
in the list. Only "Item", "Document" and all content types deriving from
that derives from "Item"). So I thought: maybe something's wrong with the
content types. So deactivating and activating the CTYPES feature was my next
option... no luck :(. Then I remembered that I had just added some content
types in a feature. I noticed that, in the ContentTypeID, I forgot to add two
zero's (00) to the parent ContentTypeID before adding my own GUID. I couldn't
deactivate my ContentTypes feature anymore (it threw an exception saying it
couldn't find the parent contenttype), so I edited my contenttypes.xml file
directly in the 12\TEMPLATE\FEATURES directory and added the necessary 00's.
Then I did an IISRESET and voila, my default content types were back and I
was again able to create Publishing sites!

Hope this helps someone!

Sven

A duplicate name "Item" was found while deploying content

Asked By Roberto Sandriano
18-Sep-07 08:30 AM
Hi Sven,



I get similar exception while deploying content from source to destination. Any help would be highly appreciated.



A duplicate name "LoginContentType" was found.    Stack Trace:    at Microsoft.SharePoint.SPContentTypeCollection.Add(SPContentType contentType)

at Microsoft.SharePoint.Deployment.ContentTypeSerializer.CreateContentType(SPContentType sourceContentType)

at Microsoft.SharePoint.Deployment.ContentTypeSerializer.ProcessContentType(SPContentType sourceContentType, String contentTypeXml, ImportObjectManager importObjectManager, Boolean IsParentSystemObject)

at Microsoft.SharePoint.Deployment.ContentTypeSerializer.SetObjectData(Object obj, SerializationInfo info, StreamingContext context, ISurrogateSelector selector)

at Microsoft.SharePoint.Deployment.XmlFormatter.ParseObject(Type objectType, Boolean isChildObject)

at Microsoft.SharePoint.Deployment.XmlFormatter.DeserializeObject(Type objectType, Boolean isChildObject, DeploymentObject envelope)

at Microsoft.SharePoint.Deployment.XmlFormatter.Deserialize(Stream serializationStream)

at Microsoft.SharePoint.Deployment.ObjectSerializer.Deserialize(Stream serializationStream)

at Microsoft.SharePoint.Deployment.ImportObjectManager.ProcessObject(XmlReader xmlReader)

at Microsoft.SharePoint.Deployment.SPImport.DeserializeObjects()

at Microsoft.SharePoint.Deployment.SPImport.Run()

at Export.ImportExport.button2_Click(Object sender, EventArgs e)
Post Question To EggHeadCafe