Reset OS X Mountain Lion web server settings

I’ve been doing a fair amount of non-standard tweaking to Mountain Lion’s web services.

It’s not difficult to completely break the web server, and initially it looks like it’s near impossible to fix it unless you know exactly what you did to break it.

Fortunately, there’s a quick command you can run in the Terminal to reset the web services to their factory default settings.

Go into the Server app.

Turn off Profile Manager, Web and Wiki.

In Terminal, run the following command

sudo serveradmin command web:command=restoreFactorySettings

Then, go back in and turn on any services that you just turned off.

That’s it.

Be aware that this will completely wipe out any custom websites you may have defined – the entire web service is reset to factory defaults.

This article was posted by Kai Howells. If you liked this content and have any technical work in the Melbourne area, say hello via my contact form or give me a call on 0419 361 653 - I cover most of the greater Melbourne area and my rates are competitive.

2 Responses to Reset OS X Mountain Lion web server settings

    • Sorry for the delay in answering you – I only just noticed the comment.
      I’m not 100% sure if it will wipe out the wiki settings, however I don’t think it does (but it’d be best to have a backup just in case!)

Leave a Reply

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