Save a snapshot using Web API commands

Prev Next

Use Web API commands to save a snapshot for Disaster Recovery purposes.

All commands described in this task are typed in your web browser address bar to remotely access your ePO - On-prem server.

These are the variables in the remote command:

  • <server_name> — The DNS server name or IP address of the remote server

  • <port> — The assigned ePO - On-prem server port number, usually "8443", unless your server is configured to use a different port number

Review the following before you begin this task:

  • You are prompted for the administrator user name and password before the output appears.

  • The default name for the Snapshot task is Disaster Recovery Snapshot Server.

  • These commands are case sensitive; make sure to review them carefully for proper capitalization and syntax.

  1. The task ID is required to run the Snapshot server task; use this command if you don't know the task ID:

    https://<server_name>:<port>/remote/scheduler.listAllServerTasks?:output=terse

    Find the ID next to the Disaster Recovery Snapshot Server task. For example, ID: 2:

    OK:
    ID Name                                                                    Next Run           
    -- ----------------------------------------------------------------------- -------------------
    2  Disaster Recovery Snapshot Server                                       None     
  2. Run the Snapshot server task using the following command.

    https://<server_name>:<port>/remote/scheduler.runServerTask?taskId=2

    If the task is successful, output similar to the following appears:

    OK

    102

  3. (Optional) Confirm that the Web API server task Snapshot ran successfully.

    1. Use this command to find the Disaster Recovery Snapshot Server Task Log ID:

      https://<server_name>:<port>/remote/tasklog.listTaskHistory?taskName=Disaster%20Recovery%20Snapshot%20Server

      This command displays all Disaster Recovery Snapshot Server tasks. Find the most recent task and note the ID number. For example, ID: 102:

      ID: 102
      Name: Disaster Recovery Snapshot Server
      Start Date: [date]
      End Date: [date]
      User Name: admin
      Status: Completed
      Source: scheduler
      Duration: Less than a minute
      
    2. Use this command and the task ID number 102 to display all task log messages:

      https://<server_name>:<port>/remote/tasklog.listMessages?taskLogId=102