Wipe and shutdown remote Linux server over SSH

Wiping and shutting down a headless linux server over SSH.

Copies zeros over the whole disk.

dd if=/dev/zero of=/dev/sdaX

Where sdaX is the device you want to wipe. Read discussion at security.stackexchange.

Since the shutdown command will be trashed by the wiping, we need to force shutdown in another way.

echo 1 > /proc/sys/kernel/sysrq
echo o > /proc/sysrq-trigger

Don’t try this at home.

Fix Tab Indenting in Coda

Since I’ve got a Swedish keyboard on my MacBook Pro tab-indenting using “Shift Left ⌘[” and “Shift Right ⌘]” does not work (or actually only Shift Right works).

The reason for this is that you must use the Alt-key to get a bracket [, and apparently Command-Alt-[ is already taken by toggling zoom on/off.

To make tab-indenting work in Coda, open System Preferences, Keyboard, click Keyboard Shortcuts tab, select Universal Access and finally uncheck the box for Turn zoom on or off.

Developing Large-Scale JavaScript Web Sites – SWDC2010 slides

Being very humbled to be part of the star struck lineup at The Scandinavian Web Developer Conference 2010 I did a talk about Developing Large-Scale JavaScript Web Sites (slides available here as PDF).

The presentation is basically a quick high-level overview of some of the main points I’ve encountered after several workshops at different clients wanting to take the step from a legacy server centric web site architecture to a modern rich client side implementation.

Ajax and REST architecture – Optimera STHLM slides

I did a presentation at Optimera STHLM entitled Faster websites with AJAX and REST architecture. The talk are more on an architecture level, rather than about implementation details.

Slides are available as PDF here (this is an english version of what was presented).

The demo I did of the Friendly Iframe ad-loading optimization by Tobias Järlund at Aftonbladet is available at the Aftonbladet dev blog (swedish).

Introduction to Google Maps API

I just did a short talk at the Google Technology User Group meetup in Stockholm this evening about the Google Maps API. The purpose of the talk was to give a quick introduction on how to get started as well as show off some of the features. I wanted to emphasize how easy, using only a few lines of code, it is to leverage power-full features like geocoding, directions and streetview in your own implementation.

Here is the presentation as pdf and the implementation examples I demonstrated.

It was great fun as always, with lots of people (apx 90). Thanks for having me!

Coders at Work book review

I recently read Coders at Work (published by Apress), here is a quick book review…

One way to describe this book, in a somewhat generalized way, is to say “Old people talking about when they were programmers”. The book is a collection of transcript style interviews with some of the most protruding people in the history of computer programming. 15 interviews in all, from Jamie Zawinski of Netscape fame (the young one of the lot, thereby the “old people” tongue-in-cheek reference) to Donald Knuth.

Each interview is prefaced with a short introduction of the interviewee, followed by a discussion around a number of topics; how did you learn to program, how do you prefer to read code, hardest bug you tracked down, do you think of yourself as a scientist, engineer, artist or craftsman, what do you think of formal proofs, have you used literate programming, how do you interview candidates for employment, and more.

The author, Peter Seibel, is himself an experienced programmer resulting in insightful questions that only someone with great knowledge about programming may ask, making the interviews more free and targeted towards the interest of the particular person. It also makes the discussion feel more genuine and honest, rather than a set of questions and answers following a strict agenda.

The focus of the interviews are not technology, but the person being interviewed and how they look back on their career. The technical discussions typically centers on systems like PDP and programming in LISP. Although most issues are still relevant today in some way or another, the context is usually not on today’s technology (you do not program using punch cards, do you?).

That means that this book is not for someone looking at quick technical tips to apply in their current programming language of choice. But for those genuinely interested in the craft of software development this book is inspiring and gives insight into the people who were significant in some way bringing the industry into what it is today.

The book really does not analyze the answers in the interviews to a greater extent, leaving that to the reader. But to mention a few reoccurring themes there seems to be a consensus that programming is harder today (mostly because of parallelization) and C++ (and especially pointers) is crap.

Notable famous people missing from the list are Linus Torvalds (Linux) and John Carmack (Doom/Quake). Both were contacted by author Peter Seibel but he never got an answer. Additionally, most of the interviewees look back at the time when they were programming as their main profession, this is not a list of the superstar programmers of today (which would make a great follow up book).

All in all, if you are interested in the people, how they are and what their thoughts and experiences are like, then this book is for you – you’ll likely find it both inspiring as well as entertaining as I did. If you want source code listings, look elsewhere.