Unix File System Issues on Mac OS X?
rlthomps-1 asks: "I've been thinking about reformatting my Mac's hard drive in UFS, since I've seen the option on the install screen. I was looking for advantages of the Unix file system since it sounds like it would have better performance over HFS+. After viewing this Apple kbase article I wasn't so sure. A test system at work won't install software correctly because the drive name is stuck as '/' among other problems. Why would Apple include the UFS option if it offers such reduced functionality, and is anyone out there using it for non-server applications? What for? Are there advantages to UFS on the desktop Mac OS?"
When Darwin was built, Apple used FreeBSD 3.2 has its core BSD os, since then many changes where applied in the UFS code in FreeBSD (softupdates are the ones comes to mind). Since then Apple's version of UFS has not change too much.
HFS+ is Apple's MacOS native enhanced file system. So if you need to run Classic, if you need to run carbonised application that do have a resource fork then you need an HFS+ partition (see Mozilla's readme).
If you're more a unix guy like and want to compile OSS, host some CVS reposiroty then you 'll need UFS.
UFS is case sensitive. HFS+ is not (it might seems to be but is not). I'de say for all macos Apps use HFS+ an create a second UFS partition where you'd put all your unix apps and other unix related stuff (CVS etc
Other references can be found
none Yet.
If you are running a server you most certainly want some form of security. HFS+ is not case sensitive. If you restrict certain files like "Hello" outsiders may be able to get to the same file by calling it "HeLlO" or "HELLO". UFS is case sensitive.
OpenDarwin.org is looking into getting up-to-date UFS with FreeBSD and then maybe UFS2 from FreeBSD -current. I have been one of few people on the opendarwin.org list to respond and the exchange has been good about how to begin. Jordan Hubbard has provided good guidance.... now I just need the time and some help I am sure.
If you are interested... please sign up.
I do use cvs over ssh and it works (I used it for OpanDarwin).
I then can ssh anywhere I want.
The problem with CVSd is the case-sensitive issue that can be found in found in HFS.
none Yet.
I thought along the same lines... It is Unix, so UFS should be better... So, I formatted my iBook and went with UFS.
I was wrong. All of the mac applications run much better under HFS. Things like Appleworks need an HFS partition so they work with OS 9 as well as X. And mozilla still won't run in a UFS partition. As of version 10.1.3 (not exactly sure which one I tried) there were still a LOT of problems with UFS. I got a lot of data corruption on my UFS partition. Also, disk IO seemed a lot slower than with an HFS partition. The system kept getting slower and slower.
Finally, I reinstalled again with HFS. All of my troubles went away. In my opinion, don't use UFS unless you have a really important reason to do so.
The most important reason to stick with HFS+ is that a UFS drive cannot boot back into OS 9, and does not support Classic. (Also, HFS+ is faster)
Reality has a liberal bias
My advice: Do *NOT* use UFS on Mac OS X unless you are running a server. If you plan on using applications besides Apache or database software, use HFS+. I bought a new Powerbook several months ago and went with UFS, assuming it would be faster, superior, etc. I found that many programs (even Mozilla!) would not run on UFS. They'd simply crash or spit out strange error messages. After getting frustrated, I reinstalled using HFS+. I was *AMAZED* at the speed difference. It really is a lot faster: Apps load faster, file copying is faster, everything just seems more responsive. And, I no longer have trouble with software such as Mozilla, Toast Titanium, Dreamweaver, etc.
The bottom line: Stick with HFS.
UFS under Mac OS X does have type/creator info. It uses the AppleDouble hack that uses hidden files to store the mac resource fork.
The main problem that desktop apps will have with UFS is its case sensitivity. Many apps expect to be able to ask for a file in any case and get a like-named but differently cased file.
Personally, I would be surprised if any program as robust as Office had this problem.
it would seem relatively trivial to port XFS to the OS. .....
There's a icensing issue Here. SGI'sxfs is GPLed, apple does not endorse GPL or LPGLed software. They removed wget because it was gpled, gnutar has also been removed. Apple want to use BSD like licence exclusively, so one day if they want to they can make a closed source OS again
If you'de want xfs on OS X it should come from The GNU-Darwin project or from Fink. Both project are leading software port (one bringing support for AMD powered ia32 machines).
none Yet.
Support for Meta data isn't the issue here - it's the fact that UFS doesn't support resource forks, which Carbon apps still contain. If you install a Carbon app on a UFS drive, your resource fork disappears.
Karma: Ran over your dogma.
Here is the issue as I understand it. If you use UFS, you are limited, because UFS doesn't recognize resource forks, therefore you can't use Cocoa or Classic apps. For those of you who don't know, previous to Cocoa, all mac applications (and lots of other files - anything with an icon or that stores a PICT or AIFF for example) had separate resource and data forks. If you put one of these files onto a FAT volume, you will see a hidden folder for resource forks. Since UFS doesn't recognize resource forks, you can't use Classic at all, and can't use Carbon apps. You can use Cocoa everything. The only advantage that I know of for UFS is that it doesn't get fragmented, where HFS+ does. However, this does make it slower in my experience, and you're still stuck using either Cocoa apps, or Darwin, which means that you can say goodbye to most users favorite apps. No Photoshop, no MS Office, no iTunes (The last time I checked, not only was iTunes Carbon, it still had some Pascal code in it). So I guess it could reduce your downtime for maintenance in a server situation, but it's totally impractical for most users.
Karma: Ran over your dogma.
I first installed OS X on a beige G3/300 minitower on March 23rd, 2001. My OS X drive was formatted as UFS and my classic drive was formatted in HFS+.
My private user data was secure when the system was booted to classic plus I never had to optimize the hard drive!
I used this configuration until 10.0.4 when my system began to act eratically. A little poking around reveal that I had no files on my system. All apps, configuration files, library files, user files -- everything but folders -- were gone.
Tens of thousands of files, gone.
I returned to classic, but last fall I decided to troubleshoot my daughter's iBook. She was running ten, standard install, and was happy with it, so I upgraded her to 10.1.1.
I was impressed and thought that the data loss bug had been fixed, so I re-installed OS X 10.1.1 on TWO identical G3/300 minitowers.
I was a very happy users and eventually upgraded both machines to 10.1.4.
Then one Sunday night when I wasn't even home, all the files on my personal computer disappeared, same as the previous summer.
One day later, I remembered that my server was configured exactly like the workstation that lost all its files, so I started poking around.
It, too, had lost all its files except two, which I had recently accessed. More significantly, file losses included mounted HFS+ file systems!
Incidents like these were echoed by Apple customer support staff, unofficially.
I'm not saying every system will have problems like I had with my old computers running UFS, but some machines do.
I lost over 40-gigabytes of files off of six hard drives. The problem is REAL.
I'm now using Red Hat as my full-time personal computer OS.
Apple includes UFS becuase all Cocoa applications will run correctly with UFS, and Carbon applications (if written correctly) will also run correctly. Apple uses its previously published standards (see Netatalk list archive for a discussion) to seperate the data and resource forks. The problem is that many MacOS applications--and the entire classic environment--require HFS compatibility. Many applications will not even install onto a UFS drive. If your environment is mostly Unix, and you are a developer or a web designer, having the same case-preserving, case-sensitive file system symantics that other Unix implementations may be a benifit. Otherwise, stick to HFS+. I, for one, have signed and recommend that other sign the Metadata petition which calls for Apple to move towarsd a modern file system which has multiple streams (as apposed to two fixed streams) and a generalized metadata implementation a la BeFS or Attributed FS to provide the core HFS compatible metadata with the ability to extend the metadata use into new areas. A journaled file system would also be a plus. HFS+ is a reasonably efficient and Unix like file system. The only difference is the case-preserving, case-insensitive file symantics, which is arguably (many discussions abound) is preferable for a GUI, and human UI in general.
A big bonus would be implementing posix compliant multiple stream bsd userland commands like cp so that you don't axe your resource fork when you cp a file from the command line, etc.
When Mozilla 1.0 became available, I formatted my HD as UFS...I had been waiting and waiting to do this just to play around with it. Anyway, it turned out to be a BIG mistake. The first thing I installed was Mozilla. It installed fine, but when I tried to run it, it would quit before the launch was finished. The same happened with Netscape...I thought maybe it was just a "Mozilla-type" thing...I was wrong...I then tried installing MS Office (sorry I turned to Microsoft...I need the compatibility for school)...that installer wouldn't even run...it wouldn't give me permission to install on UFS formatted "/" So then, I reformatted back to HFS+. I reinstalled everything, and since, everything has worked fine...I have even installed mySQL and PHP, and both of them seem to work wonderfully as well. I'm not sure if this will help or not, but when I reformatted as HFS+, I named my HD "/" just like it would have been if I had formatted it as UFS. You may also want to check out the postings by SandSpider and Nachoman...they seem like they ran into problems similar to mine...one of them suggested (along with some others) that you partition the HD so you can have both a UFS partition and a HFS+ partition. Anyway, good luck!
I was trying to get UMN Gopherd running on my OS X box awhile back, and one neat trick that was suggested to me by the maintainer of the package that helped was to use the Disk Copy application to create a virtual UFS device. I dragged the files I wanted to compile into my virtual drive, cd'ed into it, did the make thing, and presto: it compiled beautifully. Even neater is that I could still install it into the standard hierarchy, which was hfs+ formatted, and it still ran just smooth.
So my advice is this: format your drive hfs, and when you need to do a project that requires UFS, simplly create a big enough blank UFS drive using Disk Copy, and do your work in it. Talk about having your cake and eating it too!
...mmmm... cake.....
They still use GCC... but then, there are no BSD-licensed compilers.
Napster-to-go says "Fill and refill your compatible MP3 player", which is a lie. It's not MP3. It's WMA with DRM.
Second, I cannot recommend UFS for a root partition. Too many installers rely on the root partition being HFS+. They give errors about not being able to install on a "network file system" (which should be possible regardless). I had my system set up with several UFS partitions and no HFS+ partition at all, and ran into problems trying to install a bunch of stuff I genuinely wanted. So I gave up and made my root partition HFS+.
What I recommend, however, is that only the root be HFS+. My /Users partition is UFS. A couple of other partitions are UFS. I ordered an external FireWire drive and the several partitions I will be putting on it (including /Library, /Applications, and /Developer) will all be UFS.
(For those who are worried about /Library being externally mounted -- I haven't figured out what difference Apple intends there to be between /System/Library and /Library since both seem to be used identically, but I have chosen to treat /System/Library as containing things central to the running system such as StartupItems and Extensions, and /Library to be things related to applications, such as Application Support and Fonts.)
To maintain my various UFS partitions, I have an /etc/fstab and run fsck -p in the Disks StartupItem. I've been doing things this ways for months and it seems to work quite nicely. I will mention that I do not use any Classic applications, so having partitions (such as my home directory) visible from Classic is not a concern. YMMV.
That's the thing; my system drive isn't UFS. I have 5 partitions: 1) OS9 - HFS+; 2) OSX - HFS+; 3) User - UFS; 4) Swap 1 - HFS+; 5) Swap 2 - HFS+.
This way, the user data is protected, and all the apps work properly. Swap 1 is a system swap, and Swap 2 is for applications like Photoshop that have their own swap files.
=Brian
There is nothing so good that someone, somewhere, will not hate it.
I got myself a G4 as a workstation about six months back. Being new to both OS X and the Mac world, I chose to format my partitions as UFS. BAD move. A lot of software simply refused to work (Mozilla being an example) if started from an UFS partition. Others (like the Harpoon 3 Demo) worked if I did some tweaking. Since OS9 doesn't know anything about UFS volumes, I was deprived of Classic apps as well (not that I have really needed any, but anyway). All this was a pain in the ass, though. For a long time I thought the software I tried was badly coded, but soon realized that it was due to my partitions being UFS only.
Today I finally found the time to repartition as HFS+ and everything works like a charm. Finally I have a decent browser instead of that Microsoft crap. :-)
To summarize: don't do it, unless you really, REALLY, REALLY know what you are doing.
Just my .02 €
I've read all the usual arguments to use either UFS or HFS+, but the main reason I use HFS+ is it supports FileIDs. Thus Aliases don't break when you move or rename the original file. This is a huge human interface advantage.
I also suspect iterating directories is faster with HFS+.
I'm hopeful somebody will develop a better filesystem which also supports FileIDs. HFS+ has a couple problems like fragmentation and corruption when interrupted. However Disk Warrior and Plus Optimizer fix those problems.
>80 column hard wrapped e-mail is not a sign of intelligent
>life