Skip to content

Instantly share code, notes, and snippets.

Avatar

Larry Smith Jr. mrlesmithjr

View GitHub Profile
View logstash.conf
input {
udp {
type => "syslog"
port => "514"
}
filter {
if [type] == "syslog" {
dns {
reverse => [ "host" ] action => "replace"
}
View gist:eadec9e51382d2426729
output {
syslog {
type => "syslog-relay"
facility => "%{syslog_facility}"
host => "solarwinds"
port => 514
severity => "%{syslog_severity}"
}
}
View gist:2af152fe56cfe1f480fc
curl localhost:9200/_templates?pretty
No handler found for uri [/_templates?pretty] and method [GET]
View gist:53453bfb5d418f7a2b71
input {
redis {
host => "127.0.0.1"
data_type => "list"
key => "logstash"
}
}
input {
udp {
type => "syslog"
View gist:b734ea2825331d1bb837
RAW Log
<135> 05/13/2014:21:17:55 GMT nsvpx-esx-2 0-PPE-0 : SSLLOG SSL_HANDSHAKE_SUCCESS 6103955 0 : SPCBId 59218 - ClientIP 142.28.165.235 - ClientPort 56308 - VserverServiceIP 192.168.1.200 - VserverServicePort 443 - ClientVersion TLSv1.0 - CipherSuite "RC4-MD5 TLSv1 Non-Export 128-bit" - Session Reuse
filter {
if "Netscaler" in [tags] {
grok {
break_on_match => false
match => [
"message", '%{SYSLOG5424PRI} %{DATE}:%{HAPROXYTIME} GMT %{SYSLOGHOST:syslog_hostname} %{PROG:netscaler_process} : %{DATA:netscaler_feature} %{DATA:netscaler_message} %{DATA} : %{DATA} %{INT:netscaler_spcbid} - %{DATA} %{IP:client_ip} - %{DATA} %{INT:client_port} - %{DATA} %{IP:vserver_ip} - %{DATA} %{INT:vserver_port} - %{DATA} %{DATA:client_version} - %{DATA} "%{DATA:cipher_suite}" - %{DATA} %{WORD:session_method}'
]
View Logstash-ES-Cluster.sh
#!/bin/bash
#Provided by @mrlesmithjr
#EveryThingShouldBeVirtual.com
set -e
# Setup logging
# Logs stderr and stdout to separate files.
exec 2> >(tee "./Logstash_Kibana3/install_logstash_es_cluster_ubuntu.err")
exec > >(tee "./Logstash_Kibana3/install_logstash_es_cluster_ubuntu.log")
View haproxy-1_interfaces
iface lo inet loopback
auto lo
auto eth0
iface eth0 inet static
address 10.0.101.61
netmask 255.255.255.0
gateway 10.0.101.1
dns-search everythingshouldbevirtual.local
dns-nameservers 10.0.101.110 10.0.101.111 10.0.101.112
View haproxy-2_interfaces
iface lo inet loopback
auto lo
auto eth0
iface eth0 inet static
address 10.0.101.62
netmask 255.255.255.0
gateway 10.0.101.1
dns-search everythingshouldbevirtual.local
dns-nameservers 10.0.101.110 10.0.101.111 10.0.101.112
View ha.cf
watchdog /dev/watchdog
logfile /var/log/ha-log
debugfile /var/log/ha-debug
deadtime 5
warntime 10
initdead 15
bcast eth1
auto_failback on
node haproxy-1
node haproxy-2
@mrlesmithjr
mrlesmithjr / VMware Dashboard
Last active Aug 29, 2015
Logstash VMware Dashboard
View VMware Dashboard
{
"title": "VMware",
"services": {
"query": {
"list": {
"0": {
"query": "*",
"alias": "",
"color": "#7EB26D",
"id": 0,