site_archiver@lists.apple.com Delivered-To: darwin-kernel@lists.apple.com Hello, If the FS is to operate in user space, it will need to do one of: (1) operate as a standalone program not integrated with the system or To do this I want to accomplish the following. 1. Read the volume header from the disk. 2. Get the catalog file. 3. Get the file id. 4. Get the file name. -- Terry _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-kernel mailing list (Darwin-kernel@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-kernel/site_archiver%40lists.a... On Nov 16, 2005, at 4:39 AM, Pavan Chebbi wrote: I want to implement a user level file system where i want to read a file from the disk and display. (2) operate as an NFS loopback, and allow an NFS mount from the local system If you take the first approach, your job is much easier, since all your code is in user space, and your only dependency will be the ability to open and read the disk devices. If you take the second approach, the FS will show up as a mounted network volumen in the Finder, etc., and will be better integrated with the OS. There's plenty of example code for both of these approaches on the Internet, and neither one is dependent upon whether or not you are running on Darwin or Solaris or whatever. The canonical example of a set of standalone programs is mtools (for reasing DOS formatted disks on UNIX). The canonical example of a loopback NFS FS is "amd" or "automounter" (for automatically mounting FS's on UNIX when a symbolic link representing a mount instance is traversed). Plz correct me if i am wrong in the above steps. I want to list all files with the extension .mp3 which are there on the disk. Please suggest the way that i should follow. If you are going to open the device yourself, you need to make sure that the OS has not already mounted the FS in question. The only way you can reasonable do this is if: (A) The FS type is unknown to the OS (i.e. it's an entirely new disk format, or one for which there is no FS support already) (B) You explicitly unmount the device from the OS FS implementation that knows about the FS already (i.e. you use unmount on the command line to prevent any association with a device node from being automatically torn down at the same time. After that, what you have to do and the order you have to do it in depends on the on-device layout of the FS, and the defined order of operation for doing things on the FS (for example, if it was disconnected uncleanly from wherever you got it, you would need to run transactions forward or backward, depending on the FS architecture, until the FS was in a known, stable state - basically fsck). This email sent to site_archiver@lists.apple.com
participants (1)
-
Terry Lambert