Loading TOC...
Administrator's Guide (PDF)

Administrator's Guide — Chapter 3

Common Administrative Procedures

This chapter describes some of the common administrative procedures for MarkLogic Server and where you can find more details on each procedure.

The common administrative procedures are:

Installing and Upgrading MarkLogic Server

MarkLogic Server runs on a variety of platforms. For a list of support platforms and installation procedures, see the Installation Guide

For issues and procedures related to upgrading MarkLogic Server, see:

Starting and Stopping MarkLogic Server

The start, stop, and restart operations for MarkLogic Server are described in Starting and Stopping MarkLogic Server.

Creating and Configuring Forests and Databases

MarkLogic Server stores XML, JSON, XQuery, and JavaScript data in forests. App Servers connect to a database that, in turn, accesses one or more forests.

Several types of auxiliary databases are created when you install MarkLogic Server, which are described in Understanding Databases. This section outlines the general procedures for creating a database to store your documents.

To create a database to store your documents, do the following:

  1. Create one or more forests, as described in Creating a Forest. Depending on your storage, performance, and availability needs, you may want to create multiple forests, each on a separate host. See the Scalability, Availability, and Failover Guide for details.
  2. Follow the procedure described in Creating a New Database to create your database. Until you understand all of the database settings, you need only provide a name for the database in the Database Name field. You can leave all of the other fields in the Database Specification in their default state.
  3. Attach your forests to the database, as described in Attaching and/or Detaching Forests to/from a Database.

Creating and Configuring App Servers

An application is executed on an App Server, which is configured with a specific database, port number, and so on. Once you have created a database, you can create an App Server. MarkLogic Server allows you to create three types of App Servers to support different types of applications:

To secure your App Server using SSL, see Enabling SSL communication over XDQP in the Administrator's Guide.

Setting up Users, Roles, Privileges, and Permissions

MarkLogic Server provides a rich set of security objects that enable you to control user access to documents and applications, which are described in the Security Guide and in Security Administration in this guide.

In addition to the Security pages in the Admin UI, there are also XQuery, JavaScript, and REST functions you can use in scripts to set up and manage security objects.

Loading Content into a Database

You can load documents into the database using the load document functions, as described in the Loading Content Into MarkLogic Server Guide.

You can also set up a WebDAV server and client, such as Windows Explorer, to load your documents. See Simple Drag-and-Drop Conversion in the Content Processing Framework Guide for information on how to configure a WebDAV server to work with Windows Explorer.

Documents can also be loaded into the database by an XCC application, as described in Using the Sample Applications in the XCC Developer's Guide.

Running The XQuery Use Cases and Building Simple Applications

To test your MarkLogic Server configuration, Follow the procedure in Getting Started with MarkLogic Server for Exploring the Use Cases. The procedure uses Query Console to evaluate the W3C XQuery use cases.

For procedures on building a simple XQuery application, see Sample XQuery Application that Runs Directly Against an App Server in Getting Started with MarkLogic Server. For more in-depth information, see the Application Developer's Guide. If you are writing a Java application that communicates with MarkLogic Server through the XCC API, see the XCC Developer's Guide

Backing up and Restoring Data

You can make backups of a database, as described in Backing Up a Database, which backs up all of the forests in the database. You can also create backups of individual forests used by a database, as described in Making Backups of a Forest.

There are a number of key differences between database-level and forest-level backups. A database-level backup, by default, backs up all of the forests in the database to the specified directory. Each time a database backup is initiated, a new set of backup data is created in that directory. With a forest-level backup, each forest must be backed up to a separate directory. In addition, each incremental backup of a forest is added onto the previous backup data. A forest backup also has additional logic that checks to see if any of its stands have changed before overwriting the backup of the earlier stand. Only the stands that have changed are overwritten.

Along with full backups, you can use incremental backups and journal archiving to create backups that enable you to recover your database to a specific point in time. For details, see Backing Up and Restoring a Database.

You can restore an entire database from a database backup, as described in Restoring a Database without Journal Archiving. You can restore an individual forest from either a database backup, as described in Restoring a Database without Journal Archiving, or from an individual forest backup, as described in Restoring a Forest.

Monitoring and Tuning Performance

For information on how to monitor the performance of MarkLogic Server, see Monitoring MarkLogic Server Performance in the Query Performance and Tuning Guide.

Factors that impact system performance include:

For details on how to tune your applications for maximum performance, see the Query Performance and Tuning Guide.

Scripting and Scheduling Administrative Tasks

MarkLogic Server includes built-in and library modules that enable you to write XQuery, JavaScript, and REST scripts that perform administrative tasks on MarkLogic Server. The functions provided by these modules enable you to script most administrative procedures.

For example, the Admin Library Module (admin.xqy) enables you to write scripts that create or modify databases, forests, App Servers, set up SSL security, and so on. The Security Library Module (security.xqy) provides a set of functions that enable you to create scripts that set up security entities. The xdmp built-in functions enable you to do forest and database backup/restore operations, as well as other database and forest management operations.

For a general overview of scripting administrative tasks, see Scripting Administrative Tasks in MarkLogic Server in the Scripting Administrative Tasks Guide. All of the available administrative functions are described in the XQuery and XSLT Reference Guide and MarkLogic REST API Reference.

You can schedule administrative scripts to be invoked at specific intervals or times, as described in Scheduling Tasks.

Configuring Clusters, Groups and Failover

A single instance of MarkLogic Server running on a single machine is called a host. You can configure multiple hosts into a cluster, as described in the Scalability, Availability, and Failover Guide. Within a cluster, you can create groups of similarly configured hosts, as described in Groups. Different configurations of grouped hosts are useful when different groups of hosts perform different tasks or have different system capabilities.

Should a host go down, its duties can be resumed by another host in the cluster. MarkLogic provides support for failover, which allows the forest to automatically mount to a different host in the event of a forest's primary host going offline. For details on configuring forests for failover, see High Availability of Data Nodes With Failover and Configuring Shared-Disk Failover for a Forest in the Scalability, Availability, and Failover Guide.

« Previous chapter
Next chapter »