From c73625b031181d8c0ca65760ae44a1dbae4400df Mon Sep 17 00:00:00 2001 From: Siri Hansen Date: Fri, 21 Sep 2012 10:09:49 +0200 Subject: [common_test] Use ct_snmp 'agent_vsns' config value in snmp app config OTP-10432 Config parameter 'agent_vsns' in ct_snmp was ONLY used in call to snmp_config:write_agent_snmp_files. There it is only used for deciding if usm config shall be written (if v3 is included) or not. The value of 'agent_vsns' was NOT added to the snmp application's agent configuration, so the snmp application's own default value would be used - this is [v1,v2,v3]. The result was that if v3 was not included in 'agent_vsns', then usm.conf was not written, but when starting the agent it would complain that this file did not exist since snmp's default versions are all [v1,v2,v3]. This has been corrected - the 'agent_vsns' value is now inserted in the snmp application agent configuration as {versions,AgentVsns}. --- lib/common_test/src/ct_snmp.erl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/common_test/src') diff --git a/lib/common_test/src/ct_snmp.erl b/lib/common_test/src/ct_snmp.erl index 6ff21645c9..02f849201d 100644 --- a/lib/common_test/src/ct_snmp.erl +++ b/lib/common_test/src/ct_snmp.erl @@ -490,7 +490,8 @@ setup_agent(true, AgentConfName, SnmpConfName, {verbosity, trace}]}, {agent_type, master}, {agent_verbosity, trace}, - {net_if, [{verbosity, trace}]}], + {net_if, [{verbosity, trace}]}, + {versions, Vsns}], ct:get_config({SnmpConfName,agent})), application:set_env(snmp, agent, SnmpEnv). %%%--------------------------------------------------------------------------- -- cgit v1.2.3