outer space is getting closer…
Sunday, 26. March 2006, 13:59:21
Since my first experiments with the 9P filesystem on linux, a number of things changed:
- the v9fs code in the 2.6.16 kernel now allows to run executables from a 9P filesystem;
- transition is made from the old u9fs to the new npfs server infrastructure;
- efforts are made to push v9fs out to distros.
Several bugs got fixed both in the client and the server code, and things start looking brighter for use. The main hurdle for deployment is, at this very stage, (the lack of) security support - not a small one, though… Any serious deployment has to wait for this feature to be fully implemented, but experimenting in safe environments can already be done.
npfs
A special note is needed for npfs - there is no ready package yet, and you'll need to get it from the CVS repository:
$ cvs -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/npfs login $ cvs -z3 -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/npfs co -P npfs
And now the trouble might start: the configuration script and the Makefile do not catch your environment well enough to allow for the simple and well-known `./configure` and `make`. I do not know how to solve problems on anything but Linux, and I do not know how to solve them for various environments.
First thing, if you are compiling on Linux: don't run `./configure`: it will only break stuff that else might have worked. Specifically, you might need to check in the Makefiles that libnpfs/mount-Linux.c gets compiled.
I myself did not have libaio installed: the feature is not protected well enough, so you manually need to make sure not to reference it:
In the file fs/ufs.c comment out the block:
//#if SYSNAME == Linux //#define NPFS_USE_AIO //#define NPFS_USE_AIO //#endif
and then manually purge every Makefile of the string -laio. You are now ready to go, and `make` will provide you a npfs server.
Get it going!
The new npfs is much more flexible than the old u9fs and easily allows you to mount the 9P filesystem in userspace (replace the username me with your own username):
- `mkdir ~/mnt/9/`;
- `./npfs -s -p 5640&`;
- `sudo mount -t 9P 10.0.0.1 /home/me/mnt/9 -o port=5640,name=me&` - sudo here is only needed because of how mount is designed on Unix systems; I am confident that we'll soon see some fuse way of mounting in userspace;
- `ls ~/mnt/9/`.
