Administrator's Guide (PDF)

MarkLogic 10 Product Documentation
Administrator's Guide
— Chapter 4

« Previous chapter
Next chapter »

Starting and Stopping MarkLogic Server

Use the following procedures to start and stop MarkLogic Server:

Starting the Server

To start MarkLogic Server, use the appropriate system command for your platform:

Platform Command
Microsoft Windows Select Start > Programs > MarkLogic Server > Start MarkLogic Server

When you start MarkLogic Server from the Start menu, the Windows service configuration for MarkLogic Server is set to start automatically. Also, if you are using Windows, to start the service you must right-click the Start MarkLogic Server link in the Start menu and choose Run as Administrator, then choose to allow the action.

Red Hat Linux
/sbin/service MarkLogic start
Mac OS X
~/Library/StartupItems/MarkLogic start

Stopping the Server

There are two ways to perform a clean shutdown of MarkLogic Server:

Using System Command to Stop MarkLogic Server

You can stop MarkLogic Server with the appropriate system command for your platform:

Platform Command
Microsoft Windows Select Start > Programs > MarkLogic Server > Stop MarkLogic Server

If you are using Windows, to stop the service you must right-click the Stop MarkLogic Server link in the Start menu and choose Run as Administrator, then choose to allow the action.

Red Hat Linux
/sbin/service MarkLogic stop
Mac OS X
~/Library/StartupItems/MarkLogic stop

Using the Admin Interface to Stop MarkLogic Server

To stop the server from the Admin Interface, complete the following procedure:

  1. Click the Hosts icon on the left tree menu.
  2. Click on the name of the host you want to shut down.
  3. Click the Status tab on the top right.
  4. Click Shutdown.
  5. A confirmation message displays while shutting down. Click OK to shut down the server.

    MarkLogic Server must be running in order for you to use the Admin Interface. Once you have stopped the server, you will no longer be able to access the Admin Interface until you start MarkLogic Server again; to restart the server, run the system command for your platform as described in Starting the Server.

Restarting the Server

To restart the server from the Admin Interface, complete the following procedure:

  1. Click the Configure icon on the left tree menu.
  2. Click the Status tab on the top right.
  3. Click Restart.
  4. A confirmation message displays while restarting. Click OK to restart MarkLogic Server.

You may also manually stop and start the server as described above.

The restart operation normally completes within a few seconds. It is possible, however, for it to take longer under some conditions (for example, if the Security database needs to run recovery or if the connectivity between hosts in a cluster is slow). If it takes longer than a few seconds for MarkLogic Server to restart, than the Admin Interface might return a 503: Service Unavailable message. If you encounter this situation, wait several seconds and then reload the Admin Interface.

Example XQuery Scripts

This section provides the following XQuery scripts:

Script that Restarts MarkLogic Server

The following script restarts MarkLogic Server:

xquery version "1.0-ml";
xdmp:restart((), "Restarting MarkLogic Server")

Script that Stops MarkLogic Server

The following script stops MarkLogic Server:

xquery version "1.0-ml";
xdmp:shutdown((), "Shutting Down MarkLogic Server")
« Previous chapter
Next chapter »
Powered by MarkLogic Server | Terms of Use | Privacy Policy