SysLog Forwarding for XenServer
-
In /var/log/kibana/kibana.stout I have the below...
{"type":"log","@timestamp":"2016-08-15T15:43:07+00:00","tags":["fatal"],"pid":23942,"level":"fatal","message":"listen EADDRINUSE 127.0.0.1:5601","error":{"message":"listen EADDRINUSE 127.0.0.1:5601","name":"Error","stack":"Error: listen EADDRINUSE 127.0.0.1:5601\n at Object.exports._errnoException (util.js:870:11)\n at exports._exceptionWithHostPort (util.js:893:20)\n at Server._listen2 (net.js:1236:14)\n at listen (net.js:1272:10)\n at net.js:1381:9\n at GetAddrInfoReqWrap.asyncCallback [as callback] (dns.js:63:16)\n at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:82:10)","code":"EADDRINUSE"}}
And in kibana.stderr
[root@syslog-cent kibana]# tail kibana.stderr errno: 'EADDRINUSE', syscall: 'listen', address: '127.0.0.1', port: 5601 }, isOperational: true, code: 'EADDRINUSE', errno: 'EADDRINUSE', syscall: 'listen', address: '127.0.0.1', port: 5601 }
Is the system listening to the wrong port? Shouldn't it be 514 or 5140?
-
So in checking out the firewall on the Kibana server using nmap...
Starting Nmap 6.40 ( http://nmap.org ) at 2016-08-16 09:34 EDT Nmap scan report for localhost (127.0.0.1) Host is up (0.000089s latency). Other addresses for localhost (not scanned): 127.0.0.1 Not shown: 996 closed ports PORT STATE SERVICE 22/tcp open ssh 25/tcp open smtp 80/tcp open http 9200/tcp open wap-wsp No exact OS matches for host (If you know what OS is running on it, see http://nmap.org/submit/ ). TCP/IP fingerprint: OS:SCAN(V=6.40%E=4%D=8/16%OT=22%CT=1%CU=32095%PV=N%DS=0%DC=L%G=Y%TM=57B3166 OS:E%P=x86_64-redhat-linux-gnu)SEQ(SP=104%GCD=1%ISR=10A%TI=Z%CI=I%II=I%TS=A OS:)OPS(O1=MFFD7ST11NW7%O2=MFFD7ST11NW7%O3=MFFD7NNT11NW7%O4=MFFD7ST11NW7%O5 OS:=MFFD7ST11NW7%O6=MFFD7ST11)WIN(W1=AAAA%W2=AAAA%W3=AAAA%W4=AAAA%W5=AAAA%W OS:6=AAAA)ECN(R=Y%DF=Y%T=40%W=AAAA%O=MFFD7NNSNW7%CC=Y%Q=)T1(R=Y%DF=Y%T=40%S OS:=O%A=S+%F=AS%RD=0%Q=)T2(R=N)T3(R=N)T4(R=Y%DF=Y%T=40%W=0%S=A%A=Z%F=R%O=%R OS:D=0%Q=)T5(R=Y%DF=Y%T=40%W=0%S=Z%A=S+%F=AR%O=%RD=0%Q=)T6(R=Y%DF=Y%T=40%W= OS:0%S=A%A=Z%F=R%O=%RD=0%Q=)T7(R=Y%DF=Y%T=40%W=0%S=Z%A=S+%F=AR%O=%RD=0%Q=)U OS:1(R=Y%DF=N%T=40%IPL=164%UN=0%RIPL=G%RID=G%RIPCK=G%RUCK=G%RUD=G)IE(R=Y%DF OS:I=N%T=40%CD=S) Network Distance: 0 hops OS detection performed. Please report any incorrect results at http://nmap.org/submit/ . Nmap done: 1 IP address (1 host up) scanned in 12.68 seconds
-
@DustinB3403 You'd need at least 5601 open, right? What's the output of
fireall-cmd --list-all
-
[root@syslog-cent log]# firewall-cmd --list-all public (default, active) interfaces: eth0 sources: services: dhcpv6-client ssh ports: 80/tcp 5044/tcp masquerade: no forward-ports: icmp-blocks: rich rules:
-
We may be getting somewhere. You're kibana.stderr looks like you need port 5601 open.
firewall-cmd --zone=public --add-port=5601/tcp --permanent
Sidenote: I still don't like firewall-cmd. Change is hard, even for geeks.
-
@travisdh1 So with both TCP and UDP open.
[root@syslog-cent log]# firewall-cmd --list-all public (default, active) interfaces: eth0 sources: services: dhcpv6-client ssh ports: 5601/udp 80/tcp 5601/tcp 5044/tcp masquerade: no forward-ports: icmp-blocks: rich rules:
Still nothing showing up in Kibana
-
@travisdh1 said in SysLog Forwarding for XenServer:
We may be getting somewhere. You're kibana.stderr looks like you need port 5601 open.
firewall-cmd --zone=public --add-port=5601/tcp --permanent
Sidenote: I still don't like firewall-cmd. Change is hard, even for geeks.
Do you have to reload the firewalld settings to get them to apply?
firewall-cmd --reload
-
@coliver Yep, I keep forgetting that step.... spent an hour the other day wondering why things weren't working.
-
@coliver I did.
I'll run it again though.
-
So still digging into this...
[root@syslog-cent bin]# ./kibana serve restart log [10:14:12.914] [fatal] Error: listen EADDRINUSE 0.0.0.0:5601 at Object.exports._errnoException (util.js:870:11) at exports._exceptionWithHostPort (util.js:893:20) at Server._listen2 (net.js:1236:14) at listen (net.js:1272:10) at net.js:1381:9 at nextTickCallbackWith3Args (node.js:448:9) at process._tickDomainCallback (node.js:395:17) FATAL { [Error: listen EADDRINUSE 0.0.0.0:5601] cause: { [Error: listen EADDRINUSE 0.0.0.0:5601] code: 'EADDRINUSE', errno: 'EADDRINUSE', syscall: 'listen', address: '0.0.0.0', port: 5601 }, isOperational: true, code: 'EADDRINUSE', errno: 'EADDRINUSE', syscall: 'listen', address: '0.0.0.0', port: 5601 }
-
We must have to change the kibana.yml file to not listen on the localhost address...
kibana.yml...
[root@syslog-cent config]# cat kibana.yml server.host: "localhost" elasticsearch_url: "http://localhost:9200" server.port:5601
-
I'm rebooting see if its hung somewhere. As from what I can find online the kibana server is supposedly running twice...
-
Ok so after playing with the timestamp (top right) I do actually have logs, but only from the 12th of the month...
So maybe it was working, but not showing the logs... now to figure out what the crap is broken....
-
I donwloaded the Graylog OVA this morning to test it out and put it on my XS pool. Just set Xencenter to forward logs to the Graylog server, seems to work well. Xenserver still making local log entries, but i am ok with that.
Xenserver sure does like logging messages. 2 hosts making a couple hundred messages/minute, xenstored and xapi are the top ones by far. -
@momurda said in SysLog Forwarding for XenServer:
I donwloaded the Graylog OVA this morning to test it out and put it on my XS pool. Just set Xencenter to forward logs to the Graylog server, seems to work well. Xenserver still making local log entries, but i am ok with that.
Xenserver sure does like logging messages. 2 hosts making a couple hundred messages/minute, xenstored and xapi are the top ones by far.What source are you using?
-
All i did was download and import the ova, then went into Xencenter and forwarded logs on each host to the ip of the graylog server. Here is my sources page
Here is more sources, basically the whole list. I am still quite overwhelmed with the options and config of graylog, but as i get dashboards setup for things and add more log sources i will post them here as well if you would like.
-
I think it is important to note that the graylog ova is preconfigured to 'just work' according to their site, and it seems to do just that. I will try adding some of my windows vm to this and see what happens later today or tomorrow.
-
For some reason I thought / think there are some pretty big limitations to GrayLog.
Maybe I'm wrong.... but I'll take a look at it.
-
For anyone curious how to stop any local logging just modify
/var/lib/syslog.conf
Comment out everything that hits a local path, leaving the @<ip_addr> as the only option.
-
@DustinB3403 said in SysLog Forwarding for XenServer:
For anyone curious how to stop any local logging just modify
/var/lib/syslog.conf
Comment out everything that hits a local path, leaving the @<ip_addr> as the only option.
Reboot and see if it sticks.
It did not for me.