tmpfs

This is an old revision of the document!



TMPFS is now in -Current tree under /src/sys/fs/tmpfs.

Porting TMPFS

TmpFS is first developed by Julio M. Merino Vidal for NetBSD as a SoC project: [http://netbsd-soc.sourceforge.net/projects/tmpfs/ Efficient memory file-system]. Rohit Jalan ported it from NetBSD to FreeBSD. Now HowardSu and Glen Leeder ( glen.leeder@nokia.com ) are working on it to continue this effort.

We port NetBSD regression test cases.

All tests sucessful.

All tests successful. Files=184, Tests=3353, 823 wallclock secs (29.94 cusr + 368.38 csys = 398.31 CPU)

Survive after fsstress -n 10000 -p 50. Tested under AMD64/i386.

Any presure testing in SMP box are highly welcomed.

We sucessfully build world to a tmpfs in 4-CPU box with -j32.

fsx(tools/regression/fsx) is a tool to test the correctness of a filesystem read/write. It tests read, write, truncate, mmapread, mmapwrite, hole/extend write. TMPFS failed the testing with two problems: 1. The hole create by truncate or extend write is not zeroed correctly. 2. Some write data will lost due to unknow issue.

I suppose all these bugs are related to the fact that for each file, tmpfs maintain two objects (one vnode object in vnode→v_obj, one swap object in tmpfs_node→tn_obj). The data transfered between two objects are buggy (tmpfs_uio_xfer function in tmpfs_vnops.c). Any help are highly apprecaited.

The vacache code is removed. sf_buf is used for data I/O. The performance will depends on sf_buf implementation in different platform. In Amd64, sf_buf is zero copy however i386 is not. So you will notice a performance difference.

  • tmpfs.1183878866.txt.gz
  • Last modified: 2007/07/08 07:14
  • by AlexanderLeidinger