OS X Cron Coolness

I just found out today that my webhosting provider, Dreamhost, is now officially adding 50GB of storage to each hosting account to be used as offsite backup for free (well, technically included with the cost of hosting)!

I figured that was a sign that I should get off my butt and setup a cron job that would tar/gz files on my home server (where the important stuff resides) and send it over to my Dreamhost acct on a monthly basis.

Cruising through the OS X cron man page, I saw this little gem:

Instead of the first five fields, one of eight special strings may appear:

           string          meaning
           ------          -------------------------
           @reboot         Run once, at startup.
           @yearly         Run once a year, "0 0 1 1 *".
           @annually       (same as @yearly)
           @monthly        Run once a month, "0 0 1 * *".
           @weekly         Run once a week, "0 0 * * 0".
           @daily          Run once a day, "0 0 * * *".
           @midnight       (same as @daily)
           @hourly         Run once an hour, "0 * * * *".

So my cron command ends up looking (mostly) like the following:

@monthly $HOME/scripts/createbackup.sh

How easy is that? I know that most modern linux distros have /etc/cron.monthly, /etc/cron.daily, etc…but the OS X way just seemed really nice.

Anyone know if this exact same shorthand is available on other systems?

Testdrive: OpenSolaris on OS X with VirtualBox

I finally got around to installing VirtualBox (read more about it here and here) on my Mac earlier this week.  Last night I installed the OpenSolaris (2008.5) disc that I picked up at the Sun booth at OSCON last week.

So far, everything has been going swimmingly.  I could walk you through the installation, but this dude at MacWorld did a much better job than I could.

The only trouble I’ve had thus far was learning some Solaris-specific commands (pkgadd, btw) to install the “VirtualBox Additions”.  The VirtualBox Additions are a small selections of add-ons that you install within the guest OS to ease integration with the host OS (mouse control, shared folders, etc).  While I’m not familiar with Parallels, I can say that VMWare (Workstation/Player) has a very similar guest additions installation procedure.

I’ve been using VirtualBox on my Vista desktop for a few months to virtualize a Xubuntu server (sshd, apache, mysqld, etc) with great success.  Typically, the VM is utilizing less memory than iTunes, which I find utterly ridiculous.  I decided to give it a spin on my MacBook Pro because the latest update of VirtualBox has brought the Intel Mac version out of beta.

While I don’t think that VMWare has much to fear from VirtualBox in the enterprise arena, for the average developer/desktop user, VirtualBox should suit you well.  I’ll be interested to see if Parallels and VMWare will be able to continue charging $80 for their consumer versions with such a capable free competitor (backed by Sun, no less) available.

OpenSolaris Impressions

Playing with OpenSolaris has generally gone well.  It helps that the UI is Gnome and the default shell is BASH, two things that most Linux folks should be comfortable with.  Cruising around the filesystem answered one of my main questions, which was that JDK6 (not OpenJDK, mind you) is installed by default.  I still haven’t figuresd out what mechanism, if any, OpenSolaris uses for automatic updates.  If anyone has some good “OpenSolaris for a Linux Guy” articles…please pass them my way.

OpenSolaris guest running on OS X host.

OpenSolaris guest running on OS X host.

OSCON 2008 – Day 3

I’ll spare the reader the session-by-session account ala yesterday’s post, but will lean more toward the general theme that seems to have run through the majority of the session’s I’ve attended the last three days.

There seems to be a huge buzz around all things cloud and mobile.  I won’t be as bold to say that the desktop is dead, but it sure doesn’t seem nearly as sexy as it once was.  It kinda feels like back in the late 90′s when everybody said that the internet would kill newspapers…but then it didn’t happen….but now fast-forward 10 years and that truly is the case.  It has become apparent to me that the days of a desktop being most user’s primary computing device are numbered.

It appears that as we get closer to network ubiquity, devices like the iPhone and EEE PC start to make a ton of sense.  It’s not that far-fetched that for a good segment of users, that a netbook will become their primary computing device.  With a flood of new devices now coming online, someone is going to have to deal with the issue of managable scaling…thus the cloud computing push.

There was a large contigent of cloud computing vendors/providers pushing their wares.  I had some interesting discussions with folks from the following services:

Personally, I’m going to try to spend some time with RightScale/AWS.  Currently Google App Engine only supports python (perl stuff in the works possibly?) and Engine Yard is Ruby/Rails focused.  RightScale+AWS lets me do whatever I want because they’re just running a XEN virtual machine image.

I have to wonder if folks care anymore about Microsoft’s dominance on the desktop.  It feels like most people have moved on.  Microsoft has virtually no presence in the MID and Netbook (yes, I know that the EEE PC can have XP installed on it) segment.  It feels like the mobile phone segment is about the same.  Please do not try to make an argument that WindowsMobile is in any way a serviceable mobile/phone OS.  With a billion mobiles being sold a year, that’s a damn big market that Microsoft doesn’t dominate.

One more thing…

I would be remiss to not mention another topic that has kept popping up throughout the week.  That is Open Data ( or Data Portability).  So far, it’s not been a straightforward process to share all this data that users are creating by Digg’ing, Flickr’ing, etc, etc.  RSS feeds can only get us so far.  The Open Web Foundation was announced today to help move down that path.  Some other items that have been discussed in a similar vein have been: OpenID and OAuth.

OSCON 2008 – Day 2

Morning Keynotes

Two of the presenters (Tim O’Reilly and some dude from Intel) talked alot about Linux on mobile devices and cloud computing.  A couple of terms that I think we’ll be hearing more soon are: MID’s = Mobile Internet Devices (think iPod Touch) and Netbooks = small-ish laptops like the Asus EEE PC.


Pretty much just talked about the timeline of pushing for an opensource version of Java and how it all started back with GNU Classpath and gjc.  The OpenJDK is still currently running a bit behind Sun’s commercial releases, but hopefully they can catch-up around Java 7.

One nice effect of OpenJDK is now Java is started to be included by default on many Linux distro’s (Debian, Fedora, etc).

Leveraging XMPP for Cloud Computing
Wish I could tell you more, but the talk was at capacity and they wouldn’t let anyone else in.  Reminded me of Thursday nights at Harpo’s in Columbia, MO during college and their “1 in, 1 out” policy.

Groovy -vs- JRuby…which one should you use?
I basically took away from the talk that it’s pretty much a wash as far as features go.  Groovy is going to be a bit easier for normal Java dudes.  Supposedly Sun has put a lot of nice features in Netbeans for JRuby support…so I might have to give it a spin.

There was a lot to like about this talk…especially since my group at work is heavily invested in JavaFX.  I’ll list out some of the new goodness in bullet form:

  • Java 6 update 10 is due out late summer, is a consumer-focused release focusing on improving the Java user-experience
  • Applets will now run out-of-process.  This means a couple of things: A hung applet will not crash the browser and now you can have “draggable” applets that you can pull onto the desktop.
  • Applets will now share a lot of the same features as Java WebStart apps.
  • crossdomain.xml files will be available to allow for “mashups”
  • Hardware graphics acceleration is now on by default.
  • Moving toward a more modular JRE (Java Kernel)
  • Working on video support.  Java will just wrap whatever video codecs are present on the local system.  Sun is also working on a native Java video codec.
  • Check out more about 6u10 here.

New JavaFX Stuff:

  • JavaFX Script meant to resemble Javascript (more comfortable for web designers)…but you can still call normal Java code.
  • New “javadocs” format for JavaFX
  • Netbeans plugin for JavaFX – syntax highlighting, code completion, preview
  • Photoshop and Illustrator plugins that can export to “FXD” files.  Also a tool that will convert SVG’s to FXD’s

XMPP for Cloud Services
Yet another cloud computing session that was completely jam-packed.  People seem to be bonkers about anything and everything “cloud”.

Talked mostly about how the REST polling method used in most web2.0 apps today scales horribly.  Using a PubSub methodolgy scales much better.  XMPP is built from the ground up for this type of scenario.  I’m still trying to figure out how in the Java world this would be better than just using a JMS provider like ActiveMQ.  Sounds like this might be problem that is being solved by these guys.


Unbeknownst to me, I sat down for lunch at a table with Steve Souders.  He literally wrote the book on high performance web sites and is the creator of the YSlow! plugin for Firefox/Firebug.  He was an unbelievably nice guy and we had a good conversation about all things web, Yahoo! and Google (his current employer).

OSCON 2008 – Day 1

Technically, it’s day 2…but it’s day 1-ish for me.

I got into Portland around 2PM local time.  Checked-in to the hotel, then ran over to the convention center to check-in for the conference.  Probably the worst conference bag I’ve ever got.  That said, I think I have 5 computer backpacks lying around by now…so I’m definitely on overload.  Tech conferences need to move on to something else.

Not being familiar with the area and having not eaten in about 10 hrs, I went the path of least resistance and stopped by the mexican restuarant in the hotel (come to find out later it’s named “Eduardo’s Cantina”…if I’d known that, I probably would have just moved along).  I ended up chatting for a good long while with Josh Marinacci from the JavaFX team at Sun…which was cool because we’ve been working with JavaFX for well over a year now at work (I don’t think many people can say that…and even less could say they have an app in production using JavaFX).

Later in the night, they had an “Extravaganza” back over at the convention center.  There where 3 main parts (that I stayed for):

Mark Shuttleworth: Founder of the Ubuntu project, as well as the commercial company supporting Ubuntu, Canonical.

He spoke about the economics of open source, software development methodologies (specifically Agile/Scrum/XP) and building software that encourages others to extend.  I’m sure my synopsis doesn’t do it justice, but overall a good talk.

Next, O’Reilly/Google gave out some Open Source awards.  I’m sure you can check out their site for the low-down

Finally (for me), Robert Lefkowitz gave a talk about software development methodologies.  The theme of Agile/XP came up yet again.  It definitely feels like (at least from attending conventions) that we’re at a tipping point on Agile methodoligy acceptance.  One thought I hadn’t had until tonite is that this is closely tied to the rise of open source.  In most open source projects, there aren’t a lot of requirements made up front..people either use (and by extension, like) what you’ve built, or they don’t and go elsewhere.  If they do like your product, instead of creating “requirements” for new features, they just submit bug reports…which get triaged appropriately.  Sounds pretty efficient.

Simplicity in Software

Saw this pretty sweet tweet come across my FriendFeed tonite:

Simplicity is hard to build, easy to use, and hard to charge for. Complexity is easy to build, hard to use, and easy to charge for.

Original “tweet” can be found here.

Groovy FriendFeed API

I’m starting to get my feet wet with Groovy these days, so I decided a small project would expedite the learning process.  The past few weeks, I’ve become more enamored with FriendFeed…so I decided a Groovy wrapper around their RESTful Webservice API would be a pretty good choice.

I’m hosting the work up on Google Code currently.  Any feedback (especially from Groovy veterans) is appreciated!

Groovy FriendFeed API

Sun open-sourcing Java: The Slashdot reaction.

I sit here in utter disbelief.  Having just finished reading an article about Java on Slashdot, I’ve noticed that the comments regarding it are overwhelmingly positive.  Yes, Java…on Slashdot…and it’s being viewed in a positive light.

For my entire geek life reading Slashdot, I can’t think of a single time that the notoriously cantankerous crowd of commenters there has ever been remotely positive about Java.  Clearly (using my small sample set), Sun has struck a cord with the hardest of hard-core open source zealots by making this push to truely free Java.

Kudos Sun.

Essential Apps for a new Mac

It has become abundantly clear to me over the past year (while attending CSS and NFJS) that to have any hope of being taken seriously as a software developer, a Mac must be purchased.  With OSCON 2008 rapidly closing in, a decision had to be made. So….

A shiny new MacBook Pro landed on the doorstep of Breo Media Labs HQ on Friday, so I decided to reach out to the geek community at large for their recommendations for must have Mac apps. Many thanks to Alex and Scott for sending me links to their previously blogged lists.

A little over 24hrs into owning a new Mac, here’s the list:

  • Firefox
  • Quicksilver – I know there’s more to this thing, but at the least it’s a super quick way for me to start apps without having to take my hands off of the keyboard.
  • Adium – Multi-protocol IM client.  I thought I would give Digsby a spin to kill 2 birds with 1 app (IM + Twitter)..but alas their Mac version is not ready yet.
  • Thwirl – An Adobe AIR Twitter client
  • NetNewsWire – RSS Reader.  I’ve been using Google Reader for a little over a year, but have been underwhelmed in it’s ability to manage my bazillion feeds.  While my preference is for a more “cloud-centric” reader, NetNewsWire seems to be cool enough that I’ll stick with a thick client based reader for now.  It will sync with newsgator online, but I’m holding out for the (remote) possibility of it syncing with Google Reader.
  • Growl – Alerts and such.  Seems to be leveraged heavily by Adium.  A nice side effect thus far is that I’ve setup my IM+Twitter apps in a different space (Space 2).  Because of the growl integration with Adium, I get IM responses as alerts on my currently active space…thus saving time flipping back’n'forth between spaces.  A small, but nice, touch.
  • iTerm -  All the super-geek presenters at the aforementioned conferences use it, so it must be good?
  • iStatPro – Dashboard widget that displays all sorts of system resources (CPU/Disk/Memory/etc)
  • Transmission – Bittorrent Client
  • Cyberduck – FTP Client.  Using it because I’m cheap and it’s free.  I’ve heard good things about Transmit though…
  • Textmate $$ – Text editing.

UPDATE (6/23/2008):

Clearly…this is not an exhausitive list, but just a list of apps that someone new to the Mac platform will install right off the bat to make their environment feel more like home.  Got some good feedback in the comments, so some additional apps would be:


  • VLC – Probably the best media player out there…for any platform.  I wish all pre-1.0 software was as useful and stable as VLC.  Java developers should take a look at DJNativeSwing for integrating VLC into a client app.  We use it at work and have had great success.
  • Miro – While not strictly Mac software, if you want to get your IPTV on, it’s pretty cool.  Combine it with tvrss.net for TiVo-like functionality.
  • MediaLink/Connect360 ($) – If you have an PS3 or Xbox360 and want to push your media to it, both of these programs will make that a breeze.


Seems like I’m hearing pros/cons pretty evenly between Parallels ($) and VMWare Fusion ($).  Having a windows desktop (and most of my life lives in “the cloud” now) leaves me with little need (currently) to have Windows app on my laptop.  I have had pretty good luck running Xubuntu within VirtualBox on my Vista machine, so I might also give that a spin on the Mac and see how it goes.


  • Neo Office / OpenOffice.org – Time was, you had to use Neo Office if you wanted a OS X native OpenOffice.org clone.  This appears to be coming to an end with the advent of OO.org 3.  For a lot of the basic things I do these days, Google Docs is serving me quite well…especially when I need to collaborate with someone on a spreadsheet/word doc.
  • SpanningSync ($) – Syncs iCal with Google Calendar.  The wife uses it on her MacBook at home and MBP at the office and loves it.  A friend mentioned that Sunbird from Mozilla is a great replacement for iCal and syncs with Google Calendar for free.

Syntax Highlighting Test Post

A post to test out syntax highlighting of Groovy and Java Code.

?View Code GROOVY
  class Hello {
      println "Hello Groovy Code!"
package com.breomedia.labs;
public class HelloWorld {
    public static void main(String args[]) {
        System.out.println("Hello World!");