Skip to content

Instantly share code, notes, and snippets.


Hans Hasselberg i0rek

View GitHub Profile

  • oxalic acid vaporization (late november, early december)
# accepts git urls
# accepts https urls
function gclone
set url $argv
switch $url
case "git*"
set path (string replace -r "\.git\$" "" (string replace ":" "/" (string sub -s 5 $url)))
case "https://*"
set path (string sub -s 9 $url)
case '*'

Keybase proof

I hereby claim:

  • I am i0rek on github.
  • I am i0rek ( on keybase.
  • I have a public key whose fingerprint is 3A99 65AD CAFC BA51 6057 0F49 3972 102D D7CA BE4D

To claim this, I am signing this object:

i0rek /
Last active Aug 18, 2021
Install dnsperf on ubuntu
sudo apt-get install -y bind9utils libbind-dev libkrb5-dev libssl-dev libcap-dev libxml2-dev
curl -O
tar xfvz dnsperf-src-
cd dnsperf-src-
sudo make install
View gist:cda247e94d30bfe91cee
The initial observed cluster behavior:
1) Constant churn of nodes between Failed and Alive
2) Message bus saturated (~150 updates/sec)
3) Subset of cluster affected
4) Some nodes that are flapping don't exist! (Node dead, or agent down)
One immediate question is how the cluster remained in an unstable
state. We expect that the cluster should converge and return to
a quiet state after some time. However, there was a bug in the
low level SWIM implementation (memberlist library).
i0rek / gist:5565206
Created May 12, 2013
Demonstrate file upload with ethon.
View gist:5565206
require 'ethon'
def forge_easy(url, file)
easy = url, upload: true)
easy.infilesize = file.size
multi =
View fu
> require 'typhoeus'
#=> true
> Typhoeus::Config.verbose = true
> Typhoeus.get("")
* About to connect() to port 80 (#0)
* Trying 2001:500:88:200::10...
* Failed to connect to 2001:500:88:200::10: No route to host
* Undefined error: 0
* Trying
* connected
View gist:4960948
2013-02-15T14:41:21+00:00 app[web.1]: Started POST "/adyen" for at 2013-02-15 14:41:21 +0000
2013-02-15T14:41:21+00:00 app[web.1]: Parameters: {"pspReference"=>"8813609392802715", "eventDate"=>"2013-02-15T14:41:20.17Z", "merchantAccountCode"=>"Wunderlistshop", "reason"=>"73567:1111:6/2016", "originalReference"=>"", "value"=>"5", "eventCode"=>"AUTHORISATION", "merchantReference"=>"SKINTEST-blah", "operations"=>"CANCEL,CAPTURE,REFUND", "success"=>"true", "paymentMethod"=>"mc", "currency"=>"EUR", "live"=>"false"}
View gist:4960931
2013-02-15T14:55:01+00:00 app[web.1]: Started POST "/adyen" for at 2013-02-15 14:55:01 +0000
2013-02-15T15:06:13+00:00 app[web.1]: Parameters: {"pspReference"=>"dispute_report_2013_02_07.csv", "eventDate"=>"2013-02-08T18:39:13.40Z", "merchantAccountCode"=>"Wunderlistshop", "reason"=>"", "originalReference"=>"", "value"=>"0", "eventCode"=>"REPORT_AVAILABLE", "merchantReference"=>"", "operations"=>"", "success"=>"true", "paymentMethod"=>"", "currency"=>"EUR", "live"=>"false"}
View Gemfile
source ""
gem 'typhoeus', :git => ""