Sunday, December 6, 2009

dtrace rocks!

Starting from Leopard, Apple brought DTrace into OS X and replaced the old STrace. It runs in kernel space and is super powerful. Here is a good tutorial.

Some notes,
1. To use strace style Dtrace, run 'dtruss'
2. An example to debug mount problem (from here)
dtrace -n 'syscall::mount:entry { printf("%s %s %s", copyinstr(arg0), copyinstr(arg1), copyinstr(arg3)) } syscall::mount:return { printf("%s %d %d", execname, (int) arg1, errno) }'

Friday, November 13, 2009

MACOSX_DEPLOYMENT_TARGET=10.4

http://lists.apple.com/archives/java-dev/2007/Nov/msg00278.html
On Nov 9, 2007 12:06 PM, Stefan Arentz <email@hidden> wrote:
> What is the trick to compile a JNI lib on 10.5 that should also work on 10.4?
>
> Right now I'm using:
>
> g++
> -c
> -g

I got an anonymous tip :-)

simply doing an:

export MACOSX_DEPLOYMENT_TARGET=10.4

Before building made the difference. I was under the impression that
using the 10.4 SDK was enough, but it seems that the toolchain looks
at this environment variable.

Thanks! (You know who you are :-)

S.

Wednesday, October 21, 2009

remote desktop for mac os x

mac os x has the default remote desktop server, which aims for easy share, however, it is built with limited compatibility with standard vnc which turns out to be hardly connected by Realvnc vncviewer[1, 2]

after digging in google, i finally found a very good alternative vnc viewer that works pretty well, tightvnc.

A note for cvs checkout in sf.net

In case i forget again,
cvs -z3 -d:pserver:anonymous@ext2fsx.cvs.sourceforge.net:/cvsroot/ext2fsx co -P ext2fsx



Monday, October 19, 2009

Very good ext3 documentation

Here is a very good unofficial ext3 documentation which is made by some folk working on to undelete removed files in ext3 disk. The article is mainly about the details of how his program works.

The link here.

Thursday, October 15, 2009

To-Do for This Week

"Though the details differ, the pattern is depressingly repetitive. Moving targets. Fluctuating goals. Unrealistic schedules. Missed deadlines. Ballooning costs. Despair. Chaos."
                                           --Dreaming in Code.

To avoid this depressing pattern happening in my project, i need a clearer figure of what is going on and what to do next at this stage, namely this week, listed as following:

1. Things need to be read
  • ext3 document
  • ext3 code in Linux, including ext3 itself, diff of ext3 and ext2, and jbd itself
  • ext2fsx
  • e2fsprog, fsck, and how it could work in Mac OS X
  • hfs+ in OS X, know how i could use the native journal sys call
2. Things to do
  • Set a void space in OS X for testing.
  • Install ext2fsx binary, test it.
  • Compile ext2fsx from source code, test it.
  • Learn more about Xcode
  • Make any change and Compile it, test again.
3. Things to think
  • Test proposal for ext3 Recovery

Monday, September 28, 2009

Presentation #1

First presentation on Sep. 16 was mainly answering the question what and why of the project.

Here it is.

Proposal

SUMMARY
  • The goal is to add ext3 (third extended filesystem) support to the Mac OS X.

SCOPE
  • The ext3 support would work as a kernel extention (k-ext) in Mac OS X, based on existing ext2 project (ext2fsx). The difference between ext3 and ext2 is ext3 is with journaling.
  • Success is defined as successfully read/write ext3 filesystem and resume from crashes, with acceptable code quality.

DECISIONS
  • Pre-planned work hours: 15~20 hours per week.
  • Basic plan is to support recovery from crashes by reading journals, then adding support for journaling (commit/checkpoint), finally make some useful utilities which are included in current ext2fsx.

MILESTONES
  • October 10: recovery from crashes
  • October 20: journal commiting
  • October 30: journal checkpointing
  • November 15: debugging/testing complete
  • November 20: utilities
  • December 5: code cleanup done

FINISHED TASKS
  • proposal (done 9/28)
  • read ext2fsx code (done 9/15)

TASK HORIZON
  • read journal daemon code (jbd) in linux src (10/1)
  • write a tool to make ext3 disk dirty (with some journaling unflushed to disk) (10/5)
  • write recovery support (10/10)

LINKS

Monday, September 21, 2009

kk.. New HERE

This is the *OFFICIAL* blog for the ext3fsx project, a project for CMU 15-412 course of fall 2009 and a project aiming at the ext3 support on Mac OS X.

Keke,,, start from here..