메뉴 닫기

HAPROXY 기본적인 로그 정리

 

1212 

 

예전에 HAPROXY 설치와 설정에 대해 정리해 보았으며 

 

이번에는 서버를 로드밸랜싱 운영하면서의  HAPROXY 간단한 로그를 정리 해보았다.

 

haproxy 로그 정리

 

HAPROXY 데몬 시작 및 분배 시작

Jun 11 09:52:47 localhost haproxy[7557]: Pausing proxy stats. 

Jun 11 09:52:47 localhost haproxy[7557]: Pausing proxy 80. 

Jun 11 09:52:47 localhost haproxy[7825]: Proxy stats started. 

Jun 11 09:52:47 localhost haproxy[7825]: Proxy kensei started. 

Jun 11 09:52:47 localhost haproxy[7557]: Stopping proxy stats in 0 ms. 

Jun 11 09:52:47 localhost haproxy[7557]: Stopping proxy 80 in 0 ms. 

Jun 11 09:52:47 localhost haproxy[7557]: Proxy stats stopped (FE: 0 conns, BE: 0 conns). 

Jun 11 09:52:47 localhost haproxy[7557]: Proxy 80 stopped (FE: 2 conns, BE: 2 conns).

kensei 는 웹 서버 호스트 이름 

 

방화벽에 의한 차단

L7 HAPROXY –> 방화벽 차단 –> kensei WEB 서버

웹 브라우저 출력 메세지

503 Service Unavailable

No server is available to handle this request. 

 

HAPROXY 로그

Jun 11 09:56:07 localhost haproxy[7826]: Server kensei/kensei is DOWN, reason: Layer4 timeout, check duration: 10000ms. 0 active and 0 backup servers left. 0 sessions active, 0 requeued, 0 remaining in queue. 

Jun 11 09:56:07 localhost haproxy[7826]: proxy kensei has no server available!

 

 

WEB 서버 데몬 중지 (시스템 다운)

 

Jun 11 10:03:05 localhost haproxy[7826]: Server kensei/kensei is DOWN, reason: Layer4 connection problem, info: “Connection refused”, check duration: 0ms. 0 active and 0 backup servers left. 0 sessions active, 0 requeued, 0 remaining in queue. 

Jun 11 10:03:05 localhost haproxy[7826]: proxy kensei has no server available!

 

 

방화벽에 의한 차단과 웹데몬 다운에 대해 메세지가 약간씩 틀리다.

 

방화벽 차단 (Layer4 timeout)

서비스 다운 (Layer4 connection problem)

 

리얼서버 (WEB) 상태 체크 분배 시작

 

Jun 11 10:04:35 localhost haproxy[7826]: Server kensei/kensei is UP, reason: Layer4 check passed, check duration: 0ms. 1 active and 0 backup servers online. 0 sessions requeued, 0 total in queue.

 

 

모든 로그는 옵션에 따라 틀리겠지만 아이피 보다는 해당 설정값의 호스트 값으로 로그가 남는다

 

 

로그중에 active 라고 뒤에 숫자가 출력됨. 현재 살아 있는 노드의 갯수를 의미함

active 0 : 활성화된 서버가 없다 (전체 장애이다)

active 1 : 활성화된 서버 1대 

3대중에 1대가 장애이면 active 2 라고 나오면 되며 장애 복구되는 순간 active 3 이라는 로그가 첨부됨

 

[polldaddy rating=”7739789″] 

답글 남기기

이메일 주소는 공개되지 않습니다. 필수 항목은 *(으)로 표시합니다