I have a problem I want to report.
When selecting the option "Graph Linked" on nectar report, I receive the mails with the graph linked to http://cacti/graph.php?.....
I can't figure out where is the plugin trying to take the hostname from as is obviously failing, thus leaving this empty.
I'd like this field to have an option in settings so you can define a manual entry, in addition to the script to try to define it automatically.
When you have a FQDN it makes sense to detect and set the hostname to it, but what if I want to point the graphs to a specific hostname or ip address?
For now, I'd like to know if I can temporarily solve it by manually setting this to what I want on the nectar_functions.php file
Could I just change this:
Code: Select all
if ($nectar["graph_linked"] == "on" ) {
/* determine our hostname/servername in different environments */
if (isset($_SERVER["SERVER_NAME"])) {
$hostname = $_SERVER["SERVER_NAME"];
} elseif (isset($_SERVER["HOSTNAME"])) {
$hostname = $_SERVER["HOSTNAME"];
} elseif (isset($_ENV["HOSTNAME"])) {
$hostname = $_ENV["HOSTNAME"];
} elseif (isset($_ENV["COMPUTERNAME"])) {
$hostname = $_ENV["COMPUTERNAME"];
} else {
$hostname = "";
}
Code: Select all
if ($nectar["graph_linked"] == "on" ) {
$hostname = "10.3.4.15";
}
Thanks!
Ziv