Community discussions

MikroTik App
 
stx
just joined
Topic Author
Posts: 1
Joined: Mon Jan 27, 2014 8:12 am

Dude crash with VB Script, Problem with exe-functions

Mon Jan 27, 2014 9:23 am

Dear Collegues!

I have great troubles with Dude working with VB Scripts.
Since i use VB Scripts, Dude crashes. I can configure a lot of devices using functions and probes with VB Script.
All works fine. Than when i add a new device and use such a function, dude crashes. I am not able to connect to Dude Server, i have to restore a previous Version. Evenviewer lists many errors saying dude has crashed and restartet.

The simple scripts look like this:

set Args = Wscript.Arguments
Set fs=CreateObject("Scripting.FileSystemObject")
app_path=Mid(wscript.scriptfullname,1,instrRev(wscript.scriptfullname,"\"))
Set stdout = fs.GetStandardStream (1)
if args.Count <>1 then
wscript.echo VBCRLF & "Call Script with cscript.exe uncfreespace.vbs //NoLogo UNC-Path" & VBCRLF
else
uncpath =Wscript.Arguments(0)
Set fs = CreateObject("Scripting.FileSystemObject")
Set strdrive = fs.GetDrive(fs.GetDriveName(uncpath))
stdout.WriteLine Replace(Cstr(formatnumber(strdrive.freespace/1024/1024/1024,0)),".","")
end if

and the function looks like this :

0+array_element(execute("cscript.exe",concatenate(" c:\\Skripte\\uncfreespace.vbs ", " //NoLogo ", "\\", "\\", device_property("Name"), "\\", "c$"), "c:\\windows\\system32\\"),1)

So i thought, there is a problem running many scripts simultaniously.
Everything works fine until i has configured a amount of devices with this functions and probes.

The server runs under VMWare with OS Windows Server 2008 R2 SP1

As solution i thought i convert the scripts into exe-files.
But there is the same Problem. As i exceed a amount of Probes or functions dude crashes and i cannot connect to the Server.

Did anyone have similar problems and solved it?

Thank you

Who is online

Users browsing this forum: No registered users and 16 guests