This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
output { | |
# <SNIP> other outputs <SNIP> | |
# | |
# Ping me if anything is about to explode, or if any important massage pass by | |
# | |
xmpp { | |
tags => 'warn_me' | |
host => "ejabberd.example.io" | |
message => "time='%{@timestamp}', host='%{@source_host}', tags='%{@tags}',path='%{@source_path}', type='%{@type}', field='%{@fields}' message='%{@message}'," |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- NB '%{@type}' must be the same as table_name | |
-- create database logstash; | |
CREATE TABLE table_name ( | |
table_name_id int(8) unsigned NOT NULL AUTO_INCREMENT, | |
logtime datetime DEFAULT NULL, | |
tags varchar(255) DEFAULT NULL, | |
message varchar(255) DEFAULT NULL, | |
PRIMARY KEY (table_name_id) | |
); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
input{ | |
file { | |
type => "custom_logger" | |
format => plain | |
path => "/tmp/debug_ls_input" | |
tags => [ "debug","no_alert" ] | |
} | |
tcp { | |
type => "custom_logger" | |
format => "plain" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
########################################## | |
# DEFAULTS FOR TESTING | |
########################################## | |
# | |
# First we set our defaults for our config tests | |
# We have been testing with logstash monolithic 1.1.9 | |
# When testing the default is "-v" but you can try "make indexer LSFLAGS=--v" etc... | |
# We are using monolithic, unless we can work with the flatjar then use "make indexer LSTYPE=flatjar " | |
# | |
LSVERS=1.1.9 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# | |
# | |
# The following will Install autofs and create an AutoFS config that | |
# will mount SERVER:/EXPORT on MOUNT_POINT/$MOUNTNAME | |
# | |
# OPTION: | |
# You can also add all subdirs of a mount by adding a trailing "&" | |
# The following will mount each dir under /nfs/disks/ discreetly | |
# disks -rw server:/nfs/disks/& |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
REMOTE_SYSTEM=$1 | |
# You want to filter out your ssh pipe from tcpdump. | |
# So we need to know what our IP is that is connecting to the system | |
# IF behind a firewall you will want to fix this | |
# | |
# There are more elegant ways than this, I just can remember them :} | |
# LOCAL_IP=$(ifconfig |grep 192 | cut -d: -f2 | cut -d\ -f1) | |
# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# | |
# Some times you jsut want the files from an installed package... | |
# | |
for package in $( rpm -qa |egrep $1 ) | |
do | |
rpm -ql $package | xargs tar -czvf $package.tgz | |
done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# CREATE XCAT STATLESS IMAGE | |
# -- note you can not make a statless image for a distro other than the one this script is running on | |
# -- That is various tools will fail if you try to build fedora on centos, or centos6.1 on centos6.4 | |
# | |
# Setup DISTRO Variables | |
DIST=`lsb_release -i | cut -d: -f2 | sed 's/\s//g' ` | |
REL=`lsb_release -r | cut -d: -f2 | sed 's/\s//g' ` | |
MAJ=`echo $REL | cut -d. -f1 | sed 's/\s//g' ` | |
release=rh$MAJ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# define vaiables | |
# In my real set up this is a lot more complex but if you are new to xcat | |
# this should be useful enought to get started | |
HOST_NAME=nodename | |
mac=00:50:56:b0:d0:00 | |
ip=192.168.13.16 | |
XCAT=192.168.13.100 | |
OS=centos6 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DISTRO=centos6 | |
DISTRO_VERS=6.4 | |
ISO_ARCH=x86_64 | |
ISO_DISTRO=CentOS-${DISTRO_VERS} | |
RPM_MIRRIR=http://centos.mirror.iweb.ca | |
getisos(){ | |
for i in 1 2 | |
do | |
# http://centos.mirror.iweb.ca/6.4/isos/x86_64/CentOS-6.4-x86_64-bin-DVD1.iso | |
wget ${RPM_MIRRIR}/${DISTRO_VERS}/isos/${ISO_ARCH}/${ISO_DISTRO}-${ISO_ARCH}-bin-DVD${i}.iso |
OlderNewer