centreon-plugins icon indicating copy to clipboard operation
centreon-plugins copied to clipboard

apps::apache::serverstatus::plugin implement load balancer check

Open MarcusCaepio opened this issue 3 years ago • 4 comments

Hi all, the server-status site can also give you information about defined loadbalancer, when 'ProxyStatus On' is set (apache 2.4.41). It would be nice, to have a mode for the loadbalancer too, to check, if the LB is fine.

Thanks in advance! Cheers, Marcus

MarcusCaepio avatar Oct 15 '20 10:10 MarcusCaepio

Could you provide the page result ? (/server-status/?auto)

garnier-quentin avatar Oct 15 '20 11:10 garnier-quentin

Sure, here is an anonymized curl from the status page:

hostname
ServerVersion: Apache/2.4.41 (Ubuntu) OpenSSL/1.1.1f
ServerMPM: event
Server Built: 2020-08-12T19:46:17
CurrentTime: Thursday, 15-Oct-2020 13:43:40 CEST
RestartTime: Thursday, 15-Oct-2020 11:46:44 CEST
ParentServerConfigGeneration: 1
ParentServerMPMGeneration: 0
ServerUptimeSeconds: 7016
ServerUptime: 1 hour 56 minutes 56 seconds
Load1: 0.04
Load5: 0.03
Load15: 0.00
Total Accesses: 903
Total kBytes: 1368
Total Duration: 534
CPUUser: .46
CPUSystem: .38
CPUChildrenUser: 0
CPUChildrenSystem: 0
CPULoad: .0119726
Uptime: 7016
ReqPerSec: .128706
BytesPerSec: 199.662
BytesPerReq: 1551.31
DurationPerReq: .591362
BusyWorkers: 1
IdleWorkers: 49
Processes: 2
Stopping: 0
BusyWorkers: 1
IdleWorkers: 49
ConnsTotal: 0
ConnsAsyncWriting: 0
ConnsAsyncKeepAlive: 0
ConnsAsyncClosing: 0
Scoreboard: ____________W_____________________________________....................................................................................................
ProxyBalancer[0]Name: balancer://MyBalancer
ProxyBalancer[0]Worker[0]Name: http://1.2.3.4:1234
ProxyBalancer[0]Worker[0]Status: Init Ok
ProxyBalancer[0]Worker[0]Elected: 0
ProxyBalancer[0]Worker[0]Busy: 0
ProxyBalancer[0]Worker[0]Sent: 0K
ProxyBalancer[0]Worker[0]Rcvd: 0K
ProxyBalancer[0]Worker[1]Name: http://1.2.3.5:1234
ProxyBalancer[0]Worker[1]Status: Init Ok
ProxyBalancer[0]Worker[1]Elected: 0
ProxyBalancer[0]Worker[1]Busy: 0
ProxyBalancer[0]Worker[1]Sent: 0K
ProxyBalancer[0]Worker[1]Rcvd: 0K
TLSSessionCacheStatus
CacheType: SHMCB
CacheSharedMemory: 512000
CacheCurrentEntries: 0
CacheSubcaches: 32
CacheIndexesPerSubcaches: 88
CacheIndexUsage: 0%
CacheUsage: 0%
CacheStoreCount: 0
CacheReplaceCount: 0
CacheExpireCount: 0
CacheDiscardCount: 0
CacheRetrieveHitCount: 0
CacheRetrieveMissCount: 0
CacheRemoveHitCount: 0
CacheRemoveMissCount: 0

MarcusCaepio avatar Oct 15 '20 11:10 MarcusCaepio

Hey again, maybe it's better to parse /balancer-manager ? Just enabled it today and it gives many fancy information. Check: https://httpd.apache.org/docs/trunk/howto/reverse_proxy.html#manager

MarcusCaepio avatar Oct 16 '20 12:10 MarcusCaepio

Hey all, any news on this? :)

MarcusCaepio avatar Jan 22 '21 17:01 MarcusCaepio