-
1
- #1
ChrisHirst
IS-IT--Management
Batch file and ftp script to download dat updates from NAI
change the drives and paths to suit your system. I use this to download to a local IIS ftp site.
I also copy sdat????.exe to dat.exe to give a constant file name for any scheduled operations (updates to groupshield etc)
To use this copy and paste the text below into notepad, change the paths as required and put your e-mail address into the ftp script. save as the file names shown. You can then run the batch file manually or schedule it and have your client machines point to the download location using ftp or as a UNC name.
If you use this on dial up you will need to add rasdial commands to the batch file to connect and disconnect automatically.
Chris.
save this as ftp.bat
rem drive
l:
rem folder
rem this will be the download location
rem and the shared folder on your ftp site
cd l:\updates\antivirus\current
rem delete previous update files
del *.ini
del sdat*.*
del *.txt
del *.upd
del *.zip
rem Change path below to suit your script path
ftp -i -s:L:\Updates\AntiVirus\Update\Scripts\nai.ftp > ftp.log
rem echo ftp commands to a log file
rem Copy the superdat to a fixed file name
xcopy sdat*.exe dat.* /y
rem run superdat in silent mode
dat.exe /s
rem end of batch file
***********************************************************
save this as nai.ftp
open ftp.nai.com
anonymous
me@wherever.xxx
cd pub\antivirus\datfiles\4.x
type ascii
mget *.ini
mget *.txt
type binary
mget *.upd
mget dat*.zip
mget sdat*.*
bye
end of ftp file
***************************************************
change the drives and paths to suit your system. I use this to download to a local IIS ftp site.
I also copy sdat????.exe to dat.exe to give a constant file name for any scheduled operations (updates to groupshield etc)
To use this copy and paste the text below into notepad, change the paths as required and put your e-mail address into the ftp script. save as the file names shown. You can then run the batch file manually or schedule it and have your client machines point to the download location using ftp or as a UNC name.
If you use this on dial up you will need to add rasdial commands to the batch file to connect and disconnect automatically.
Chris.
save this as ftp.bat
rem drive
l:
rem folder
rem this will be the download location
rem and the shared folder on your ftp site
cd l:\updates\antivirus\current
rem delete previous update files
del *.ini
del sdat*.*
del *.txt
del *.upd
del *.zip
rem Change path below to suit your script path
ftp -i -s:L:\Updates\AntiVirus\Update\Scripts\nai.ftp > ftp.log
rem echo ftp commands to a log file
rem Copy the superdat to a fixed file name
xcopy sdat*.exe dat.* /y
rem run superdat in silent mode
dat.exe /s
rem end of batch file
***********************************************************
save this as nai.ftp
open ftp.nai.com
anonymous
me@wherever.xxx
cd pub\antivirus\datfiles\4.x
type ascii
mget *.ini
mget *.txt
type binary
mget *.upd
mget dat*.zip
mget sdat*.*
bye
end of ftp file
***************************************************