diff --git a/pandora_agents/unix/FreeBSD/pandora_agent.conf b/pandora_agents/unix/FreeBSD/pandora_agent.conf index 4ea1e428eb..62fa6bdec5 100644 --- a/pandora_agents/unix/FreeBSD/pandora_agent.conf +++ b/pandora_agents/unix/FreeBSD/pandora_agent.conf @@ -39,7 +39,9 @@ udp_server_auth_address 0.0.0.0 # To define agent name by specific command, define 'agent_name_cmd'. # (In the following example, agent name is 'hostname_IP') -#agent_name_cmd /bin/echo -n `hostname` ; /bin/echo -n "_" ; /bin/echo `/sbin/ifconfig bce0 | /usr/bin/grep 'inet' | /usr/bin/awk '{print $2;}' | cut -d: -f2` +# If set to __rand__ the agent will generate a random name. +#agent_name_cmd LANG=C; /bin/echo -n `hostname`; /bin/echo -n "_"; /bin/echo `/sbin/ifconfig eth0 | /bin/grep 'inet addr' | /usr/bin/awk '{print $2;}' | /usr/bin/cut -d: -f2` +agent_name_cmd __rand__ #Parent agent_name #parent_agent_name parent_name diff --git a/pandora_agents/unix/Linux/pandora_agent.conf b/pandora_agents/unix/Linux/pandora_agent.conf index a4e2a62a2c..0fbce4900c 100644 --- a/pandora_agents/unix/Linux/pandora_agent.conf +++ b/pandora_agents/unix/Linux/pandora_agent.conf @@ -39,7 +39,9 @@ udp_server_auth_address 0.0.0.0 # To define agent name by specific command, define 'agent_name_cmd'. # (In the following example, agent name is 'hostname_IP') +# If set to __rand__ the agent will generate a random name. #agent_name_cmd LANG=C; /bin/echo -n `hostname`; /bin/echo -n "_"; /bin/echo `/sbin/ifconfig eth0 | /bin/grep 'inet addr' | /usr/bin/awk '{print $2;}' | /usr/bin/cut -d: -f2` +agent_name_cmd __rand__ #Parent agent_name #parent_agent_name caprica diff --git a/pandora_agents/win32/bin/pandora_agent.conf b/pandora_agents/win32/bin/pandora_agent.conf index 3b0aabc91b..fb37a56175 100644 --- a/pandora_agents/win32/bin/pandora_agent.conf +++ b/pandora_agents/win32/bin/pandora_agent.conf @@ -33,7 +33,10 @@ temporal "%ProgramFiles%\pandora_agent\temp" # To define agent name by specific command, define 'agent_name_cmd'. # If agent_name_cmd is defined, agent_name is ignored. # (In the following example, agent name is 'hostname_IP') +# If set to __rand__ the agent will generate a random name. #agent_name_cmd cscript.exe //B "%ProgramFiles%\Pandora_Agent\util\agentname.vbs" +agent_name_cmd __rand__ + #Parent agent_name #parent_agent_name caprica diff --git a/pandora_server/lib/PandoraFMS/Core.pm b/pandora_server/lib/PandoraFMS/Core.pm index 3aecfb9f08..ef236546e1 100644 --- a/pandora_server/lib/PandoraFMS/Core.pm +++ b/pandora_server/lib/PandoraFMS/Core.pm @@ -4495,7 +4495,7 @@ sub pandora_self_monitoring ($$) { my $xml_output = ""; - $xml_output = ""; + $xml_output = ""; $xml_output .=" "; $xml_output .=" Status"; $xml_output .=" generic_proc";