로그 로테이트 썸네일형 리스트형 우분투에서 Logrotate를 설정하는 방법 우분투에서 Logrotate를 설정하는 방법Logrotate는 로그 파일의 크기 증가를 방지하고 디스크 공간을 효율적으로 관리하기 위해 로그 파일을 주기적으로 압축, 이동, 삭제하는 도구입니다.1. Logrotate 기본 구조 이해Logrotate는 기본 설정 파일과 개별 설정 파일을 사용합니다.기본 설정 파일 : /etc/logrotate.conf개별 애플리케이션 설정 파일 : /etc/logrotate.d2. Logrotate 기본 설정 파일 확인/etc/logrotate.conf 파일은 시스템 전체에 적용되는 기본 정책을 정의합니다.cat /etc/logrotate.conf# see "man logrotate" for details# global options do not affect precedi.. 더보기 lsyncd 로그 파일의 로테이션을 구성하는 방법 lsyncd 로그 파일의 로테이션을 구성하는 방법 lsyncd 로그 파일의 로테이션을 구성하려면 로그 파일을 logrotate를 사용하여 로테이트하도록 설정해야 합니다. lsyncd(/etc/lsyncd/lsyncd.conf.lua) 구성 파일 예시 더보기 vim /etc/lsyncd/lsyncd.conf.lua settings { logfile = "/var/log/lsyncd/lsyncd.log", statusFile = "/var/run/lsyncd/lsyncd.status" } sync { default.rsyncssh, source = "/path/to/your/logfile.log", host = "remote-server-ip-or-hostname", targetdir = "/path/on/.. 더보기 이전 1 다음