开发人员实验基础架构

在我的公司中,我经常遇到您需要提供某种服务以便彻底“领取”它的情况。 尽管PCshnik功能强大,但PyCharm和Chrome占用了大部分资源,很少有实验可以留在虚拟机上。


因此,我们得到了一个带有几个用于实验和本地Gitlab的服务器的小型机架。 但是出了点问题,真的想玩一些新的东西。


免责声明


我远不是新闻工作者,所以请您原谅我可能出现的文字错误。 尽管我阅读了全文,但仍然可能会错过一些内容。 始终打开以进行个人消息更正。


除其他事项外,“他们不会争论口味”,我也不会做任何广告,而只是想分享我们如何解决问题。 好吧,当然,所有这一切都可以用不同的方式完成,但是我希望那样。


歌词


一次,由于我们的客户经常使用OpenStack,我们也成功地部署了OpenStack 痛苦和眼泪 与其他人一起测试某些产品。
但是问题是办公室!= DC,我们很幸运地在每隔2-3个月稳定断电一次的地方租用一个办公室,而且,他们在晚上做这件事,直到没人看到为止。 您是否在电源故障后尝试提高OpenStack集群? 通常,该产品显然不适合我们的需求(尽管增加5-10个节点或部署ansible的整个基础架构非常方便)。


吃掉一个简单工作的群集(实际上是2-3台带有4CPU / 16GbRAM的服务器,纯粹是一个空群集)的资源,以及将控制器与计算节点保持分开以免干扰工作的需求(AIO占用了一个简单的35GB RAM,这很令人失望)对于办公室中的服务器来说太多了)。


当然,一切都可以在AWS / DO / Azure / GCE中进行,但是如果有3-4台服务器,那为什么不使用它们,因为无论如何,现有设备的价格会比“云”便宜。


配套设备


实际上关于铁:


  1. 落地柜KRAULER KRC6832
  2. 4U日立HA8000 / RS440(AG)4个Intel Xeon X7460(6C / 6T)/ 160GB / 4个内存提升卡/ 4个2.5“ HDD 1TB SATA + 4个2.5” HDD 0.5TB SATA / LSI RAID 0-1-5-6 / 6xGLAN / 2xPSU 1570W(我不知道为什么会有这样的PSU,如果他在满载情况下从来不超过500W)
  3. APC Smart-UPS 3000VA RM 2U UPS
  4. Mikrotik云路由器交换机125-24G-1S-RM(这不是办公室基础架构的核心-只是机架)
  5. SSD WD蓝色500Gb SATA

除其他外,还有:


  1. 服务器1U Fujitsu RX100S6 Intel Core i3-540 / 16 GB DDR-3 ECC / 2x 3.5“ HDD 147Gb SAS / LSI Raid 0-1 / 2xGlan / PSU 250W(运行Gitlab CE)
  2. 板载Intel Xeon X3430的1U Nec Express 5800 / R110c服务器,其规格如第1节所述(运行Gitlab CI运行器)。
  3. 一对1200VA的UPS。

在突然的夜间断电导致OpenStack中的Ceph变得不可用之后,最后2台服务器被成功占用,因此决定将它们转移到独立的节点上。 但是,没有什么可以阻止它们稍后被传输到VM。


日立一般2件,但是我们将所有东西都装在一台机器上,稍后我将解释原因。
我画了这么详细,只是为了使决定清楚。


选择的面粉


OpenStack的主要问题是AIO过于贪婪,无法与虚拟机竞争,并且分散在主机上……简而言之,原始的OpenStack,无论我们多么喜欢它,但都无法满足我们的需求和功能。


逻辑上假设,可能值得切换到VMWare ESXi(正如许多同志所建议的那样)。 但是我没有这个产品的灵魂...


有必要有可能对我们的需求进行良好的自定义(在十字路口的某个地方便宜,生产和灵活),并为那些不想配置任何东西但仅配置任何东西的简单开发者提供便利 做“ fi-fi-fi-fi” 编码和实验。


之所以选择Proxmox VE,是因为:


  1. 尽管是“类固醇”,但这是debian,这意味着更容易弄清+自定义。
  2. 既有KVM容器又有简单的LXC容器,它们在资源方面更加经济。
  3. 在完全免费的版本中,它可以扩展为群集。
  4. Dofigallion的各种存储(lvm薄,Ceph,GlusterFS,NFS等)
  5. 我们将使用的设备的100%支持。

配置Proxmox


该出版物进一步描述了我如何在几乎实时的模式下使用Proxmox配置仅服务器的基础结构。 不会以任何方式描述Gitlab服务器迁移,因为它与本主题无关。


网络和路由器


OpenStack之后有一些用于对网络进行切片的遗留物,特别是Mikrotiks上的公用网络和OSPF设置。 我想要以下内容:


  • 确保服务器的内部网络与虚拟机将进入的公共网络隔离。
  • 使用Mikrotik作为主要路由器,使用DNS和ntp作为机架。
  • 使用所有6个服务器接口来访问和释放虚拟机。

我将描述如何从头开始:


  • 我们将所有接口驱动到网桥中(我们认为配置是从第二个端口进行的):

转过我
/interface bridge add name=bridge1 protocol-mode=none /interface bridge port add bridge=bridge1 interface=ether1 trusted=yes add bridge=bridge1 interface=ether2 add bridge=bridge1 interface=ether3 add bridge=bridge1 interface=ether4 add bridge=bridge1 interface=ether5 add bridge=bridge1 interface=ether6 add bridge=bridge1 interface=ether7 add bridge=bridge1 interface=ether8 add bridge=bridge1 interface=ether9 add bridge=bridge1 interface=ether10 add bridge=bridge1 interface=ether11 add bridge=bridge1 interface=ether12 add bridge=bridge1 interface=ether13 add bridge=bridge1 interface=ether14 add bridge=bridge1 interface=ether15 add bridge=bridge1 interface=ether16 add bridge=bridge1 interface=ether17 add bridge=bridge1 interface=ether18 add bridge=bridge1 interface=ether19 add bridge=bridge1 interface=ether20 add bridge=bridge1 interface=ether21 add bridge=bridge1 interface=ether22 add bridge=bridge1 interface=ether23 add bridge=bridge1 interface=ether24 add bridge=bridge1 interface=sfp1 

  • 我们在网络10.20.0.0/24上配置OSPF Mikrotik(然后我们将通过防火墙规则禁止我们进入内部网络):

转过我
 /ip address add address=10.20.0.254/24 interface=bridge1 network=10.20.0.0 /ip route add check-gateway=ping distance=1 gateway=10.20.0.1 /routing ospf network add area=local network=10.20.0.0/24 /routing ospf instance set [ find default=yes ] redistribute-connected=as-type-2 \ redistribute-static=as-type-2 router-id=10.20.0.254 

  • 我们为公共网络+ DHCP服务器配置VLAN100:

转过我
 /interface vlan add interface=bridge1 name=public_rack vlan-id=100 /ip address add address=172.16.0.1/16 interface=public_rack network=172.16.0.0 /ip pool add name=public_rack_dhcp_pool1 ranges=172.16.253.1-172.16.253.254 add name=public_rack_dhcp_pool0 next-pool=public_rack_dhcp_pool1 ranges=\ 172.16.254.1-172.16.254.254 /ip dhcp-server add add-arp=yes address-pool=public_rack_dhcp_pool0 disabled=no interface=\ public_rack lease-time=1h name=public_rack_dhcp /ip dhcp-server network add address=172.16.0.0/16 dns-server=172.16.0.1 domain=domain.lan\ gateway=172.16.0.1 ntp-server=172.16.0.1 /ip dns set allow-remote-requests=yes cache-size=4096KiB max-concurrent-queries=400 \ max-concurrent-tcp-sessions=80 query-server-timeout=10s \ query-total-timeout=1m40s servers=10.20.0.1 

  • 我们配置防火墙规则,以便仅访问以下路由器:

转过我
 /ip firewall filter add action=drop dst-address=10.20.0.0/24 in-interface=public_rack add action=drop dst-address=10.20.0.0/24 src-address=172.16.0.0/24 in-interface=bridge1 add action=accept dst-address=10.20.0.1 in-interface=public_rack 

这并不是说该规则是非常正确的规则,但是如果其中一位专家告诉您如何正确编写它,我将不胜感激。 通常,我们仅需要在L2上进行隔离,但是在L3上,我会带来更多信息以供熟悉。


服务器设置


将调整服务器以从当前驱动器获得最佳性能。 但是,我们不会忘记一切都会发生,并且在夜晚,每个人都在睡觉时,灯光会突然消失一两个小时。


  • 我们将除SSD外的所有驱动器安装到垃圾桶中。
  • 我们通过滑轨而不是驱动器连接SSD。
  • 我们将所有LAN端口连接到Mikrotik。
  • 使用直写式缓存配置RAID:
    • RAID 10中的4个1TB
    • RAID 10中有4个500GB
    • 我们使两个阵列都可启动。
  • 在第一个阵列和第一个接口上安装Proxmox VE 6( 从此处获取 )。
  • 分配地址10.20.0.10/24
  • 在安装结束时,我们重新启动。

由于我们不想购买任何东西,因此应该禁用与订阅有关的所有内容:


  • 进入GUI时删除弹出窗口(适用于版本> = 5.1):
     sed -i.bak "s/data.status !== 'Active'/false/g" /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js && systemctl restart pveproxy.service 
  • 通过替换文件中的行,我们切换到经济人士的存储库:

/ etc / apt / sources.list.d / pve-enterprise.list`
 # deb https://enterprise.proxmox.com/debian/pve buster pve-enterprise deb http://download.proxmox.com/debian/pve buster pve-no-subscription 

这是我们完成基本设置的地方。


网络接口的魔力


通常,设置Proxmox Bridge可以正常工作。 但是我不是我,如果不是 我将直肠切除扁桃体 我会做点奢侈的事。 我真的希望OVSBridge也可以为OVSBond工作。 但是问题是我也不希望用户每次创建VM / LXC时都为其分配VLAN。 因此,对于所有6个接口,设置步骤如下:


  • 安装Open vSwitch软件包: apt install openvswitch-switch -y
  • 我们按以下方式编辑文件/etc/network/interfaces

转过我
 #  OVSBond   vlan- allow-vmbr0 bond0 iface bond0 inet manual ovs_bonds enp5s0f0.100 enp5s0f1.100 enp6s0f0.100 enp6s0f1.100 enp8s0f0.100 enp8s0f1.100 ovs_type OVSBond ovs_bridge vmbr0 ovs_options vlan_mode=native-untagged bond_mode=balance-slb auto lo iface lo inet loopback iface enp5s0f0 inet manual iface enp5s0f1 inet manual iface enp6s0f0 inet manual iface enp6s0f1 inet manual iface enp8s0f0 inet manual iface enp8s0f1 inet manual #   OVSBond vlan- auto enp5s0f0.100 iface enp5s0f0.100 inet manual auto enp5s0f1.100 iface enp5s0f1.100 inet manual auto enp6s0f0.100 iface enp6s0f0.100 inet manual auto enp6s0f1.100 iface enp6s0f1.100 inet manual auto enp8s0f0.100 iface enp8s0f0.100 inet manual auto enp8s0f1.100 iface enp8s0f1.100 inet manual #   bond  " ". #   ,          Ceph ( ). auto bond1 iface bond1 inet static address 10.20.0.10 netmask 24 bond-slaves enp5s0f0 enp5s0f1 enp6s0f0 enp6s0f1 enp8s0f0 enp8s0f1 bond-miimon 100 bond-mode balance-xor bond-xmit-hash-policy layer2+3 #      VLAN100 allow-ovs vmbr0 iface vmbr0 inet static address 172.16.0.2 netmask 16 gateway 172.16.0.1 ovs_type OVSBridge ovs_ports bond0 

配置LVM + lvmcache


首先,删除旧的pve/data以免与meta部分混淆,等等。


 lvremove pve/data 

将第二部分添加到我们的卷组中:


 pvcreate /dev/sdb vgextend pve /dev/sdb 

我们在Proxmox文档教我们的同时创建了一个新部分,并提供了一个用于优化快照的小技巧:


 lvcreate -L 2.4T -n data pve lvconvert --type thin-pool -c 64K --poolmetadatasize 15.81G pve/data 

现在我们需要连接lvmcache,但是为了优化SSD资源,我专门为其分配了一个241GB的区域。 此数量足以用于高速缓存,磁盘的其余部分将成为死块的资源。 没错,这是理论上的,因为我个人并不完全了解这是否可行。 无论如何,465GB缓存的长度将是原来的两倍,并且难以删除(例如,替换磁盘或扩展阵列)。


 vgextend pve /dev/sdc1 lvcreate --type cache-pool -L240G pve /dev/sdc1 lvconvert --type cache --cachepool pve/lvol1 pve/data 

UPD: dm_cache有一个小故障,因此,您需要再做一个魔术:


 apt install thin-provisioning-tools -y echo "dm_cache" >> /etc/initramfs-tools/modules echo "dm_cache_mq" >> /etc/initramfs-tools/modules echo "dm_persistent_data" >> /etc/initramfs-tools/modules echo "dm_bufio" >> /etc/initramfs-tools/modules update-initramfs -k `uname -r` -u -t update-grub 

起初,一切正常,但是由于某种原因,它停止了。 显然,随着更新,这些模块被删除了。


最后的润色


我通常在重新启动之前进行此操作,以确保所有内容都已更新并且内核是最新的:


 apt update && apt dist-upgrade -y && apt autoremove -y pveam update 

顺便说一句,在第6版中,内核是5.0,而在发布之时,内核似乎是5.3.7。
就是这样,现在我们正在发送系统以重新启动。 如果我们做对了所有事情,那么在重新启动后,可以从两个地址从外部访问我们的服务器。 您还可以下载新鲜的容器模板并享受生活。


我们制作精美的图形


好吧,我们不仅是管理员,而且还是DevOps(这甚至意味着什么?),因此我们需要知道某些虚拟机何时会失效并做一些不好的事情。


具有InfluxDB和Grafana的容器


通常,所有这些操作都最容易在GUI中完成,但是突然间我冒进了一种懒惰的方式来截取屏幕截图,因此我将用命令对其进行描述。


我们看一下可用的模板:


 root@cloud:~# pveam available --section system system alpine-3.10-default_20190626_amd64.tar.xz system alpine-3.9-default_20190224_amd64.tar.xz system archlinux-base_20190924-1_amd64.tar.gz system centos-6-default_20191016_amd64.tar.xz system centos-7-default_20190926_amd64.tar.xz system centos-8-default_20191016_amd64.tar.xz system debian-10.0-standard_10.0-1_amd64.tar.gz system debian-8.0-standard_8.11-1_amd64.tar.gz system debian-9.0-standard_9.7-1_amd64.tar.gz system fedora-29-default_20181126_amd64.tar.xz system fedora-30-default_20190718_amd64.tar.xz system gentoo-current-default_20190718_amd64.tar.xz system opensuse-15.0-default_20180907_amd64.tar.xz system opensuse-15.1-default_20190719_amd64.tar.xz system ubuntu-16.04-standard_16.04.5-1_amd64.tar.gz system ubuntu-18.04-standard_18.04.1-1_amd64.tar.gz system ubuntu-19.04-standard_19.04-1_amd64.tar.gz system ubuntu-19.10-standard_19.10-1_amd64.tar.gz 

我认为对于初学者来说,您可以下载ubuntu-18.04-standard_18.04.1-1_amd64.tar.gz


 root@cloud:~# pveam download local ubuntu-18.04-standard_18.04.1-1_amd64.tar.gz root@cloud:~# pveam list local NAME SIZE local:vztmpl/ubuntu-18.04-standard_18.04.1-1_amd64.tar.gz 203.54MB 

为InfluxDB和Grafana创建一个容器:


 root@cloud:~# pct create 999 local:vztmpl/ubuntu-18.04-standard_18.04.1-1_amd64.tar.gz --cores 2 --memory 2048 --password hostpassword --onboot 1 --net0 name=eth0,bridge=vmbr0,gw=172.16.0.1,ip=172.16.1.101/24 --storage local-lvm --hostname monit 

我们通过ssh root@172.16.1.101pct console 999连接到ssh root@172.16.1.101的终端。


安装InfluxDB和Grafana软件包:


 apt update && apt install curl wget gnupg software-properties-common -y add-apt-repository "deb https://packages.grafana.com/oss/deb stable main" echo "deb https://repos.influxdata.com/ubuntu bionic stable" | tee /etc/apt/sources.list.d/influxdb.list curl -sL https://repos.influxdata.com/influxdb.key | apt-key add - wget -q -O - https://packages.grafana.com/gpg.key | apt-key add - apt update && apt install influxdb grafana -y systemctl daemon-reload systemctl enable grafana-server systemctl start grafana-server systemctl enable influxdb systemctl start influxdb 

我们为工作配置InfluxDB。 为此,我们首先需要创建一个数据库:


 influx > CREATE DATABASE proxmox > quit 

接下来,我们需要配置Proxmox将请求发送到的UDP端口:


`/ etc / influxdb / influxdb.conf`
 #   ,     . [[udp]] enabled = true bind-address = "0.0.0.0:8089" database = "proxmox" batch-size = 1000 batch-timeout = "1s" 

...然后现在重新systemctl restart influxdbsystemctl restart influxdb


配置Proxmox和仪表板


这里的一切都非常简单。 在具有proxmox的服务器上,您需要创建一个包含以下内容的文件:


`/ etc / pve / status.cfg`
 influxdb: influx1 server 172.16.1.101 port 8089 

默认情况下,那里没有文件。


由于某些未知原因,指标并没有立即消失,因此我不得不在代理服务器上调用systemctl restart pvestatd


现在我们需要可视化所有这一切。 我们转到地址http://172.16.1.101 {000 /(管理员:admin)的grafana,更改密码。
我在该网站的荒野中发现了石墨烯,您可以拧紧一个漂亮的仪表板来渲染Proxmox,但是它有一点点 档案 解决时要考虑到我们所有的现实。


  • 转到配置 -> 数据源 -> 添加数据源 ,选择InfluxDB
  • 选中default框。
  • 填写网址http://localhost:8086
  • 我们填写数据库proxmox
  • 保存。

现在我们需要导入仪表板:


  • 转到创建 -> 导入
  • 我们在此处插入:

董事会内容
 { "annotations": { "list": [ { "builtIn": 1, "datasource": "-- Grafana --", "enable": true, "hide": true, "iconColor": "rgba(0, 211, 255, 1)", "name": "Annotations & Alerts", "type": "dashboard" } ] }, "description": "Display data from the Proxmox host and hosted VM's and Containers.", "editable": false, "gnetId": 10048, "graphTooltip": 0, "id": 2, "iteration": 1574232555436, "links": [], "panels": [ { "collapsed": false, "datasource": null, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 0 }, "id": 43, "panels": [], "title": "Summary", "type": "row" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#299c46", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "format": "none", "gauge": { "maxValue": 100, "minValue": 0, "show": false, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 3, "w": 2, "x": 0, "y": 1 }, "id": 58, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0.18)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": false }, "tableColumn": "", "targets": [ { "groupBy": [], "measurement": "cpustat", "orderByTime": "ASC", "policy": "default", "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "cpus" ], "type": "field" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": "", "timeFrom": null, "timeShift": null, "title": "Cores", "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#299c46", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "format": "bytes", "gauge": { "maxValue": 100, "minValue": 0, "show": false, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 3, "w": 3, "x": 2, "y": 1 }, "id": 60, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0.18)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": false }, "tableColumn": "", "targets": [ { "groupBy": [], "measurement": "memory", "orderByTime": "ASC", "policy": "default", "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "memtotal" ], "type": "field" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": "", "timeFrom": null, "timeShift": null, "title": "Total Memory", "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#299c46", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "format": "bytes", "gauge": { "maxValue": 100, "minValue": 0, "show": false, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 3, "w": 3, "x": 5, "y": 1 }, "id": 62, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0.18)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": false }, "tableColumn": "", "targets": [ { "groupBy": [], "measurement": "memory", "orderByTime": "ASC", "policy": "default", "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "swaptotal" ], "type": "field" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": "", "timeFrom": null, "timeShift": null, "title": "Total Swap", "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#73BF69", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "decimals": 2, "description": "", "format": "percentunit", "gauge": { "maxValue": 1, "minValue": 0, "show": true, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 6, "w": 4, "x": 8, "y": 1 }, "id": 2, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": true }, "tableColumn": "", "targets": [ { "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "cpustat", "orderByTime": "ASC", "policy": "default", "query": "SELECT mean(\"cpu\") FROM \"cpustat\" WHERE (\"host\" =~ /^$server$/) AND $timeFilter GROUP BY time($__interval) fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "cpu" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": "0.5,0.75", "timeFrom": null, "timeShift": null, "title": "Server CPU", "transparent": true, "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#73BF69", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "decimals": 2, "description": "", "format": "short", "gauge": { "maxValue": 10, "minValue": 0, "show": true, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 6, "w": 4, "x": 12, "y": 1 }, "id": 9, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": true }, "tableColumn": "", "targets": [ { "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "cpustat", "orderByTime": "ASC", "policy": "default", "query": "SELECT mean(\"avg1\") FROM \"cpustat\" WHERE (\"host\" =~ /^$server$/) AND $timeFilter GROUP BY time($__interval) fill(null)\n", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "avg1" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": "6,8", "timeFrom": null, "timeShift": null, "title": "Load Average (1 Minute)", "transparent": true, "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#73BF69", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "decimals": 2, "description": "", "format": "percentunit", "gauge": { "maxValue": 1, "minValue": 0, "show": true, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 6, "w": 4, "x": 16, "y": 1 }, "id": 10, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": true }, "tableColumn": "", "targets": [ { "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "cpustat", "orderByTime": "ASC", "policy": "default", "query": "SELECT mean(\"wait\") FROM \"cpustat\" WHERE (\"host\" =~ /^$server$/) AND $timeFilter GROUP BY time($__interval) fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "wait" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": "0.5,0.75", "timeFrom": null, "timeShift": null, "title": "I/O Wait", "transparent": true, "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#73BF69", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "decimals": 2, "description": "", "format": "gbytes", "gauge": { "maxValue": 160, "minValue": 0, "show": true, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 6, "w": 4, "x": 20, "y": 1 }, "id": 11, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": true }, "tableColumn": "", "targets": [ { "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "memory", "orderByTime": "ASC", "policy": "default", "query": "SELECT mean(\"memused\") / 1073741824 FROM \"memory\" WHERE (\"host\" =~ /^$server$/) AND $timeFilter GROUP BY time($__interval) fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "memused" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "/ 1073741824" ], "type": "math" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": "96,140", "timeFrom": null, "timeShift": null, "title": "Used Memory", "transparent": true, "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" }, { "bgColor": null, "clockType": "24 hour", "countdownSettings": { "customFormat": null, "endCountdownTime": "2019-04-12T19:20:00.000Z", "endText": "00:00:00" }, "datasource": "InfluxDB", "dateSettings": { "dateFormat": "YYYY-MM-DD", "fontSize": "20px", "fontWeight": "normal", "showDate": true }, "gridPos": { "h": 3, "w": 8, "x": 0, "y": 4 }, "id": 20, "links": [], "mode": "time", "offsetFromUtc": null, "offsetFromUtcMinutes": null, "options": {}, "refreshSettings": { "syncWithDashboard": false }, "targets": [ { "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "orderByTime": "ASC", "policy": "default", "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "value" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [] } ], "timeFrom": null, "timeSettings": { "customFormat": "HH:mm:ss", "fontSize": "40px", "fontWeight": "normal" }, "timeShift": null, "timezone": null, "timezoneSettings": { "fontSize": "12px", "fontWeight": "normal", "showTimezone": false, "zoneFormat": "offsetAbbv" }, "title": "Time", "transparent": true, "type": "grafana-clock-panel" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#299c46", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "format": "dateTimeAsIso", "gauge": { "maxValue": 100, "minValue": 0, "show": false, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 6, "w": 6, "x": 0, "y": 7 }, "id": 24, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0.18)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": false }, "tableColumn": "", "targets": [ { "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "cpustat", "orderByTime": "ASC", "policy": "default", "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "cpu" ], "type": "field" }, { "params": [], "type": "last" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": "", "timeFrom": null, "timeShift": null, "title": "Last Update", "transparent": true, "type": "singlestat", "valueFontSize": "100%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "last_time" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#299c46", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "decimals": 1, "format": "dtdurations", "gauge": { "maxValue": 100, "minValue": 0, "show": false, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 6, "w": 6, "x": 6, "y": 7 }, "id": 16, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0.18)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": false }, "tableColumn": "", "targets": [ { "groupBy": [], "measurement": "system", "orderByTime": "ASC", "policy": "default", "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "uptime" ], "type": "field" }, { "params": [], "type": "last" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": "", "timeFrom": null, "timeShift": null, "title": "Host Uptime", "transparent": true, "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" }, { "columns": [], "datasource": "InfluxDB", "fontSize": "100%", "gridPos": { "h": 6, "w": 6, "x": 12, "y": 7 }, "id": 7, "interval": "", "links": [], "options": {}, "pageSize": null, "scroll": true, "showHeader": true, "sort": { "col": 1, "desc": false }, "styles": [ { "alias": "Time", "colorMode": null, "colors": [ "rgba(245, 54, 54, 0.9)", "rgba(237, 129, 40, 0.89)", "rgba(50, 172, 45, 0.97)" ], "dateFormat": "YYYY-MM-DD HH:mm:ss", "decimals": 2, "mappingType": 1, "pattern": "Time", "thresholds": [], "type": "hidden", "unit": "short" }, { "alias": "Uptime", "colorMode": null, "colors": [ "rgba(245, 54, 54, 0.9)", "rgba(237, 129, 40, 0.89)", "rgba(50, 172, 45, 0.97)" ], "dateFormat": "YYYY-MM-DD HH:mm:ss", "decimals": 1, "mappingType": 1, "pattern": "uptime", "rangeMaps": [ { "from": "", "text": "", "to": "" } ], "thresholds": [], "type": "number", "unit": "dtdurations", "valueMaps": [ { "text": "Offline", "value": "0" } ] }, { "alias": "VM", "colorMode": null, "colors": [ "rgba(245, 54, 54, 0.9)", "rgba(237, 129, 40, 0.89)", "rgba(50, 172, 45, 0.97)" ], "dateFormat": "YYYY-MM-DD HH:mm:ss", "decimals": 2, "mappingType": 1, "pattern": "host", "sanitize": true, "thresholds": [], "type": "string", "unit": "short", "valueMaps": [] } ], "targets": [ { "groupBy": [ { "params": [ "host" ], "type": "tag" } ], "limit": "1", "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT last(uptime) AS \"uptime\" FROM \"system\" WHERE (\"object\" = 'qemu') AND (\"nodename\" =~ /^$server$/) AND time > (now() - 10m) AND uptime > 0 GROUP BY \"host\" limit 1", "rawQuery": true, "refId": "A", "resultFormat": "table", "select": [ [ { "params": [ "uptime" ], "type": "field" }, { "params": [ "uptime" ], "type": "alias" } ] ], "tags": [ { "key": "object", "operator": "=", "value": "qemu" } ] } ], "timeFrom": null, "timeShift": null, "title": "Running VMs", "transform": "table", "transparent": true, "type": "table" }, { "columns": [], "datasource": "InfluxDB", "fontSize": "100%", "gridPos": { "h": 5, "w": 6, "x": 18, "y": 7 }, "id": 8, "interval": "", "links": [], "options": {}, "pageSize": null, "scroll": true, "showHeader": true, "sort": { "col": 1, "desc": false }, "styles": [ { "alias": "Time", "colorMode": null, "colors": [ "rgba(245, 54, 54, 0.9)", "rgba(237, 129, 40, 0.89)", "rgba(50, 172, 45, 0.97)" ], "dateFormat": "YYYY-MM-DD HH:mm:ss", "decimals": 2, "mappingType": 1, "pattern": "Time", "thresholds": [], "type": "hidden", "unit": "short" }, { "alias": "Uptime", "colorMode": null, "colors": [ "rgba(245, 54, 54, 0.9)", "rgba(237, 129, 40, 0.89)", "rgba(50, 172, 45, 0.97)" ], "dateFormat": "YYYY-MM-DD HH:mm:ss", "decimals": 1, "mappingType": 1, "pattern": "uptime", "thresholds": [], "type": "number", "unit": "dthms" }, { "alias": "LXC", "colorMode": null, "colors": [ "rgba(245, 54, 54, 0.9)", "rgba(237, 129, 40, 0.89)", "rgba(50, 172, 45, 0.97)" ], "dateFormat": "YYYY-MM-DD HH:mm:ss", "decimals": 2, "mappingType": 1, "pattern": "host", "sanitize": true, "thresholds": [], "type": "string", "unit": "short", "valueMaps": [] } ], "targets": [ { "groupBy": [ { "params": [ "host" ], "type": "tag" } ], "limit": "1", "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT last(uptime) AS \"uptime\" FROM \"system\" WHERE (\"object\" = 'lxc') AND (\"nodename\" =~ /^$server$/) AND time > (now() - 10m) AND uptime > 0 GROUP BY \"host\" limit 1", "rawQuery": true, "refId": "A", "resultFormat": "table", "select": [ [ { "params": [ "uptime" ], "type": "field" }, { "params": [ "uptime" ], "type": "alias" } ] ], "tags": [ { "key": "object", "operator": "=", "value": "qemu" } ] } ], "timeFrom": null, "timeShift": null, "title": "Running LXCs", "transform": "table", "transparent": true, "type": "table" }, { "collapsed": false, "datasource": null, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 13 }, "id": 26, "panels": [], "title": "Memory And CPU Usage", "type": "row" }, { "aliasColors": { "I/O Wait": "dark-blue", "Load Average (1 Min)": "dark-red" }, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 7, "w": 12, "x": 0, "y": 14 }, "id": 22, "interval": "", "legend": { "alignAsTable": false, "avg": true, "current": true, "max": false, "min": false, "rightSide": false, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 2, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [ { "alias": "Load Average (1 Min)", "yaxis": 2 } ], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "CPU Usage", "groupBy": [ { "params": [ "1m" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "cpustat", "orderByTime": "ASC", "policy": "default", "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "cpu" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "* 100" ], "type": "math" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] }, { "alias": "I/O Wait", "groupBy": [ { "params": [ "1m" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "cpustat", "orderByTime": "ASC", "policy": "default", "refId": "B", "resultFormat": "time_series", "select": [ [ { "params": [ "wait" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ " * 100" ], "type": "math" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] }, { "alias": "Load Average (1 Min)", "groupBy": [ { "params": [ "1m" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "cpustat", "orderByTime": "ASC", "policy": "default", "refId": "C", "resultFormat": "time_series", "select": [ [ { "params": [ "avg1" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "Host CPU Usage", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "decimals": null, "format": "percent", "label": "Percent", "logBase": 1, "max": null, "min": "0", "show": true }, { "decimals": null, "format": "short", "label": "Load", "logBase": 1, "max": "10", "min": "0", "show": true } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 7, "w": 12, "x": 12, "y": 14 }, "id": 4, "interval": "", "legend": { "alignAsTable": true, "avg": true, "current": true, "max": true, "min": true, "rightSide": false, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 2, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "Memory Use", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "memory", "orderByTime": "ASC", "policy": "default", "query": "SELECT mean(\"memused\")/mean(\"memtotal\") * 100 FROM \"memory\" WHERE (\"host\" =~ /^$server$/) AND $timeFilter GROUP BY time($__interval) fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "memused" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "Host Memory Usage", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "decimals": null, "format": "percent", "label": null, "logBase": 1, "max": "100", "min": "0", "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": true } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "decimals": 2, "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 0, "y": 21 }, "id": 28, "interval": "", "legend": { "alignAsTable": true, "avg": true, "current": true, "hideEmpty": false, "hideZero": true, "max": false, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 2, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "1m" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT last(\"cpu\") FROM \"system\" WHERE (\"object\" = 'qemu') AND $timeFilter GROUP BY time($__interval) fill(null)", "rawQuery": false, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "cpu" ], "type": "field" }, { "params": [], "type": "last" } ] ], "tags": [ { "key": "object", "operator": "=", "value": "qemu" }, { "condition": "AND", "key": "nodename", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "VM CPU Usage", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "decimals": 2, "format": "percentunit", "label": "", "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 12, "y": 21 }, "id": 31, "interval": "", "legend": { "alignAsTable": true, "avg": true, "current": true, "hideZero": true, "max": false, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 2, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT (mean(\"mem\")/last(maxmem))*100 FROM \"system\" WHERE (\"object\" = 'qemu') AND (\"nodename\" =~ /^$server$/) AND $timeFilter GROUP BY time($__interval), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "mem" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [ { "key": "object", "operator": "=", "value": "qemu" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "VMs Memory Usage", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "percent", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "decimals": 2, "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 0, "y": 27 }, "id": 29, "interval": "", "legend": { "alignAsTable": true, "avg": true, "current": true, "hideEmpty": false, "hideZero": true, "max": false, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 2, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "1m" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT last(\"cpu\") FROM \"system\" WHERE (\"object\" = 'lxc' AND \"nodename\" =~ /^$server$/) AND $timeFilter GROUP BY time(1m), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "cpu" ], "type": "field" }, { "params": [], "type": "last" } ] ], "tags": [ { "key": "object", "operator": "=", "value": "lxc" }, { "condition": "AND", "key": "nodename", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "LXC CPU Usage", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "decimals": 2, "format": "percentunit", "label": "", "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 12, "y": 27 }, "id": 32, "interval": "", "legend": { "alignAsTable": true, "avg": true, "current": true, "hideZero": true, "max": false, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 2, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT (mean(\"mem\")/last(maxmem))*100 FROM \"system\" WHERE (\"object\" = 'lxc') AND (\"nodename\" =~ /^$server$/) AND $timeFilter GROUP BY time($__interval), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "mem" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [ { "key": "object", "operator": "=", "value": "qemu" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "LXC Memory Usage", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "percent", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "collapsed": false, "datasource": null, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 33 }, "id": 34, "panels": [], "title": "Disk I/O", "type": "row" }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 0, "y": 34 }, "id": 36, "interval": "", "legend": { "alignAsTable": true, "avg": false, "current": true, "hideZero": true, "max": true, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 1, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "1m" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"diskread\"), 1s)) FROM \"system\" WHERE (\"object\" = 'qemu' AND \"nodename\" =~ /^$server$/) AND $timeFilter GROUP BY time(1m), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "diskread" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "1s" ], "type": "derivative" } ] ], "tags": [ { "key": "object", "operator": "=", "value": "qemu" }, { "condition": "AND", "key": "nodename", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "VMs I/O Read", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "Bps", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 12, "y": 34 }, "id": 37, "interval": "", "legend": { "alignAsTable": true, "avg": false, "current": true, "hideZero": true, "max": true, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 2, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "1m" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "hide": false, "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"diskwrite\"), 1s)) FROM \"system\" WHERE (\"object\" = 'qemu' AND \"nodename\" =~ /^$server$/) AND $timeFilter GROUP BY time(1m), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "diskwrite" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "1s" ], "type": "derivative" } ] ], "tags": [ { "key": "object", "operator": "=", "value": "qemu" }, { "condition": "AND", "key": "nodename", "operator": "=", "value": "dianna" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "VMs I/O Write", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "Bps", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 0, "y": 40 }, "id": 38, "interval": "", "legend": { "alignAsTable": true, "avg": false, "current": true, "hideZero": true, "max": true, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 1, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "1m" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"diskread\"), 1s)) FROM \"system\" WHERE (\"object\" = 'lxc' AND \"nodename\" =~ /^$server$/) AND $timeFilter GROUP BY time(1m), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "diskread" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "1s" ], "type": "derivative" } ] ], "tags": [ { "key": "object", "operator": "=", "value": "lxc" }, { "condition": "AND", "key": "nodename", "operator": "=~", "value": "/^$server$/" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "LXCs I/O Read", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "decimals": null, "format": "Bps", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": "0", "show": false } ], "yaxis": { "align": false, "alignLevel": 0 } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 12, "y": 40 }, "id": 39, "interval": "", "legend": { "alignAsTable": true, "avg": false, "current": true, "hideZero": true, "max": true, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 2, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "1m" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"diskwrite\"), 1s)) FROM \"system\" WHERE (\"object\" = 'lxc' AND \"nodename\" =~ /^$server$/) AND $timeFilter GROUP BY time(1m), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "diskwrite" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "1s" ], "type": "derivative" } ] ], "tags": [ { "key": "object", "operator": "=", "value": "lxc" }, { "condition": "AND", "key": "nodename", "operator": "=", "value": "dianna" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "LXCs I/O Write", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "Bps", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "collapsed": false, "datasource": null, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 46 }, "id": 41, "panels": [], "title": "Network Traffic", "type": "row" }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 0, "y": 47 }, "id": 45, "interval": "", "legend": { "avg": true, "current": true, "max": false, "min": false, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 1, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "Rx-$tag_instance", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "nics", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"receive\"), 10s)) AS \"Rx\" FROM \"nics\" WHERE (\"host\" =~ /^$server$/ AND \"instance\" =~ /bond[01]/) AND $timeFilter GROUP BY time($__interval), \"instance\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "receive" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "10s" ], "type": "non_negative_derivative" }, { "params": [ "Rx" ], "type": "alias" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" }, { "condition": "AND", "key": "instance", "operator": "=", "value": "enp2s0" } ] }, { "alias": "Tx-$tag_instance", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "nics", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"transmit\"), 10s)) FROM \"nics\" WHERE (\"host\" =~ /^$server$/ AND \"instance\" =~ /bond[01]/) AND $timeFilter GROUP BY time($__interval), \"instance\" fill(null)", "rawQuery": true, "refId": "B", "resultFormat": "time_series", "select": [ [ { "params": [ "transmit" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "10s" ], "type": "non_negative_derivative" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" }, { "condition": "AND", "key": "instance", "operator": "=", "value": "enp2s0" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "bonds rx-tx", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "bps", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 12, "y": 47 }, "id": 46, "interval": "", "legend": { "avg": true, "current": true, "max": false, "min": false, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 1, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "Rx", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "nics", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"receive\"), 10s)) FROM \"nics\" WHERE (\"host\" =~ /^$server$/ AND \"instance\" = 'vmbr0') AND $timeFilter GROUP BY time($__interval) fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "receive" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "10s" ], "type": "non_negative_derivative" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" }, { "condition": "AND", "key": "instance", "operator": "=", "value": "vmbr0" } ] }, { "alias": "Tx", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "nics", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"transmit\"), 10s)) FROM \"nics\" WHERE (\"host\" =~ /^$server$/ AND \"instance\" = 'vmbr0') AND $timeFilter GROUP BY time($__interval) fill(null)", "rawQuery": true, "refId": "B", "resultFormat": "time_series", "select": [ [ { "params": [ "transmit" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "10s" ], "type": "non_negative_derivative" } ] ], "tags": [ { "key": "host", "operator": "=~", "value": "/^$server$/" }, { "condition": "AND", "key": "instance", "operator": "=", "value": "vmbr0" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "vmbr0", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "bps", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 0, "y": 53 }, "id": 47, "interval": "", "legend": { "alignAsTable": true, "avg": true, "current": true, "hideEmpty": false, "hideZero": true, "max": false, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 1, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"netin\"), 10s)) FROM \"system\" WHERE (\"nodename\" =~ /^$server$/ AND \"object\" = 'qemu') AND $timeFilter GROUP BY time($__interval), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "netin" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "10s" ], "type": "non_negative_derivative" } ] ], "tags": [ { "key": "nodename", "operator": "=~", "value": "/^$server$/" }, { "condition": "AND", "key": "object", "operator": "=", "value": "qemu" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "VMs Traffic In", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "bps", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 12, "y": 53 }, "id": 49, "interval": "", "legend": { "alignAsTable": true, "avg": true, "current": true, "hideEmpty": false, "hideZero": true, "max": false, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 1, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"netout\"), 10s)) FROM \"system\" WHERE (\"nodename\" =~ /^$server$/ AND \"object\" = 'qemu') AND $timeFilter GROUP BY time($__interval), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "netout" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "10s" ], "type": "non_negative_derivative" } ] ], "tags": [ { "key": "nodename", "operator": "=~", "value": "/^$server$/" }, { "condition": "AND", "key": "object", "operator": "=", "value": "qemu" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "VMs Traffic Out", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "bps", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 0, "y": 59 }, "id": 48, "interval": "", "legend": { "alignAsTable": true, "avg": true, "current": true, "hideEmpty": false, "hideZero": true, "max": false, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 1, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"netin\"), 10s)) FROM \"system\" WHERE (\"nodename\" =~ /^$server$/ AND \"object\" = 'lxc') AND $timeFilter GROUP BY time($__interval), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "netin" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "10s" ], "type": "non_negative_derivative" } ] ], "tags": [ { "key": "nodename", "operator": "=~", "value": "/^$server$/" }, { "condition": "AND", "key": "object", "operator": "=", "value": "lxc" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "LCXs Traffic In", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "bps", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "aliasColors": {}, "bars": false, "dashLength": 10, "dashes": false, "datasource": "InfluxDB", "fill": 1, "fillGradient": 0, "gridPos": { "h": 6, "w": 12, "x": 12, "y": 59 }, "id": 50, "interval": "", "legend": { "alignAsTable": true, "avg": true, "current": true, "hideEmpty": false, "hideZero": true, "max": false, "min": false, "rightSide": true, "show": true, "total": false, "values": true }, "lines": true, "linewidth": 1, "links": [], "nullPointMode": "null", "options": { "dataLinks": [] }, "percentage": false, "pointradius": 2, "points": false, "renderer": "flot", "seriesOverrides": [], "spaceLength": 10, "stack": false, "steppedLine": false, "targets": [ { "alias": "$tag_host", "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "host" ], "type": "tag" }, { "params": [ "null" ], "type": "fill" } ], "measurement": "system", "orderByTime": "ASC", "policy": "default", "query": "SELECT abs(derivative(mean(\"netout\"), 10s)) FROM \"system\" WHERE (\"nodename\" =~ /^$server$/ AND \"object\" = 'lxc') AND $timeFilter GROUP BY time($__interval), \"host\" fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "netout" ], "type": "field" }, { "params": [], "type": "mean" }, { "params": [ "10s" ], "type": "non_negative_derivative" } ] ], "tags": [ { "key": "nodename", "operator": "=~", "value": "/^$server$/" }, { "condition": "AND", "key": "object", "operator": "=", "value": "lxc" } ] } ], "thresholds": [], "timeFrom": null, "timeRegions": [], "timeShift": null, "title": "LXCs Traffic Out", "tooltip": { "shared": true, "sort": 0, "value_type": "individual" }, "type": "graph", "xaxis": { "buckets": null, "mode": "time", "name": null, "show": true, "values": [] }, "yaxes": [ { "format": "bps", "label": null, "logBase": 1, "max": null, "min": null, "show": true }, { "format": "short", "label": null, "logBase": 1, "max": null, "min": null, "show": false } ], "yaxis": { "align": false, "alignLevel": null } }, { "collapsed": false, "datasource": null, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 65 }, "id": 52, "panels": [], "title": "Storage Pools", "type": "row" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#299c46", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "format": "percentunit", "gauge": { "maxValue": 1, "minValue": 0, "show": true, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 7, "w": 4, "x": 6, "y": 66 }, "id": 54, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "pluginVersion": "6.1.3", "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0.18)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": false }, "tableColumn": "", "targets": [ { "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "orderByTime": "ASC", "policy": "default", "query": "SELECT last(\"used\") / last(\"total\") FROM \"system\" WHERE (\"host\" = 'local-lvm' AND \"nodename\" =~ /^$server$/) AND $timeFilter GROUP BY time($__interval) fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "value" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [] } ], "thresholds": "0.75,0.875", "timeFrom": null, "timeShift": null, "title": "local-lvm Usage", "transparent": true, "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#299c46", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "format": "percentunit", "gauge": { "maxValue": 1, "minValue": 0, "show": true, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 7, "w": 4, "x": 10, "y": 66 }, "id": 63, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "pluginVersion": "6.1.3", "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0.18)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": false }, "tableColumn": "", "targets": [ { "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "orderByTime": "ASC", "policy": "default", "query": "SELECT last(\"used\") / last(\"total\") FROM \"system\" WHERE (\"host\" = 'local-lvm-test' AND \"nodename\" =~ /^$server$/) AND $timeFilter GROUP BY time($__interval) fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "value" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [] } ], "thresholds": "0.75,0.875", "timeFrom": null, "timeShift": null, "title": "local-lvm-test Usage", "transparent": true, "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" }, { "cacheTimeout": null, "colorBackground": false, "colorValue": false, "colors": [ "#299c46", "rgba(237, 129, 40, 0.89)", "#d44a3a" ], "datasource": "InfluxDB", "format": "percentunit", "gauge": { "maxValue": 1, "minValue": 0, "show": true, "thresholdLabels": false, "thresholdMarkers": true }, "gridPos": { "h": 7, "w": 4, "x": 15, "y": 66 }, "id": 55, "interval": null, "links": [], "mappingType": 1, "mappingTypes": [ { "name": "value to text", "value": 1 }, { "name": "range to text", "value": 2 } ], "maxDataPoints": 100, "nullPointMode": "connected", "nullText": null, "options": {}, "pluginVersion": "6.1.3", "postfix": "", "postfixFontSize": "50%", "prefix": "", "prefixFontSize": "50%", "rangeMaps": [ { "from": "null", "text": "N/A", "to": "null" } ], "sparkline": { "fillColor": "rgba(31, 118, 189, 0.18)", "full": false, "lineColor": "rgb(31, 120, 193)", "show": false }, "tableColumn": "", "targets": [ { "groupBy": [ { "params": [ "$__interval" ], "type": "time" }, { "params": [ "null" ], "type": "fill" } ], "orderByTime": "ASC", "policy": "default", "query": "SELECT last(\"used\") / last(\"total\") FROM \"system\" WHERE (\"host\" = 'local' AND \"nodename\" =~ /^$server$/) AND $timeFilter GROUP BY time($__interval) fill(null)", "rawQuery": true, "refId": "A", "resultFormat": "time_series", "select": [ [ { "params": [ "value" ], "type": "field" }, { "params": [], "type": "mean" } ] ], "tags": [] } ], "thresholds": "0.75,0.875", "timeFrom": null, "timeShift": null, "title": "local Usage", "transparent": true, "type": "singlestat", "valueFontSize": "80%", "valueMaps": [ { "op": "=", "text": "N/A", "value": "null" } ], "valueName": "current" } ], "refresh": "10s", "schemaVersion": 20, "style": "dark", "tags": [ "ProxMox", "Storage", "Hypervisor" ], "templating": { "list": [ { "allValue": null, "current": { "text": "cloud", "value": "cloud" }, "datasource": "InfluxDB", "definition": "SHOW TAG VALUES FROM system WITH KEY=host WHERE object='nodes'", "hide": 0, "includeAll": false, "label": "Server", "multi": true, "name": "server", "options": [], "query": "SHOW TAG VALUES FROM system WITH KEY=host WHERE object='nodes'", "refresh": 1, "regex": "", "skipUrlSync": false, "sort": 5, "tagValuesQuery": "", "tags": [], "tagsQuery": "", "type": "query", "useTags": false } ] }, "time": { "from": "now-24h", "to": "now" }, "timepicker": { "refresh_intervals": [ "5s", "10s", "30s", "1m", "5m", "15m", "30m", "1h", "2h", "1d" ], "time_options": [ "5m", "15m", "1h", "6h", "12h", "24h", "2d", "7d", "30d" ] }, "timezone": "", "title": "Proxmox", "uid": "kxQQuHRZk", "version": 29 } 

  • Import .

- . , Dashboard' Gitlab. , , Prometheus , Datastore Grafana , external, datastore.


Grafana , .
Grafana dashboard Proxmox
Proxmox VE dashboard
Proxmox Network

Source: https://habr.com/ru/post/zh-CN473576/


All Articles