Testing MacOS X read only ZFS capability

When I first heard Jonathon Schwartz announce that MacOS 10.5 (aka Leopard) would include ZFS, I was psyched!  As a Microsoft free user of Macs and Unix since the late 1980s, I was looking forward to seeing Sun's open source file system in MacOS and was convinced that its snapshot capability would be the basis of Time Machine, Apple's new backup facility.  Imagine my disappointment when news trickled out that the first release of Leopard would only included a basic, read-only implementation of ZFS.  What good is a read only file system?

Leopard shipped two weeks ago and ZFS is almost impossible to find by anyone but developers and OS nuts like me.  It's completely invisible to the typical Mac user.  Then I heard a different piece of news.  Apple shipped 2 MILLION copies of Leopard in the first weekend!  Once ZFS becomes a more prominent part of MacOS, they will be able to touch many more people than Sun ever could in our enterprise ready Solaris OS.  I feel confident that Apple will continue to innovate on top of ZFS.  And in typical Apple style, the end user (like my 82 year old mother who loves her Mac and has no idea that she's running Unix) may never know what ZFS is, but they will appreciate the benefits that they get.   The same will no doubt be true  in their  implementation of Sun's Dtrace technology.

With that in mind, I set about to find a way to prove to myself that ZFS is in there and compatible with ZFS in Solaris 10.  Here's what I did using my MacBook Pro, VMware Fusion 1.1RC1 beta and Solaris 10 08/07.

  • Halt Solaris and shut down the VM
  • VM > Settings > + > Add USB controller
  • Boot Solaris
  • Plug in the USB memory stick. (the VM must have focus)
    • This was actually the most time consuming part of the whole exercise.  It did not mount reliably)
  • If you're lucky, mount shows: /rmdisk/noname on /vol/dev/dsk/c2t0d0/noname:c
  • umount /rmdisk/noname 
  • zpool create usbpool /vol/dsk/noname
  • zpool list
    NAME                    SIZE    USED   AVAIL    CAP  HEALTH     ALTROOT
    usbpool                 120M     88K    120M     0%  ONLINE     -

  • zfs list
    NAME         USED  AVAIL  REFER  MOUNTPOINT
    usbpool       85K  87.9M  24.5K  /usbpool

  • zpool export usbpool
  • Suspend the VM and quit Fusion to avoid confusion
  • Re-insert the USB stick.
  • Finder complains that the disk is not readable.  Click Ignore
  • Open a terminal on the Mac.
  • sudo bash
  • zpool import
      pool: usbpool
        id: 13927799406997242219
     state: ONLINE
    status: The pool is formatted using an older on-disk version.
    action: The pool can be imported using its name or numeric identifier, though
        some features will not be available without an explicit 'zpool upgrade'.
    config:

        usbpool     ONLINE
          disk2     ONLINE
  • zpool import usbpool 
  • Mount shows:
    • usbpool on /Volumes/usbpool (zfs, local, read-only)
  • I was then able to view and copy files from the newly mounted pool
  • Woooo Hoooo! 

Why should you care?

ZFS is a truly easy to use, open source, endian independent, scalable, reliable file system.  This is the first example of it being ported to a commercial, consumer oriented product.

Things to like about ZFS:

Learn more at the ZFS learning center.

Comments:

Post a Comment:
  • HTML Syntax: NOT allowed
About

Jim Laurent is an Oracle Sales consultant based in Reston, Virginia. He supports US DoD customers as part of the North American Public Sector hardware organization. With over 17 years experience at Sun and Oracle, he specializes in Solaris and server technologies. Prior to Oracle, Jim worked 11 years for Gould Computer Systems (later known as Encore).

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today