Skip to content

Instantly share code, notes, and snippets.

@Toady00
Toady00 / 0_reuse_code.js
Created March 16, 2017 19:25
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
vault mount \
--path levvel \
--description "Example CA for vault demo" \
pki
vault mount-tune \
--max-lease-ttl 87600h \
levvel
vault write \

Keybase proof

I hereby claim:

  • I am toady00 on github.
  • I am toady00 (https://keybase.io/toady00) on keybase.
  • I have a public key ASAo7DdK4IKmtlOy7X-QxKy05LeVI3LzDHUP6BFLNYRF4Qo

To claim this, I am signing this object:

==> /Users/brandon/Library/Containers/com.docker.docker/Data/logs/2016-04-13/com.docker.driver.amd64-linux.log <==
2016-04-13T20:48:58.715775-04 Info - proxy >> POST /images/create?fromImage=redis&tag=latest
2016-04-13T20:48:58.715879-04 Info - Dial /tmp/u.socket
2016-04-13T20:48:58.715950-04 Info - Dial IP /tmp/u.socket
==> /Users/brandon/Library/Containers/com.docker.docker/Data/logs/2016-04-13/com.docker.slirp.log <==
2016-04-13T20:48:58.727232-04 Error - com.docker.slirp: [INFO] unix:/tmp/u2.socket:192.168.64.2:2375: connected
==> /Users/brandon/Library/Containers/com.docker.docker/Data/logs/2016-04-13/com.docker.driver.amd64-linux.log <==
2016-04-13T20:49:00.088432-04 Info - proxy << POST /images/create?fromImage=redis&tag=latest
=========================================================================
JBoss Bootstrap Environment
JBOSS_HOME: /opt/torquebox/current/jboss
JAVA: java
JAVA_OPTS: -Xms64m -Xmx512m -XX:MaxPermSize=256m -Djava.net.preferIPv4Stack=true -Djboss.modules.system.pkgs=org.jboss.byteman -Djava.awt.headless=true
@Toady00
Toady00 / aggregated_app.log
Last active August 29, 2015 14:04
TB Singleton jobs that aren't
# app 1 logs
Jul 18 15:14:19 prod-app-01 -: **** CardApprovalMailer Starting ****
Jul 18 15:14:19 prod-app-01 -: **** CardApprovalMailer Finished ****
# app 2 logs
Jul 18 15:14:49 prod-app-02 -: **** CardApprovalMailer Starting ****
Jul 18 15:14:49 prod-app-02 -: **** CardApprovalMailer Finished ****
# app 3 logs
Jul 18 15:14:51 prod-app-03 -: **** CardApprovalMailer Starting ****
@Toady00
Toady00 / KV.rb
Created June 29, 2014 23:34
Ruby Class for getting and setting Consul KeyValues
require 'base64'
require 'json'
require 'rest_client'
module Consul
class KV
URL = "http://localhost:8500/v1/kv"
attr_reader :key,
:create_index,
@Toady00
Toady00 / stace_trace
Created May 30, 2014 14:09
Torquebox Thread Dump showing 8 blocked web threads
2014-05-30 11:18:30
Full thread dump Java HotSpot(TM) 64-Bit Server VM (23.25-b01 mixed mode):
"Attach Listener" daemon prio=10 tid=0x00007f3468027000 nid=0x4257 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"http-/10.211.50.32:8080-11" daemon prio=10 tid=0x00007f345089b000 nid=0x40a6 waiting for monitor entry [0x00007f345c7e5000]
java.lang.Thread.State: BLOCKED (on object monitor)
at org.torquebox.core.pool.SimplePool.borrowInstance(SimplePool.java:68)
- waiting to lock <0x0000000742a354d8> (a java.lang.Object)
@Toady00
Toady00 / yellow-es-nodes.sh
Created April 24, 2014 14:57
I've got 3 es nodes on ec2. I added ebs volume to each (1 at a time), stopped es, copied data/log to the new volume, edited config file to point to new location, and restarted es. Each time the cluster went green within a few seconds. I forgot to change the config file on the second one, so I edited it, and restarted es again. After that, the cl…
# Before data migration
curl -XGET 'http://127.0.0.1:9200/_cluster/health?pretty=true'
# {
# "cluster_name" : "abc_cluster",
# "status" : "green",
# "timed_out" : false,
# "number_of_nodes" : 3,
# "number_of_data_nodes" : 3,
# "active_primary_shards" : 20,
@Toady00
Toady00 / orientdb_stack_trace.txt
Created April 18, 2014 19:52
orientdb stack trace
# com.orientechnologies.orient.enterprise.channel.binary.OChannelBinaryAsynchClient.throwSerializedException(OChannelBinaryAsynchClient.java:264)
# com.orientechnologies.orient.enterprise.channel.binary.OChannelBinaryAsynchClient.handleStatus(OChannelBinaryAsynchClient.java:231)
# com.orientechnologies.orient.enterprise.channel.binary.OChannelBinaryAsynchClient.beginResponse(OChannelBinaryAsynchClient.java:202)
# com.orientechnologies.orient.enterprise.channel.binary.OChannelBinaryAsynchClient.beginResponse(OChannelBinaryAsynchClient.java:113)
# com.orientechnologies.orient.client.remote.OStorageRemote.beginResponse(OStorageRemote.java:1952)
# com.orientechnologies.orient.client.remote.OStorageRemote.openRemoteDatabase(OStorageRemote.java:1597)
# com.orientechnologies.orient.client.remote.OStorageRemote.open(OStorageRemote.java:201)
# com.orientechnologies.orient.client.remote.OStorageRemoteThread.open(OStorageRemoteThread.java:80)
# com.orientechnologies.orient.core.db