View ceph-rados-latency.py
#!/usr/bin/env python
'''
This script writes X MegaByte random data to a number RADOS objects and reads the data again afterwards
It sends these statistics towards a InfluxDB so you can plot the latency of your Ceph cluster
Author: Wido den Hollander <wido@widodh.nl>
'''
View create-win10-usb.sh
#!/bin/bash
#
# Create Windows 10 USB under Ubuntu 16.04
# You might need to adjust some paths
#
DEV=sda
fdisk /dev/$DEV
View docker-ipv6-nat.sh
#!/bin/sh
#
# ONLY USE IPV6 NAT FOR TESTING PURPOSES
#
# IPV6 IN PRODUCTION SHOULD RUN WITHOUT NAT!
#
ip6tables -t nat -A POSTROUTING -s fd00::/64 -j MASQUERADE
dockerd --ipv6 --fixed-cidr-v6=fd00::/64
View rbd-iscsi-tgt.conf
<target iqn.2015.01.rbd.example.com:iscsi>
driver iscsi
bs-type rbd
readonly true
backing-store rbd/rbdimage1
initiator-address 192.168.72.50
initiator-address 192.168.72.51
initiator-address 192.168.72.52
initiator-address 192.168.79.60
initiator-address 192.168.79.61
View ceph-build-rpm.sh
#
# Commands to clone Ceph and build RPMs from Source using Docker
#
# Modify to your needs
#
# Author: Wido den Hollander <wido@widodh.nl>
docker pull centos:7
docker run -ti centos:7 /bin/bash
yum install -y git rpm-build rpmdevtools
View ceph-cluster-pool.py
#!/usr/bin/env python
#
# Simple Python script which creates a few RADOS connections and randomly uses them to perform
# stat calls on Objects
#
# Script was used to diagnose some problems a customer experienced with his Ceph cluster
#
# Author: Wido den Hollander <wido@widodh.nl>
#
import random
View gist:1359f814007392644cf7ed68ec08bb63
#!/bin/sh
#
# Author: Wido den Hollander <wido@widodh.nl>
#
set -e
TIMEOUT=5
HEALTH=$(ceph --connect-timeout=$TIMEOUT health|head -n 1|awk '{print $1}')
View kernel-cleanup.sh
#!/bin/sh
# Cleanup all old kernels and associated packages from the system
set -x
IFS='
'
# more than 1 might very well be broken!
retention=1
View serf.service
[Unit]
Description=SERF
Documentation=https://www.serf.io/
[Service]
Type=simple
ExecStart=/usr/local/bin/serf agent -bind=[2001:db8::100] -rejoin -join=[2001:db8::100] -join=[2001:db8::101] -join=[2001:db8::102] -event-handler=/usr/local/bin/serf-event-handler
Restart=always
RestartSec=10s
View rgw.vcl
vcl 4.0;
import std;
import directors;
acl purge {
"::1";
"127.0.0.1";
}