Browser cache maintenance: the final chapter (?)

Robert Sullivan SCP_SULLI at sals.edu
Tue Mar 23 13:59:20 EST 1999


I would like to thank all who responded to my recent question about cleaning
out the cache files under NT4 and MS Internet Explorer.  It now appears that
the real problem was something else, but I was going to have to handle the
cache files eventually, so the discussion was very useful.

I'm not sure how Win 95 and 98 handle it, but (as far as I can tell) NT is very
pick about what it lets you see in the cache directories.  It appears to only
show you files created by your own account, even if you're administrator.  This
means the public account cache has to be cleared while that account is logged
in - hence my question about secured PCs.

NT is also rather picky about letting you clear the files from outside MSIE;
trying to do it from the command line and Windows Explorer yielded mixed
results.  (This is not a problem with the Cookies folder.)

Fortunately, I did find a solution - though I couldn't make all the cache go
away, I could get rid of the folder itself (?).  I could also use an
environment variable for the current user to handle just that account's folder,
so there is no rights problem.

Here's my batch file:

CLEARCACHE.CMD
@echo off
rd %Userprofile%\"Temporary Internet Files" /s /q
md %Userprofile%\"Temporary Internet Files"
del %Userprofile%\Cookies\*.* /s /q /f >nul

/s /q gets rid of any subdirectories quietly, and the folder is then recreated. 
I don't have a problem getting rid of cookies, but if there aren't any an error
message shows, so I redirect that to nul.

Because NT doesn't handle the autoexec.bat file in the way previous versions of
Windows did, I added a call to Clearcache to the Run key in the Registry (it's
more secure than the Startup folder).

Meanwhile...there was circumstantial evidence that it was a cache problem, but
I was not completely convinced.  The Event Viewer showed that something was
trying to access c:\winnt\system32\ddhelp.exe, but I didn't know what.  Giving
rights to it might solve the immediate problem, but I still wanted to know what
was going on.

To make a long story short, we upgraded QuickTime at the same time that we
moved to IE4, and it wanted this file.  (We use very tight security, and that
wasn't one of the .exe files we had unlocked.)  As soon as we gave the public
account read access, the freezing problem went away.

Solving that problem and the cache cleaning issue made me happy, but software
which fails silently is maddening.

Thanks again!  Hope my story helps someone.

Bob Sullivan                               scp_sulli at sals.edu
Schenectady County Public Library (NY)     http://www.scpl.org


More information about the Web4lib mailing list