Skip to content

Instantly share code, notes, and snippets.

@jbfavre
Last active March 8, 2020 19:24
Show Gist options
  • Save jbfavre/6811939 to your computer and use it in GitHub Desktop.
Save jbfavre/6811939 to your computer and use it in GitHub Desktop.
Vertica monitoring draft. Which relevant informations can we get from v_monitor view ?

Vertica monitoring

Found into Vertica Ganglia monitoring package:

SQL statements

from verticalib.php

Events (SNMP Trap)

select node_name,event_problem_description,event_severity,reporting_node,event_expiration,current_timestamp,event_posted_timestamp from v_monitor.active_events

Which could be replaced with

select count(*),event_severity from v_monitor.active_events group by event_severity

Other

select designed_fault_tolerance,current_fault_tolerance from v_monitor.system
select display_license()

from fetch_vt_info.php

select node_name,active_user_session_count,active_system_session_count,total_user_session_count,total_system_session_count,total_active_session_count,total_session_count,running_query_count,executed_query_count from v_monitor.query_metrics
select node_name,request_count,local_request_count,nvl(request_queue_depth,0),active_thread_count,open_file_handle_count,memory_requested_kb,address_space_requested_kb,wos_used_bytes,wos_row_count,ros_used_bytes,ros_row_count,total_used_bytes,total_row_count from v_monitor.resource_usage
select node_name,disk_block_size_bytes,disk_space_used_blocks,disk_space_used_mb,disk_space_free_blocks,disk_space_free_mb,disk_space_free_percent from v_monitor.disk_storage

from ros_count.pl

Nothing for now

admintools commands

/opt/vertica/bin/admintools -t list_db -d <DBNAME>
/opt/vertica/bin/admintools -t host_to_node -d <DBNAME> -s <HOSTINFO> (from previous command output)
/opt/vertica/bin/admintools -t view_cluster

Found from v_monitor table list

SQL statements

select * from v_monitor.node_resources
select * from v_monitor.locks
select count(*),user_name,reason from v_monitor.login_failures group by user_name,reason
select * from v_monitor.disk_storage
select * from v_monitor.error_messages
select * from v_monitor.host_resources
select * from v_monitor.query_metrics
select * from v_monitor.resource_usage
select tuning_cost, count(*) from v_monitor.tuning_recommendations group by tuning_cost

select * from v_monitor.node_states where event_timestamp >= TIMESTAMP 'NOW' - INTERVAL '1 minute'

select * from v_monitor.network_usage where (TIMESTAMP 'NOW' - INTERVAL '1 minute') >= start_time and (TIMESTAMP 'NOW' - INTERVAL '1 minute') <= end_time
select * from v_monitor.cpu_usage where (TIMESTAMP 'NOW' - INTERVAL '1 minute') >= start_time and (TIMESTAMP 'NOW' - INTERVAL '1 minute') <= end_time
select * from v_monitor.io_usage where (TIMESTAMP 'NOW' - INTERVAL '1 minute') >= start_time and (TIMESTAMP 'NOW' - INTERVAL '1 minute') <= end_time

admintools commands

/opt/vertica/bin/admintools -t node_map
/opt/vertica/bin/admintools -t db_status -s [UP|DOWN|ALL]
/opt/vertica/bin/admintools -t list_allnodes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment