Sat 25 October 2014
Tags:
I am migrating away from a Linux/WP OpenVZ VPS to an OpenBSD/KVM VPS for hosting my website and
other data. Please excuse the dust and broken links while I figure out Pelican.
I will probably write more notes here related to OpenBSD, PF, IPSec, Python, and pet projects …
Continue reading »
Thu 28 June 2012
I wonder if the Facebook storage engineers developing
Knox
know about this?
Pro Tip: Don't yell at your storage or it will eat your expectect performance for lunch.
Continue reading »
Wed 21 April 2010
I recently needed to trim the last N characters from a string in shell.
I wrote this little function to handle it.
This requires a newer distro that has updated coreutils that includes
the 'fold' command (Feb 2010).
#!/bin/bash
function trimChars() {
if [ $2 ]; then
TRIM_LAST=$2
elif ! [ $2 …
Continue reading »
Mon 01 February 2010
Tags:
To debug a specific python script, start by inserting the following in to your .py file:
import pdb; pdb.set_trace()
These commands allow you to step through the code from the point of
where pdb.set_trace() is placed in your script.
p \<object> - print the content of an …
Continue reading »
Mon 01 February 2010
Tags:
i've been learning bits of python here and there for work and for play
and I came across a simple solution to a simple problem I had to solve
in python.
There are some things in python that once you realize how things work
you think "that is so simple …
Continue reading »