“You have successfully unsubscribed from our newsletter. We are sorry to see you go. Please note that it may take up to 10 days for your request to be processed. You may still receive emails during that time.”

Unsubscribe message from every email newsletter you’ve signed up for

Translation: We hope this bullshit 10-day period will make you forget you unsubscribed, so that you don’t get mad when we don’t actually unsubscribe you.

filter-messages-like-these.png The above, from Rafael Torres on Tumblr, is precisely why I no longer unsubscribe from anything, I just make a Gmail filter to delete the message as soon as it arrives.

No hoops to jump through, no confirmation required. Poof! Gone!

Most of the time I filter on the From: line, because almost all of those newsletters now come with a footer or header asking you to add newsletter@sketchydomain.com to your “white list” or address book. They don’t want their newsletter accidentally ending up in your Spam folder. That’s the address that you want to make sure is in the “From:” spot in the Create a Filter page on Gmail.

vistaprint-filter-on-from.png

This is a good solution but not a great solution.

It doesn’t cost them anything more to start sending out two emails: one from the old “From:” line and one from another. Or they could sell your email address.

A better solution would be to filter the email address that the email is delivered to rather than sent from.

Various solutions to this have cropped up, including OtherInbox which gives you a free (limited) domain such as @you.otherinbox.com. OtherInbox will let you have email delivered to any email address at your personal domain and will automatically filter each of them. So you could have ebay@you.otherinbox.com and amazon@you.otherinbox.com and so on. If you decided that you don’t want to accept email at any of these addresses, just click a box and voilà!

OtherInbox needs to make money, however, so they place some limits on the service, and make other features available for a fee.

The biggest drawback for me is that I had to remember to check my OtherInbox mailbox, and it wasn’t Gmail.

You should be able to use a “+” with any Gmail address, such as tj+sketchydomain@gmail.com and filter using that. Unfortunately, in practice there are two drawbacks to this method:

  1. It is easy for them to just drop the +sketchydomain and spam you directly
  2. Many, many, many web forms will not accept a “+” in an email address, even though they should

I eventually decided to make my own solution, using the idea from OtherInbox along with Google Apps (not Gmail).

I’ve written about quitting Gmail for Google Apps. When I setup my email with Google Apps, I setup two main email addresses:

  1. A default email that I use for communicating with real people
  2. A “newsletters” account, which accepts email sent to any address (commonly referred to as a “Catch-all”)

catch-all-google-apps-mail.png Now when I have to give my email address, I can use sketchydomain@example.com and from that point on I can start filtering messages sent to that email address. (I can also post email addresses on webpages and find out who scrapes web pages for email addresses.)

The last real key to this equation was figuring out how to accurately filter email sent to a specific address.

Your first instinct is probably to just put sketchydomain@example.com in the To: part of Create a Filter, but that will not catch all messages sent to that address. All someone has to do is put your email address in the BCC line or as part of a mailing list and that email address won’t appear at all.

To catch all messages sent to a Gmail/Google Apps address, you want to use a little-known search filter called deliveredto: which Google describes as

Search for messages within a particular email address in the Delivered-To line of the message header
Example: deliveredto:username@gmail.com

Meaning: Any message with username@gmail.com in the Delivered-To: field of the message header (which can help you find messages forwarded from another account or ones sent to an alias).

The Delivered-To: can’t be spoofed by the person who sent the message.

It can’t be left out.

gmail-deliveredto-screenshot.png To filter on the “Delivered-To:” field you use “deliveredto:” (note the absence of the “-”) and put the email address after it in the “Has the words” section of the “Create a Filter” dialog.

Click “Test Search” to see what messages that it would match.

Then just create a filter to delete any new messages which are sent to that address.

And suddenly your “10 day waiting period” has been reduced to 10 seconds. If your email address is ever sold to another company, they will use the same address, and it too will get filtered. If you ever decide that you do want to get their newsletter again, just delete the filter. (HAHAHAHAHA… no, really, it could happen…)

Jason asked a really good question:

Quick question, Tumblr Hive:

For the longest time, I’ve been hosting my Tumblr blogging account (jasonpermenter.tumblr.com) elsewhere with a custom domain name (jasonpermenter dot com). Am I right in assuming that if I click the button and revert back to using “jasonpermenter.tumblr.com” in my Tumblr settings, all the previous external links, reblogs, &c, associated with my blog will break?

Anyone have any help/comments/suggestions/advice before I brazenly take jasonpermenter dot com back for other purposes?

For those who don’t know, Tumblr will automatically create a free website for you at YOURNAMEHERE.tumblr.com. You can, if you wish, use your own domain name, such as YOURNAMEHERE.com.

However (and this is the cool part), Tumblr still maintains YOURNAMEHERE.tumblr.com.

My first reaction to Jason’s question was that he could use the Tumblr Backup App currently in beta. The backup app will let you export your entire Tumblr into static files which can be used on any website, which is very cool. However, there are a few problems with this.

Most Tumblr URLs look like this: http://jasonpermenter.tumblr.com/post/337030717/breaking-links. A “secret” about Tumblr URLs, however, is that this is the only part that matters: http://jasonpermenter.tumblr.com/post/337030717/. Everything after the number is just for show. Tumblr calls them “Descriptive” URLs, and they are good for SEO, not to mention being easier to read when you are looking through your web browsing history.

The good news is that you can put anything you want there, and even change them after it is posted, and Tumblr will figure it out. So imagine Jason changed the URL to http://jasonpermenter.tumblr.com/post/337030717/not-breaking-links but I had already linked to http://jasonpermenter.tumblr.com/post/337030717/breaking-links. Tumblr will handle it.

This is a great feature that Tumblr offers, but there are two “catches”:

  1. The Tumblr Backup App currently exports files with paths like this: /posts/337030717.html (note that instead of /post/ they are exporting to /posts/ and they stick a .html on the end of the number).

  2. You don’t know what URLs someone might have linked to. For example, you could conceivably track down all the URLs in your website and setup all the static files that you exported from your Tumblr, but you wouldn’t catch those people who (like me) sometimes trim off the “excess” part of the URL.

The more I thought about it, the more I realized that trying to solve this using static files and URLs on your own domain was stupid idea.

Really, this is one of those situations where a computer should do all the work for you. After all, it’s a simple matter of calculating the proper substitution. In plain English, all we want to do is this:

Whenever anyone goes to http://something.com slash ‘post’ slash ’series of numbers’ slash ‘optional words here’ automatically redirect them to http://something.TUMBLR.com slash ‘post’ slash ’series of numbers’ slash ‘optional words here’…

Turns out there’s a feature to do just that, called mod_rewrite. The problem is that it is both incredibly powerful and incredibly complex.

The good news is that once someone figures out the right incantation, it should work for anyone else trying to solve the same problem. In this case the solution appears to be:

RewriteEngine on
RewriteRule ^post/([^/.]+) http://jasonpermenter.tumblr.com/post/$1 [L]

Add that to the /.htaccess file on your server and all of your incoming links should automatically redirect to the proper place.

Please note that I am not a mod_rewrite expert; in fact, I know very little about it. I figured out the above by adapting information from mod_rewrite, a beginner’s guide (with examples) (which I found via Google) and a little trial & error.

That said, I have it setup on this site, and you can test it for yourself using these URLs:

http://luo.ma/post/337030717/breaking-links

http://luo.ma/post/337030717/

http://luo.ma/post/337030717/LOREM-IPSO-FACTO

All of which should redirect you to http://jasonpermenter.com/post/337030717/breaking-links.

If anyone who knows mod_rewrite better would like to suggest improvements to what I have above, please do.

To add someone to a Twitter list, you have to load their Twitter page, then click the box, then choose the correct list you want to add them to.

That’s fine if you are dealing with a few of them, but what if you have a long list of 100+ names you want to add to a Twitter list?

That’s where “twitter-add-to-list.sh” comes in:

twitter-add-to-list.sh tj luomat twitreport 

will add those three names to a Twitter list. Which list? The list you define in the script using the $LISTNAME variable.

The script is fairly easy to use. You need to edit three lines:

TWITTER_USERNAME=
TWITTER_PASSWORD=
LISTNAME=

Put in the appropriate information, save the file, and off you go (NOTE: be sure that the list already exists).

Download

Thanks to the power of Dropbox, you can always get the latest version of the script (the one that I am using and possibly updating) at:

http://dl.dropbox.com/u/18414/bin/twitter-add-to-list.sh

That link will probably display in your browser, so if you want to save it locally, right-click (Mac users: control-click) the link and choose the appropriate save action.

rmdir and .DS_Store

2009/12/15

Has this ever happened to you?

$ rmdir test
rmdir: test: Directory not empty

$ ls -A test     
.DS_Store

Grrr. The directory is empty, except for the .DS_Store file which Mac OS X sometimes creates.

This happened to me enough times that I wished that Apple would create a version of ‘rmdir’ which would delete the .DS_Store iff it was the only file in an otherwise empty folder.

I’ve been waiting for Apple to do this for 4 years now, and finally decided that it was stupid to wait when I could fix the problem myself with a few lines of code.

Behold TJ’s rmdir function. (You’ll want to control+click that link if you want to download the file, otherwise it will just display in your browser.)

39 lines of actual code plus comments. Why so long? I tried to be extra careful, since we are talking about deleting files, after all.

The code itself is fairly simple:

  1. Take a bunch of arguments
  2. Check to see if those arguments translate to directories
  3. If they do, check to see if the directory is emptied by /bin/rmdir
  4. If /bin/rmdir fails, check to see if the only file in the folder is .DS_Store
  5. If yes, delete the file and re-run /bin/rmdir on the folder
  6. If no, just report the directory is not empty

Voilà.

This is a zsh function which ought to work in most bash-like shells. If you’d prefer a bash script it is also available. (I’d recommend renaming the script to ‘rmdir’ and just dropping it in your $PATH.

Tested on Mac OS X 10.6.2 using zsh 4.3.9.

Jason Coe at Appmodo is becoming the Rob Enderle of iPhone Tethering rumors.

Here is his latest post

AT&T CEO Says Tethering Coming Soon for iPhone

POSTED BY JASON COE ON NOVEMBER 10, 2009 AT 2:10 PM | HARDWARE, NEWS, IPHONE

Last Thursday at the Web 2.0 Summit in San Fransisco, AT&T Wireless CEO Ralph de la Vega made the announcement that tethering for the iPhone 3G is coming “soon”, although the word “soon” was quite defined last month in one of our previous reports. The comment was also reiterated by an AT&T spokesman yesterday morning. The announcement comes as an AT&Tempt to build hype for the service as AT&T continues to upgrade and patch their network for continued 3G coverage.

No details were leaked yet regarding price, but judging by AT&T’s BlackBerry model tethering plans, we can expect pricing to be around $60 each month, something we’ve been saying since July. De La Vega also stated that the company and Apple are “working together to bring the functionality to the iPhone”, however the feature can already be accessed by jailbreaking your iPhone.

At the end of an article is a link to Macworld

Sounds good, right?

Here are some of the flaws:

  1. The link to Macworld is to an article from November 2008. In case you have amnesia, it is currently November 2009. The “[l]ast Thursday at the Web 2.0 summit” was November 6th, 2008.

  2. Coe links to his article last month (see also here) where he reiterated that tethering was not coming until 2010. What made him sure that tethering wasn’t coming until 2010? Because an AT&T representative would not give a specific date. Is that evidence? No, that’s a guess. Could he be right? Sure. But he doesn’t have anything real to base this on.

  3. Jason has consistently claimed that AT&T is going to charge $55-$60 a month on top of your existing iPhone data plan for tethering.

Here is what AT&T had to say (on the record) about the cost:

“There are a lot of reports out there, but wanted you guys to know that rumors of $55 tethering plan on top of an unlimited data plan are false. We’ll have more news to share when the iPhone tethering option is closer to launch.”

Coe continues to claim that “his source” says differently. He has previously described this source as “an undisclosed reputable AT&T employee”. The first bit of “insider information” this source gave?

EXCLUSIVE: A source with AT&T informed Appmodo today that MMS for the iPhone will be coming mid July, not “the end of the summer” as previously reported. June 17th, Appmodo

As we all know, the date ended up being just after the end of summer.

Today Coe cites “AT&T’s BlackBerry model tethering plans” as an indicator that the costs will be “around $60/month”.

So I took about two minutes to Google for AT&T BlackBerry tethering plans, and found this page

AT&T-Blackberry-Tethering.png

That chart very clearly shows “Smartphone Personal: $30.00″ and “Smartphone Personal plus Tethering: $60.00.”

iPhone 3G/3GS customers are already paying the same $30/month for unlimited data. If we are going to use AT&T’s Blackberry Tethering costs as a guide for what iPhone Tethering might cost, it would be $60 total per month not $60 in addition to the $30 you are already paying which is the line that Coe keeps repeating.

I don’t know why Coe keeps insisting on this “additional $60/month” cost, but there is absolutely no evidence for it.

Nor is there any evidence that tethering is coming “soon”…

In fact, if Coe had read today’s report from Macworld instead of last year’s, he would have seen this:

AT&T Monday reiterated its plans to offer tethering on the iPhone, but again gave no date when that might happen— more than a year after the carrier first said tethering would be coming “soon.”

Asked just when that would be, a spokesman said in an e-mail: “We plan to offer tethering on the iPhone but have not announced a date.”

Emphasis added, as Macworld goes on to link to their article from a year ago quoting Ralph de la Vega.

I don’t know when tethering is coming. I do know that so far, Jason Coe at Appmodo has been completely wrong with his predictions, and his source has been unreliable. If AT&T fails to deliver tethering by December 31st, he can claim that he correctly read the tea leaves of AT&T’s “non-statement” of when it was coming, but it will have been a guess… all they have said officially is “It’s coming, but we aren’t saying when.”

Update: Coe has now changed the link to point to Computerworld.com where the title of the page is “Tethering to iPhone still coming, AT&T says; no date set”. This is the source of the Macworld article I mentioned above. Coe has not changed the rest of the article to reflect the fact that he is referencing a quote from a year ago.

UPDATE: the above article has been taken down, and now points to a story about AT&T being sued for not providing MMS in some part of the USA.

I’ve had a Gmail account since Fri, Jun 25, 2004 at 12:03 PM. I know this because I still have the “Gmail is different. Here’s what you need to know…” message.

I don’t remember when I started my second Gmail account, but in the past 5+ years, I have assembled a small collection of Gmail accounts (more than 10, less than 20). Why? For separate projects, true separation is helpful. I want all of my work emails separated from all of my personal emails separate from all of my Twitter/Tumblr/etc emails. Sometimes it’s helpful to be able to give out an email address which is somewhat “disposable” and doesn’t connect to your real identity.

It seemed fine until…

About 6 months ago, one of these ’spare’ accounts was suspended without warning. When I tried to login, I saw this:

Gmail-Disabled-Web-Login .png
No, that isn’t my real Gmail address

Clicking on that “?” link takes you to this page which says:

I’m getting a message that says ‘Sorry, your account has been disabled.’

If you’ve been redirected to this page from the sign in page, it means that access to your Google Account has been disabled.

In most cases, accounts are disabled because of a perceived violation of either the Google Terms of Service or product-specific Terms of Service.

Google reserves the right to:

  • Suspend a Google Account from using a particular product or the entire Google Accounts system if the Terms of Service or product-specific policies are violated.

  • Terminate your account at any time, for any reason, with or without notice.

If your Google Account has been disabled, please review the relevant Terms of Service before attempting to create another account. For guidelines on a specific Google product, please visit the product homepage for a link to its Terms of Service.

If you believe your account was disabled in error, contact us.

Did you see that bold bullet point? They can delete your account at any time, for any reason, without notice. Emphasis added. What’s your recourse then?

This happened on 4-5 accounts. Fortunately it did not happen on my primary account.

I clicked on the “?” link and then the “disabled in error” link. I received a message back asking me to prove I owned the account using the “Can’t access your account?” link.

After asking for an alternate email address, they begin asking questions:

Describe the problem you’re experiencing:

  • I am unable to reset my password
  • I believe someone has taken over my account
  • Other

You can check the “Other” box but it doesn’t give you any room to say “My account was disabled without any notice or reason given.”

You are essentially trying to prove that you own the account, as if you had forgotten the password.

“Do you use Gmail with this account?” (Well, yeah)

“Do you use orkut with this Google Account?” (What? No)

“Do you use Blogger with this Google Account?” (NO)

“Google products you used with this account and the date you started using each one” (N/A)

“Account creation date” (Who the hell remembers?)

“Last successful login date” (How should I know?)

“Last password you remember” (That one I could answer, because it was stored in Mac OS X’s Keychain)

“Please note that we need your IP address in order to resolve this issue. Your IP address will be captured automatically when you submit this form.” (This is meaningless, because I have a dynamic IP. Most of the internet is on a dynamic IP. Static IPs are rare.)

(n.b. I didn’t remember when I had last logged in because I didn’t log in very often. Some of these accounts very rarely get any email. I wasn’t checking them manually, because I use Mailplane.app automatically logging in for me. If I didn’t see any login error or unread messages, I assumed that it was working fine. Unfortunately Mailplane has not done checking for “disabled” accounts. I have contacted the developer and he has added the necessary checking to the latest beta, so Mailplane will alert you if your account is disabled, as shown here:)

Mailplane-Disabled.png
This will be available in the next version of Mailplane

I did the best I could to guess at the answers, and then I waited.

Here is the first email response I received:

Thank you for your report. We’ve completed our investigation and cannot return your account at this time. We were unable to verify that you own this account based on the information you provided.

If you can provide additional information to verify that you own this account, please visit http://www.google.com/support/accounts/bin/request.py?ara=1 and submit another report. Whether we can return access to this account depends on the strength and accuracy of your responses, so be sure to provide as much information as possible. If you’re unsure about specific dates or information, provide your best guess.

To create a new account, please visit https://www.google.com/accounts/NewAccount

We apologize for any inconvenience and appreciate your cooperation and understanding.

Regards, The Google Team

I had purchased a “.com” domain and registered the accompanying “@gmail.com” email address to use with it.

What nefarious purpose had the account been used for? Receiving notifications of blog comments which had been posted to it. As far as I know I hadn’t even sent a single email from it, so I certainly wasn’t a spammer.

I emailed them again and received this response:

This account has been disabled and we’re unable to return it.

The email then copied the “Terms of Service” text above it.

At this point I was beyond angry. There was no justification for suspending the account, but they held the strings. What if it had been my main email address that I’ve been using for 5+ years?

I contacted them again, giving them as much information as I could scrape together, and then I waited.

A few days later, the account was restored.

Be Prepared

I have since gotten smarter. Every time I setup a new Gmail account, I set it to forward all messages to another account. Go to Forwarding and POP/IMAP settings, and tell it to forward a copy of all your incoming mail to a non-Gmail account.

Gmail Forwarding and POP.png
I maintain an account at Dreamhost specifically for this purpose.

If an account is suspended, I can go in and identify when emails stopped arriving. It also gives me access to what might otherwise be lost information.

Last but not least: when you create a new Gmail account, Google sends you a “Verification code” to the “alternate email” address that you provide when you sign up. The message looks like this:

GMail Verification Email.png
Yes, Gmail is warning me that this message from Gmail might be phishing, despite that it is “signed by” Gmail. Which tells you what a bunch of hogwash “email signing” is.

Save that email (or at the very least, the code and the name of the account it goes with) somewhere other than in Gmail. I suggest Yojimbo or Evernote or in a textfile in your Dropbox.

The first time it happened I was able to piece together enough information that they enabled the account, but it seemed unlikely for awhile. Since then it has been smoother, I believe due in no small part because I have the information that they want.

But why?

Good luck getting any answer out of Gmail as to why your account was suspended.

I’ve also never been told “You have too many Gmail accounts.” In fact, whenever one of these accounts was suspended I used my main Gmail account as the “emergency contact” address.

I was not told “We believe that your account was compromised. You should pick a better password.”

Here is what I was told:

We apologize for any inconvenience you may have experienced. The issue you described should now be resolved.

One of the emails continued:

If you are still having trouble accessing your account and you still have access to the email address you used to create your account, please reset your password by visiting https://www.google.com/accounts/ForgotPasswd. If you aren’t receiving the password-assistance email, please check your inbox for an email from accounts-noreply@google.com.

If you don’t have access to the primary email address on the account or have forgotten the answer to your security question, please fill out the form at http://www.google.com/support/accounts/bin/request.py?ara=1

What Now?

I’ve decided that the only safe bet is to give up my @Gmail address. I’m not suggesting that everyone should do the same, but I have lost trust that Gmail won’t just one day decide to disable my main email address. They reserve the right. I have no recourse. It’s a free service, they can do whatever they want. It’s not like I could sue them. The most I could do would be to sit there with hat in hand and say “Please, sir, give me my email address back…”

So what did I do?

I registered a new domain name (no, not this one, for reasons I won’t bother to explain here). I picked one that I could easily remember, and went with a “.net” instead of a “.com” because they are a lot easier to find. Then I signed up for Google Apps Standard Edition.

Don’t feel cheated. There’s a very important difference here.

The domain is under my control. If Google decided to shut it down or interfere with it in any way, I can immediately switch the email hosting back to Dreamhost and have my email restored in a matter of minutes or hours (not days).

I did the exact same Forwarding and POP/IMAP trick when I setup my Google Apps account, forwarding to a Dreamhost email account.

That gives me a full archive/backup of my email separate from what Google has.

I’m hopeful that Google will be less capricious about randomly suspending non-@gmail accounts, but it’s less of an issue because I can use “aliases” (what Google refers to as ‘nicknames’) in my Google Apps account. For example I could have: flickr@example.net, twitter@example.net, tumblr@example.net, ebay@example.net, paypal@example.net, amazon@example.net, and a whole bunch of others, and they would all deliver to the same mailbox.

If I need/want that “true separation” (which is why I created separate Gmail accounts in the first place) I’ve got 50 users for free. Assuming each of them has 30 aliases available I could conceivably have the equivalent of 1,500 email addresses.

Actually, it’s more than that. You can create a “catch-all” which will accept any email sent to any address at your domain. Now anyone who knows email will tell you that’s almost asking for spam, but setting up one user (anybody@example.net) and setting it as a catch-all will let you do something like what Other Inbox is good for: a throwaway email address that you can make specific to any website.

Scenario: You’re at “SomeReallyLameWebSite.com” and they demand an email to download something, or insist that you create an account. Give them “SomeReallyLameWebSite@example.net”. Get what you need, and then create a filter to delete any messages sent to that address.

n.b. Someone is bound to say “Well you could just use ‘myrealname+foo@gmail.com’ to do that!” Except that there are a lot of sites, a lot of sites, which will not accept a “+” on the left-hand side of an email address, claiming it is “invalid”. Plus, all any spam harvester would have to do is take a list of all the emails they have and strip off everything from the + to the @ to get your actual email address.

The End Result

My (latest) disabled account was re-enabled one day after I contacted Google. I received the same form letter as above.

I’m giving up on “@gmail.com” but not Gmail. It’s going to be a bit of a pain for awhile as I figure out all of the places I need to change my email address. Of course I’m not deleting my main @gmail.com email address (and I’m trying to get my recently-disabled account restored). I am simply moving things over as I think of them. Fortunately I’m on so few mailing lists these days that I don’t get anywhere near the volume of email I once got–in fact, mailing list management was the reason I originally got my first Gmail account. It was strictly “throw away” content. Amazing how much has changed since then!

I don’t mean that I won’t use it for anything… for example, it seems to be tied with Google Wave and Google Voice (Google Apps users still need a Gmail account sometimes) but for everything else? My email needs to be under my control.

Doesn’t yours?

I bought the MPEG-2 Quicktime Playback Component several years ago.

Why? Well, read the above link, but basically it allows me to play MPEG-2 files in Quicktime.

What can I say, I’m a simple man.

Yes, you can play MPEG-2 files using VLC. This isn’t intended to convince you of why you might want the MPEG-2 com.

It’s also not going to tell you how to get it if you haven’t paid for it (sorry, if that’s what you were looking for).

The purpose is to be able to figure out to re-download it after you’ve paid for it. (If you want to buy it, it’s $20 at the Apple Store.)

Because I keep forgetting.

  1. Goto http://store.apple.com/

  2. Click on the “Account” link shown here, top right corner:

mpeg-2-a.png

(That was how the store was designed as of 2009-01-30. It may have changed since. Basically you want to find a way to log in once you are at the Apple Store website.)

  1. Look for a download link “Downloadable software purchases” such as this:

mpeg-2-b.png

(You’ll be prompted to login.)

4) You’ll see a line like this (the date will indicate when you purchased it)

QT 6 MPEG-2 Playback - Mac OS X     D2187Z/A    3 August 2004       Download

The word “Download” will be a clickable link.

That’s it.

Simple. Once you know what the steps are.

As Dr. Cupper used to say, “Everything is easy when you know what you are doing.”

Find and Post My IP

2009/09/16

I use and love DynDNS but for some reason one of my hosts isn’t updating like it should.

While I work on a solution, I need to make sure that I can get at the machine via ssh, which means I need to know its IP address.

There are a lot of sites which offer to show you your IP but when I tried a few of them via scripts, they either blocked lynx, or required that the search be done interactively. Not to mention the ads and other crap/

I can see their point (they don’t want to be inundated with a bunch of automated requests) and this isn’t a tricky problem to solve, assuming you have access to a webserver where you can run PHP. Create a small file named something like ’showmyip.php’:

Step 1: Make a PHP file on your server

<?php

$ip=$_SERVER['REMOTE_ADDR'];
echo "<html><body>$ip</body></html>";

?>

You could skip the actual HTML markup, but it’s shown here as an example.

Step 2: Create a script on the computer you want to be able to find via IP

Then you just need a script which will check the IP, and then upload it to the same server. So, an example of how this might work here at luo.ma

#!/bin/zsh -f

# your $PATH may be different
PATH=//usr/local/bin:/usr/local/sbin:/opt/local/bin:/sbin:/bin:/usr/sbin:/usr/bin

MYIP=`lynx -dump -nomargins "http://luo.ma/showmyip.php" | egrep '[0-9]'`

if [ "$MYIP" != "" ]
then

    ssh luo.ma "(echo $MYIP > public_html/$HOST.ip.txt)" 

fi

Note: http://luo.ma/showmyip.php is not the actual path. My goal here is not to setup a free service for you, but show you how to setup your own.

This assumes that you’ve already setup password-less ssh between the $HOST machine and the server. If you’re operating at this level of geekdom, I’m sure you can figure out how to make that work…

Save that “/usr/local/bin/uploadmyip.zsh” (or whatever… be sure to make it executable!) and add it to cron:

Step 3: Add script from step 2 to cron

*/15 * * * *  /usr/local/bin/uploadmyip.zsh

That tells cron to update it every 15 minutes.

Notes:

Be sure to customize the script to your setup:

  1. Change http://luo.ma/showmyip.php to the path on your server.
  2. Change ssh luo.ma to ssh your.server.name.here
  3. Change public_html/ to wherever you want the file stored relative to your $HOME on the remote server.

The end result is that I could go to http://luo.ma/imac.ip.txt and always know that I was getting the current IP address for my iMac, from any computer.

I was watching an instructional movie tonight in QuickTime X, and needed to pause it to look at what was going on.

This is what QuickTime gave me. Note the that “now you see me, now you don’t” window bar is actually obscuring the menu bar of the application shown on the screen, which is the part of the movie I was trying to look at more closely:

QT X screenshot

The new UI of Quicktime lacks any “chrome”. It’s a slick look… if all you’re doing it watching a movie. However, if you want to pause a movie, well it’s pretty dang ugly. You can forget getting a screenshot of whatever you’re watching, because that’s when the faux-chrome appears, and it never goes away.

Compare that to how this same image looks in QuickTime 7:

QT 7 screenshot

Yes, my screenshot shows the “chrome” but I could crop that out fairly easily if I wanted to, but more importantly, in QuickTime 7 I can actually see what I wanted to see which was which menu item was being used.

Despite the new QuickTime’s designation as “X” (or “10″ like “Mac OS X”) it’s really a 1.0. It’s a fairly typical Apple move, throw away the old way completely and force people to use the new way, much like with iMovie. As with iMovie, Apple has kept QuickTime 7 around as an optional install, and it is still downloadable from Apple’s website.

This 1.0 is rough around the edges, and so minimal that it’s fairly painful, especially if you were used to QuickTime Pro. Yes, the chrome-less looks nice (actually it looks strange, but it’s an “ok” kind of strange), but it isn’t always practical.

I wondered if there was a preference to make the window bar “normal”—which was when I realized that there are no preferences for QuickTime X at all

Oh, Apple…

This particular problem is “fixable”… simply have the “faux” window bar and controls fade after a few seconds, as QuickTime 7 did in full screen mode. Move the mouse over the window, and it reappears. I suspect Apple will do something like that in a later version of QuickTime, but perhaps they were concerned that people would not know where the controls were at all if they didn’t keep them on-screen for QuickTime X “1.0″.

That said, I seem to recall from my brief stint with Windows XP that Windows Media Player did something like hiding the chrome, but then making it reappear outside (not overlapping) the content in the window. If so, Apple would probably avoid doing that just to avoid comparisons with Windows Media Player.

There are other choices on the Mac, of course. Not just QuickTime 7, but VLC. QuickTime X’s UI is unique, as far as I know, and Apple might be happy to let the other players do other things better, but they want to provide the best playback experience.

I just happen to prefer the older way, which is why I went to the Finder, selected a .mov, and told it to “Change All” to open with QuickTime 7 instead of X.

There’s a bumper sticker that I’ve often seen on pickup trucks which reads:

Yes, this is my truck
No, I won’t help you move

Well, I don’t own a pickup truck, but like most Known Computer Geeks, I do get asked to help people with their computers. Most of the time I’m glad to do it, especially if I can sit in front of the machine and look around for myself. Most of the time people are very grateful. A couple of friends bought me a nice bottle of scotch as a thank you for helping them. Did I say “couple of friends”? I meant “my new best friends.”

I don’t do crossword puzzles and I can’t rewire the house. I can usually solve computer mysteries, and I enjoy the challenge. Usually. Mostly in hindsight, after I’ve figured it out.

Hell is Other People’s Computers

A friend brought her laptop and said that Dropbox had stopped working. She also said that her 4 year old great-granddaughter had been playing on the computer around the same time. (They have since put a password on their main account and made a guest account for her.)

I assumed this would be a simple task: download and reinstall Dropbox. Whatever was missing would be replaced.

Except that it wouldn’t reinstall. Every attempt was met with this error message:

Error opening file for writing c:\users\sally\appdata\roaming\dropbox\bin\python25.dll [abort] [retry] [fail]

I was logged in as ’sally’ which was the only administrator account on the machine.

Things I tried:

  • right-clicking on the installer .exe and doing ‘run as administrator’.

  • turning User Account Control off.

  • deleting the folder.

I saw that the folder was marked “Read Only” and so I changed that.

Nothing worked.

Everything seemed to be telling me it was a permissions problem, but nothing was giving me the option to give it my OK to “do it anyway.”

I tried installing it after doing a “Safe Boot” but that didn’t seem to work either.

Finally, I decided to create another administrator account. I logged in and installed Dropbox again, and it worked…

but during the installation process, a program called ThreatFire jumped up and said “Hey! This program looks dangerous! Do you want to install it?!” I said I did, and it finished installing.

When I realized I hadn’t seen that same warning in the other account, I became curious. I tried disabling it, but that didn’t help. Then I opened the program up and looked around. Sure enough, there in its “quarantine” was Dropbox.

I restored it (ignoring the message that I was running a “potentially malicious program”) and it works fine.

When I told Sally about it, she said “Oh, that’s right, there was something that came up, but I wasn’t sure what it said.”

(Here is the fundamental problem with these anti-virus/anti-spyware programs: they have to be overly aggressive to catch new threats, or else risk people getting infected even though they had installed the program. They also need to prove that they are doing something, so you won’t think that you wasted your money buying them. People who are worried about these things are going to become more worried because they are constantly bombarded with warnings that they are under potential attack. They are, most likely, going to do one of two things: either start accepted everything or start denying everything. If they start accepting everything, they’re more likely to eventually get hit by a piece of malware. If they start denying everything, they’re going to find things don’t work, and they aren’t going to know why.)

In just a very short time running Vista, I am amazed at how hyperactive Microsoft made it. Requiring user confirmation of every action may give them the ability to say “We’re secure! We asked if you wanted to do it!” but the annoyance level is so high that I would suspect many users have disabled the warnings altogether.

As usual, “create a new account and see if it works there” is a really handy diagnostic.