Hello guys I need to configure more 3 targets in my SNMP configuration. How I perform that?
I have the command:
vicfg-snmp.pl --server host.example.com --username root --password password -t target.example.com@162/public
I need to run this command 3 times or I use commas to insert all targets?
Anyone knows?
thanks.
Just tested the below string.
vicfg-snmp.pl --server <esx_host_name> --username root -t 1.1.1.1@162/public,2.2.2.2@162/public
/etc # cat /etc/vmware/snmp.xml
<config>
<snmpSettings>
<communities/>
<enable>false</enable>
<targets>1.1.1.1@162 public;2.2.2.2@162 public</targets>
</snmpSettings>
</config>/etc #
-KjB
Multiple targetes are separated by commas.
-KjB
Didn't work using commas. My snmp.xml file don't appear any target
/etc/vmware # cat snmp.xml
Just tested the below string.
vicfg-snmp.pl --server <esx_host_name> --username root -t 1.1.1.1@162/public,2.2.2.2@162/public
/etc # cat /etc/vmware/snmp.xml
<config>
<snmpSettings>
<communities/>
<enable>false</enable>
<targets>1.1.1.1@162 public;2.2.2.2@162 public</targets>
</snmpSettings>
</config>/etc #
-KjB
You better write a script for this. That will give result.
Cheers, Yours Udin
Hello thanks for your reply. Only work after I copy a new snmp.xml file with configurations in blank.
I already edited the file using one target.
Thanks.