Beware of The Flying Scotsman

Landed in Shanghai yesterday.   It’s amazing – it’s like a whole different country here!  Contrary to previous beliefs, it’s not all sticky or covered in jam.  Damn.  I’ll keep looking for that place.

The language barrier is tough.  Chinese isn’t like most languages that I’ve encountered in my travels where it’s based on Latin so I can guess what every third word is.  But it’s not hopeless; I think in a few days I’ll have picked up some basic phrases and symbols.  In the mean time, I’m being nice to people and lots of folks speak a bit of English and I’m grateful for that.  In a pinch, gesturing wildly has worked.

I got picked up by a prepaid taxi at the airport – you know all those drivers at airport arrival halls with names written on signs?  That was me.  A very nice man was stood with the following written on a sign:

Patric
k vanstaver
en

He got me to my hotel in good time and it was great.  We didn’t understand a single word we said to each other, but what I love is that humor doesn’t require language.  In the parking garage at the airport we took the elevator to the wrong floor and we had a good laugh about it together.  Nice guy, he was very polite even though I hadn’t taken the time to even remember how to say “thank you” in Chinese.  He also drove a mean stick shift.

Made it into the office at 5 PM in good spirits.  Walked right into the end of a management meeting with two guys in London on video conference.  My boss, Steve, who lives in Chicago was in London and it was a bit puzzling running into him on video conference when neither of us are at home.

I very quickly met everyone in the office here.  I like the office here; it’s rather small in comparison, probably about 25 people total.  Everyone’s friendly to a visitor, which is great.  Unfortunately my brain doesn’t do well with names, so it’s going to take me a while to get to know everyone.  And it’s hard, because I’m self-conscious about how little of the language I know and how much or little people might know.

My host here is Kevin, who’s the head of IT in the AP region and lives here in Shanghai.  Kevin earned the name The Flying Scotsman a few years back when he moved here to help open this office.  Kevin and I have a bad history of drinking too much when we’re in the same city.  Staying in Shanghai at the same time is Jason, our global head of IT, who likes to stay out as well.  We went out to dinner last night (at a rather Western style place, which wasn’t much of an experience) and stayed out much too late bar-hopping.  We’re pretty sure that the wrong turn was the absinthe.  We all lived like we were college kids, and we’re paying for it today.  Productivity is low.

The city is crazy.  There’s a highway right by the office here which has lanes both on the ground and elevated above it.  California, you pale in comparison.  There’s a sprinkling of cyclists here, which is a welcome sight.  Drivers are crazy tho, so you have to watch before you walk.  Lots of colors too – buildings and trees and everything is covered in lights.  I’ve got a great view from the 32nd floor of the hotel room and hopefully I can get a picture or two of it all.

Thursday is St. Patrick’s day, and apparently we’re all going out for drinks.  I’ll be impressed if I find some green beer!

Posted in Uncategorized | Tagged | 4 Comments

Sipdroid and diamondcard

A few years ago when first travelling overseas I spent $10 on a SIP-to-landline calling service, Diamondcard, that would allow me to use Ekiga on my laptop to make phone calls while in the UK to the US.  It works well, and it’s cheap.

Nowadays I have a T-Mobile G1.  Using Sipdroid and any available data connection, I can now make calls on Diamondcard from my phone.

How to:

  • Buy a Diamondcard account.  Yes, click the giant red SIGNUP NOW link.  Put ten bucks into it.  You’ll end up with two distinct pieces of authentication:
    • Website login username & password: these aren’t used to connect to the SIP server.
    • Account ID (mine’s five digits) and PIN number (mine’s 12 digits).  These are for SIP authentication.
    • Diamondcard account information
  • Download and install Sipdroid.  I recommend grabbing the version off the site as it supports connections over 3G, which is not available in the market edition.
  • In Sipdroid go to Menu -> Settings -> SIP Account Settings
    • Authorization Username: <your Account ID>
    • Password: PIN number
    • Server: sip.diamondcard.us
    • Be sure the protocol is set to UDP
    • Diamondcard Connected
    • You should see the green circle of happiness in the notifications bar (pictured above).  If you see yellow or red, it’s failing to connect or authenticate.
  • Make a test call.  Dial *43 for the standard Asterisk echo test.  Sipdroid shows latency and loss stats on screen, watch them.  I recommend staying on the echo test for a few minutes to see how stable your connection is.
  • Call people!  I’m pretty sure you’ll need to be explicit about country codes so be sure to prefix numbers appropriately, such as +1 800-555-0123 or +44 20 7946 0123.

You might also want to:

  • Plug Diamondcard into PBXes.org (it does work, maybe I’ll write it up…)
  • Set your Diamondcard Caller ID
Posted in Uncategorized | Tagged , | 2 Comments

How to recover an ext3 volume with an unreadable journal

Last Wednesday I came to work to find my workstation had died overnight — and upon reboot, it failed to mount or fsck the root partition.  Unfortunately it seems my disk has seen enough service and was having failed reads:

Jun 19 08:51:39 atlas kernel: [ 1324.948428] sd 3:0:1:0: [sdb] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE,SUGGEST_OK
Jun 19 08:51:39 atlas kernel: [ 1324.948434] sd 3:0:1:0: [sdb] Sense Key : Medium Error [current] [descriptor]
Jun 19 08:51:39 atlas kernel: [ 1324.948442] Descriptor sense data with sense descriptors (in hex):
Jun 19 08:51:39 atlas kernel: [ 1324.948446]         72 03 11 04 00 00 00 0c 00 0a 80 00 00 00 00 00
Jun 19 08:51:39 atlas kernel: [ 1324.948463]         00 03 fa 3f
Jun 19 08:51:39 atlas kernel: [ 1324.948470] sd 3:0:1:0: [sdb] Add. Sense: Unrecovered read error – auto reallocate failed
Jun 19 08:51:39 atlas kernel: [ 1324.948519] ata4: EH complete
Jun 19 08:51:39 atlas kernel: [ 1324.950250] sd 3:0:1:0: [sdb] 156250000 512-byte hardware sectors: (80.0 GB/74.5 GiB)
Jun 19 08:51:39 atlas kernel: [ 1324.950919] sd 3:0:1:0: [sdb] Write Protect is off
Jun 19 08:51:39 atlas kernel: [ 1324.954928] sd 3:0:1:0: [sdb] Write cache: enabled, read cache: enabled, doesn’t support DPO or FUA

After getting a new disk and the machine back operable, I’ve now plugged it in and trying to recover it.  Mounting fails, as it seems there are read errors in the journal itself:

Jun 19 08:35:39 atlas kernel: [  364.686504] EXT3-fs: INFO: recovery required on readonly filesystem.
Jun 19 08:35:39 atlas kernel: [  364.686508] EXT3-fs: write access will be enabled during recovery.
<errors like above>
Jun 19 08:36:08 atlas kernel: [  393.492868] JBD: recovery failed

It seems somewhat logical that it might be common to have physical failures in the area of the disk where the journal lives.  In my case, it seems the unreadable part(s) of the disk are all within the journal.  I ran debugfs on the volume to find that I could read all sorts of things on the disk — so I just needed to tell it to skip reading the journal and mount the disk anyway.

  1. Before you remove the journal, you need to remove the needs_recovery flag from the volume.  You’d think this is possible with tune2fs, but it doesn’t seem so.  So you do it with debugfs:

    debugfs -w -R “feature ^needs_recovery” /dev/sdb1

  2. Then remove the journal, forcibly:

    tune2fs -f -O ^has_journal /dev/sdb1

  3. Now, go ahead and mount your volume as ext2:

    mount -t ext2 -o ro /dev/sdb /mnt/disk

Voila!  You’ve now nuked your journal, and marked your volume ready for mounting.  It’s possible that it has inconsistencies and needs a fsck, but I mounted anyway and was able to recover everything without failure.

I learned this trick from an Ubuntu forums post at http://ubuntuforums.org/archive/index.php/t-953279.html

Posted in Uncategorized | Tagged | 1 Comment

Gnome terminal 2.26 annoyingly protects running child processes?

Has anyone else been as annoyed as I am about this dialog?  Every time I close a terminal which has a running child process, rather than the terminal closing and the child process(es) getting killed, gnome-terminal tries to protect:

Dialog: Close this window?

I’m not unlike any other user: I don’t like unnecessary dialogs.

However as I’ve discovered, there is a fix!  Open up gconf-editor (Configuration Editor, not that you can find it on many menu systems these days) and browse to /apps/gnome-terminal/global and uncheck the confirm_window_close key.

GNOME Configuration Editor: /apps/gnome-terminal/global

Now you may return to killing your numerous terminals the way you’ve always enjoyed.

Posted in Uncategorized | Tagged , | 3 Comments

Firefox Three, Guinness World Records, and bananas.

So I guess bananas has nothing to do with it, although all you monkeys will be jealous to know I had one with my dinner, and it was tasty.

However the real fruit of the day is (you guessed it) Firefox Three.  I’m pretty happy to see this release; I’ve used the betas on and off for a while and been impressed how far it’s come.  It’ll still struggle to compete with the simplicity of Epiphany, but that’s just because I’m human.

It should also be noted that the Spread Firefox group has coordinated a campaign to start a new Guinness World Record for “the most software downloaded in 24 hours.”  So far since they opened the download floodgates about 18:16 UTC, and in the past ~ten hours or so, the Spread Firefox Download Day page is reporting over three million downloads, although I’m willing to bet that this is thus far an unofficial number.

There’s been a lot of commentary on the bad choice of starting time, the lack of advertising, some issues with the map not showing all the countries accurately but please spare us.  This is supposed to be a fun thing, so have fun with it!  Three million downloads thus far implies that the masses are quite happy.  You can’t seriously expect the organizers of this to make everyone just oh-so-peachy, so just roll with it!  Go download Firefox Three and enjoy!

Well done to everyone working with Mozilla!

Posted in Uncategorized | Tagged , | 1 Comment

Evolution Crash Detection

I’ve recently made the jump to the latest ‘n greatest desktop, GNOME 2.22. Altogether I’m quite happy with the software. Not so happy with all the Gentoo bugs. But that’s another story.

One of my favorite bugs is the crashes that Xorg keeps causing, which has made my computing experience similarly enjoyable to Windows 95 where the computer is no longer logical, and likes to crash in a multitude of ways with no warning.

However onto the subject: Evolution’s new crash detection feature. I won’t debate the merit of this feature. Just the dialog box that I had to squint at over morning tea for a whole minute before I understood what the hell it’s prompting me for:

evolution crash detection

I get what this feature exists for. They’re worried that certain types of emails are crashing Evolution upon viewing, so we have a feature to disable the preview pane in the rare case that this is the issue. I suppose. I’ve personally never once had this issue. But what the hell. I’ll play along.

I’m annoyed by this dialog. When my software makes me think, it makes me unhappy. I don’t like to think:

  • I don’t use the preview pane. Why am I seeing this dialog? There’s nothing to disable!
  • “…appears to have exited unexpectedly…” — how the hell else would Evolution’s data files be in a state indicating crash? Be assertive in your dialog messages, as your users appreciate it! This should read “Evolution exited unexpectedly the last time it was run.”
  • The text seems to indicate that “all preview panes will be hidden.” This tells me that the software will do what it says. But what options am I given? An Ignore and a Recover option. At this point in reading the dialog, I wasn’t expecting to be asked a question. I can make some assumptions about what these buttons do…but…what? I had to ponder about what button to push for a whole (admittedly sleepy) minute.

Bug 530345 filed. Hopefully not too grumpy in my bug report, I really do want this to get fixed. But it made me think so early in the morning so I’m allowed to be grumpy, right?

Posted in Uncategorized | Tagged , , | 1 Comment

Cycling in Buckinghamshire, UK

So I got out on Sunday this weekend as well, and rode from High Wycombe to Aylesbury.  It was a good ride!  Proper English weather (rained like piss all day.)

Took a few pictures as well.

Quite nice that most of the National Rail lines here don’t care at all if you bring a bike aboard.  It makes it so easy to get out of London and enjoy!

Posted in Uncategorized | Tagged , , | 1 Comment

Hike in Surrey, UK

This past Saturday we went on a bit of a hike around Surrey.  It was quite fun!  We had a small crew from work and a few friends from outside work.  Hop on a train from Victoria station to Holmwood, Dorking and walk to Gomshall, Surrey, and train back from there.  ’twas a mighty good time.  I’ve drawn a quick map of the area (apologies, but I’ve become completely obsessed with drawing maps of where I’ve been!)

Check out a few photos, if ya like.

This hike is out of an excellent book, Time Out Country Walks near London, which I strongly recommend for anyone living in or around London!

Posted in Uncategorized | Tagged , | Comments Off on Hike in Surrey, UK

Cycling in London: Not for the faint of heart!

Fortunately for me I’m completely nuts!

So I’ve been in London (yes the actual City of London) for the past week and a half for work, and part of my adventure was to bring my bicycle with in order to try to ride around London and not get run over by any buses. The weather finally held (and I got my courage up) so I went for a ride. Needless to say, I didn’t die (else this bit of writing would be quite magical, no?)

It’s a bit different riding here. Shit, I’d take downtown Chicago at rush hour any day for a leisurely ride compared to here! Here I am, riding on the opposite sided of the road (which means that right turns are the difficult ones, not left turns!), none of the roads run in a straight line and always seem to be taking me away from the direction I’d like to be going, the roads are narrow and all under some sort of construction, the cabs are equally as crazy as Chicago cabs, and oh yeah — the cyclists here are completely insane as well…it makes for one heck of a ride!

However most importantly, I didn’t get eaten by a big red London bus.  Hooray!

I took a few pictures off Blackfriar’s bridge before the sun went down. Mostly just to prove that I was here. Hopefully I’ll be able to get out more now that the weather isn’t total crap.

Cycling in London == scary. However I did find some interesting resources on TFL for cyclists, and I’ve sent off for some maps. We’ll see how good they are!

If you’re a driver in London and were out today, thank you for not hitting me :)

Posted in Uncategorized | Tagged , , | 5 Comments

Hey Chicago! Voice your opinion for the Ordinance for Bicycle Safety 2008!

I was just recently made aware that the CBF has been working hard at an amendment for some city ordinances on cycling which will help define some legal lines that drivers & cyclists can count on.  I think it’s quite reasonable from a purely safety perspective; I do not view this as a way for cyclists to get back at drivers or anything sly, but as a way to help guarantee everyone’s safety by outlining reasonable bits of understanding for cyclists and drivers.  If this is passed, this will be a good way to inform drivers of reasonable expectations so they can be better educated on how to interact with cyclists on the road.  This is a win for both drivers and cyclists in my book!  This amendment if passed, will mandate (snipped from CBF email verbatim):

  • Requiring a minimum of three feet of clearance while passing bicyclists
  • Prohibiting a motorist from opening a door into moving traffic, reducing the danger of “dooring”
  • Raising the fines for vehicles parked in bike lanes or marked shared lanes
  • Requiring motorists to yield to oncoming bicyclists when turning left, which prevents a “left hook” crash
  • Prohibiting motorists from turning right in front of a bicyclist, which prevents a “right hook” crash
  • Requiring motorists to exercise due care for bicyclists in addition to pedestrians

It also outlines some fines for doing bad things as outlined here, but I think that’s just to motivate drivers and I’m not concerned with the money values.  This amendment will help with some of the usual concerns that both myself and several others I’ve ridden with have had in Chicago; it can be quite worrysome cycling in the city and this is a good thing!

So, if you’re living in the city, please voice your two cents to your alderman!  From my understanding, not all of them sit on the Traffic Control & Safety Committee who votes on this, but it’s still good to voice your opinion.  The next meeting of the committee is quite soon – Wednesday March 5th at 9 AM.  If you support this amendment, please make yourself heard to make cycling in the city a safer place!

Feel free to check out a copy of the email going around about this.

The actual legislation is online as well.

Posted in Uncategorized | Tagged , | 1 Comment