Table of Contents

6 Screen export and import

Screen export and import is available since Zabbix version 1.8.2.

Screen export and import controls can be found under Configuration → Screens menu, where all configured screens are displayed.

6.1 Screen exporting

In left bottom corner a selection box is available with two options: “Export selected” and “Delete selected”.

To export screens:

  1. Mark checkboxes next to screens you wish to export;
  2. Select “Export selected” if it's not selected already;
  3. Press button “Go”;
  4. Select file where Zabbix should store XML data with exported screens.

6.2 Screen importing

Importing screens is as easy as exporting them. On the top right corner near “Create Screen” button, you will find new button - “Import Screen”.

To import screens:

  1. Press “Import Screen” button. File selection along with options to control import is shown;
  2. Click the button to select XML file containing exported Zabbix screens;
  3. Check box under “Update existing” if you need to update (overwrite) existing screens;
  4. Check box under “Add missing” if you need to create new screen if it's missing;
  5. Press import to send needed data to the Zabbix frontend;
  6. Wait till page reloads. It can take some time if you have lots of screens to import or lots their elements. Zabbix frontend will inform you about import success or failure. Click on “Details” link in the left upper corner to see more detailed information about what has been done by import, or why it failed to import.
Screen import form

6.3 Exported data

Only screen structure is exported. That includes all screen settings are and all screen elements along with their configuration.

6.4 Not exported data

Anything included in the screen itself (like a host, hostgroup or any other data) is not exported.

When importing a screen, if any of the referenced elements is missing, import will fail, for example, with:

Cannot find trigger "child_node5: ZBXHost:DOUBLE CHECK" used in exported screen "Link Screen"

6.5 XML format - screen definition

Screen export consists of screen definition itself and any additional elements.

<screens>
  <screen>
    <name>Screen name</name>
    <hsize>1</hsize>
    <vsize>2</vsize>
    <screenitems>
      <screenitem></screenitem>
      ...
      <screenitem></screenitem>
    </screenitems>
  </screen>
</screens>

6.6 XML format - screen elements

Available screen elements and their IDs.

6.7 XML format - available element tags

Bold text - mandatory tag for all elements;
Normal text - tag available for all elements;
Italic text - tag optionally available for some elements (see below for details).

If <resourceid> refers to an object by name, it can have subtags. If data is exported from a distributed setup installation, node will always be identified by name:

<node>Zabbix node</node>

For example, Simple graph <resourceid> entry from a non-distributed setup would look like this:

<resourceid>
  <host>Zabbix server</host>
  <key_>system.cpu.load</key_>
</resourceid>

In a distributed setup, it becomes:

<resourceid>
  <node>Zabbix node</node>
  <host>Zabbix server</host>
  <key_>system.cpu.load</key_>
</resourceid>

Individual object references are listed at each element.

6.8 XML format - individual screen element details, A-Z

Each individual element must have mandatory tags from the previous section and may have tags that are available for all elements. If there are additional tags available for the specific element, they are listed here.

6.8.1 Clock

Resource type 7. Additional tags:

6.8.2 Data overview

Resource type 10. Additional tags:

Available <resourceid> contents:

<name>Linux servers</name>
6.8.3 Graph

Resource type 0. Additional tags:

Available <resourceid> contents:

<host>Zabbix host</host>
<name>Graph name</name>
6.8.4 History of actions

Resource type 12. Additional tags:

6.8.5 History of events

Resource type 13. Additional tags:

6.8.6 Hosts info

Resource type 4. Additional tags:

Available <resourceid> contents:

<name>Linux servers</name>
6.8.7 Map

Resource type 2. Additional tags:

Available <resourceid> contents:

<name>City map</name>
6.8.8 Plain text

Resource type 3. Additional tags:

Available <resourceid> contents:

<host>Zabbix server</host>
<key_>system.cpu.load</key_>
6.8.9 Screen

Resource type 8. Additional tags:

Available <resourceid> contents:

<name>Application servers screen</name>
6.8.10 Server info

Resource type 6. No additional tags available.

6.8.11 Simple graph

Resource type 1. Additional tags:

Available <resourceid> contents:

<host>Zabbix server</host>
<key_>system.cpu.load</key_>
6.8.12 Status of host triggers

Resource type 16. Additional tags:

Available <resourceid> contents:

<host>aleksei_host</host>
6.8.13 Status of hostgroup triggers

Resource type 14. Additional tags:

Available <resourceid> contents:

<name>aaa</name>
6.8.14 System status

Resource type 15. No additional tags available.

6.8.15 Triggers info

Resource type 5. Additional tags:

Available <resourceid> contents:

<name>aaa</name>
6.8.16 Triggers overview

Resource type 9. Additional tags:

Available <resourceid> contents:

<name>aaa</name>
6.8.17 URL

Resource type 11. Additional tags:

6.9 XML export example

The following is a simple screen (2×2), exported to XML. It contains one custom graph in upper left cell (spanning two columns), one simple graph in the lower left cell and trigger status element, filtered for a hostgroup, in the lower right cell. Notice the encoding of & as &amp;.

<?xml version="1.0" encoding="UTF-8"?>
<screens>
  <screen>
    <name>Excellent screen</name>
    <hsize>2</hsize>
    <vsize>2</vsize>
    <screenitems>
      <screenitem>
        <resourcetype>0</resourcetype>
        <resourceid>
          <host>Zabbix server</host>
          <name>CPU Load &amp; traffic</name>
        </resourceid>
        <width>1000</width>
        <height>100</height>
        <x>0</x>
        <y>0</y>
        <colspan>2</colspan>
        <rowspan>0</rowspan>
        <elements>0</elements>
        <valign>0</valign>
        <halign>0</halign>
        <style>0</style>
        <dynamic>0</dynamic>
      </screenitem>
      <screenitem>
        <resourcetype>1</resourcetype>
        <resourceid>
          <host>Zabbix server</host>
          <key_>zabbix[uptime]</key_>
        </resourceid>
        <width>500</width>
        <height>90</height>
        <x>0</x>
        <y>1</y>
        <colspan>0</colspan>
        <rowspan>0</rowspan>
        <elements>0</elements>
        <valign>0</valign>
        <halign>0</halign>
        <style>0</style>
        <dynamic>0</dynamic>
      </screenitem>
      <screenitem>
        <resourcetype>14</resourcetype>
        <resourceid>
          <name>Linux servers</name>
        </resourceid>
        <width>500</width>
        <height>100</height>
        <x>1</x>
        <y>1</y>
        <colspan>0</colspan>
        <rowspan>0</rowspan>
        <elements>25</elements>
        <valign>0</valign>
        <halign>0</halign>
        <style>0</style>
        <dynamic>0</dynamic>
      </screenitem>
    </screenitems>
  </screen>
</screens>