disable HFS+ journaling on Leopard to use disks read/write with linux

Disk Utility in Leopard no longer allows you to disable journaling through the interface on a drive. The menu where it used to be only says "Enable Journaling" but it's grayed out (cause your drive is probably journaling already).

Political Rant (feel free to scroll on by)

So, someone at apple is making it harder and harder to run non-journaled hfs+ filesystems, even for external drives. Is this someone responsibly looking out for data integrity of their users, or deviously making it harder to use the disks crossplatform? Seems like removing this option is going to inconvenience more people than it helps. I hope this is an oversight that gets fixed at some point, cause HFS+ isn't that bad of a platform for moving data if you don't care about Windows clients. Ubuntu and Debian Linux now ship with HFS+ support by default - probably because of the rise of the iPod.

Apple should make non-journaled HFS+ disks the standard for moving data between Linux and Mac and help us get away from the horrible FAT32. How hard is it to leave in the option to disable journaling - or even to point out that linux computers can read non-journaled hfs+? The CD burning system advises you how to make windows friendly disks, and mail.app offers to send windows friendly attachments! Apparently the days of Apple being the most compatible platform - a platform that went out of its way to interoperate with what the other systems were doing to minimize pain for its small user base - is now over. Of maybe Apple is fine with interoperating with the ubiquitous, expensive and inconsistent windows world, but is pretty scared to invite the rapidly maturing and totally free Linux platform to the party? Unfortunately, too many steps down that road and microsoft's NTFS will solidify into the default crossplatform filesystem now that linux has read/write support for it. With all the patents on NTFS being held in Redmond, that's not good for anyone long-term.

Getting started

Anyway, here's how you disable journaling on a hfs+ filesystem by using the command line tool.

diskutil is the command line tool provided by Darwin (the mac's BSD core) that does what Disk Utility does through a graphical user interface. Fortunately, it can do everything that the graphical interface can do. Parenthetically, diskutil is still capable of making partitions smaller than 1GB (another casualty of Leopard's changes to the GUI Disk Utility) check out the partitionDisk command - it's not easy, but it works.

Ok, back to our subject!

Scouting it out

Type diskutil --help to see all the associated commands. Type man diskutil to really get more information about what it can do.

First: Lets assume that you are trying to turn off journaling on a 300GB disk called "Janice" that is connected to your machine via firewire. The first thing you should do is to read the listing of disks to find out where Janice is in the system's underlying mount points.


yourcomputer:~ youruser$ diskutil list

diskutil list
/dev/disk0
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     Apple_partition_scheme                        *74.6 Gi    disk0
   1:        Apple_partition_map                         31.5 Ki    disk0s1
   2:            Apple_Bootstrap                         40.0 Mi    disk0s2
   3:            Apple_UNIX_SVR2                         2.0 Gi     disk0s3
   4:            Apple_UNIX_SVR2                         33.0 Gi    disk0s4
   5:                  Apple_HFS MacHD                   39.4 Gi    disk0s6
/dev/disk1
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     Apple_partition_scheme                        *279.5 Gi   disk1
   1:        Apple_partition_map                         31.5 Ki    disk1s1
   2:             Apple_Driver43                         28.0 Ki    disk1s2
   3:             Apple_Driver43                         28.0 Ki    disk1s3
   4:           Apple_Driver_ATA                         28.0 Ki    disk1s4
   5:           Apple_Driver_ATA                         28.0 Ki    disk1s5
   6:             Apple_FWDriver                         256.0 Ki   disk1s6
   7:         Apple_Driver_IOKit                         256.0 Ki   disk1s7
   8:              Apple_Patches                         256.0 Ki   disk1s8
   9:                  Apple_HFS Janice                  279.4 Gi   disk1s10


Look for the name of your disk. The second set of lines there ends with a line that says "Janice". diskutil groups all of the logical divisions of a physical disk together in the list. Since our volume 'Janice' is listed under /dev/disk1, we can determine that /dev/disk1 is our 300 GB external firewire drive.

What is the rest of that garbage before the the Janice line? It's a series of small partitions that Apple uses to store various types of information about the disk. The very first one, disk1 itself, is a tiny area containing the map of all the other areas. Each subsequent partition has an added number s1, s2 etc appended to the disk name - disk1 in this case - to make a complete identifier for that partition on this mac system. You're going to need to note that Janice HFS partition where we want to disable journaling is disk1s10.

OK, we know what we have to target, let's do it.

Taking Action

If you read the man page for diskutil (type 'man diskutil' in your terminal) you might think that we could just type:

yourcomputer:~ youruser$ diskutil disableJournal /Volumes/Janice
An error occured journaling the filesystem: The underlying task reported failure on exit (-9972)

Hmm... what happened here.. dunno. Maybe despite me owning the disk, I need to apply a little more elbow grease by using elevated privileges. I'll use sudo.

yourcomputer:~ youruser$ sudo diskutil disableJournal /Volumes/Janice
Password:
An error occured journaling the filesystem: The underlying task reported failure on exit (-9972)

Darn it, Apple! Is this why you disabled the option in the GUI? Cause there are bugs in diskutil that you didn't bother to fix by October's Leopard ship date? Maybe I'm being cynical, but the error message sure isn't helping me at all.

Oh well... Google doesn't come to the rescue.

Reading the man page again..... what if I dismount the disk and use the [force] option that the manual page tells me can only be run on an unmounted disk?

Let's try. Unmount your drive -- "Eject" in the Leopard finder. Then form a slightly different command by inserting the term 'force' after the disableJournal command, and by replacing the mounted volume name with the partition identifyer that I had you get in the first section. Like so...

yourcomputer:~ youruser$ sudo diskutil disableJournal force /dev/disk1s10
Password:
Journaling has been disabled for volume Janice on disk1s10

Ah, that's better. I think I'll move all my media files onto this disk for editing on my inexpensive, user-friendly and powerful linux workstation. Sweet, thanks Apple!

UPDATE: A quicker solution is to hold down option when you click the menu in Disk Utility - this enables the disable journaling option. Thanks to the reader that informed me. Fortunately haven't had to struggle with either command line errors or gui obfuscation to disable journaling again as haven't booted MacOS in a while.

Video Evidence

We did it - over 100 miles for Haiti!

the crew

Last week I asked some of my friends and family to help me support the work of Haiti Reborn. I was going to ride 100 miles in two days on my bike to earn their support. It was a leap of faith in more than one way. But it's been rewarded. I survived and had a pretty serious experience of what can be done with individual belief and the support of a caring community. I want to thank you all.

It was tough!!!!!!! I'm still recovering, but here's the short version.

the map

I did over 100 miles. We started on the W&OD from DC to Purcellvile, MD. Paved, and up and down (mostly up). It was pretty damn hard to keep going. Andy had a tough fall, and lunch somehow didn't happen till 3:30 pm.

My muscles were definitely getting hammered by the climbs. I didn't finish the first day, and was picked up by the truck several miles short of the farm where we spent the night but I had done 51 miles before my legs gave out. The next day I saw what I skipped and I wouldn't have made it.

We had a wonderful night on a vegetable farm with some of the warmest folks and most spartan conditions of my adult life. I'll tell you about it later, promise.

Chicken hill tents

After a cold night in a tent, I was able to continue the next morning, not really sure why it worked out that way (seriously). After some hills and a cool ferry ride at White's ferry, we got on the the flat but rocky C&O canal towpath. Flat is good, rocky sucks, but at least lunch was on time. Did I mention it was flat? All told we pushed through at least 55 miles back, and it wasn't until the last hill coming from Rock Creek Park up into Mt. Pleasant that I started walking my bike. I'm pretty proud that I made it at all and I definitely need to give a shout out to those who helped me on the trail and those that motivated me with their good vibes and donations!

When we got back to DC, we rode up to La Casa in Mt. Pleasant. There was a nice potluck with folks from all over and were fussed over a bit. Nicole cooked and also took some great photos. I changed into my least sweaty gear. Fun was had by all.

Special thanks to the people in the support vehicles who sacrificed their weekend riding around and waiting for us!

Some other points:

* The bike finished with several fewer parts than when I started.
* October 13th was the first frost in Northern VA.
* Mustard greens are pretty freaking awesome.
* The MD side of Great Falls is underrated.
* There will be video....so stay tuned.
* My friends and family are very generous folks.

Andy, Tom and I

You can complete your pledges here if you haven't done so already.

sweet chariot

before the ride pt.1

Two weeks ago I had been searching for a bike for weeks. I own a mountain bike, a hand-me-down from Nicole, but I wasn't going to commit suicide by trying to ride one 100 miles. If you don't think you'd feel a difference, you've never ridden a road bike. So I went back and forth nearly every day between buying the used road bikes that show up on craigslist and fixing up the 1970 vintage French road bike that Carol had pulled off Alan's shop wall (where it had hung since 1980?) and lovingly wiped dust-free.

First stop was City Bikes in Adams Morgan with the classic. What did I need to ride this thing 100 miles 10 days from now? The shaved headed tech took one look at it and said that "this isn't the bike you want to be sinking money into." He noted the aging components and several badly chosen past repairs that would stop him from even doing a tune up.

Hm.. tough to tell Carol that I wasn't going to use Alan's bike after all that work, but I supposed I wanted a bike anyway and this was the excuse to buy one. So I started answering craigslist postings and squinting at tiny terrible photos. I ended up at the Lucky Frog.

When I saw the doublewide crouching in the edge of the dark parking lot I worried I might be going to meet a fence. But my encounter was to be with another sort of creature that shuns the light of day.

The Lucky Frog is a role-playing game cards store slowly becoming a bike shop. Under the buzzing fluorescents, between walls of D&D boxed sets and dusty display cases of Magic The Gathering (tm) cards is growing a motley collection of mountain bikes and the few road bikes that I had come to see. Dan the jovial owner and I took turns getting in the way of the dragon t-shirted regulars that were wandering in and out to kibitz a lustily contested game in the corner. The guys seemed vaguely puzzled with our interest in the bikes, which no doubt were an encroaching threat on their gaming space. Was Dan, smiling and clad in a yellow soccer jersey, a recent turncoat in the ancient and vicious struggle of indoor vs outdoor pastimes? Who got to him? Was it a child, a doctor, a bathroom scale?

Dan fiddled with the seat, adjusted this and that, and I took the object of my affections in dozens of loops around the deserted lot. Finally, reluctantly, I admitted it was too small of a frame for me and we ran out of time. Dan said he would try to fix up that other bike he'd just gotten in for me and I should come back tomorrow.

When I called back the next day, already on the way out in my car, Dan told me that a stripped bolt on the fall-back bike was a custom part that would take a week to order. I couldn't wait that long to train, so the deal was off. I was back to square one.

Presidential Prefs, end of August 2007

What's actually good for the country is not Democrats winning, it's about the right policies being put into place and the right kind of democracy being created.

So, here's my take on the upcoming election, ordered by how desirable I find each outcome (best first). The number that follows each is the likelihood I see of it coming to pass.

1. Edwards or Gore win primary and go on to win general election, inaugurating a new progressive era of real policy change that starts NOW! - 20% likely

2. Hillary Clinton wins primary and loses general election, removing biggest obstacle (the DLC, Clinton legacy) to the reinvention of Democratic party as a real party of the people. Change starts now, but accelerates in 2012. - 35% likely

3. Obama wins primary and goes on to win general election as a unifier above all else, lacks courage to really make any changes to anything while president. Change postponed 4-8 years. - 10% likely

4. Edwards or Gore win primary and lose general election, creating doubt about the viability of people powered candidates. Change set back 6-10 years. - 5% likely

5. Hillary Clinton wins primary and wins general election, spends years hammering the Democratic party back into the corporate mold while fighting the battles of the 90s over again with reinvigorated GOP. Change stalls for 12-16 years - 30% likely

Mother, Father and son-daughter

Nadine has seen the ultrasounds and has read the results of all the tests the doctors do to give children an early niche in our statistical system. Stephan has read the baby books, weighed names and those family that think about it suspect he's found a favorite. But the child's great grandmother is knitting a yellow and green jumper. You see, the parents won't let on whether it's a boy or a girl.

We somehow forgot Stephan's birthday in the midst of these weeks when we're thinking so often of them. Nicole and I realized almost a week late, and we're fumbling around feeling terrible--sending flowers and stammering that we got too caught up to track more than one big day at a time. We should have done better. Germans take special days seriously, and something's wrong if a minute past 12 midnight on your birthday eve doesn't find a relative or two hitting busy signals as they call seconds late with best wishes. I'm exaggerating, but not much.

Floridians have opposite instincts--my family has been known to schedule birthday parties on proximate or even distant weekends from the calendar day, and I am pretty sure that one year I gave my sister a gift certificate IOU that she never redeemed. It's not that we don't care, its that we have an ingrained and cultivated aversion to expecting a fuss to be made over us. We all love each other, respect each other, would do anything for each other, but somehow feel that pulling together a celebration would inconvenience someone somehow. Perhaps it's living in Central America that made us guard against being disappointed by not expecting such excess. And maybe we're growing out of it. My Dad threw a surprise party for my Mom last year and she turned around and pulled together my sister's friends from all around (we flew in from DC) for a night together in her honor this February. Not on the EXACT birthday, of course, but it is a start.

Whoops

Oh, the cleverness. The Bush administration is playing off Shia against Sunni in the Middle East, pitting Iran against Saudi Arabia and Egypt. Saddam's execution was the masterstroke--in death he once more plays the part Washington groomed him for since the 80s--and now hatred is welling up ever faster midst the oilfields.

There's only one problem with this picture. Where's the likely battlefield where these foes will meet? You'd think that if the strategy was to pit our enemies against each other and let them fight it out, we'd be stepping back to a safe distance. Yet, as Cheney pulls the strings, playing both sides against the middle, does he not see that in this case our troops in Iraq are the middle?