Keeping Links Kosher

As part of the re-vamp I’ve put together a 404 script that emails me whenever it’s called. This has certainly been an eye-opener as to the misguided traffic that this site gets. An email is so much different than just seeing the hits in your logs, and I would recommend anyone serious about maintaining a site do something similar.

There are a few links to my old curly quotes entry that link to a rather funky perversion of a fly-by-night URI scheme that has long since gone by the by. These links worked just fine until I deleted the file that was keeping things going, now it’s time to move things into the magic .htaccess file.

Let’s take a look at the URI in question:
http://www.photomatt.net/archives/m/200209?p=186

My first thought was to just plop latter part of the request and create a rule just for this link, as such.

Redirect Permanent /archives/m/200209?p=186 http://photomatt.net/p186

Didn’t work, never matched. Next try I decided to go for something a little broader:

RedirectMatch 301 .*p=([0-9]+) http://photomatt.net/p$1

Didn’t work, never matched. Some research found that the problem lies in the query string, and the Apache redirect directives don’t address the query string. So let’s give mod_rewrite a go:

RewriteRule ^.*p=([0-9]+) http://photomatt.net/p$1 [R=301,L]

Still no luck. (For those that wonder, the HTTP response code 301 indicates that the resource has been permanently moved. “Permanent” in the first try is just a synonym of “301”.) It looks like the magical mod_rewrite doesn’t match query strings either. Some more research turned up that while redirect doesn’t match or rewrite query strings, it does pass them all. So we are left with:

Redirect Permanent /archives/m/200209 http://photomatt.net/

Which, counter-intuitively, works. The ?p=186 on the end is just passed to the root of the site, which gives it to my index file which knows just what to do with it. I would like to eliminate the query string entirely and forward the URI to http://photomat.net/p186 but while that would be trivial in any scripting language I can’t nail down how to do it on the Apache or mod_rewrite level. So my options now are to add something to the global header to catch p=something query strings and redirect it, but I’d like to keep that file clean, so more likely is that I’ll start adding some URI management code into the 404 handler and generally make that file more sophisticated in general. We’ll see.

Airport Security

It’s not that the terrorist picks an attack and we pick a defense, and we see who wins. It’s that we pick a defense, and then the terrorists look at our defense and pick an attack designed to get around it. Our security measures only work if we happen to guess the plot correctly. If we get it wrong, we’ve wasted our money. This isn’t security; it’s security theater.

Bruce Schnier on why airport security is A Waste of Money and Time in the New York Times.

Exploring Ubiquiti

I was looking for something else when I stumbled across a little $95 router that claimed it could do 1M packets per second, multi-WAN, was tiny, and had 80 5-star reviews. Huh? The reviews had some left-handed compliments (“for advanced users only”) but one mentioned getting hooked on the company’s other products as well. Next thing I know I’m looking at a $67 access point that has everyone raving about its range and extensibility. These things were too cheap — my assumption was it was a Chinese OEM like Zyxel that makes novel but ultimately not the best quality products.

At this point I should confess I’m a bit of a consumer networking geek — it’s a hobby of mine. I really enjoy upgrading people’s routers so they have better range in parts of the house they didn’t before, getting them a DOCSIS 3.0 modem so their connection is faster (and buying it so they don’t pay an exorbitant rental fee to their cable company), everything about Sonos, hooking up an Airport Express to Sonos so you can Airplay things, showing how you can set up two APs with the same SSID and clients will just connect to whatever they’re closest to, you don’t need each one to have a unique SSID, you can give the 2.4ghz and 5ghz networks the same SSID, Time Machine for backups, setting up failover internet with multiple connections or a USB LTE stick… I redo all my home stuff about once every 18 months, and then take the best of what I’ve learned and set up friends. I’m constantly updating firmware. My current best practice setup is Sonos for all audio, usually streaming from Spotify or SiriusXM, a Peplink Balance One router, Netgear Nighthawk R9000 access points (though I liked the ASUS AC66U just as much), if I need a switch I’ll go for a higher-end managed one that support spanning tree protocol (STP) properly because otherwise the way the Sonos does bridging can spaz out and overload your network, Nest themostat and smoke detectors, Smartthings for everything else. I’m waiting for August for smart locks.

At the Automattic office we run Meraki, which was pretty solid until we upgraded to the MR34 to get 802.11AC, but it’s expensive, and you need to subscribe to a per-device yearly license fee for everything to work. They also have a great WP-powered blog, and generally the cleanest site of anyone out there. That said, they’re impossible to buy without going through a terrible reseller, so I’ve never been able to justify using it at home.

Back to Ubiquiti. First I come across their forums/community sites, which are ugly and sprawling and full of amazing info from people who do wireless deployments across all of the top companies like Aruba, Ruckus, Aerohive, Xirrus, Meraki. You see people making builds for alternative UPNP packages and that going into their core release months later. (Everything is Debian based, from what I can tell.) The company is based in San Jose that went public a few years ago, and is now worth about 3.7B, and the founder (formerly of Apple) bought the Memphis Grizzlies. They seem to have gotten their start with long-haul point-to-point wireless radios that can go dozens of kilometers, which makes sense why their APs would be known for their range. You can buy direct from them, or like I mentioned most of their stuff is available on Amazon. And it’s inexpensive! Even Ubiquiti’s AC product, which is $300, is much, much cheaper than the Meraki MR34 which costs $1,400 and requires a yearly license or it stops working.

Plus they make these wonderfully cheesy product promo videos:

https://www.youtube.com/watch?v=5aRDVVXMFzE

Normally I wouldn’t post about something until I’ve tried it in-person, but I was excited to find this whole new (to me) world of high-performance, reasonable-cost devices. John Pozazidides, long-time WP community member, did an overview of the Unifi devices on Youtube. At Automattic our once-a-year grand meetup is coming up in Utah, and every year wireless is an issue, especially the first day or two. I ordered some of the Ubiquiti equipment to test when I’m in Houston next week, looking forward to playing around with it.

Any Ma.tt readers with experience with any of these or big WLAN deployments?

VaultPress

We just announced VaultPress to the world. You can get your invite here. I’m very excited about this service because it is the first step toward my dream of every WordPress, regardless of where it’s hosted, to have best-in-the-world network (cloud? ;)) services that take all the worry and hassle away. People invest so much time, money, effort, blood, sweat, and tears into their WordPress-powered sites — they deserve for that to be 100% secure.

Bay Bridge Cable Walk

Had a cool opportunity to walk up the cable to the top of the the first tower of the Bay Bridge today with folks from the Bay Lights project. You walk right up the cable/pipe to the top, it actually wasn’t that hard. Once on top the vistas were amazing. I tried to grab some photos of the hardware behind the lights at the top of the cables. The top of the tower is 526 feet high, and 280,000 cars drive on the bridge every day, making it the second busiest bridge in the world. Guest photos by Lucas Saugen.

Continue reading Bay Bridge Cable Walk

Thumb recovering, now flu

Well the good news is my thumb seems to be recoving, though I’m still keeping it in a splint because it’s really sensitive. The bad news is a few days ago I came down with some sort of cold/flu or strep throat (going to doctor again tomorrow) that has really knocked me out. Maybe it’s the same thing as Om Malik and Matt Marshall. (Someone should do a Web 2.0 mashup of blogs, event calendars, and Google maps to identify Patient Zero.) The only thing that has allowed me to stay concious and not fall too far behind is Tylenol Sore Throat, which is one of the most amazing painkillers ever. My sister was in town and bought this for me and it has been magical, though it tastes awful. One of the biggest problems with sore throats is I don’t eat or drink because it hurts too much, which then gets you dehydrated and sicker. With TST I’m able to get some food and drink down and it also helps with the fever. Hopefully within another day or two this will run its course.

Lent This Year: Buying Things

Today is Ash Wednesday and the start of Lent, when typically Catholics give something up, or try to form a new habit, for about six weeks. Many of my friends who aren’t Catholic do the same, it’s a good practice to try to go without something in your life you take for granted. It can make you reexamine assumptions, take you out of your comfort zone, or make you appreciate the thing you gave up much more when you return to it. Also it’s just a bit more fun when you do it with friends. 😀

Last few years I’ve given up:

  • 2013: Meat.
  • 2014: Smartphones. (This was hard!)
  • 2015: I meditated every day using Calm.

This year I’ve been thinking about what I take for granted, and surveyed friends for what their suggestions would be. One of the things that I’m pretty bad at is buying too many things, especially gadgets. I’m pretty good at clearing out old ones so it doesn’t get too cluttered, but I definitely have a habit of getting the latest USB gadgets on Amazon, shirts from Kit & Ace, workout stuff from Lululemon, shoes I don’t need, etc.

So the thing I’m going to give up this year is shopping or buying any material things. I’m also going to take the opportunity to try and reduce the stuff I do have in my life to things that spark joy.

Clever Virus

Just in case anyone has seen this one going around yet, it is the most clever and well-done spoof I’ve seen in a long time. I have been getting dozens of these and they are humorous because I run my own email systems, so the email just doesn’t make any sense. However I’ve gotten several questions from people I host asking what this means. Here’s what the email looks like:

To: m@wordpress.org
Subject: Email account utilization warning.
From: management@wordpress.org

Dear user, the management of WordPress.org mailing system wants to let you know that,

Our antivirus software has detected a large ammount of viruses outgoing
from your email account, you may use our free anti-virus tool to clean up
your computer software.

Please, read the attach for further details.

Attached file protected with the password for security reasons. Password is 88315.

Cheers,
The WordPress.org team       http://www.wordpress.org

So if you get this, please ignore it like you ignore all attachments that you aren’t expecting.

Rosie O’Donnell

This is too crazy — Rosie O’Donnell of talk show fame has a WordPress blog in which she writes poetry-like entries daily that get hundreds of comments. (And the site is very snappy, this is why more and more high-traffic publishers are switching to WordPress.) It gets better — she’s also on Flickr. I feel like I just stumbled into an alternate universe where celebrities are using software I helped write. Hat tip: neiljmorrow via email.

Do you know someone who is an amazing developer or designer? Someone who is passionate about helping people? An awesome lounge manager? Or maybe that person is you. Automattic is hiring for a variety of positions, and for all except two you can live and work wherever you like in the entire planet. There are also a number of other benefits; the main downside it’s a high performance culture and expectations are extremely high. Automattic hires the best folks regardless of geography, and we are especially looking for people right now outside of US timezones.

New TV Ads

As I mentioned in the State of the Word this is the year we’re ramping up marketing. There is lots to learn and much to follow, but we have our first TV ads up in six markets to test. Each shares a story of a business in Detroit, and I actually got the chance to visit one of the businesses earlier today.