Hi,
We would like to inform you that there is no way to pass
the directory of configuration files as command line argument. If your
requirement is to change the location of configuration files, you need
to hard code the absolute path in the Main file(WebNMSnmpAgent.java) of
the generated agent.
For Example :(By default the below line will be present)
public static String agentDir = ".";
At present Agent takes the configuration files from the current
directory. If you need to change the configuration files location then
please hard code the absolute path(i.e where the conf directory is
located.)
public static String agentDir = "C:\\configfiles";
And also you have to change the xmlFiles(For Tables) location. For this you need to hardcode the absolute path in the corresponding (TableName)RequestHandler.java files.
For Example(By default)
AaplicationTableXMLToVector xmlToVector = new AaplicationTableXMLToVector(WebNMSSnmpAgent.agentDir + File.separator + "xmlFiles" + File.separator + "AGENT-SAMPLE-MIB", "AaplicationTable.xml", agentName);
In the above code please hard code the required absolutepath of xmlFiles in the bold code given above.
Trust the information provided is helpful. Please get back to us for any further clarification.
Thanks & Regards,
Jyothi.