K
Kai Thorsrud
Hi
I'm currently into converting a perl linux app into a .Net windows service.
The application monitors our syslog log files to capture i.p adress changes
on some of our routers having dynamic i.p. In the syslog logfile i capture
the new IP adress of the router. I then need to telnet to that i.p adress
and fetch the hostname. A list of these routers will be presented on a
webpage.
I've created the application in vb.net and most parts of it is working fine
except for the telnet module. I've created a TCPClient class that takes care
of this. However with my limited .Net experience this is gonna take some
time to implement the Telnet protocol to handle all sorts of stuff
However time is limited and i need to get this app up and running. I have a
perlscript doing this for me returning the routerconfig to stdout (the dos
window). I've tried to do a:
Shell(Me.FileToExecute, AppWinStyle.Hide, True, 3000) where Me.FiletoExecute
= C:\Perl\bin\Perl.exe C:\files\syslog\telnet.pl >
C:\files\syslog\SmallOffice93Config.txt
however the shell doesn't like piping to a file and outputs this to the
command window. Is there a way i can fetch the data from the command window,
or a way to pipe the data to a file ? Or is it possible to embed a
perlscript directly into .net ?
I use the Perl ppm module Net-Telnet-Cisco to send my telnet command.
Help is appreciated
Best Regards
Kai Thorsrud
I'm currently into converting a perl linux app into a .Net windows service.
The application monitors our syslog log files to capture i.p adress changes
on some of our routers having dynamic i.p. In the syslog logfile i capture
the new IP adress of the router. I then need to telnet to that i.p adress
and fetch the hostname. A list of these routers will be presented on a
webpage.
I've created the application in vb.net and most parts of it is working fine
except for the telnet module. I've created a TCPClient class that takes care
of this. However with my limited .Net experience this is gonna take some
time to implement the Telnet protocol to handle all sorts of stuff
However time is limited and i need to get this app up and running. I have a
perlscript doing this for me returning the routerconfig to stdout (the dos
window). I've tried to do a:
Shell(Me.FileToExecute, AppWinStyle.Hide, True, 3000) where Me.FiletoExecute
= C:\Perl\bin\Perl.exe C:\files\syslog\telnet.pl >
C:\files\syslog\SmallOffice93Config.txt
however the shell doesn't like piping to a file and outputs this to the
command window. Is there a way i can fetch the data from the command window,
or a way to pipe the data to a file ? Or is it possible to embed a
perlscript directly into .net ?
I use the Perl ppm module Net-Telnet-Cisco to send my telnet command.
Help is appreciated
Best Regards
Kai Thorsrud