24
Dec

MSSQL 트랜잭션로그삭제

   Posted by: poss   in DATABASE

이벤트뷰어에 MSSQL관련 에러메시지가 잔뜩 나와있어서 확인해 본 결과 트랜잭션 로그 파일이 139GB나 되었다. 남은공간 9MB.  해결방법은 해당 트랜잭션로그를 삭제하거나, 줄이는 방법인데, 아래와 같은 명령어를 쿼리분석기에서 실행하면 된다.

backup log DATABASE_NAME with truncate_only
dbcc shrinkdatabase(DATABASE_NAME, truncateonly)
dbcc shrinkdatabase(DATABASE_NAME, 500)

트랜잭션로그 크기를 500MB로 제한.

Tags:

This entry was posted on 수요일, 12월 24th, 2008 at 4:25 오후 and is filed under DATABASE. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

Leave a reply

Name (*)
Mail (will not be published) (*)
URI
Comment
*

Switch to our mobile site