Viewing Current Data Retention Policy
To view the current retention policy for a Data Collector component, use the GET_DATA_COLLECTOR_POLICY() function and supply the component name as the function's argument.
To retrieve a list of all current component names, query the V_MONITOR.DATA_COLLECTOR system table, which returns Data Collector components, their current retention policies, and statistics about how much data is retained. For example:
mcdb=> \xExpanded display is on. mcdb=> SELECT * from data_collector; -[ RECORD 1 ]----------+------------------------------------------------------------------------------------------- node_name | v_mcdb_node0001 component | AllocationPoolStatistics table_name | dc_allocation_pool_statistics description | Information about global memory pools, which generally cannot be recovered without restart access_restricted | t in_db_log | f in_vertica_log | f memory_buffer_size_kb | 64 disk_size_kb | 256 record_too_big_errors | 0 lost_buffers | 0 lost_records | 0 retired_files | 1429 retired_records | 647358 current_memory_records | 0 current_disk_records | 1493 current_memory_bytes | 0 current_disk_bytes | 215737 first_time | 2012-11-30 07:04:30.000726-05 last_time | 2012-11-30 07:16:56.000631-05 kb_per_day | 24377.3198211312 -[ RECORD 2 ]----------+-------------------------------------------------------------------------------------------
The following command returns the retention policy for a specific component, NodeState
.
=> SELECT get_data_collector_policy('NodeState');
The results let you know that 10KB is retained in memory and 100KB on disk:
get_data_collector_policy------------------------------------------ 10KB kept in memory, 100KB kept on disk. (1 row)