From ef8d7adad0e1556dc6c1eb26c23b483247bc1e5c Mon Sep 17 00:00:00 2001 From: Tony Murray Date: Tue, 8 Jan 2019 13:46:45 -0600 Subject: [PATCH] Remove graph_types definitions from DB (#9618) * Remove graph_types from DB. This is silly since defining them in definitions.inc.php already does the same thing. Adds missing ones in definitions.inc.php and rewrites others since I already wrote them before I realized they were duplicates. * remove dead table * Remove graph_types inserts from schema files. * update db_schema.yaml --- build.sql | 1 - doc/Developing/os/Custom-Graphs.md | 31 ++---------- includes/definitions.inc.php | 76 ++++++++++++------------------ misc/db_schema.yaml | 11 ----- sql-schema/032.sql | 1 - sql-schema/073.sql | 2 - sql-schema/140.sql | 1 - sql-schema/141.sql | 1 - sql-schema/146.sql | 1 - sql-schema/148.sql | 1 - sql-schema/152.sql | 2 - sql-schema/155.sql | 4 -- sql-schema/194.sql | 1 - sql-schema/229.sql | 1 - sql-schema/231.sql | 1 - sql-schema/250.sql | 6 --- sql-schema/251.sql | 1 - sql-schema/252.sql | 1 - sql-schema/269.sql | 1 - sql-schema/279.sql | 1 + tests/bootstrap.php | 2 - 21 files changed, 36 insertions(+), 111 deletions(-) create mode 100644 sql-schema/279.sql diff --git a/build.sql b/build.sql index 01f8192ef9..a6e7ab313d 100644 --- a/build.sql +++ b/build.sql @@ -73,7 +73,6 @@ CREATE TABLE IF NOT EXISTS `ports_adsl` ( `interface_id` int(11) NOT NULL, `po CREATE TABLE IF NOT EXISTS `perf_times` ( `type` varchar(8) NOT NULL, `doing` varchar(64) NOT NULL, `start` int(11) NOT NULL, `duration` double(5,2) NOT NULL, `devices` int(11) NOT NULL, KEY `type` (`type`)) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin; CREATE TABLE IF NOT EXISTS `device_graphs` ( `device_id` int(11) NOT NULL, `graph` varchar(32) COLLATE utf8_unicode_ci NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; CREATE TABLE IF NOT EXISTS `graph_types` ( `graph_type` varchar(32) COLLATE utf8_unicode_ci NOT NULL, `graph_subtype` varchar(32) COLLATE utf8_unicode_ci NOT NULL, `graph_section` varchar(32) COLLATE utf8_unicode_ci NOT NULL, `graph_descr` varchar(64) COLLATE utf8_unicode_ci NOT NULL, `graph_order` int(11) NOT NULL, KEY `graph_type` (`graph_type`), KEY `graph_subtype` (`graph_subtype`), KEY `graph_section` (`graph_section`)) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -INSERT INTO `graph_types` (`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES('device', 'bits', 'netstats', 'Total Traffic', 0),('device', 'hr_users', 'system', 'Users Logged In', 0),('device', 'ucd_load', 'system', 'Load Averages', 0),('device', 'ucd_cpu', 'system', 'Detailed Processor Usage', 0),('device', 'ucd_memory', 'system', 'Detailed Memory Usage', 0),('device', 'netstat_tcp', 'netstats', 'TCP Statistics', 0),('device', 'netstat_icmp_info', 'netstats', 'ICMP Informational Statistics', 0),('device', 'netstat_icmp_stat', 'netstats', 'ICMP Statistics', 0),('device', 'netstat_ip', 'netstats', 'IP Statistics', 0),('device', 'netstat_ip_frag', 'netstats', 'IP Fragmentation Statistics', 0),('device', 'netstat_udp', 'netstats', 'UDP Statistics', 0),('device', 'netstat_snmp', 'netstats', 'SNMP Statistics', 0),('device', 'temperatures', 'system', 'Temperatures', 0),('device', 'mempools', 'system', 'Memory Pool Usage', 0),('device', 'processors', 'system', 'Processor Usage', 0),('device', 'storage', 'system', 'Filesystem Usage', 0),('device', 'hr_processes', 'system', 'Running Processes', 0),('device', 'uptime', 'system', 'System Uptime', 0),('device', 'ipsystemstats_ipv4', 'netstats', 'IPv4 Packet Statistics', 0),('device', 'ipsystemstats_ipv6_frag', 'netstats', 'IPv6 Fragmentation Statistics', 0),('device', 'ipsystemstats_ipv6', 'netstats', 'IPv6 Packet Statistics', 0),('device', 'ipsystemstats_ipv4_frag', 'netstats', 'IPv4 Fragmentation Statistics', 0),('device', 'fortigate_sessions', 'firewall', 'Active Sessions', 0), ('device', 'screenos_sessions', 'firewall', 'Active Sessions', 0), ('device', 'fdb_count', 'system', 'MAC Addresses Learnt', 0),('device', 'cras_sessions', 'firewall', 'Remote Access Sessions', 0); CREATE TABLE IF NOT EXISTS `vminfo` (`id` int(11) NOT NULL AUTO_INCREMENT, `device_id` int(11) NOT NULL, `vmwVmVMID` int(11) NOT NULL, `vmwVmDisplayName` varchar(128) NOT NULL, `vmwVmGuestOS` varchar(128) NOT NULL, `vmwVmMemSize` int(11) NOT NULL, `vmwVmCpus` int(11) NOT NULL, `vmwVmState` varchar(128) NOT NULL, PRIMARY KEY (`id`), KEY `device_id` (`device_id`), KEY `vmwVmVMID` (`vmwVmVMID`)) ENGINE=InnoDB DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `cef_switching` ( `device_id` int(11) NOT NULL, `entPhysicalIndex` int(11) NOT NULL, `afi` varchar(4) COLLATE utf8_unicode_ci NOT NULL, `cef_index` int(11) NOT NULL, `cef_path` varchar(16) COLLATE utf8_unicode_ci NOT NULL, `drop` int(11) NOT NULL, `punt` int(11) NOT NULL, `punt2host` int(11) NOT NULL, `drop_prev` int(11) NOT NULL, `punt_prev` int(11) NOT NULL, `punt2host_prev` int(11) NOT NULL,`updated` INT NOT NULL , `updated_prev` INT NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8; UPDATE sensors SET sensor_class='frequency' WHERE sensor_class='freq'; diff --git a/doc/Developing/os/Custom-Graphs.md b/doc/Developing/os/Custom-Graphs.md index bf193efa01..db9a1bccf0 100644 --- a/doc/Developing/os/Custom-Graphs.md +++ b/doc/Developing/os/Custom-Graphs.md @@ -1,17 +1,12 @@ source: Developing/os/Custom-Graphs.md path: blob/master/doc/ -If you are adding custom graphs, please add the following to `includes/definitions.inc.php`: -```php -//Don't forget to declare the specific graphs if needed. It will be located near the end of the file. +First we define our graphs in `includes/definitions.inc.php` to share our work and contribute in the development of LibreNMS. :-) (or place in `config.php` if you don't plan to contribute) -//Pulse Secure Graphs -$config['graph_types']['device']['pulse_users']['section'] = 'firewall'; -$config['graph_types']['device']['pulse_users']['order'] = '0'; -$config['graph_types']['device']['pulse_users']['descr'] = 'Active Users'; -$config['graph_types']['device']['pulse_sessions']['section'] = 'firewall'; -$config['graph_types']['device']['pulse_sessions']['order'] = '0'; -$config['graph_types']['device']['pulse_sessions']['descr'] = 'Active Sessions'; +```php +// Pulse Secure Graphs +$config['graph_types']['device']['pulse_sessions'] = ['section' => 'firewall', 'order' => 0, 'descr' => 'Active Sessions']; +$config['graph_types']['device']['pulse_users'] = ['section' => 'firewall', 'order' => 0, 'descr' => 'Active Users']; ``` #### Polling OS @@ -58,22 +53,6 @@ if (is_numeric($sessions)) { $graphs['pulse_sessions'] = true; } ``` -We finish in the declaration of the two graph types in the database: - -We can do that within a file to share our work and contribute in the development of LibreNMS. :-) - -```bash -sql-schema/xxx.sql -php includes/sql-schema/update.php -./scripts/build-schema.php -``` - -Or put the SQL commands directly in Mysql or PhpMyadmin for our tests: - -```php -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'pulse_users', 'firewall', 'Active Users', 0); -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'pulse_sessions', 'firewall', 'Active Sessions', 0); -``` #### Displaying diff --git a/includes/definitions.inc.php b/includes/definitions.inc.php index 050feb2ec5..e5bf77e491 100644 --- a/includes/definitions.inc.php +++ b/includes/definitions.inc.php @@ -220,9 +220,7 @@ $config['graph_types']['device']['screenos_sessions']['order'] = '0'; $config['graph_types']['device']['screenos_sessions']['descr'] = 'Active Sessions'; //FortiOS Graphs -$config['graph_types']['device']['fortios_lograte']['section'] = 'Analyzer'; -$config['graph_types']['device']['fortios_lograte']['order'] = '0'; -$config['graph_types']['device']['fortios_lograte']['descr'] = 'Log Rate'; +$config['graph_types']['device']['fortios_lograte'] = ['section' => 'analyzer', 'order' => 0, 'descr' => 'Log Rate']; //PAN OS Graphs $config['graph_types']['device']['panos_sessions']['section'] = 'firewall'; @@ -243,9 +241,7 @@ $config['graph_types']['device']['panos_sessions_ssl']['descr'] = 'Activ $config['graph_types']['device']['panos_sessions_sslutil']['section'] = 'firewall'; $config['graph_types']['device']['panos_sessions_sslutil']['order'] = '0'; $config['graph_types']['device']['panos_sessions_sslutil']['descr'] = 'Active SSL Proxy Utilization'; -$config['graph_types']['device']['panos_activetunnels']['section'] = 'firewall'; -$config['graph_types']['device']['panos_activetunnels']['order'] = '0'; -$config['graph_types']['device']['panos_activetunnels']['descr'] = 'Active GlobalProtect Tunnels'; +$config['graph_types']['device']['panos_activetunnels'] = ['section' => 'firewall', 'order' => 0, 'descr' => 'Active GlobalProtect Tunnels']; //PF Graphs $config['graph_types']['device']['pf_states']['section'] = 'firewall'; @@ -279,17 +275,9 @@ $config['graph_types']['device']['pf_memdropped']['section'] = 'firewall $config['graph_types']['device']['pf_memdropped']['order'] = '10'; $config['graph_types']['device']['pf_memdropped']['descr'] = 'MemDropped'; - - - - //Pulse Secure Graphs -$config['graph_types']['device']['pulse_users']['section'] = 'firewall'; -$config['graph_types']['device']['pulse_users']['order'] = '0'; -$config['graph_types']['device']['pulse_users']['descr'] = 'Active Users'; -$config['graph_types']['device']['pulse_sessions']['section'] = 'firewall'; -$config['graph_types']['device']['pulse_sessions']['order'] = '0'; -$config['graph_types']['device']['pulse_sessions']['descr'] = 'Active Sessions'; +$config['graph_types']['device']['pulse_sessions'] = ['section' => 'firewall', 'order' => 0, 'descr' => 'Active Sessions']; +$config['graph_types']['device']['pulse_users'] = ['section' => 'firewall', 'order' => 0, 'descr' => 'Active Users']; // Infoblox dns/dhcp Graphs $config['graph_types']['device']['ib_dns_dyn_updates']['section'] = 'dns'; @@ -306,14 +294,10 @@ $config['graph_types']['device']['ib_dhcp_messages']['order'] = $config['graph_types']['device']['ib_dhcp_messages']['descr'] = 'DHCP messages'; // Cisco WAAS Optimized TCP Connections -$config['graph_types']['device']['waas_cwotfostatsactiveoptconn']['section'] = 'graphs'; -$config['graph_types']['device']['waas_cwotfostatsactiveoptconn']['order'] = '0'; -$config['graph_types']['device']['waas_cwotfostatsactiveoptconn']['descr'] = 'Optimized TCP Connections'; +$config['graph_types']['device']['waas_cwotfostatsactiveoptconn'] = ['section' => 'graphs', 'order' => 0, 'descr' => 'Optimized TCP Connections']; // SonicWALL Sessions -$config['graph_types']['device']['sonicwall_sessions']['section'] = 'firewall'; -$config['graph_types']['device']['sonicwall_sessions']['order'] = '0'; -$config['graph_types']['device']['sonicwall_sessions']['descr'] = 'Active Sessions'; +$config['graph_types']['device']['sonicwall_sessions'] = ['section' => 'firewall', 'order' => 0, 'descr' => 'Active Sessions']; $config['graph_types']['device']['bits']['section'] = 'netstats'; $config['graph_types']['device']['bits']['order'] = '0'; @@ -438,9 +422,7 @@ $config['graph_types']['device']['netscaler_tcp_pkts']['section'] = 'load balanc $config['graph_types']['device']['netscaler_tcp_pkts']['order'] = '0'; $config['graph_types']['device']['netscaler_tcp_pkts']['descr'] = 'TCP Packets'; -$config['graph_types']['device']['asa_conns']['section'] = 'firewall'; -$config['graph_types']['device']['asa_conns']['order'] = '0'; -$config['graph_types']['device']['asa_conns']['descr'] = 'Current connections'; +$config['graph_types']['device']['asa_conns'] = ['section' => 'firewall', 'order' => 0, 'descr' => 'Current connections']; $config['graph_types']['device']['cisco-iospri']['section'] = 'voice'; $config['graph_types']['device']['cisco-iospri']['order'] = '0'; @@ -477,9 +459,8 @@ $config['graph_types']['device']['sgos_average_requests']['order'] = '0'; $config['graph_types']['device']['sgos_average_requests']['descr'] = 'Average HTTP Requests'; // SRX Flow Sessions -$config['graph_types']['device']['junos_jsrx_spu_sessions']['section'] = 'network'; -$config['graph_types']['device']['junos_jsrx_spu_sessions']['order'] = '0'; -$config['graph_types']['device']['junos_jsrx_spu_sessions']['descr'] = 'Flow Sessions'; +$config['graph_types']['device']['junos_jsrx_spu_flows'] = ['section' => 'network', 'order' => 0, 'descr' => 'SPU Flows']; +$config['graph_types']['device']['junos_jsrx_spu_sessions'] = ['section' => 'network', 'order' => 1, 'descr' => 'Flow Sessions']; // Blue Coat SGOS // Client Connections @@ -512,18 +493,10 @@ $config['graph_types']['device']['bluecoat_http_server_connections_idle']['descr //riverbed specific graphs -$config['graph_types']['device']['riverbed_connections']['section'] = 'network'; -$config['graph_types']['device']['riverbed_connections']['order'] = 0; -$config['graph_types']['device']['riverbed_connections']['descr'] = 'Connections'; -$config['graph_types']['device']['riverbed_optimization']['section'] = 'network'; -$config['graph_types']['device']['riverbed_optimization']['order'] = 1; -$config['graph_types']['device']['riverbed_optimization']['descr'] = 'Optimization'; -$config['graph_types']['device']['riverbed_datastore']['section'] = 'network'; -$config['graph_types']['device']['riverbed_datastore']['order'] = 2; -$config['graph_types']['device']['riverbed_datastore']['descr'] = 'Data store productivity'; -$config['graph_types']['device']['riverbed_passthrough']['section'] = 'network'; -$config['graph_types']['device']['riverbed_passthrough']['order'] = 3; -$config['graph_types']['device']['riverbed_passthrough']['descr'] = 'Bandwidth Passthrough'; +$config['graph_types']['device']['riverbed_connections'] = ['section' => 'network', 'order' => 0, 'descr' => 'Connections']; +$config['graph_types']['device']['riverbed_optimization'] = ['section' => 'network', 'order' => 1, 'descr' => 'Optimization']; +$config['graph_types']['device']['riverbed_datastore'] = ['section' => 'network', 'order' => 2, 'descr' => 'Datastore productivity']; +$config['graph_types']['device']['riverbed_passthrough'] = ['section' => 'network', 'order' => 3, 'descr' => 'Bandwidth passthrough']; //mikrotik specific graphs $config['graph_types']['device']['routeros_leases']['section'] = 'network'; @@ -537,14 +510,25 @@ $config['graph_types']['device']['secureplatform_sessions']['order'] = 0; $config['graph_types']['device']['secureplatform_sessions']['descr'] = 'Active connections'; //arbos specific graphs -$config['graph_types']['device']['arbos_flows']['section'] = 'graphs'; -$config['graph_types']['device']['arbos_flows']['order'] = '0'; -$config['graph_types']['device']['arbos_flows']['descr'] = 'Accumulative flow count per SP device'; +$config['graph_types']['device']['arbos_flows'] = ['section' => 'graphs', 'order' => 0, 'descr' => 'Accumulative flow count per SP device']; //F5 specific graphs -$config['graph_types']['device']['apm_sessions']['section'] = 'apm'; -$config['graph_types']['device']['apm_sessions']['order'] = '0'; -$config['graph_types']['device']['apm_sessions']['descr'] = 'Active Sessions'; +$config['graph_types']['device']['bigip_apm_sessions'] = ['section' => 'apm', 'order' => 0, 'descr' => 'Active Sessions']; + +// Bluecoat ProxySG Graphs +$config['graph_types']['device']['sgos_average_requests'] = ['section' => 'network', 'order' => 0, 'descr' => 'Average HTTP Requests']; +$config['graph_types']['device']['sgos_client_connections'] = ['section' => 'network', 'order' => 1, 'descr' => 'HTTP Client Connections']; +$config['graph_types']['device']['sgos_client_connections_active'] = ['section' => 'network', 'order' => 2, 'descr' => 'HTTP Client Connections Active']; +$config['graph_types']['device']['sgos_client_connections_idle'] = ['section' => 'network', 'order' => 3, 'descr' => 'HTTP Client Connections Idle']; +$config['graph_types']['device']['sgos_server_connections'] = ['section' => 'network', 'order' => 4, 'descr' => 'HTTP Server Connections']; +$config['graph_types']['device']['sgos_server_connections_active'] = ['section' => 'network', 'order' => 5, 'descr' => 'HTTP Server Connections Active']; +$config['graph_types']['device']['sgos_server_connections_idle'] = ['section' => 'network', 'order' => 6, 'descr' => 'HTTP Server Connections Idle']; + +// Cisco AsyncOS Graphs +$config['graph_types']['device']['asyncos_conns'] = ['section' => 'proxy', 'order' => 0, 'descr' => 'Current connections']; + +// Zywall Graphs +$config['graph_types']['device']['zywall_sessions'] = ['section' => 'firewall', 'order' => 0, 'descr' => 'Sessions']; // Device Types $i = 0; diff --git a/misc/db_schema.yaml b/misc/db_schema.yaml index d16962ad3a..80ee637fff 100644 --- a/misc/db_schema.yaml +++ b/misc/db_schema.yaml @@ -644,17 +644,6 @@ graph_types: graph_type: { Name: graph_type, Columns: [graph_type], Unique: false, Type: BTREE } graph_subtype: { Name: graph_subtype, Columns: [graph_subtype], Unique: false, Type: BTREE } graph_section: { Name: graph_section, Columns: [graph_section], Unique: false, Type: BTREE } -graph_types_dead: - Columns: - - { Field: graph_type, Type: varchar(32), 'Null': false, Extra: '' } - - { Field: graph_subtype, Type: varchar(32), 'Null': false, Extra: '' } - - { Field: graph_section, Type: varchar(32), 'Null': false, Extra: '' } - - { Field: graph_descr, Type: varchar(64), 'Null': false, Extra: '' } - - { Field: graph_order, Type: int(11), 'Null': false, Extra: '' } - Indexes: - graph_type: { Name: graph_type, Columns: [graph_type], Unique: false, Type: BTREE } - graph_subtype: { Name: graph_subtype, Columns: [graph_subtype], Unique: false, Type: BTREE } - graph_section: { Name: graph_section, Columns: [graph_section], Unique: false, Type: BTREE } hrDevice: Columns: - { Field: hrDevice_id, Type: 'int(10) unsigned', 'Null': false, Extra: auto_increment } diff --git a/sql-schema/032.sql b/sql-schema/032.sql index 81d5210a0d..f9f9189f1b 100644 --- a/sql-schema/032.sql +++ b/sql-schema/032.sql @@ -1,2 +1 @@ CREATE TABLE IF NOT EXISTS `ciscoASA` ( `ciscoASA_id` int(11) NOT NULL AUTO_INCREMENT, `device_id` int(11) NOT NULL, `oid` varchar(255) NOT NULL, `data` bigint(20) NOT NULL, `high_alert` bigint(20) NOT NULL, `low_alert` bigint(20) NOT NULL, `disabled` tinyint(4) NOT NULL DEFAULT '0', PRIMARY KEY (`ciscoASA_id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ; -INSERT INTO `graph_types` SET `graph_type`='device', `graph_subtype`='asa_conns',`graph_section`='firewall',`graph_descr`='Current connections',`graph_order`='0'; diff --git a/sql-schema/073.sql b/sql-schema/073.sql index 2342cb4db9..e69de29bb2 100644 --- a/sql-schema/073.sql +++ b/sql-schema/073.sql @@ -1,2 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'pulse_users', 'firewall', 'Active Users', 0); -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'pulse_sessions', 'firewall', 'Active Sessions', 0); diff --git a/sql-schema/140.sql b/sql-schema/140.sql index 91b9fa6e25..e69de29bb2 100644 --- a/sql-schema/140.sql +++ b/sql-schema/140.sql @@ -1 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'waas_cwotfostatsactiveoptconn', 'graphs', 'Optimized TCP Connections', 0); diff --git a/sql-schema/141.sql b/sql-schema/141.sql index 4e334d275f..e69de29bb2 100644 --- a/sql-schema/141.sql +++ b/sql-schema/141.sql @@ -1 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'panos_activetunnels', 'firewall', 'Active GlobalProtect Tunnels', 0); diff --git a/sql-schema/146.sql b/sql-schema/146.sql index 6444f69d16..e69de29bb2 100644 --- a/sql-schema/146.sql +++ b/sql-schema/146.sql @@ -1 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'sonicwall_sessions', 'firewall', 'Active Sessions', 0); diff --git a/sql-schema/148.sql b/sql-schema/148.sql index 42dba223f4..e69de29bb2 100644 --- a/sql-schema/148.sql +++ b/sql-schema/148.sql @@ -1 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'zywall_sessions', 'firewall', 'Sessions', 0); diff --git a/sql-schema/152.sql b/sql-schema/152.sql index 1014beb35c..e69de29bb2 100644 --- a/sql-schema/152.sql +++ b/sql-schema/152.sql @@ -1,2 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'sgos_average_requests', 'network', 'Average HTTP Requests', 0); - diff --git a/sql-schema/155.sql b/sql-schema/155.sql index 27b591b290..e69de29bb2 100644 --- a/sql-schema/155.sql +++ b/sql-schema/155.sql @@ -1,4 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'riverbed_connections', 'network', 'Connections', 0); -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'riverbed_optimization', 'network', 'Optimization', 0); -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'riverbed_datastore', 'network', 'Datastore productivity', 0); -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'riverbed_passthrough', 'network', 'Bandwidth passthrough', 0); diff --git a/sql-schema/194.sql b/sql-schema/194.sql index fce964810a..e69de29bb2 100644 --- a/sql-schema/194.sql +++ b/sql-schema/194.sql @@ -1 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'asyncos_conns', 'proxy', 'Current Connections', 0); diff --git a/sql-schema/229.sql b/sql-schema/229.sql index 88f1ffd099..e69de29bb2 100644 --- a/sql-schema/229.sql +++ b/sql-schema/229.sql @@ -1 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'arbos_flows', 'graphs', 'Accumulative flow count per SP device', 0); diff --git a/sql-schema/231.sql b/sql-schema/231.sql index 74a21db3dd..e69de29bb2 100644 --- a/sql-schema/231.sql +++ b/sql-schema/231.sql @@ -1 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'fortios_lograte', 'analyzer', 'Log Rate', 0); diff --git a/sql-schema/250.sql b/sql-schema/250.sql index 33fa0357fe..e69de29bb2 100644 --- a/sql-schema/250.sql +++ b/sql-schema/250.sql @@ -1,6 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'sgos_client_connections', 'network', 'HTTP Client Connections', 0); -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'sgos_server_connections', 'network', 'HTTP Server Connections', 0); -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'sgos_client_connections_active', 'network', 'HTTP Client Connections Active', 0); -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'sgos_server_connections_active', 'network', 'HTTP Server Connections Acitve', 0); -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'sgos_client_connections_idle', 'network', 'HTTP Client Connections Idle', 0); -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'sgos_server_connections_idle', 'network', 'HTTP Server Connections Idle', 0); diff --git a/sql-schema/251.sql b/sql-schema/251.sql index a0d808c3c2..481cdf1768 100644 --- a/sql-schema/251.sql +++ b/sql-schema/251.sql @@ -1,2 +1 @@ DELETE FROM `graph_types` WHERE `graph_descr` = 'HTTP Server Connections Acitve'; -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'sgos_server_connections_active', 'network', 'HTTP Server Connections Active', 0); diff --git a/sql-schema/252.sql b/sql-schema/252.sql index db74654b94..e69de29bb2 100644 --- a/sql-schema/252.sql +++ b/sql-schema/252.sql @@ -1 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'junos_jsrx_spu_flows', 'network', 'SPU Flows', 0); diff --git a/sql-schema/269.sql b/sql-schema/269.sql index 1fe4ce5564..e69de29bb2 100644 --- a/sql-schema/269.sql +++ b/sql-schema/269.sql @@ -1 +0,0 @@ -INSERT INTO `graph_types`(`graph_type`, `graph_subtype`, `graph_section`, `graph_descr`, `graph_order`) VALUES ('device', 'apm_sessions', 'apm', 'Active Sessions', 0); diff --git a/sql-schema/279.sql b/sql-schema/279.sql new file mode 100644 index 0000000000..838ff83197 --- /dev/null +++ b/sql-schema/279.sql @@ -0,0 +1 @@ +drop table graph_types_dead; diff --git a/tests/bootstrap.php b/tests/bootstrap.php index 267682d3a3..73936d80cb 100644 --- a/tests/bootstrap.php +++ b/tests/bootstrap.php @@ -101,8 +101,6 @@ if (getenv('DBTEST')) { 'alert_templates', 'config', // not sure about this one 'dbSchema', - 'graph_types', - 'port_association_mode', 'widgets', ); $truncate = array_diff($tables, $excluded);