🎧 New: AI-Generated Podcasts Turn your study notes into engaging audio conversations. Learn more

ZCP_day_3_slides_Part3.pdf

Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...

Full Transcript

PRACTICAL SETUP 1) Install Zabbix Java Gateway 2) Configure Zabbix Java Gateway and Zabbix server 3) Configure the "Training resources" host: Add JMX interface Link template: DNS: training.lan Generic Java JMX Port: 12345 4) Check JMX agent icon status and "Latest data" for the values 5) Install...

PRACTICAL SETUP 1) Install Zabbix Java Gateway 2) Configure Zabbix Java Gateway and Zabbix server 3) Configure the "Training resources" host: Add JMX interface Link template: DNS: training.lan Generic Java JMX Port: 12345 4) Check JMX agent icon status and "Latest data" for the values 5) Install jmxterm command-line utility Get available Mbeans using jmxterm Add "HeapMemoryUsage: init" to the "Generic Java JMX" template 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved 20 minutes Practical task No: 20 41 VMware monitoring 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved 30 minutes 42 Monitoring VMware environments: MONITORING OF VMWARE Auto-discovery of clusters, hypervisors, datastores and guest VMs Support the host prototypes; able to extend for XEN, KVM, Linux Containers, etc. Minimum required version for VMware vCenter or vSphere is 5.1 i https://www.zabbix.com/documentation/current/manual/vm_monitoring 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 43 MONITORING OF VMWARE Works out-of-the-box Does not require any 3rd party tools It is based on native VMWare SOAP API Optimized to generate as less API calls as possible The call-outs below identify the VMware data collection process found in the diagram 1. 2. 3. 4. Configuration data request Information about VMs Performance counter statistics request Performance counter statistics 1 2 3 Zabbix Server 6.0 Certified Professional ● Day 3 4 © 2023 by Zabbix. All rights reserved vCenter or ESXi Theory 44 Main templates for monitoring VMware: VMware FQDN VMWARE TEMPLATES The main template using FQDN for macros (recommended) Monitored VM should have a unique OS name compliant with FQDN rules VMware Tools must be installed on every machine VMware The main template using UUID for macros Can be used if FQDN requirements cannot be met The monitoring templates are automatically assigned by the main template: VMware Guest monitor virtual machines VMware Hypervisor monitor hypervisors 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 45 VMWARE DISCOVERY Low-level discovery rule is used to automatically discover: VMware clusters, hypervisors, datastores and virtual machines It is possible to control, which parts are monitored by disabling discovery rules The user macros are defined on the "VMware" or "VMware FQDN" template: {$VMWARE.USERNAME} VMware service username {$VMWARE.PASSWORD} VMware service password {$VMWARE.URL} VMware service SDK URL (https://servername/sdk) 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 46 Host prototypes are used to add new hosts: For Hypervisors on the template "VMware Hypervisor" For Virtual machines on the template "VMware Guest" VMWARE DISCOVERY Datastores and clusters are created as items under vCenter host: 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 47 HOST PROTOTYPES Hosts can be created using Low-level discovery rules through host prototypes: Discovered hosts will be associated with the LLD rule of the host that created them Host prototypes cannot have their own items, triggers or graphs All entities are inherited from the linked templates LLD rules are responsible for creating, updating, and deleting hosts as needed LLD macros should be utilized in the following fields of the host prototype: Host name Visible name Host group prototype You have the option to define the subsequent host properties: Template linkage Interfaces with LLD macros as addresses Tags with LLD macros as values User macros with LLD macros as values Inventory settings 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 48 Configuration of a Host prototype HOST PROTOTYPE CONFIGURATION LLD macros are used for: Host name Visible name Host group prototypes Interface address Tags User macros A host can be assigned to Existing Host groups Host groups created from prototype Template linkage The hosts created by the host prototype will become read-only: They can be modified only by changing the host prototype properties Deleted hosts will be rediscovered by LLD rule 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 49 HOSTS DISCOVERED BY LLD Discovered hosts are prefixed with the name of the discovery rule Most of the configuration options are read-only, except: Enabling or disabling the host Host inventory values in manual mode Discovered hosts can be removed: Automatically, based on Keep lost resources period (in days) value of the discovery rule Manually Discovered hosts can have their own inherited LLD rules through templates LLD rules on discovered hosts cannot include host prototypes 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 50 VMWARE COLLECTORS Zabbix uses VMware collectors to collect the information about virtual infrastructure Information can be gathered from vCenter or from each hypervisor separately Up to 2 VMware collectors may be used for each connection to VMware infrastructure data One collector is collecting VMware configuration Other collector is collecting VMware performance metrics configuration with vCenter without vCenter Hypervisor A Hypervisor B Hypervisor A vCenter Hypervisor C 6.0 Certified Professional ● Day 3 VMware collector #1 VMware collector #1 VMware collector #2 VMware collector #2 VMware collector #3 Hypervisor B VMware collector #4 © 2023 by Zabbix. All rights reserved Theory 51 VMWARE MONITORING Collected information is stored into VMware cache Information in the VMware cache is updated based on Zabbix server configuration parameters Poller collects information from cache based on the update interval in item configuration ### Option: VMwareFrequency # How often Zabbix will connect to VMware service to obtain a new data. VMwareFrequency=60 ### Option: VMwarePerfFrequency # How often Zabbix will connect to VMware service to obtain performance data. VMwarePerfFrequency=60 VMwarePerfFrequency Item update interval VMware collector #1 vmware cache Vcenter VMwareFrequency 6.0 Certified Professional ● Day 3 poller VMware collector #2 © 2023 by Zabbix. All rights reserved Theory 52 MONITORING OF VMWARE - CONFIGURATION Create a new host for vCenter or Hypervisor: Link a template named "VMware" A dummy host interface is required, because VMware checks are "simple checks" ! The IP address of agent interface will not be used for VMware monitoring! 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 53 MONITORING OF VMWARE - CONFIGURATION Define the user macros on the host: Use "Inherited and host macros" section It is recommended to use the secret text option for a password Define VMWARE macros Done! Wait for a moment and check Hosts or Latest data section 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 54 MONITORING OF VMWARE - DATA Monitoring > Hosts Latest data view 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 55 MONITORING OF VMWARE - COMMON ISSUES No data collected – check Zabbix server or proxy configuration file: With StartVMwareCollectors = 0 no data will be collected No new hosts created – check errors for the LLD rules Strange-looking graphs? Item update interval is less than VMwarePerfFrequency 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 56 MONITORING OF VMWARE - EXTENDING TEMPLATES Retrieving additional performance statistics for hypervisor and virtual machines: vmware.hv.perfcounter[<url>,<uuid>,<path>,<instance>] vmware.vm.perfcounter[<url>,<uuid>,<path>,<instance>] vmware.hv.sensors.get[<url>,<uuid>] Example. CPU usage expressed as a percentage: vmware.hv.perfcounter[{$VMWARE.URL},{HOST.HOST},"cpu/usage[average]"] More details: https://www.vmware.com/support/developer/converter-sdk/conv60_apireference/vim.PerformanceManager.html https://www.vmware.com/support/developer/converter-sdk/conv60_apireference/cpu_counters.html 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved Theory 57 Advanced problem detection 6.0 Certified Professional ● Day 3 © 2023 by Zabbix. All rights reserved 30 minutes 58 TIMESHIFT DEFINITION Zabbix trigger functions support two types of the timeshift: Relative timeshift 1 day period from current time time Yesterday 00:00:00 Yesterday 09:32:14 Today 00:00:00 Now 09:32:14 Tomorrow 00:00:00 Absolute timeshift Entire yesterday time Yesterday 00:00:00 6.0 Certified Professional ● Day 3 Today 00:00:00 Now 09:32:14 © 2023 by Zabbix. All rights reserved Tomorrow 00:00:00 Theory 59 TIMESHIFT WITH RELATIVE PERIODS The relative time shift uses the current time as a starting point: This parameter allows to reference data from the time period in the past Time shift starts with now - specifying the current time, followed by: +N<time unit> -N<time unit> to add N time units to subtract N time units avg(/host/key,4h:now-1d) Complex expressions are supported by using multiple time units in calculation avg(/host/key,6h:now-1d+8h) 6h:now-16h 4h:now-1d 4h 6h:now-1d+8h time 22 23 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 Yesterday 2021-10-20 00:00:00 6.0 Certified Professional ● Day 3 1 Today 2021-10-21 00:00:00 © 2023 by Zabbix. All rights reserved 2 3 4 5 6 Now 2021-10-21 06:00:00 Theory 60

Use Quizgecko on...
Browser
Browser