Error ( file not found) When Trying to Activate SharePoint Server Publishing Feature

I needed to activate Publishing feature in a sub site which I got newly created but it occurred an error as below which I was not able to go ahead.

“Error ( file not found) when trying to activate office SharePoint server publishing feature”.


checked the Alternate Access mappings (AAM) as I was accessing this site externally. I have been forgot to include the URL Entry in External Zone. tried again to activate the feature after adding URL and the error disappeared.


Make sure you have configured AAM for your Site collections once you created them.