I work with websphere portal which contains log files which gets updated automatically and these files are getting locked some how while the server is active.
I created a batch which clears the content when server is not running,but once the server starts the job fails unable to clear the conten.
Hence can any one suggest me a way out so that i can clear the contents while the server is active.
The code used by me for clearing the text is
for %%f in (C:\wsapps\ebp\deployment\logs\portal.log) do (type nul > %%f)