Skip to content

Instantly share code, notes, and snippets.

View aperiodic's full-sized avatar

Dan Lidral-Porter aperiodic

  • BlackBerry
  • Seattle, WA
View GitHub Profile
OpenSSH_5.2p1, OpenSSL 0.9.8r 8 Feb 2011
debug1: Reading configuration data /Users/dlp/.ssh/config
debug1: Reading configuration data /etc/ssh_config
debug1: Connecting to clojars.org [173.230.139.200] port 22.
debug1: Connection established.
debug1: identity file /Users/dlp/.ssh/id_rsa type 1
debug1: identity file /Users/dlp/.ssh/id_dsa type -1
debug1: Remote protocol version 2.0, remote software version OpenSSH_5.3p1 Debian-3ubuntu7
debug1: match: OpenSSH_5.3p1 Debian-3ubuntu7 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
set -g prefix C-h
# double prefix flips between current and last window
bind-key C-h last-window
unbind p
bind-key C-p previous-window
unbind n
bind-key C-n previous-window
# vi copy-mode keys
@aperiodic
aperiodic / gist:1673985
Created January 25, 2012 01:23
TT JStack (when reduce tasks are hanging)
Deadlock Detection:
No deadlocks found.
Thread 23966: (state = IN_NATIVE)
- java.lang.UNIXProcess.waitForProcessExit(int) @bci=0 (Interpreted frame)
- java.lang.UNIXProcess.access$900(java.lang.UNIXProcess, int) @bci=2, line=20 (Interpreted frame)
- java.lang.UNIXProcess$1$1.run() @bci=165, line=132 (Interpreted frame)
@aperiodic
aperiodic / gist:1673171
Created January 24, 2012 22:36
Hanging Reduce Task Stack Dump
Deadlock Detection:
No deadlocks found.
Thread 10740: (state = BLOCKED)
- java.lang.Thread.sleep(long) @bci=0 (Interpreted frame)
- org.apache.hadoop.mapred.ReduceTask$ReduceCopier$GetMapEventsThread.run() @bci=116, line=2740 (Interpreted frame)
Thread 10739: (state = BLOCKED)
@aperiodic
aperiodic / gist:1357108
Created November 11, 2011 03:29
lazybot config.clj
(let [plugins #{"dictionary" "lmgtfy" "google" "translate" "eball" "utils" "leet"
"clojure" "login" "log" "brainfuck" "whatis" "shorturl" "haskell"
"mail" "timer" "fortune" "rss" "title" "operator" "seen" "sed" "help"
"load" "embedded" "karma" "yesno" "autoreply" "weather"}]
{:servers [REDACTED] ; A list of servers.
:prepends #{"@"} ; The character you want for a prepend. Currently set to @
:weather {:token ""} ; Wunderground token.
:dictionary {:wordnik-key "99c266291da87b231f40a0c8902040da0b568588c25526cff"} ; Wordnik API key.
:sed {:automatic? true}
:max-operations 3 ; The maximum number of operations that can be running at any given time.
@aperiodic
aperiodic / mapred-site.xml
Created November 1, 2011 20:04
TT's mapred-site.xml
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<configuration>
<property>
<name>mapred.job.tracker</name>
<value>REDACTED (an ec2 internal DNS name):8021</value>
<final>true</final>
</property>
@aperiodic
aperiodic / syslog
Created November 1, 2011 19:48
Failed reduce task's logs
2011-11-01 11:12:59,373 WARN org.apache.hadoop.conf.Configuration: /mnt/data/hadoop/mapred/local/taskTracker/ubuntu/jobcache/job_201110251936_0044/job.xml:a attempt to override final parameter: mapred.system.dir; Ignoring.
2011-11-01 11:12:59,374 WARN org.apache.hadoop.conf.Configuration: /mnt/data/hadoop/mapred/local/taskTracker/ubuntu/jobcache/job_201110251936_0044/job.xml:a attempt to override final parameter: mapred.local.dir; Ignoring.
2011-11-01 11:12:59,374 WARN org.apache.hadoop.conf.Configuration: /mnt/data/hadoop/mapred/local/taskTracker/ubuntu/jobcache/job_201110251936_0044/job.xml:a attempt to override final parameter: mapred.tasktracker.reduce.tasks.maximum; Ignoring.
2011-11-01 11:12:59,415 WARN org.apache.hadoop.conf.Configuration: /mnt/data/hadoop/mapred/local/taskTracker/ubuntu/jobcache/job_201110251936_0044/job.xml:a attempt to override final parameter: mapred.tasktracker.map.tasks.maximum; Ignoring.
2011-11-01 11:12:59,416 WARN org.apache.hadoop.conf.Configuration: /mnt/data/hadoop/mapr
@aperiodic
aperiodic / gist:1225735
Created September 18, 2011 23:58
Node-canvas greyscale jpg bug example
/**
* Script to demonstrate node-canvas greyscale JPG bug
*
* example input: http://i.imgur.com/BrPWa.jpg
* example output: http://i.imgur.com/eg2Nc.png
*/
var Canvas = require('canvas')
, Image = Canvas.Image;
var fs = require('fs');
@aperiodic
aperiodic / gist:1217674
Created September 14, 2011 20:23
Curry module `npm test` output
npm ERR! [email protected] test: `synct test/*.js`
npm ERR! `sh "-c" "synct test/*.js"` failed with 127
npm ERR!
npm ERR! Failed at the [email protected] test script.
npm ERR! This is most likely a problem with the curry package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! synct test/*.js
npm ERR! You can get their info via:
npm ERR! npm owner ls curry
@aperiodic
aperiodic / gist:1217659
Created September 14, 2011 20:19
Curry.js test error
[dlp@Hackworth:curry]$ expresso test/curry.expresso.js
uncaught: Error: Cannot find module 'curry'
at Function._resolveFilename (module.js:317:11)
at Function._load (module.js:262:25)
at require (module.js:346:19)
at Object.<anonymous> (/Users/dlp/code/opensource/curry/test/curry.expresso.js:2:13)
at Module._compile (module.js:402:26)
at Object..js (module.js:408:10)
at Module.load (module.js:334:31)