John,

Actually, it's in the Windows 2000 Resource Kit.  You can download the executable from the following page instead of installing the entire package:

    http://www.petri.co.il/download_free_reskit_tools.htm

Matt



John T (Lists) wrote:

Only comes on Windows Server 2003 SP1 or above.

 

Tried running it on Windows Server 2000 and it errored saying target system must be running Windows XP or above.

 

John T

eServices For You

 

"Seek, and ye shall find!"

 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] On Behalf Of Matt
Sent:
Wednesday, April 19, 2006 4:28 PM
To: Declude.JunkMail@declude.com
Subject: Re: [Declude.JunkMail] OT: Help with WinZip command line

 

John,

I would suggest taking a second look at Dean's reply.  The "forfiles" command acts on the date of the file and not the time stamp, so therefore you won't be having issues with timestamps.  It also has the ability to go through an entire directory tree and use wildcards to find the files, and then it passes the file names in to the chained app (WinZip command line) for execution.  This is about as simple as it gets.  You could do the entire task in one line of code.

The only caveat is that I am not sure whether or not Windows 2000 comes with forfiles, but I'm sure that you could always copy the executable over from Windows 2003 if needed.

Matt


John T (Lists) wrote:

What is defining %%f?
 
John T
eServices For You
 
"Seek, and ye shall find!"
 
 
  
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:Declude.JunkMail-
[EMAIL PROTECTED]] On Behalf Of Andy Schmidt
Sent: Wednesday, April 19, 2006 3:26 PM
To: Declude.JunkMail@declude.com
Subject: RE: [Declude.JunkMail] OT: Help with WinZip command line
 
Hi John,
 
The FOR/DO will iterate through the directory listing using "ex*.log" and
then perform a WINZIP for each item.
 
The /R makes it recursive (meaning, including subfolders) - which is what
you want.
 
&&f is one item in the directory list (the path to one log file at a
    
time).
  
~      modifies an item from the directory list, specifically:
~dpn   takes only the drive, path and filename (leave out the extension)
 
So:
 
%%~dpnF.zip
 
means, take the directory item %%F, put use only the drive:/Path/Filename
and append ".zip".
 
In other words the Winzip command will look like that
 
 WINZIP -m -ex -Td01 c:\Path\exDDMMYY.log  c:\Path\exDDMMYY.zip.
 
for each of youu log files in all of your subfolders.
 
 
Best Regards
Andy Schmidt
 
Phone:  +1 201 934-3414 x20 (Business)
Fax:    +1 201 934-9206
 
 
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of John T (Lists)
Sent: Wednesday, April 19, 2006 06:09 PM
To: Declude.JunkMail@declude.com
Subject: RE: [Declude.JunkMail] OT: Help with WinZip command line
 
    
I just use the winzip command line tool every day to turn the 1 day
old "log" file into a "zip" file by the SAME name in the SAME
location.  This way, you can simply move anything *.zip to a different
drive, while *.log are "current" log files.
 
Here is the content of my Compress2DayOldLogs.cmd file:
 
C:
CD "C:\WINNT\system32\LogFiles\"
FOR /R %%f in (ex*.log) do "C:\Program Files\WinZip\WZzip.exe" -m -ex
      
-Td01
    
%%~dpnf.zip %%f
      
OK, can some one please explain the logic of this line. This appears to be
what I need to do. My understanding is that it is only calling the winzip
command to a specific file name.
 
John T
eServices For You
 
"Seek, and ye shall find!"
 
 
---
This E-mail came from the Declude.JunkMail mailing list.  To unsubscribe,
just send an E-mail to [EMAIL PROTECTED], and type "unsubscribe
Declude.JunkMail".  The archives can be found at
http://www.mail-archive.com.
 
---
This E-mail came from the Declude.JunkMail mailing list.  To
unsubscribe, just send an E-mail to [EMAIL PROTECTED], and
type "unsubscribe Declude.JunkMail".  The archives can be found
at http://www.mail-archive.com.
    
 
---
This E-mail came from the Declude.JunkMail mailing list.  To
unsubscribe, just send an E-mail to [EMAIL PROTECTED], and
type "unsubscribe Declude.JunkMail".  The archives can be found
at http://www.mail-archive.com.
 
 
  


Reply via email to