Skip to content

Instantly share code, notes, and snippets.

View gburd's full-sized avatar

Greg Burd gburd

View GitHub Profile
@gburd
gburd / gist:738469
Created December 12, 2010 23:41
Combines JBookTrader marketData log files.
#!/usr/bin/env python
# Author Gregory Burd <gburd@ossus.com>
#
# The author places this work into the public domain.
# http://creativecommons.org/licenses/publicdomain/
import sys, re
count = len(sys.argv)
files = []
@gburd
gburd / brew-doctor
Created August 12, 2011 20:35
brew install clisp fails to build
gburd@tautog:~$ brew doctor
Your OS X is ripe for brewing.
Any troubles you may be experiencing are likely purely psychosomatic.
gburd@tautog:~$ uname -a
Darwin tautog.local 11.0.0 Darwin Kernel Version 11.0.0: Sat Jun 18 12:56:35 PDT 2011; root:xnu-1699.22.73~1/RELEASE_X86_64 x86_64
@gburd
gburd / desktop.sh
Created December 8, 2011 19:31
Automate the install of X11 and Gnome2 on FreeBSD
#!/bin/sh
##################################################################
##################################################################
#
# The FreeBSD Easy Work Station Installation Script.
# David Childers - 15 Dec, 2009 / Updated 15 April, 2011
#
# This software is released under the Attribution-ShareAlike version 3.0 Licence.
# http://www.creativecommons.org/licenses/by-sa/3.0/
#
@gburd
gburd / haproxy.conf
Last active July 5, 2022 13:34
Recommended haproxy settings to balance Riak protobuf and http interfaces (note: WORK IN PROGRESS)
# Documentation for HAProxy
# http://code.google.com/p/haproxy-docs/w/list
# http://haproxy.1wt.eu/download/1.2/doc/architecture.txt
# NOTES:
# open files limits need to be > 256000, use ulimit -n to set (on most POSIX systems)
global
log 127.0.0.1 local0
log 127.0.0.1 local1 notice
@gburd
gburd / qs4riak.txt
Created February 8, 2012 17:46 — forked from micrypt/gist:1048924
Riak Quick Start from GitHub
# Install Erlang
$ sudo apt-get install autoconf
$ curl -O https://raw.github.com/dreverri/kerl/master/kerl; chmod a+x kerl
$ ./kerl build R14B04 r14b04
$ ./kerl install r14b04 /opt/erlang/r14b04
$ . ~/.kerl/installs/r14b04/activate
# Build Riak from source
$ git clone git://github.com/basho/riak.git
$ cd riak
@gburd
gburd / gist:1828342
Created February 14, 2012 17:26 — forked from seancribbs/gist:1704534
Riak Ruby install
--- setup:
gem install riak-client
--- create a cluster
require 'rubygems'
require 'riak/cluster'
cluster = Riak::Cluster.new(:count => 4, :source => "/opt/riak/1.0.3/node1/bin", :root => "/tmp/mycluster")
cluster.create
cluster.start
cluster.join
@gburd
gburd / gist:2265856
Created March 31, 2012 14:58
tank's zfs setup
AVAILABLE DISK SELECTIONS:
0. c0t0d0 <ATA-OCZ-REVODRIVE-1.23-55.90GB>
/pci@0,0/pci8086,3b42@1c/pci12d8,e130@0/pci1095,7124@0/disk@0,0
1. c0t1d0 <ATA-OCZ-REVODRIVE-1.23-55.90GB>
/pci@0,0/pci8086,3b42@1c/pci12d8,e130@0/pci1095,7124@0/disk@1,0
2. c2d0 <WDC WD10- WD-WCASJ134583-0001-931.51GB>
/pci@0,0/pci-ide@1f,2/ide@0/cmdk@0,0
3. c3d0 <WDC WD10- WD-WCASJ126055-0001-931.51GB>
/pci@0,0/pci-ide@1f,2/ide@1/cmdk@0,0
4. c4d0 <GIGABYTE-FB15841760ECB972-0001-4.00GB>
@gburd
gburd / console
Created April 20, 2012 21:19
tank's setup after adding card (SYBA SD-PEX40044 RAID Caddy for Two 2.5" SATA 6Gbps Hard Disk Drives, PCI-Express Card, Marvell 88SE9128 Chipset)
[root@00-25-90-0c-52-53 ~]# format
Searching for disks...done
AVAILABLE DISK SELECTIONS:
0. c0t0d0 <ATA-OCZ-REVODRIVE-1.23-55.90GB>
/pci@0,0/pci8086,d13a@5/pci12d8,e130@0/pci1095,7124@0/disk@0,0
1. c0t1d0 <ATA-OCZ-REVODRIVE-1.23-55.90GB>
/pci@0,0/pci8086,d13a@5/pci12d8,e130@0/pci1095,7124@0/disk@1,0
2. c2d0 <WDC WD10- WD-WCASJ134583-0001-931.51GB>
@gburd
gburd / iopattern.ksh
Created April 26, 2012 19:38
iopattern - print disk I/O pattern.
#!/usr/bin/ksh
#
# iopattern - print disk I/O pattern.
# Written using DTrace (Solaris 10 3/05).
#
# This prints details on the I/O access pattern for the disks, such as
# percentage of events that were of a random or sequential nature.
# By default totals for all disks are printed.
#
# $Id: iopattern 65 2007-10-04 11:09:40Z brendan $
-module(timeit).
-compile(export_all).
%% @doc Dynamically add timing to MFA. There are various types of
%% timing.
%%
%% all - time latency of all calls to MFA
%%
%% {sample, N, Max} - sample every N calls and stop sampling after Max
%%