Skip to content

Instantly share code, notes, and snippets.

@qdzlug
qdzlug / cns.md
Created September 19, 2016 16:38
CNS Lab

Current Setup

  • Client is Macbook w/ the Triton tools installed.
  • Using Demo01 Sandbox.
  • Misterbind is the instance we are testing from - it's a slave to CNS, but that is not an important part of the equation - ie, we could test from anywhere.....
  • Our current UUID is 9535103a-3b8d-4922-b78d-0e5dda8186a9
  • We have configured this CNS to come up as public.demo01.local for our domain name.

Round Robin Balancing via DNS

@qdzlug
qdzlug / 0_reuse_code.js
Last active August 29, 2015 14:26
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

Manatee Brain Transplant

The goal of this process is to upgrade a manatee of any vintage to Manatee v2. It relies on ZFS send/recv to replicate the data, but is limited to a migration between nodes in ONWM.

step 1. upgrade moray

Upgrading moray to a forward/backward compatible version is a prerequisite of the upgrade. The usual process is to disable one moray node, double-check the stack reconnects correctly, reprovision that node, and then repeat for other moray nodes.

If there is only one moray node deployed, deploying a second using the new image allows you to upgrade the original node as above.

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname

Setting up fabrics in coal

Prerequisites

You need pretty much the newest version of everything. Go update it all. I'll wait.

sdcadm installations and configuring

Manatee Brain Transplant

The goal of this process is to upgrade a manatee of any vintage to Manatee v2. It relies on ZFS send/recv to replicate the data, but is limited to a migration between nodes in ONWM.

step 1. upgrade moray

Upgrading moray to a forward/backward compatible version is a prerequisite of the upgrade. The usual process is to disable one moray node, double-check the stack reconnects correctly, reprovision that node, and then repeat for other moray nodes.

If there is only one moray node deployed, deploying a second using the new image allows you to upgrade the original node as above.

Setting up fabrics in coal

Prerequisites

You need pretty much the newest version of everything. Go update it all. I'll wait.

sdcadm installations and configuring

cat manta_identify_sorted.txt | \
awk '{print $7 " " $1 " " $3}' | \
sort -n | \
sed -e 's/MB/ MB/' -e 's/KB/ KB/' | \
-e 's/+0+0//' -e 's/x/ /' |
awk '{print $1 ", " $2 ", " $3 ", " $4 ", " $5}' > Getty_Filesizes.csv
time find . -name '*.jpg' -exec sh -c 'convert "{}" -thumbnail 10000@ -strip -quality 95 PNG8:`basename "{}" jpg`png' ';'
mfind /$MANTA_USER/public/getty -n 'jpg$' | mjob create -w -m 'convert $MANTA_INPUT_FILE -thumbnail 10000@ -strip -quality 95 PNG8:/var/tmp/out.png && mpipe ${MANTA_INPUT_OBJECT%.*}.png < /var/tmp/out.png'