Hello all,
I'm annoucing the first alpha release of an ext2fs file server for
VSTa. This is available by ftp to ftp://131.188.190.131/ with
kind ftp hospitality from Markus Friedl (CIP 92)
<msfriedl@cip.informatik.uni-erlangen.de>.
I can also email gnu zipped uuencoded diff files to the
e2fsprogs-0.5b-WIP.tar.gz distribution.
*****************************************************************************
Announcing Extfs-VSTa 0.1 ALPHA (for testers only)
--------------------------------------------------
This is the first announce of my first alpha release of extfs-VSTa, a
port of Linux ext2fs file system to VSTa. This is *NOT* a public
release, but only a release for ALPHA testers only. It is based upon
(and contains) e2fsprogs-0.5b-WIP.tar.gz available on several Linux
ftp sites. This is a derivative work of, since it is based upon, e2fs
and libext2fs by Theodore Y. Ts'o and Remy Card (contained in this
e2fsprogs-0.5b-WIP.tar.gz gnu zipped tar file).
This is distributed
as e2fs_0_1.tgz, a 341327 GNU zipped tar file containing the full modified
e2fsprogs-0.5b-WIP.tar.gz file tree with my vsta extensions.
or
as e2fs.diff and e2fsvsta.diff as patches to be applied to the
original e2fsprogs-0.5b-WIP.tar.gz. e2fs.diff (40070 bytes) contains
the patches to e2fsprogs files (mostly adding #include
<vsta/ext2fs.h>). e2fsvsta.diff ( 76449 bytes) is a patch file for
creating the vsta specific source code files; it should be applied
after the e2fs.diff patch file.
I'm putting the files on ftp://131.188.190.131/incoming with kind
permission of Markus Friedl (CIP 92)"
<msfriedl@cip.informatik.uni-erlangen.de>.
Following is the README file.
## file vstasrv/README -*-text-*-
## rcsid: $Id: README,v 0.1 1994/11/27 21:11:36 basile Exp $
EXT2FS-VSTA 0.1 first alpha release - an fileserver for the VSTa
microkernel compatible with Linux Ext2Fs filesystems.
*** THIS IS A FIRST ALPHA RELEASE ***
about my port of ext2fs on Linux from Remy Card to VSTa.
--------------------------------------------------------
Copyright 1994 (for the vstasrv/ subdirectory)
by Basile STARYNKEVITCH (at home)
8, rue de la Faiencerie
92340 BOURG LA REINE
France
homephone: (33) [1] 4665-4553 (till 10pm)
(south suburb of Paris, in France)
27th november 1994
work email: << basile@soleil.serma.cea.fr >> sometimes in 1995 this
will change to << basile.starynkevitch@cea.fr >> but i don't know when
this will happen.
This is done for fun only at my spare time at home on my own i486/PC
running Linux (the latest version, ie 1.1.66 today). the vstasrv/
subdirectory is my own code (released under GNU Public License, any
version). This has no connection with my work (but i only have email
at work, not yet at home).
I don't have much time for this ext2fs server ported to VSTa. I don't
promise anything (no warranty as usual), not even to enhance and/or
maintain this code.
This was cross-developped under Linux (edited with GNU emacs 19.28,
cross-compiled with GNU gcc 2.6.2 targeted for VSTa with additionnal
patches on ftp.cygnus.com: pub/embedded/, cross-linked with GNU
binutils 2.5.2, using GNU make 3.72.1). My PC is home-assembled:
i486DX2/66 on Orchid motherboard with 16Mb RAM, IDE and Scsi
drives(total is 800Mb) and QIC-150 Scsi tape streamer. (And my wife
and our 3 kids want to use the PC too!!)
This was tested by booting VSTa 1.3.2 distribution. The only
difference from the ftp-able VSTa 1.3.2 was a patched cons2 server for
french keyboard support (ie AZERTYUIOP). I debugged mostly with
DBPRINTF output (to stdout).
*******************************************
goals and design
-------------------------------------------
*** THIS IS A FIRST ALPHA RELEASE ***
After emails from Bryan Ford <baford@schirf.cs.utah.edu>,
Francois-Rene Rideau <rideau@clipper.ens.fr>, Remy.Card@masi.ibp.fr,
and another kind person (T.T.?) whose email i've lost, i decided to
look into e2fsprogs-0.5b-WIP.tar.gz. This is a derivative work of
these, since it is based upon e2fs and libext2fs by Theodore Y. Ts'o and
Remy Card.
Having fun in coding is a goal. Simplicity of code is a design
goal. Efficiency is not a goal. Robustness is not a goal neither (but
i still hope this to be robust one day). Understanding what
filesystems and microkernels are is also a goal. Don't expect this to
be ever as good as ext2 native on Linux is! I'm writing it for fun,
and to be able to read Linux data (and perhaps to write it someday,
but currently this is for readonly filesystems). I looked (and somehow
copied) into Linux ext2 code, obviously the libext2 code, and also the
VSTa dos and vstafs fileservers code.
Features include: cached inode and file blocks access (with a FIFO
discipline) and a variable number of cached inodes and blocks (thru an
hash table for cached inodes, an hash table for cached blocks, an hash
table for clientconnection). Tentative mapping of Linux uid/gid and
access mode into VSTa. Only regular files, directories and symlinks
are handled. Other files (ie fifos, char&block devices) are
ignored. Newlines can't figure in filenames.
Source files are -with output from the wc word counter (lines, words,
chars)
The common include for server view (ie cached) of clientstate, inode,
block:
300 1080 9050 ext2vsta.h
The caching machinery -which does the physical IO of blocks and inodes
(and also their cleaning):
408 1432 12470 cache.c
The main routines. Contains filesystem and server initialization, and
the main message dispatching routine, and many small message handling
(ie FS_OPEN, FS_STAT, all client related stuff etc).
701 2411 18477 main.c
The read and write routines. Currently, only reading routines are
coded. This handles the FS_READ message (for regular files and
symlinks):
256 1025 7858 rw.c
The VSTa port IO manager for libext2 -interfacing to VSTa ports.
329 1618 11122 vsta_io.c
Total is almost two thousand lines. I expect that another thousand is
needed (ie for writing).
1994 7566 58977 total
This does not include any of e2fs existing code, ie about seven
thousand lines (including a patched <vsta/ext2_fs.h> include file).
The caching (of blocks and inodes) is done as follow. We maintain an
hash table of cached blocks and another hash table of cached
inodes. Each has a reference count (it is a pity that C isn't garbage
collected). To be removed from the cache, a block or inode should have
a 0 refcount. At some times, aged blocks or inodes which hasn't been
accessed are removed. Any access to a block or inode increment the
refcount and update the age. Ages are simply measured by a counter,
incremented every 16 messages recieved by the server. Caches are
cleaned after message handling (ie at bottom of message handling look)
so no block or inode is removed during message processing (which can
hence use 0-refcounted blocks or inodes, eg temporary blocks in double
indrect access). This could also handle an hypothetical FS_MEMORY
message sent when memory is low to clean up server memory (such a
message would be handled by flushing the cache).
I didn't code the writing of files, etc. I suppose that written blocks
or inodes should be written immediately. I'll be glad to hear
suggestions about this. Also, filesystem checking is not done.
*******************************************
running the ext2fs vsta server
-------------------------------------------
*** THIS IS A FIRST ALPHA RELEASE ***
Only READONLY ext2 filesystems are currently supported. This code
can't write a single valid byte on an ext2 filesystem. However, it is
buggy and could destroy your data.
DON'T USE THIS CODE WITHOUT BACKUPS. IT COULD BREAK YOUR DATA (and
perhaps your hardware!). Actually DON'T RUN THIS CODE except for
testing (it gives tons of debugging outputs, at least when compiled
with -DDEBUG). And please, read the code before running it!
The running script is: (in a file /vsta/bin/testext2)
#! /vsta/bin/ash -x
/vsta/bin/ext2fs -r -i -p disk/wd:wd0_lxnat0 fs/ext2fs > /ext2out.tmp
## eof testext2
## parameters and options are:
-r : readonly filesystem
-i : ignore all permission test
-p disk/wd:wd0_lxnat0 : diskport is disk/wd:wd0_lxnat0 meaning the
IDE first IDE disk (wd0) first linux native partiton (lxnat0).
fs/ext2fs : the name given to the filesystem served by this server
> /ext2out.tmp: tons of debugging output goes here (stdout)
The mounted Linux partition is a Slackware root partition (contains /
/lib /etc /bin but not /usr /var /tmp /home* which I have on separate
partitions).
The testing client script is: (in a file /vsta/bin/e2client)
#! /vsta/bin/ash -x
sleep 2
mount fs/ext2fs /m
date
fstab
date >> /ext2out.tmp
echo before stat and ls of /m >> /ext2out.tmp
stat /m
ls /m
echo before stat and ls of /m/etc >> /ext2out.tmp
stat /m/etc
ls /m/etc
echo before ls and cat of /m/etc/motd >> /ext2out.tmp
ls /m/etc/motd
cat /m/etc/motd
echo testing a big copy of /m/bin/cp into /cplinux.tmp >> /ext2out.tmp
cp /m/bin/cp /cplinux.tmp
## eof e2client
*******************************************
testing the ext2fs vsta server
-------------------------------------------
*** THIS IS A FIRST ALPHA RELEASE ***
This code is NOT for general use. DON'T USE IT unless you read it and
understood it.
I don't know if there are some memory leaks. I don't know how to get
the size of an active or sleeping process under VSTa.
I didn't understand fully the VSTa filesystem protocol. I understood
parts of it gradually, and i probably misunderstood some of it. I
don't understand exactly how files are created, deleted, moved, etc in
filesystem protocols terms.
I didn't understand really what are VSTa permissions and
capabilities. I didn't understand what are Ext2fs Access Control Lists
(i believe these are not yet implemented). I tried to map unix uid/gid to
VSTa ids and unix user,group,others modes to VSTa permissions, but my
coding is a crude and untested guess. The -i server option bypasses
all tests. If someone could explain me (or better yet, debug and/or
recode my routines) how to map Posix UID/GID access modes to VSTa I
will be grateful.
I expect brave alpha testers to read the code, run it, and preferably
send me patches or at least bug reports. They should expect or at
least be prepared to lose their data. This didn't happen to me yet, or
i didn't notice it (because this is currently a readonly filesystem
server).
Futures enhancements could be writing routines, less buggy permission
routines, etc.. I don't promise anything. (I might give up or just
might not have time to code).
VSTaling and Linuxing at home only
-- Basile STARYNKEVITCH ---- Commissariat a l Energie Atomique DRN/DMT/SERMA * C.E. Saclay bat.470 * 91191 GIF/YVETTE CEDEX * France fax: (33) 1- 69.08.23.81; phone: (33) 1- 69.08.40.66 email: basile@soleil.serma.cea.fr; homephone: (33) 1- 46.65.45.53 N.B. Any opinions expressed here are solely mine, and not of my organization. N.B. Les opinions exprimees ici me sont personnelles et n engagent pas le CEA. Please cite a small part of my mail in all answers Veuillez citer une petite partie de mon courrier dans vos reponsesReceived on Mon Nov 28 01:12:19 1994
This archive was generated by hypermail 2.1.8 : Thu Sep 22 2005 - 15:12:10 PDT