MDS Errors while making portal administration changes in Oracle WebCenter Portal (WCP)

26

Aug 2016

MDS Errors while making portal administration changes in Oracle WebCenter Portal (WCP)

1979403

Issue:

 

While editing an existing attribute in Web center portal, I faced the below errors. Then I tried to make some other changes and pretty much every administrative change to Portal attributes or navigation failed with the same error.

 

Screenshot of the error:

8-25-2016 9-30-48 PM

 

WC_Spaces diagnostic logs had the below errors:

[WC_Spaces2] [ERROR] [] [oracle.webcenter.webcenterapp.internal.view.error.WCErrorHandlerImpl] [tid: [ACTIVE].ExecuteThread: ‘4’ for queue: ‘weblogic.kernel.Default (self-tuning)’] [userId: areddy] [ecid: 005EitPtJMb6eLWFLz3V8A0007P8001GiV,0:3] [APP: webcenter#11.1.1.4.0] [DSID: 0000LR4BaZx2rI3Lzmg8yW1NjGDJ00001v] WCS#2016.08.25.20.11.08: Error occurred while editing the custom attribute name=bpmWorkspace and value=http://soahost/bpm/workspace. ..

..

..

Caused by: oracle.mds.core.ValidationException: MDS-01611: not saving changes in MDS session because some changes are not valid MDS-02202: Content of the metadata object “/oracle/webcenter/webcenterapp/metadata/webcenter-config.xml” is not valid. MDS-02201: type validation failure for the metadata object “/oracle/webcenter/webcenterapp/metadata/webcenter-config.xml” MDS-02203: type validation error for the metadata object “/oracle/webcenter/webcenterapp/metadata/webcenter-config.xml” at the node “webcenter(xmlns(mds_ns1=http://xmlns.oracle.com/webcenter/webcenterapp))/mds_ns1:defaultSiteTemplateId[2]” Element defaultSiteTemplateId not expected MDS-02203: type validation error for the metadata object “/oracle/webcenter/webcenterapp/metadata/webcenter-config.xml” at the node “webcenter(xmlns(webcenter=http://xmlns.oracle.com/webcenter/webcenterapp))/webcenter:skin[2]” Element webcenter:skin not expected

 

Resolution:

There is no good explanation on what causes the MDS corruption but the below described work around will resolve the issue

  • Connect to the webcenter domain using WLST and run the below command to export the webcenter-config.xml file

 

exportMetadata(application=’webcenter’, server=’WC_Spaces1′,toLocation=’/tmp/ar’,docs=’/oracle/webcenter/webcenterapp/metadata/webcenter-config.xml’)

*** /tmp/ar is the temporary directory where the exported files will be saved. Adjust the directory name to your needs

 

  • Go to the temporary directory where the exported files are saved. Browse through the directory path until you find the file named webcenter-config.xml.xml

[oracle@wcphost webcenter]$ /tmp/ar/oracle/webcenter/webcenterapp/metadata/mdssys/cust/site/webcenter/webcenter-config.xml.xml

 

  • Edit the file webcenter-config.xml.xml and deleted the elements that the error above is complaining. In my example, I had to delete the lines containing defaultSiteTemplateId and skin. Make sure to delete the complete insert statement fro the elements. Once you delete the entries, save the file
  • Import the file back in to the MDS using the below WLST command

importMetadata(application=’webcenter’, server=’WC_Spaces1′,fromLocation=’/tmp/ar’,docs=’/oracle/webcenter/webcenterapp/metadata/webcenter-config.xml’)

 

  • Restart your spaces servers and go back to the portal. You should be able to perform any portal administration tasks.

 

Post Your Thoughts

Your email address will not be published. Required fields are marked *