Open jva5007 opened 9 years ago
Can I get a copy of "/server-status?auto"? I suspect that there is a slight difference between the way the CSV parser is set to work vs what Apache is doing.
@gpmidi this is my server-status page. The same error is ocurring with me:
ServerVersion: Apache/2.4.16 (Ubuntu) mod_fcgid/2.3.9 OpenSSL/1.0.1f
ServerMPM: worker
Server Built: 2015-09-08T00:00:00
CurrentTime: Friday, 04-Dec-2015 12:55:46 UTC
RestartTime: Friday, 04-Dec-2015 12:46:34 UTC
ParentServerConfigGeneration: 1
ParentServerMPMGeneration: 0
ServerUptimeSeconds: 552
ServerUptime: 9 minutes 12 seconds
Load1: 3.79
Load5: 1.03
Load15: 0.74
Total Accesses: 658
Total kBytes: 31790
CPUUser: 1.62
CPUSystem: .13
CPUChildrenUser: 0
CPUChildrenSystem: 0
CPULoad: .317029
Uptime: 552
ReqPerSec: 1.19203
BytesPerSec: 58972.8
BytesPerReq: 49472.6
BusyWorkers: 114
IdleWorkers: 6
Scoreboard: .R...R.RRRRRR.RRRRRRWKWWWWRWWWR..R.RRR.RWWWRWWWWRWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWRWRWWWWWRWWWKWWWWWRWWWWWWWWWKKWWWWWWWWWWWWRWWWWWWWWWWWW___KR_RW__..................................................
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
I tried to run this script from our monitoring server for a remote host running Apache 2.4.16, but when I excecute cron, it returns the following error.
Traceback (most recent call last): File "/usr/local/plugin/fetch.py", line 225, in data = parse(data = data) File "/usr/local/plugin/fetch.py", line 78, in parse for (key, val) in csvobj: ValueError: need more than 1 value to unpack
I have added hostname before each item key in the template.
When I add print data in 77th line in the script it shows correct data from apache server along with the error above. I also checked with 'print repr(csvobj)' but it shows the following.
<_csv.reader object at 0x7f04feca5a60> Traceback (most recent call last): File "/usr/local/plugin/fetch.py", line 225, in data = parse(data = data) File "/usr/local/plugin/fetch.py", line 78, in parse for (key, val) in csvobj: ValueError: need more than 1 value to unpack
remote host is an amazon ec2 instance.