powershellcommand-linencache

Can I clear an NCache cache without confirmation?


I've got an NCache implementation (configured in replicated format across a pair of servers, if that makes any difference) and I want to script clearing the cache. I've got a powershell script that calls the NCache clearcache.exe tool (in \bin\tools) with the appropriate parameters, but the tool then prompts me for confirmation that I actually do want to clear a non-empty cache (why yes, I do!).

I've looked at the inline help for the command (scanty) and in the NCache documentation online (http://www.alachisoft.com/resources/docs/ncache/help/main.html) without any luck for help with additional parameters (like a --force option or the like).

Is there any such option that would allow me to clear the cache without having to interact with the script? Is there another path to accomplishing the same thing?


Solution

  • If you look at page 35 here (NCache Command Line Tools guide), you'll see that you can use /F to force a clear cache.