Kiva Numbers

April 9th, 2009

Just received the regular email newsletter from Kiva, and saw they have included some interesting stats.

In 42 months, 472765 users have provided $66,854,835 in loan capital.

Two things struck me as pretty cool. Firstly, nearly $67 million in about three and a half years is pretty amazing.

But even better than that is that it was raised by less than half a million people – probably even less than that as they only specified Kiva users, not actually lenders. So your average Kiva user has put up about $40/year. Not really a lot to make a huge difference is it? I used to easily spend that on Starbucks on any given week.

So I’m left thinking two things. Firstly, it’s about time I put up another $25 for a loan. Secondly, I’d like to challenge you to chip in $25. Remember, this isn’t even a donation. It’s a loan that gets paid back, so there’s a very very good chance you’ll still get to spend that $25 on whatever the hell you want. Or you can recycle it and lend it to someone else.

What else did you have in mind to make the world a better place today?

Why can’t I share an automounted directory using NFS in Solaris 10?

April 3rd, 2009

Don’t worry, it’s not a trick question. I honestly don’t know just yet. If I did, I’d be writing a post called “How to share an automounted directory using NFS in Solaris 10″. I dream that one day soon I can do that.

In the meantime, I’m writing up the scenario that doesn’t work in the hope that it a) provides me with a blinding flash of insight, b) lets other people know it’s not just them or c) prompts someone who knows the answer to drop it in the comments. Come on, you know you want to!

The General Idea

I’ve got a machine running Solaris 10 10/08 with several user accounts. Home directories for these accounts are in /export/home/. They are being automounted in /home. I want to share the /home/username directories using  NFS. Should be simple right?

The Setup

/etc/auto_master:

/home   auto_home   -nobrowse

/etc/auto_home:

fred box1:/export/home/fred

/etc/dfs/dfstab:

share -F nfs /home/fred

After confirming that NFS is running and online (svcs -a | grep nfs), we activate the shares:

# shareall
share_nfs: /home/fred: Operation not applicable

Sharing /export/home/fred works just fine.

The official Sun docs suggest that the “Operation not applicable” error means I should contact my vendor for an upgrade. Right. I’m fairly sure this was working in Solaris 8, but need to double check.

XScreenSaver in Solaris 10

March 26th, 2009

It seems to be that XScreenSaver won’t load for regular users in Solaris 10 (update 6, 10/08) using JDS.

This means that a regular user can’t lock their workstation screen or have the screensaver come on. Typically, an error message along the lines of “XScreenSaver failed to load” pops up when the user logs in.

Pretty annoying all round.
Happily, it’s an easy fix. Edit your .profile and add /usr/openwin/bin to your $PATH variable.

Log out. When you log back in, you should see a “Lock Screen” option on your menu and screensavers should kick in.

What’s the hardest part of waking up before sunrise?

March 23rd, 2009

It’s hardly a secret that I have never been what you’d call a morning person. I always believed that it was genetic, a characteristic to be struggled with and accepted.

Sure, large doses of caffeine and large motivational factors (gotta catch a 6am flight!) could provide a short term burst of early morning activity, but it was begrudged and ever so fleeting.

My current work has posed an interesting challege in the early morning situation. I have to leave my place before 7am every morning. Ouch. To put that in context, 7am has always been my “first alarm” time. It’d be fair to expect another 30-45 minutes of alarm-snooze cycle on top of that. So this has been a struggle, compounded by the lack of drinkable coffee accessable from work – my usual crutch throughout the day. I’ve been struggling, but suddenly, I’m finding it not so bad.

I’m seeing the sunrise through eyes that arn’t bleary or cranky at the world for daring to demand my attention this early.

I’d never have thought it possible, but there it is. So then, how!?!

Incredibly (to me at least), it’s quite simple.

Firstly, lose the crutch. Quit caffeine. I’ve written about it previously. While my motivation wasn’t to make getting up easier (I actually expected it to make my mornings harder and more miserable, permenantly), that’s probably been the best outcome so far.  I can wake up, get up and not be in that foggy, caffeine craving but deprived state. That’s actually a pretty cool feeling. Not having the fog seems much better than being chemically extracted from it. Who knew.

As a side note, I still drink coffee. I guess you’d now call me a social coffee consumer. Usually 1 – 3 cups per week, as opposed to before lunch on any given day.

The second change has been a fair bit harder for me. Maybe not for everyone, but definitely for me.

Go to bed early enough to get the right amount of sleep for you.

I have no idea what that means for you, but for me it means getting in to bed by 10:30 to wake up a bit before 6. For someone who could count on one hand the number of pre-midnight bedtimes in the last 8 or 9 years, it took some getting used to. Cutting out the caffeine certainly helped because instead of feeling a bit tired and instinctively having an espresso so I could stay up a bit longer and do something (work, play or otherwise), I’d go to bed. Being tired actually meant getting ready for bed. There were a few other things to get used to though.

I had to make my bedtime independant. If it’s my bedtime, I go to bed. That means wrapping up whatever I am working on earlier.  Sometimes going to sleep while Ellen’s still up with lights on. Sending visitors home earlier than I used to. Whatever. The thing that isn’t going to change is the time I have to get up in the morning. So if I want to feel good in the moming, I have to actively make the call to go to sleep.

It’s been a challenge, but I think it’s worth it.

iPod Shuffle Unboxing

March 18th, 2009

So after a little bit of stuffing around with missed deliveries, I finally have my new iPod Shuffle. Happy days!

I ordered it last Wednesday morning. I think it was the size of it, and wanting to buy something so that Mactalk got a cut that won me over so quickly. This seemed like the perfect opportunity.

iPod Shuffle TNT Package ready to open

iPod Shuffle TNT Package ready to open

Obviously it came well packaged…

iPod Shuffle in box

iPod Shuffle in box

The only difference to the standard retail packaging was a bit of white plastic wrapped around the outside of the plastic box.

You could pretty  much buy these in vending machines now...

You could pretty much buy these in vending machines now...

iPod Shuffle in packaging, ready to crack open :-)

iPod Shuffle in packaging, ready to crack open :-)

Headphone plug and 3 way switch

Headphone plug and 3 way switch

iPod Shuffle from the back.

iPod Shuffle from the back.

ipod-shuffle-unboxing-small-7

I got mine laser engraved. Figured if I was buying online, I may as well take advantage of the free engraving service. I won’t be getting a case for it (really not that much to protect!), so the engraving will be pretty much the only unique identifier on it. I suspect lots of people will end up with these, so easier to have it personalised. The engraving is top quality too. There is about 1cm of horizontal space to engrave on, and they’ve fitted 12 perfectly legible characters on one line. Apple really have a good machine for doing this!

iPod Shuffle sync cable

iPod Shuffle sync cable

The USB sync cable is perfectly compact, just like the shuffle. I plug it into the back of my desktop keyboard and – kind of obviously – it seems made for it. It’s about 7-8cm long, so it won’t be a hassle to pack if you want to use your shuffle as removable storage.

It really is tiny.

It really is tiny.

I’ll reiterate what pretty much everyone is saying. This iPod is TINY. A miniturised Nano. About the size of a recent model USB drive, the build quality is amazing for something this small. It’s machined. Refined. Engineered. Metallic. It’s got that all metal feel that I love about my MacBook Pro. It’s all class.

The whole kit.

The whole kit.

All of the playback controls are on the headphones. The controls work well, the voiceover thing is pretty cool. Much better than I’d expected based on the promo video on the Apple site. The sound quality is decent enough for what I plan on using this for (commuting & exercise). When I want big sound, I’ll plug my big headphones into the laptop. So, I’m happy. It’ll be interesting to see if a remote cable accessory is on the market soon to allow people who do what to use their own headphones to do so if they wish.

All in all, I’m really happy with it. I wouldn’t want it as my only iPod, but for having on hand for when you just want to listen to something and don’t hugely care what, it is perfect. Well done Apple!

Caffeine Sensitivity

March 4th, 2009

I broke my caffeine free streak a couple of days earlier than I expected. I had a day off and figured, what the hell.

In total I had 3 coffees for a total of 5 shots throughout the day. The last double shot latte was courtesy of Sam atYala, and it was awesome as always. What was different though, was my reaction to the caffeine.

My last coffee was at around 4pm. By 5pm I had a headache building up – I figured food would help and it did a little. Berocca & Ibuprofen eventually dealt with it later in the night.

Only problem was, I could not sleep. Went to bed before 11 knowing I was waking up a bit before 6am. And then I just lay in bed wide awake. Midnight, 1am, 2am came and went. Got up, had a glass of water. Pretended something interesting was happening on the Internet. Went back to bed. Still awake. I eventually drifted off around 3.30 to be woken up  2 1/2 hours later by my alarms going off. Ouch.

So, it seems like going cold turkey for 2 weeks was enough to reset my caffeine sensitivity back to more normal levels – sort of. I didn’t get the immediate kick that I was used to, but damn, my brain just wouldn’t turn off.Used to be that a double shot espresso would provide a nice little buzz, but I could have one at 10pm and head to bed 2 hours later and sleep more or less just fine.

The end result is now that I’m feeling a bit wary of having much coffee/caffeine at all. Maybe it’ll be down to 1 or more often none per day.

Turns out I’m fully functional without it, and honestly, I’m happier that way.

Handling line endings in Ruby on Rails

February 24th, 2009

I’ve been working on a Rails app that automatically builds shell scripts. It pulls a bunch of prewritten code out of an SQLite database and writes it out in order to a text file.

Only problem is there are some rouge line ending sneeking to the database. I’m developing on Solaris 10 where the default line ending is a line feed character (LF, 0x0A). For reasons I don’t understand, Rails and/or SQLite is using an LF CR combination on all of the code that was entered through a text field and saved to the database. When it gets spat back out into the shell script text file and I try to execute it, Korn chokes. Korn expects LF line endings in text files and that’s all there is to it.

After poking around to uncover where the line ending might be being set, I decided it’d be easier to tweak the three places in the Ruby script where code was being outputted to the text file and modify the line ending there.

finalscript << assertion.snippet.code.delete("\x0D") << "\n"

Essentially we’re deleting all of the CR characters from the chunk of code, leaving just the LF which keeps Korn happy.

I’m not totally happy with it as a solution, but it works, it was fast and cheap and solves something that probably doesn’t affect too many people.


				

Seven days without caffeine

February 24th, 2009

Seven days in to my caffeine free period of life (yes, it’s a period, not permenant) and I think I’ve gotten past most of the feeling like rubbish stages. At the very least, I’ve been able to function at work without feeling like the living dead, and actually written some decent code and solved some problems. All without caffeine. Amazing!
Some observations, in no particular order:

Detoxing is sneaky

When you’re used to operating with a lot of caffeine in your system, you know when it’s time for a top up. Hrm, feeling snoozy. Coffee. Fuzzy, coffee. Needing a moment of clarity, RedBull. When you’re getting used to not having that, the downward slides can be sneakier. I’ve been careful about getting plenty of sleep, but the effects are outworking in other ways. I’ll feel grumpier. Or unsettled. Headachy. Whatever it the problem, they sneak up on me, starting out fairly mild going from there. It just makes everything harder. I’ve found there to be three go to options (as opposed to one previously, have a coffee…).

  1. Go to bed. Obviously I can’t do this at 11am, but a lot of the time it’s happened after 8pm, so just getting ready for bed has definitely helped. The extra sleep certainly helps.
  2. Berocca.  This stuff is awesome. It’s a big cup of fizzy-make-better without the inevitable sugar/caffeine crash. Not sure what an excessive dose would be. I’m doing 1-2 per day.
  3. Walking & exercise. Moving around seems to help feel less crap. I’m sure if you looked you’d find someone authoritative saying that exercising releases endorphins. I’m sure it does. For me, lifting heavy things or going for a walk to the shops puts me in a better mood, and if I was feeling tired before, I’ll still be tired, but satisfyingly tired. I lifted heavy stuff. I deserve sleep.

Coffee isn’t just a drink. It’s a social object.

Chemical stimulation aside, I’ve missed the social aspect of coffee. It’s not just something I drink. Coffee is something I do. With other people. I’ve found I’ve skipped oppportunities where I would have gone out for coffee with folks, instead opting to stay in. Bummer. Sure, there are other drinks which would substitute. But at the moment, coffee is still a major social motivator for me.

As an aside, I really miss Starbucks in this town. For me, they had the social factors figured out. Can’t think of anywhere else around here that fills that gap.

    On the whole I’m really quite happy with how it’s all going. In a couple of weeks I plan to have coffee again, but only for social purposes, not as a productivity crutch.

    Bugger

    February 21st, 2009
     /></a></p>
<p><span style=Bugger, originally uploaded by geoffconet.

    Saw this unfold at the Carillion as we were sitting on the other side of the lake.

    There was nothing I could do except take some pics, and definitely nothing they could have done. By the time they got to the bike, it would have caused more injury than anything to try and stop it.

    Not much you can do except laugh about it. And hope they hose themselves down – the lake has been closed for the past 2 weeks due to blue-green algae infection… Yikes.

    Living in a world without caffeine

    February 20th, 2009

    This week, for the third time in my life, I’ve quit caffeine. For plenty of people, this wouldn’t be a big deal. For me, it is. And it’s that very fact that it is a big deal which is prompting me to quit.

    Read the rest of this entry »