search cancel

Collecting more log data than the roll over period

book

Article ID: 258445

calendar_today

Updated On:

Products

DX Unified Infrastructure Management (Nimsoft / UIM)

Issue/Introduction

I need to gather log data for a problem, but the logs roll faster than I can capture the data, when the problem occurs.

Environment

Release : 20.4

Resolution

Create a batch file with similar contents so that it can be run on a schedule in Windows:

@echo on
cd "C:\Program Files (x86)\Nimsoft\robot"
FOR /F "tokens=2,3,4 delims=/ " %%A IN ('date /t') DO SET DATE=%%A-%%B-%%C
FOR /F "tokens=1,2,3,4 delims=/: " %%A IN ('time /t') DO SET TIME=%%A.%%B.%%C
set LOGFILE=%DATE%_%TIME%
for /f %%f in ('dir /b ..\probes\gateway\sdgtw\_sdgtw.log') do copy ..\probes\gateway\sdgtw\%%f .\%LOGFILE%-%%f

Then I created the following task:

Attachments