🔍 elastic search/💡 elk
-
ELK 를 통한 사용자 요청에 대한 로그 수집🔍 elastic search/💡 elk 2022. 11. 23. 14:41
💬 Access Log 이용 이전에는 Elasticsearch를 이용해 access log를 수집 @Controller public class UserController { @GetMapping("/api/v1/users/") public User getUserInfo(@PathVariable("id") String id) { // 블라블라 } } 여기서 정의된 GET /v1/orders/ 라는 API가 사용되었지만 access log에는 다음과 같이 기록된다 127.0.0.1 - "GET /api/v1/users/A0000001 HTTP/1.1" 200 50 "-" "-" "127.0.0.1" 127.0.0.1 - "GET /api/v1/users/A0000002 HTTP/1.1" 200 50 "-" ..
-
ELK 구축 및 Filebeat로 로그 전송🔍 elastic search/💡 elk 2022. 11. 22. 11:23
📌 Docker Compose 로 ELK 구축 ELK 구축 https://github.com/deviantony/docker-elk mkdir ~/workspace cd ~/workspace git clone https://github.com/deviantony/docker-elk.git Logstash 파이프라인 설정 추가 Logstash 파이프라인 설정은 logstash/pipeline/logstash.conf 를 수정해주면 된다. Logstash 파이프라인 설정은 크게 다음의 3단계로 구성된다. Input Filter Output input { # FileBeat를 통해 로그 수집 beats { port => 5000 host => "0.0.0.0" ssl => false } tcp { port =..