Stop! mysqlHammerOfThor.py time!

So, expanding upon my previous post, I wrote a simple python script that would kill all queries running on a MySQL instance based on a host wildcard or runtime of a query.

Yes, yes, I know about mk-kill, but I enjoy writing little scripts.  Writing trivial scripts is always a great way to get better. :)

Continue reading

Share

Automating Some Cassandra Maintenance


Lets talk about Cassandra maintenance.

Nothing crazy here… these are just some notes I jotted down for folks I work with explaining a cronjob I put into production as well as providing the simple script.  Thought some other people might benefit.

Continue reading

Share

Code Example: Linux + PyUSB & the Dream Cheeky Thunder/Storm USB Missile Launcher


Went to Staples the other day to grab some assorted accessories for work and I saw they had some Brookstone USB Desktop Missile Launchers in the clearence section, so I grabbed one.

What fun, I thought. Plugged it into my work desktop (running LinuxMint Debian Edition) only to find there were no linux drivers for this particular device.

This turned into a nice little weekend project :)

Continue reading

Share

Code Example: Using Python Suds to Access the Bronto API.

For some internal notification system I was attempting to write a script that would occasionally clear a list in Bronto, our email delivery platform.

They have a lovely little SOAP API, but almost all of the examples were in PHP or Java. Since I am running this as a cronjob, and me being more of a Pythonist, I thought Python was a better place for me to implement this.

The Bronto team, while not terribly proficient in Python, were as helpful as they could be. My major stumbling blocks were getting the authentication mechanism to work correctly, then it took a while to discover how to properly pass arguments to the API.

Eventually I’ll do more stuff with it, but for now, I thought I’d publish this in case it might be useful for someone else using Python with thier API.

Code starts below. Mind you, I am not a developer, be kind :)

Continue reading

Share