On Tue, 20 Jan 2004 16:59:04 -0800, "Martin Simmons"
<(E-Mail Removed)> wrote in
microsoft.public.win2000.cmdprompt.admin:
>Lectori Salutum,
>
>
>I have a batchfile running that checks my internet
>connectivity 4 times a day. If there is no connectivity,
>it checks the DNS-servers, etc. The FINAL command is to
>teboot the server. But I want the command before the last
>to be a reboot of my (A)DSL modem (router).
>
>This can be done be telnetting to the device and give it
>the commands: SYSTEM and then REBOOT. But this has to be
>done automated (via a batch-file).
>
>With FTP you can give commands batch-orientated by
>typing: FTP HOSTNAME -S:FILE.EXT
>The same I want to do with telnet, only telnet does not
>know a parameter like that.
>
>Does anyone know how to do this???
Here's what I wrote earlier on the subject:
(Quoted from
<http://groups.google.com/groups?hl=en&selm=k49hjv4v3bk99g03hvftucqhql795e1rr3%404ax.com>
I don't think there is a way of scripting the standard Microsoft
telnet client (although some people in the past have come up with some
VB scripts which issued SendKeys commands - ugly).
I suggest you use a comms program, and among those I would use Kermit.
See :
http://www.columbia.edu/kermit/ckermit.html and
http://www.columbia.edu/kermit/ckscripts.html
Unfortunately, the Win32 version (Kermit95) is not free; you'll
probably find others which are, but I can't comment on those.
--
Michael Bednarek
http://mbednarek.com/ "POST NO BILLS"