aboutsummaryrefslogtreecommitdiffstats
path: root/lib/common_test/src/ct_snmp.erl
diff options
context:
space:
mode:
authorSiri Hansen <[email protected]>2012-09-21 10:09:49 +0200
committerSiri Hansen <[email protected]>2012-09-21 10:09:49 +0200
commitc73625b031181d8c0ca65760ae44a1dbae4400df (patch)
tree547d92fc8db1ebc487c8308f1d923f278a593928 /lib/common_test/src/ct_snmp.erl
parent53b3095adb6478c63da1ef5ef7f3006e4fd614ef (diff)
downloadotp-c73625b031181d8c0ca65760ae44a1dbae4400df.tar.gz
otp-c73625b031181d8c0ca65760ae44a1dbae4400df.tar.bz2
otp-c73625b031181d8c0ca65760ae44a1dbae4400df.zip
[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}.
Diffstat (limited to 'lib/common_test/src/ct_snmp.erl')
-rw-r--r--lib/common_test/src/ct_snmp.erl3
1 files changed, 2 insertions, 1 deletions
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).
%%%---------------------------------------------------------------------------