I will try to change it but if I remember exactly, it was the snmpget with more than one OIDs in the list that does not understand correctly with the EXEC command.
And it works perfectly with SHELL command. Example: /usr/bin/snmpget - c public - v 2c 198.168.0.3 enterprises.ucdavis.52.101.1 enterprises.ucdavis.52.101.2 enterprises.ucdavis.52.101.3 enterprises.ucdavis.52.101.4 enterprises.ucdavis.52.101.5 And, the result that only the 1st Oids is executed on EXEC command but all are executed on the SHELL command. The list of OIDs depend of the config line to execute so it's a variable parameter. Le 17 août 09 à 22:30, Benoît Minisini a écrit : >> I tried the both solutions: SHELL and EXEC, but the parameters used >> are not the same for each command executed. >> >> So, after many tries, I the EXEC command give me errors during >> execution because it's very difficult to play with the character " or >> ' in the command. > > You just have to replace: > > SHELL "command " & Quote.Shell(arg1) & " " & Quote.Shell(arg2) ... > > By: > > EXEC [ "/usr/bin/command", arg1, arg2, ... ] ... > > I strongly suggest that you do replace SHELL by EXEC. I almost sure > that the > bottleneck is there! But I may be wrong. > > -- > Benoît > > ------------------------------------------------------------------------------ > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 > 30-Day > trial. Simplify your report design, integration and deployment - and > focus on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > Gambas-user mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/gambas-user Olivier Cruilles Mail: [email protected] ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ Gambas-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/gambas-user
