Search found 160 matches

by MKANET
01 Aug 2013 20:03
Forum: DOS Batch Forum
Topic: Pulling my hair out.. simple stringlen counter breaks script
Replies: 34
Views: 25910

Pulling my hair out.. simple stringlen counter breaks script

The below script (thanks so much to PenPen on the forum!!!) runs perfectly against the below stunnel.log file. As soon as I insert a stringlength counter (reserved for a future function) , the added lines of code produces a, " The syntax of the command is incorrect. " error. I have tried a...
by MKANET
31 Jul 2013 16:38
Forum: DOS Batch Forum
Topic: Inserting DNS name of each IP address in WWW log files
Replies: 12
Views: 8950

Re: Inserting DNS name of each IP address in WWW log files

Hi PenPen, I think below is what you wanted me to try (without the temp file). It looks like it may be doing the opposite of what I was aiming for. It's only showing lines which include /C:"127.0.0" /C:"192.168" /C:"byte" /C:"WSAECONNRESET" /C:"Peer sudde...
by MKANET
30 Jul 2013 16:26
Forum: DOS Batch Forum
Topic: Inserting DNS name of each IP address in WWW log files
Replies: 12
Views: 8950

Re: Inserting DNS name of each IP address in WWW log files

BTW: I made an attempt to make the above batch file more efficient (see below); but, it produces a, "The syntax is of the command is incorrect" . I tried putting echo ON at the beginning; but it didn't show me anything useful to me. Maybe there's a much better way to do this? @ECHO OFF set...
by MKANET
30 Jul 2013 13:40
Forum: DOS Batch Forum
Topic: Inserting DNS name of each IP address in WWW log files
Replies: 12
Views: 8950

Re: Inserting DNS name of each IP address in WWW log files

penpen, I just wanted to thank you again for the examples you posted. They works great; and, further help me become a better batch/script maker! I also wanted to make a slightly modified script; which gives me a very stripped down stunnelx.log file (only showing who visited the website besides me). ...
by MKANET
29 Jul 2013 08:52
Forum: DOS Batch Forum
Topic: Inserting DNS name of each IP address in WWW log files
Replies: 12
Views: 8950

Re: Inserting DNS name of each IP address in WWW log files

Hi Foxidrive, I'm so sorry, I don't know how I missed your post! I intentionally inserted lines that don't have IP addresses; in hopes that it is presumed (for the batch file) to ignore those lines. Luckily penpen presumed this correctly. Also, Penen presumed correctly that IP's are only going to be...
by MKANET
28 Jul 2013 20:50
Forum: DOS Batch Forum
Topic: Inserting DNS name of each IP address in WWW log files
Replies: 12
Views: 8950

Re: Inserting DNS name of each IP address in WWW log files

WOW!!! Thanks so much penpen! It all works very well. I only had to change "ping" to "pinging" for it to work with the Win7 ping command. I'm was able to significantly reduce the time it takes to complete processing of the batch file by using nslookup instead of the ping command....
by MKANET
27 Jul 2013 21:13
Forum: DOS Batch Forum
Topic: Inserting DNS name of each IP address in WWW log files
Replies: 12
Views: 8950

Inserting DNS name of each IP address in WWW log files

I use an application (stunnel) that generates log files like the below example. Ive been racking my brain trying to figure out how to make a batch file can insert the DNS name before each IP address it sees in the log file (doing reverse name lookup for each IP). Also, to reformat the time/date stam...
by MKANET
13 Oct 2012 21:24
Forum: DOS Batch Forum
Topic: Simplest way to wait for command to finish before continuing
Replies: 8
Views: 50866

Re: Simplest way to wait for command to finish before contin

Huh? I dont get it. Your example doesnt work. Plus, it doesn't include cmdow. Maybe I didn't explain well enough? try writing at this way: start /b /wait cmd /C "C:\PROGRA~1\INTERN~1\iexplore.exe" "http://movies.netflix.com/WiHome" The IE between double quotes and also the url
by MKANET
13 Oct 2012 20:07
Forum: DOS Batch Forum
Topic: Simplest way to wait for command to finish before continuing
Replies: 8
Views: 50866

Simplest way to wait for command to finish before continuing

How can I execute the below line; and, wait until it exits memory before continuing? cmdow /run /hid C:\PROGRA~1\INTERN~1\iexplore.exe http://movies.netflix.com/WiHome I can do this successfully without using cmdow (below). I just can't figure out how to include the full command line above; which al...
by MKANET
05 Jul 2012 23:54
Forum: DOS Batch Forum
Topic: Trying to build a Uptime.exe alternative via native windows
Replies: 31
Views: 33520

Re: Trying to build a Uptime.exe alternative via native wind

I think we might be talking about two different things. Either that, or maybe there's a language barrier? I was just explaining that "my machine" didn't have any event IDs that matched wmic. Especially event id 12. You suggested I was using two different machine, which I proved I wasnt (fi...
by MKANET
05 Jul 2012 23:32
Forum: DOS Batch Forum
Topic: Is it possible to add another command, same line as CALL :
Replies: 9
Views: 5767

Re: Is it possible to add another command, same line as CALL

Hmmm... interesting. I thought for sure my second post clarified what I was actually having trouble with. I guess it didn't go without saying after all that I wasn't talking about the original example anymore I think what confused me is already had a setlocal enableDelayedExpansion in the beginning ...
by MKANET
05 Jul 2012 23:04
Forum: DOS Batch Forum
Topic: Trying to build a Uptime.exe alternative via native windows
Replies: 31
Views: 33520

Re: Trying to build a Uptime.exe alternative via native wind

Nope. Sorry, wrong again. http://i67.photobucket.com/albums/h283/mkanet/wrongagain.png It looks like you booted the machine 1/2 an hour before that and the likelihood is that you had booted it after that also and hadn't scrolled up in the log. IOW it was finger trouble. ID-Ten-T error.
by MKANET
05 Jul 2012 22:13
Forum: DOS Batch Forum
Topic: Is it possible to add another command, same line as CALL :
Replies: 9
Views: 5767

Re: Is it possible to add another command, same line as CALL

Yes, I was hoping that went without saying since I already clarified what I was trying to do (what you quoted). If it still doesn't make sense, below is an updated example. If I have everything after the & on a separate line, %converted% is shown. Otherwise, it's still undefined.. call :Converte...
by MKANET
05 Jul 2012 21:50
Forum: DOS Batch Forum
Topic: Trying to build a Uptime.exe alternative via native windows
Replies: 31
Views: 33520

Re: Trying to build a Uptime.exe alternative via native wind

Yeah my original code was meant for my work environment. I'm currently at home, with only one machine. I wasn't able to find a matching timestamp in the system event logs. But there were ones that were closer than event id 12. Not sure why it would be different between our machines. http://i67.photo...
by MKANET
05 Jul 2012 21:15
Forum: DOS Batch Forum
Topic: Trying to build a Uptime.exe alternative via native windows
Replies: 31
Views: 33520

Re: Trying to build a Uptime.exe alternative via native wind

No.. I only have one machine.
foxidrive wrote:It looks like results from two different machines.