(against 'include/utility_functions.php')
Code: Select all
127c127
< command) values ($local_data_id," . $host["id"] . "," . $data_input["id"] . ",$action_type,'" . $host["management_ip"] . "',
---
> command,rrd_num) values ($local_data_id," . (empty($host["id"]) ? 0 : $host["id"]) . "," . $data_input["id"] . ",$action_type,'" . $host["management_ip"] . "',
131c131
< '" . get_data_source_path($local_data_id,true) . "','$command')");
---
> '" . get_data_source_path($local_data_id,true) . "','$command',1)");
148c148
< arg1) values ($local_data_id," . $host["id"] . "," . $data_input["id"]. ",0,'" . $host["management_ip"] . "',
---
> arg1,rrd_num) values ($local_data_id," . (empty($host["id"]) ? 0 : $host["id"]) . "," . $data_input["id"]. ",0,'" . $host["management_ip"] . "',
152c152
< '" . get_data_source_path($local_data_id,true) . "','" . $field["snmp_oid"] . "')");
---
> '" . get_data_source_path($local_data_id,true,1) . "','" . $field["snmp_oid"] . "',1)");
167c167
< arg1) values ($local_data_id," . $host["id"] . "," . $data_input["id"]. ",0,'" . $host["management_ip"] . "',
---
> arg1,rrd_num) values ($local_data_id," . (empty($host["id"]) ? 0 : $host["id"]) . "," . $data_input["id"]. ",0,'" . $host["management_ip"] . "',
171c171
< '" . get_data_source_path($local_data_id,true) . "','$oid')");
---
> '" . get_data_source_path($local_data_id,true) . "','$oid'," . sizeof($outputs) . ")");
199,200c199,200
< snmp_community,snmp_version,snmp_username,snmp_password,rrd_name,rrd_path,command) values
< ($local_data_id," . $host["id"] . "," . $data_input["id"]. ",1,'" . $host["management_ip"] . "',
---
> snmp_community,snmp_version,snmp_username,snmp_password,rrd_name,rrd_path,command,rrd_num) values
> ($local_data_id," . (empty($host["id"]) ? 0 : $host["id"]) . "," . $data_input["id"]. ",1,'" . $host["management_ip"] . "',204c204
< '" . get_data_source_path($local_data_id,true) . "','$script_path')");
---
> '" . get_data_source_path($local_data_id,true) . "','$script_path'," . sizeof($outputs) . ")");
Code: Select all
ALTER TABLE `data_input_data_cache` ADD `rrd_num` TINYINT( 2 ) UNSIGNED NOT NULL AFTER `rrd_path`;