-
@echo off
net use \\ip\Backup\log\Eventlog /user:id pw
#set "date=%YYYY%%MM%%DD%"
set "target=\\ip\Backup\log\Eventlog"
wmic nteventlog where filename='Application' backupeventlog "%target%\Application-%ComputerName%_%date%.evt"
wmic nteventlog where filename='Security' backupeventlog "%target%\Security-%ComputerName%_%date%.evt"
wmic nteventlog where filename='System' backupeventlog "%target%\System-%ComputerName%_%date%.evt"
wmic nteventlog where filename='application' cleareventlog
wmic nteventlog where filename='system' cleareventlog
wmic nteventlog where filename='security' cleareventlog
exit'IT' 카테고리의 다른 글
보안그룹 인바운드 추가 (0) 2019.08.29 JVM 환경에서 LDAP 연동 후 빈번한 로그인 실패 발생시 대응 방법출처: https://mcpaint.tistory.com/276 [MC빼인트와 함께] (0) 2019.08.22 ssh pem로 접속 (0) 2019.05.16 nagios noti (0) 2019.04.30 쉘스크립트 리스트 (0) 2019.04.16