Skip to content

Instantly share code, notes, and snippets.

[Wed Mar 10 07:40:01 2010] [notice] Apache/2.2.14 (Unix) mod_ssl/2.2.14 OpenSSL/0.9.8l Phusion_Passenger/2.2.9 PHP/5.2.11-pl0-gentoo configured -- resuming normal operations
[ pid=11617 file=ext/apache2/Hooks.cpp:727 time=2010-03-10 07:40:06.344 ]:
Unexpected error in mod_passenger: The ApplicationPool server unexpectedly closed the connection while we're reading a response for the 'get' command.
Backtrace:
(backtrace support disabled during compile time)
[Wed Mar 10 07:40:07 2010] [notice] child pid 11609 exit signal Segmentation fault (11)
[ pid=11618 file=ext/apache2/Hooks.cpp:727 time=2010-03-10 07:40:09.93 ]:
Unexpected error in mod_passenger: Could not connect to the ApplicationPool server: Broken pipe (32)
Backtrace:
# This controller handles the login/logout function of the site.
class SessionsController < ApplicationController
# Be sure to include AuthenticationSystem in Application Controller instead
include AuthenticatedSystem
layout nil
# render new.rhtml
def new
end
def create
@opie4624
opie4624 / build-tunnel.sh
Created June 19, 2010 19:57
Reliable outbound SSH tunnel through a restrictive proxy. Read more: http://post.ly/k4O9
#!/bin/bash
echo
date
echo "----------------------------"
if ssh -O check tunnel@vpn.example.com; then
echo "Tunnel's up."
else
echo "Starting up tunnel..."
if ssh -R 2222:localhost:22 tunnel@vpn.example.com -f 'sleep 3300'; then
echo "Seems good."
var fs = require('fs');
var email_file = process.argv[2];
var ws = fs.createWriteStream('/var/node/log.txt', {flags: 'a+', mode: 0666});
ws.write(email_file + ' ' + new Date() + " \n", 'utf8');
var http = require('http');
try {
var mail_server = http.createClient(3000, 'mail.example.com');
var request = mail_server.request('POST', '/services/1.0/rest/mail/', {host: 'mail.example.com'});
@opie4624
opie4624 / sudoers
Created February 23, 2011 23:47
example environment variables for sudo
## Locale settings
Defaults env_keep += "LANG LANGUAGE LINGUAS LC_* _XKB_CHARSET"
##
## Run X applications through sudo; HOME is used to find the
## .Xauthority file. Note that other programs use HOME to find
## configuration files and this may lead to privilege escalation!
Defaults env_keep += "HOME"
##
## X11 resource path settings
Defaults env_keep += "XAPPLRESDIR XFILESEARCHPATH XUSERFILESEARCHPATH"
@opie4624
opie4624 / Xoom-3G-MtnView.txt
Created February 25, 2011 21:56
Measurement Lab NDT tests from my Motorola Xoom
Testing started at Fri Feb 25 02:28:31 PST 2011
From:
OS: Name = Linux, Architecture = armv7l, Version = 2.6.36.3-g2a65edc
Java: Version = 0, Vendor = The Android Project
Latitude: 37.574165
Longitude: -122.309439
NetworkType: mobile
To:
root@prx7:~# shef -z
loading configuration: /etc/chef/client.rb
Session type: client
Loading....................epic fail!
/usr/lib/ruby/gems/1.8/gems/chef-0.9.16/lib/chef/mixin/recipe_definition_dsl_core.rb:56:in `method_missing': undefined method `template' for #<Chef::Recipe:0x7fe8a0e720a8> (NoMethodError)
from /var/cache/chef/cookbooks/chef-client/recipes/config.rb:29:in `from_file'
from /usr/lib/ruby/gems/1.8/gems/chef-0.9.16/lib/chef/cookbook_version.rb:473:in `load_recipe'
from /usr/lib/ruby/gems/1.8/gems/chef-0.9.16/lib/chef/mixin/language_include_recipe.rb:40:in `include_recipe'
from /usr/lib/ruby/gems/1.8/gems/chef-0.9.16/lib/chef/mixin/language_include_recipe.rb:27:in `each'
@opie4624
opie4624 / AppMessages.txt
Created May 15, 2011 07:02
Crash of Mac Arduino 0022
localhost ~/Downloads/noisebridge$ /Applications/Arduino.app/Contents/MacOS/JavaApplicationStub
[JavaAppLauncher] Requested [1.5*], launching in [1.6] instead.
WARNING: RXTX Version mismatch
Jar version = RXTX-2.2pre1
native lib Version = RXTX-2.2pre2
Binary sketch size: 1018 bytes (of a 30720 byte maximum)
Invalid memory access of location 0xb1a2fbe0 eip=0x2f15b90c
Segmentation fault
localhost ~/Downloads/noisebridge$
@opie4624
opie4624 / 01-create-repo.txt
Created September 8, 2011 06:58
Splitting a repository
~/Code/Work$ mkdir repoA
~/Code/Work$ cd repoA/
~/Code/Work/repoA$ git init
Initialized empty Git repository in /Users/akraut/Code/Work/repoA/.git/
(init) ~/Code/Work/repoA$ touch file1
(init file1) ~/Code/Work/repoA$ touch file2
(init file1 file2) ~/Code/Work/repoA$ git add file?
(init file1 file2) ~/Code/Work/repoA$ git commit -m 'add test files'
[master (root-commit) 6be573c] add test files
0 files changed, 0 insertions(+), 0 deletions(-)
[10:31:47] <C> .w 78757
[10:31:47] <diffusion> Austin, TX (78757): 94F/94F 31% 9 mph from SW Fair (1h19m13s from now)
[10:34:59] <witriew> .w
[10:34:59] <diffusion> Mountain View, CA (94043): 17C/17C (63F/63F) 78% 7 mph (11 km/h) from NNW Cloudy (38m59s ago)
[10:35:05] <witriew> mmmmmm
[10:35:46] <witriew> .w vancouver, ca
[10:35:46] <diffusion> Locations found: Vancouver, Canada; West Vancouver, Canada; North Vancouver, Canada
[10:35:55] <witriew> .w Vancouver, CA
[10:35:55] <diffusion> Locations found: West Vancouver, Canada; Vancouver, Canada; North Vancouver, Canada