ini files or copying a new shortcut to everyone’s desktop. Copy the commands once (last command being exit followed by a new line) and just right-click on the dos window every time a shell opens. I use a for loop, psexec and a list of computers (FOR /f “tokens=1” %X in (allcomps.txt) do psexec %X –s cmd). If I have to make a change to all the computers on the network. This can be done with any command line program that doesn’t have a gui. I know everyone’s going to say telnet this and telnet that, but the reason that im passing this on to those who aren’t aware of it is…. If you’ve flipped out and want to use telnet as your mail client for some reason or check for open relays this can save allot of time Save it with a descriptive name if you think your might need it in the future. (this is the feature I hate most about XP) The XP command window opens an options menu when right clicked so just select paste. The buffer will enter and execute each command in turn. If you running 2k you can do this by simply right clicking on the DOS window after coping from notepad. Select all, copy and paste it right into the telnet session. Write all the commands down as if it were a batch file and be sure to add a new line at the end to execute the last command. Now that I have a solution id like to share it…someone might need it someday who knows. Why would this only work sometimes? Do I need to increase the sleep times perhaps? I have tried to sleep 6000 ms, and it seems like its long enough.Some time ago I was looking for and couldn’t find a way to have scripted telnet sessions for someone I know who works in air conditioning that said he could really use one. I've witnessed the test fail, and what happens is the telnet window is opened, but it hangs on the "username" prompt, eventually the telnet session just times out and the window never closes. I can run this test about 10 times, but it'll only work about 8 out of 10 times. Set OBJECT=WScript.CreateObject("WScript.Shell") My vbs script looks like this: WScript.sleep 1000 I have a batch file that starts up a telnet session and executes a few command with using a vbs script: start telnet.exe another.hostname
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |