summaryrefslogtreecommitdiff
path: root/user
diff options
context:
space:
mode:
Diffstat (limited to 'user')
-rw-r--r--user/flaviocruz.mdwn126
-rw-r--r--user/madhusudancs.mdwn395
-rw-r--r--user/scolobb.mdwn134
-rw-r--r--user/zhengda.mdwn110
-rw-r--r--user/zhengda/howto.mdwn95
5 files changed, 860 insertions, 0 deletions
diff --git a/user/flaviocruz.mdwn b/user/flaviocruz.mdwn
new file mode 100644
index 00000000..9c9af71d
--- /dev/null
+++ b/user/flaviocruz.mdwn
@@ -0,0 +1,126 @@
+[[meta copyright="Copyright © 2008 Free Software Foundation, Inc."]]
+
+[[meta license="""[[toggle id="license" text="GFDL 1.2+"]][[toggleable
+id="license" text="Permission is granted to copy, distribute and/or modify this
+document under the terms of the GNU Free Documentation License, Version 1.2 or
+any later version published by the Free Software Foundation; with no Invariant
+Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license
+is included in the section entitled
+[[GNU_Free_Documentation_License|/fdl]]."]]"""]]
+
+Name: Flávio Cruz
+
+Email: flaviocruz at gmail dot com
+
+Some [Hurd stuff](http://opensvn.csie.org/leic/hurd/)
+
+And code: [cl-hurd](http://freehg.org/u/flavioc/cl-hurd/)
+
+hg clone [http://freehg.org/u/flavioc/cl-hurd/](http://freehg.org/u/flavioc/cl-hurd/)
+
+## Summer session
+
+Creating an extensible translator library in lisp using the mig generated stubs.
+
+### What's done
+
+- The library for writing translators is mostly written.
+- This library is intended to implement virtual filesystems. Examples are: translators were data is located in a local file (like zipfs, tarfs, rarfs, ...), single file translators (that do content filtering, output of a command, etc), network based filesystems (ftpfs, httpfs, ...), proxy filesystems (like hostmux, usermux, etc..)
+- It's possible to specialize the basic translator library and implement new translator classes. This is done using CLOS.
+- There is a tree-translator class that makes the managing of a node tree very easy, doing all the work for us, through a simple directory API and implementing the directory callbacks for us.
+- There is a simple example (something like zipfs) translator that can expose the directories and file contents of a ZIP file.
+- More translator examples include:
+ - /dev/null translator.
+ - /dev/zero translator.
+ - translator that creates a symlink node.
+ - tmpfs like translator.
+ - a translator that does proxying between clients and the underlying translator returning all data in upper-case.
+ - a translator that watches for changes in a file describing the file system structure.
+ - an IRC translator.
+ - a categorizer translator: creates a virtual directory containing files listed in a file, each file is categorized with a script. For example, a script can output the music author (in an mp3 file) and then all files will be categorized by author.
+- Translator options (manipulated through fsysopts) have a simple and easy to use API.
+- All the Mach port manipulation API is available.
+- It's possible to send and receive messages. Simple example:
+<pre>
+ (let* ((spec-mixed (make-message-spec :fields '(:string :integer :char :string :integer :real)))
+ (msg-mixed (make-message :spec spec-mixed))
+ (port (port-allocate :right-receive)))
+ (send-message msg-mixed :remote port :data (list "abc" 42 #\b "cba" 314 3.14))
+ (receive-message msg-mixed :source port) ; This returns T on success.
+ (get-message msg-mixed))) ; Returns '("abc" 42 #\b "cba" 314 3.14)
+</pre>
+- New message types (like :string, :integer) can be implemented, providing a powerful extension mechanism.
+- Creation of symlinks and symlink path resolution.
+- Creation of character/block devices, fifos and sockets.
+- Patch that opens stdin + stdout to /dev/null.
+- Project has been separated into 5 ASDF installable systems:
+ - hurd-common
+ - mach
+ - hurd
+ - hurd-translator
+ - tree-translator
+- Test cases are now written.
+
+
+### What needs to be done
+
+- Fix fsys-getroot (block happens in trivfs based translators, when they do RPC's to me when I call fsys_getroot to them) and fetch-root (for passive translators).
+- Make the library multithreaded (blocked by the pthread conversion project and the unavailable thread support in CLISP)
+- Use the socket stubs?
+- More documentation
+
+
+### Project dependencies
+
+- CLISP
+- [CFFI](http://common-lisp.net/project/cffi/) (apt-get installable)
+- [Flexi streams](http://www.weitz.de/flexi-streams/) (apt-get installable)
+- [Trivial garbage](http://www.cliki.net/trivial-garbage) (not in debian repositories)
+- [cl-zip](http://common-lisp.net/project/zip/) (only needed for the zip translator)
+- [cl-irc](http://common-lisp.net/project/cl-irc/) (for the irc translator)
+
+
+## To do
+
+### Documentation
+- Manually Bootstrapping a Translator
+
+### Translation
+- Translate the Hurd website to Portuguese?
+
+## Completed tasks
+
+### Patches
+- http://alioth.debian.org/tracker/index.php?group_id=30628&atid=410472
+ - libsvg patch accepted.
+- Adapted glibc patch (http://www.schwinge.homeip.net/~thomas/tmp/glibc-patches/0009-2007-07-22-version-of-init-first.c_vs._GCC_4.1.patch.patch)
+ - http://opensvn.csie.org/leic/hurd/patches/glibc-init-first.patch
+- Patch to remove some GNUMach IPC warnings and minor cleanup:
+ - http://opensvn.csie.org/leic/hurd/patches/gnumach-ipc-warnings.patch
+- Website patches that correct some encountered typos:
+ - http://opensvn.csie.org/leic/hurd/patches/hurd-talk-typo.patch
+
+### Documentation read
+
+- GNU/Hurd User's Guide, an introduction to the important concepts and software of the GNU system, written for new users, AKA "GNUbies."
+- Towards a New Strategy of OS Design, an architectural overview by Thomas Bushnell, BSG.
+- The Hurd, a presentation by Marcus Brinkmann.
+- The Hurd Hacking Guide.
+- The GNU Mach Reference Manual
+- The GNU Hurd Reference Manual
+- The Unofficial GNU Mach IPC beginner's guide
+- Mach IPC without MIG
+- CFFI User's Manual
+
+### Before selection
+
+- Uptime program in C and Lisp using CFFI.
+- Hello translator.
+
+## Misc
+
+### Lisp implementations that run on Hurd
+
+- Clisp
+- ECL
+- ?
diff --git a/user/madhusudancs.mdwn b/user/madhusudancs.mdwn
new file mode 100644
index 00000000..1139c718
--- /dev/null
+++ b/user/madhusudancs.mdwn
@@ -0,0 +1,395 @@
+[[meta copyright="Copyright © 2008 Free Software Foundation, Inc."]]
+
+[[meta license="""[[toggle id="license" text="GFDL 1.2+"]][[toggleable
+id="license" text="Permission is granted to copy, distribute and/or modify this
+document under the terms of the GNU Free Documentation License, Version 1.2 or
+any later version published by the Free Software Foundation; with no Invariant
+Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license
+is included in the section entitled
+[[GNU_Free_Documentation_License|/fdl]]."]]"""]]
+
+[[!meta title="GNU/Linux compatible procfs"]]
+
+[[!toc ]]
+----
+
+ Project Name
+----
+
+GNU/Linux compatible procfs pseudo-filesystem
+
+------
+
+ Project Description
+----
+I wish to provide a sophisticated procfs pseudo-filesystem to “the Hurd”. An implementation of /proc pseudo-filesystem already exists in hurdextras repository. After skimming through the code it is clear that it needs a lot
+of rework and tuning. Experiences from GNU/Linux have proven procfs to be a very useful facility in implementing
+many of the process management tools. So the goal of this project is to rework on the existing procfs on “the Hurd”
+so that its not only reliable and robust but also more importantly it is fully compatible with the GNU/Linux procfs.
+The project thus aims at making the GNU/Linux process management tools like top, sysctl, kill,
+skill, nice, snice, pgrep, free, tload, uptime, fuser, killall, pidof, pstree, etc., to run out of the box.
+
+------
+
+ Mentor
+----
+
+Olaf Buddenhagen
+
+------
+
+ Project Schedule
+----
+
+#####&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1.&nbsp;Initial preparation and migration (Community Bonding Period: has already started – May 25th)
+
+ This phase involves improving my translator programming skills by gaining
+ hands-on experience in it and becoming well versed in it. I will also go
+ through the Hurd code to understand its architecture in depth and will read
+ documentations related to obtaining process related information in Hurd.
+ This phase also involves the migration of existing procfs to use libnetfs.
+
+#####&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;2.&nbsp;Analysis and Design (May 26th – June 11th )
+
+ This phase involves the analysis of previous migration. Also involves
+ interacting with the mentor, the Hurd community and other people involved
+ in development of ps. tools to draw the exact design of the proposed procfs
+ including the algorithms required for coding.
+
+#####&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;3. &nbsp;Coding Stage I (June 12th – June 22nd )
+
+ Finishing up the migration to libnetfs based on the finalized design and
+ making necessary changes to the existing procfs. Coding up to
+ /proc/<pid>/exe in the features list.
+
+#####&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;4.&nbsp;Coding Stage II (June 23rd – July 13th)
+
+ Involves coding of the features from /proc/<pid>/environ, up to
+ /proc/<pid>/maps. These contain most of the information required for ps.
+ tools and hence form the heart of the project. Will be completed by
+ mid-term evaluation deadline.
+
+#####&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;5. &nbsp;Coding Stage III (July 14th – July 26th )
+
+ Coding the rest of the features in the list including any necessary
+ features that may be added in the analysis phase.
+
+#####&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;6. &nbsp;Final Testing and evaluation (July 27th – August 8th )
+
+ Closely interacting with the community and requesting them to help me
+ in overall testing and reviewing and making changes as per their
+ suggestions. Also involves testing with the ps. tools and consolidating
+ the documentation.
+
+#####&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;7. &nbsp;Packaging and Wrap-up (August 9th - August 18th )
+
+ Final phase of testing and fixing remaining bugs. Working with the
+ community to merge the project with the CVS HEAD of Hurd. Documentation
+ reviews, making necessary changes as per the suggestions and wrapping
+ up the documentation.
+
+------
+
+ Deliverables
+----
+
+1. /proc filesystem that uses libnetfs. Using this library makes it easier for implementing a large set of functionalities and hence makes the implementation robust.
+2. The core GNU/Linux compatible /proc filesystem with functionalities to support and provide information for ps. tools like procps, psmisc etc.
+
+Non-code deliverables include an exhaustive Documentation. This documents the code of the Hurd's procfs which explains in detail the implementation of each of the functionalities of procfs implemented
+during the course of this project.
+
+------
+
+ Code Repository
+----
+
+[http://github.com/madhusudancs/procfs/tree/master](http://github.com/madhusudancs/procfs/tree/master)
+
+Clone URL: [git://github.com/madhusudancs/procfs.git](git://github.com/madhusudancs/procfs.git)
+
+------
+
+ Progress
+----
+
+1. Packages Ported: [http://www.madhusudancs.info/parted-hurdi386 parted-1.7.1]
+2. Packages Porting in progress: autogen_1:5.9.4-1. Error installing texlive-bin. Error tracked to some post installation scripts of texlive-bin. Problem seems to be in fmutil. Trying to debug.
+3. Have to start coding libnetfs skeleton for procfs translator.
+
+**Target for next week**
+
+ Task To be completed by Status Now
+
+ 1. Finish Defining the necessary netfs call backs&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;25-05-2008&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Completed
+ 2. Create Directories for each process with pid directory name&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;27-05-2008&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Completed
+ 3. Create stat file for each process within this directory and<br/>
+ put atleast 1 information into it&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 31-05-2008&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;In Progress
+
+**Documentations Read/Reading**
+
+1. [Hurd Hacking Guide](http://www.gnu.org/software/hurd/hacking-guide/hhg.html) (Have Concentrated mainly on Translator part)
+2. [Linux Kernel Implementation of procfs](http://users.sosdg.org/~qiyong/lxr/source/Documentation/filesystems/proc.txt)
+
+**Code Being Read**
+
+1. libps
+2. libnetfs
+3. [procfs implementation in Linux kernel](http://users.sosdg.org/~qiyong/lxr/source/fs/proc/)
+4. ftpfs (In Hurd main)
+5. cvsfs (In Hurd extras)
+6. xmlfs (In Hurd extras)
+7. httpfs (In Hurd extras)
+8. gopherfs (In Hurd extras)
+9. libfuse (In Hurd extras)
+10. procfs (libtrivfs based, In Hurd extras)
+
+------
+
+ Post Mid-Term Road Map
+----
+
+
+####Already Implemented
+
+#####File - /proc/&lt;PID&gt;/stat
+
+* pid
+
+* comm
+
+* state
+
+* ppid
+
+* pgrp
+
+* session
+
+* tty_nr
+
+* tpgid
+
+* minflt
+> The number of minor faults the process has made which have not required loading a memory page
+> from disk.
+
+* majflt
+> The number of major faults the process has made which have required loading a memory page from
+> disk.
+
+* utime
+> The number of jiffies that this process has been scheduled in user mode.
+
+* stime
+> The number of jiffies that this process has been scheduled in kernel mode.
+
+* priority
+> The standard nice value, plus fifteen. The value is never negative in the kernel.
+
+* num_threads
+> Number of threads in this process.
+
+* starttime
+> The time in jiffies the process started after system boot.
+
+* vsize
+> Virtual memory size in bytes.
+
+* rss
+> Resident Set Size: number of pages the process has in real memory, minus 3 for administrative
+> purposes. This is just the pages which count towards text, data, or stack space. This does not
+> include pages which have not been demand-loaded in, or which are swapped out.
+
+* itrealvalue
+> The time in jiffies before the next SIGALRM is sent to the process due to an interval timer.
+
+* nswap
+> Number of pages swapped (not maintained).
+
+* cnswap
+> Cumulative nswap for child processes (not maintained).
+
+* flags
+> PF_* fields defined in (Not Linux compatible, but nearly says the something Linux says)
+
+* nice
+> The nice value ranges from 19 to -19.
+
+* cutime
+> The number of jiffies that this process’s waited-for children have been scheduled in user
+> mode.
+
+* cstime
+> The number of jiffies that this process’s waited-for children have been scheduled in kernel mode.
+
+#####File - /proc/&lt;PID&gt;/statm
+
+* size
+> total program size
+
+* resident
+> resident set size
+
+* lib
+> library
+
+* dt
+> dirty pages
+
+####I already know the where the information is exactly available.
+
+#####Other Per-PID Files
+
+#####* /proc/&lt;PID&gt;/exe
+
+#####* /proc/&lt;PID&gt;/environ
+
+#####Non Per-PID Files
+
+#####* /proc/version
+
+
+####I know where the information is available roughly, but need to look in detail to extract the exact information.
+
+* cminflt
+> The number of minor faults that the process’s waited-for children have made.
+
+* cmajflt
+> The number of major faults that the process’s waited-for children have made.
+
+* signal
+> The bitmap of pending signals.
+
+* blocked
+> The bitmap of blocked signals.
+
+* sigignore
+> The bitmap of ignored signals.
+
+* sigcatch
+> The bitmap of caught signals.
+
+* policy
+> Scheduling policy.
+
+#####File - /proc/&lt;PID&gt;/statm
+
+* text
+> text (code)
+
+#####Other Per-PID Files
+
+#####* /proc/&lt;PID&gt;/cwd
+
+####The information may be available, but needs to be searched to know where it will be.
+
+#####File - /proc/&lt;PID&gt;/stat
+
+* rlim
+> Current limit in bytes on the rss of the process (usually 4294967295 on i386).
+
+* startcode
+> The address above which program text can run.
+
+* endcode
+> The address below which program text can run.
+
+* startstack
+> The address of the start of the stack.
+
+* kstkesp
+> The current value of esp (stack pointer), as found in the kernel stack page for the process.
+
+* kstkeip
+> The current EIP (instruction pointer).
+
+* exit_signal
+> Signal to be sent to parent when we die.
+
+#####File - /proc/&lt;PID&gt;/statm
+
+* share
+> shared pages
+
+* data
+> data/stack
+
+#####Other Per-PID File
+
+#####* /proc/&lt;PID&gt;/root
+
+#####Non Per-PID Files
+
+#####* /proc/stat
+
+#####* /proc/meminfo
+
+####I fear information may not be available.
+
+#####File - /proc/&lt;PID&gt;/stat
+
+* wchan
+> This is the "channel" in which the process is waiting. It is the address of a system call, and
+> can be looked up in a namelist if you need a textual name. (If you have an up-to-date
+> /etc/psdatabase,
+
+* processor
+> CPU number last executed on.
+
+* rt_priority
+> Real-time scheduling priority
+
+* delayacct_blkio_ticks
+> Aggregated block I/O delays, measured in clock ticks (centiseconds).
+
+
+###Newly added to Roadmap(but these were the original goals of the project)
+
+#### procps tools need to be ported so that they run on top of the procfs
+
+> ##### pgrep&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;Done
+> ##### pkill&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;Done
+> ##### killall&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;Done
+> ##### pstree&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;Done
+> ##### top&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;Mostly Done (except per-PID shared memory field, and non per-PID caches and buffers field)
+> ##### free&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;Mostly Done (Ditto from above)
+> ##### htop&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;Mostly Done (Ditto again)
+> ##### watch&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;Done
+> ##### tload&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;I think it is done. (Need someone to test it)
+> ##### libgtop&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;In progress
+> ##### gnome-system-moitor&nbsp;&nbsp;&nbsp;-&nbsp;&nbsp;In progress
+
+
+
+------
+
+ Code Updates
+----
+
+1. May, 14, 2008
+2. May, 18, 2008
+3. May, 28, 2008
+4. June, 1, 2008
+5. June, 2, 2008
+6. June, 4, 2008
+7. June, 5, 2008 (3 commits, 00:30 HRS, 02:30 HRS, 11:15HRS, all in IST)
+8. June, 9, 2008
+9. June, 19, 2008 (Targets 1 and 2 successfully accomplished. Duration between the commits became inevitably longer because of the large amount of time spent on debugging the code.)
+
+------
+
+ Contact Details
+----
+
+Name : Madhusudan.C.S
+
+Email : [madhusudancs@gmail.com](mailto:madhusudancs@gmail.com)
+
+Blog : [http://www.madhusudancs.info](http://www.madhusudancs.info/)
+
+Detailed proposal: [http://www.madhusudancs.info/gnu-hurd-procfs-proposal](http://www.madhusudancs.info/gnu-hurd-procfs-proposal)
+
+Google Summer of Code Site Link: [Abstract](http://code.google.com/soc/2008/hurd/appinfo.html?csaid=D2E9266819D2EEF9)
+
+
diff --git a/user/scolobb.mdwn b/user/scolobb.mdwn
new file mode 100644
index 00000000..2de8eb4f
--- /dev/null
+++ b/user/scolobb.mdwn
@@ -0,0 +1,134 @@
+[[meta copyright="Copyright © 2008 Free Software Foundation, Inc."]]
+
+[[meta license="""[[toggle id="license" text="GFDL 1.2+"]][[toggleable
+id="license" text="Permission is granted to copy, distribute and/or modify this
+document under the terms of the GNU Free Documentation License, Version 1.2 or
+any later version published by the Free Software Foundation; with no Invariant
+Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license
+is included in the section entitled
+[[GNU_Free_Documentation_License|/fdl]]."]]"""]]
+
+# scolobb
+
+Sergiu Ivanov, interested non-student
+
+Mail: <mailto:unlimitedscolobb@gmail.com>
+
+Project: Namespace-based translator selection
+
+---
+
+## Current Task
+
+Write the filesystem proxy for namespace-based translator selection (*nsmux*).
+
+The code is at <http://github.com/scolobb/nsmux/tree/master>.
+
+---
+
+###Did this week
+
+* Modified the node cache so that it maintains shadow nodes alive.
+
+###Plans for the next week
+
+* Implement the shutting down of translator stacks when *nsmux* is asked to go away (in case **antrik** considers that necessary).
+
+* Make *nsmux* provide the access to the translator stack of the real node, in case a translator (mainly, a filter) should ask for its underlying node to be opened in O_NOTRANS mode.
+
+---
+
+###Current Status
+
+####DONE:
+
+* The skeleton which mirrors the filesystem.
+
+* Provide proxy nodes (modify the standard version of netfs_S_dir_lookup).
+
+####TODO:
+
+* Create the generic filtering translator.
+
+* Create the translator '0' (providing the untranslated version of the
+ node).
+
+* Create the "recursive wrappers" for one-node translators.
+
+* Create special translators for the main proxy so that its functionality
+ should be complete.
+
+* Implement sharing of dynamic translator stacks where possible.
+
+* Make dynamic translators go away as soon as they are not required.
+
+* Refine the skeleton in several places so that it should become faster
+ and more reliable.
+
+* Kill bugs.
+
+* Integrate nsmux upstream.
+
+* Solve the libtrivfs stacking issue.
+
+* Patch libnetfs (it does not support file_get_translator_cntl, for
+ instance).
+
+---
+
+###Progress
+
+####8: Fri Sep 19:
+
+> Modified the ncache so that it now maintains shadow nodes (and directory nodes too, it is a side effect at the moment) alive.
+
+####7: Sat Aug 30 - Fri Sep 5:
+
+> Added the code for shutting down dynamic translator stacks.
+
+####6: Mon Aug 4 - Fri Aug 29:
+
+> Implemented the proxy nodes.
+
+####5: Thu Jul 24 - Thu Jul 24:
+
+> Created a *libnetfs*-based one-node translator, working exactly like the *libtrivfs*-based translator I had written before; the former, however, can be included in a translator stack.
+
+####4: Tue Jul 22 - Thu Jul 24:
+
+> Attempted to make a *libtrivfs*-based translator to be able to be stacked upon itself (to be able to receive a translator on top of itself, more exactly); attempted to borrow some code from *libnetfs* but this didn't bring any results.
+
+####3: Sun Jul 20 - Tue Jul 22:
+
+> Implemented the possibility to propagate a translator on all files belonging to a directory 'dir' in the request of the type 'dir,,x/'.
+
+####2: Thu Jul 17 - Fri Jul 18:
+
+> Extended the lookup code in *nsmux* to allow for looking up nodes like 'file,,x' and added the possibility to escape the double-comma in the following way: ',,,'.
+
+####1: Mon Jul 12 - Tue Jul 13:
+
+> Implemented a simple *libtrivfs*-based translator to test the lookup code for *nsmux*.
+
+####0: Sat Jul 12 - Sat Jul 12:
+
+> Made small changes to the code of *filterfs* to fit the needs of *nsmux*.
+
+---
+
+## Completed Tasks
+
+####2: Sat May 3 - Fri Jul 17:
+
+> Write a translator that should filter the contents of the directory it is set on according to some property. The property can be an arbitrary command.
+
+> The code is at <http://github.com/scolobb/filterfs/tree/master>.
+
+####1: Mon Apr 28 - Wed Apr 30:
+
+> Wrote a Python extension module in C for retreiving the uptime. The module is based on the code of *w*.
+
+####0: Sun Apr 27:
+
+> Followed the code of *dmesgd* (<http://www.bddebian.com/junk/dmesgd/>) kindly offered by **bddebian** and rewrote it from scratch as a tutorial.
+
diff --git a/user/zhengda.mdwn b/user/zhengda.mdwn
new file mode 100644
index 00000000..e15aade1
--- /dev/null
+++ b/user/zhengda.mdwn
@@ -0,0 +1,110 @@
+# Zheng Da
+
+Email: zhengda1936 at gmail dot com
+
+Project: Network virtualization for subhurds etc.
+
+The [code](http://www.assembla.com/spaces/VNetHurd/trac_subversion_tool).
+
+The [[howto]] shows the instructions of setting up the virtual network in hurd and subhurd.
+
+---
+
+## The design and the implementation
+
+### The requirements:
+* to implement a mechanism which help pfinet servers communicate with each other. For example, if pfinet 1 has IP A and pfinet 2 has IP B, the packet sent by pfinet 1 with destination address IP B should be received by pfinet 2.
+* Sub-hurd should be able to use this mechanism to communicate with each other.
+* Meanwhile this mechanism should allow non-privileged the user to start his own pfinet.
+
+
+### The possible approach is to use the multiplexer and the filter.
+The multiplexer's roles are:
+
+1. to create some virtual network interface, so pfinet can send packets to it.
+2. to receive the packet from pfinet, and forward the packet to other pfinets in hurd
+3. or forward the packet to the real network device in the kernel and send it to the network.
+
+A filter translator is needed to enforce the policies between the interface and the pfinet server. For example, the filter can control which packets can be delivered to the pfinet server, and which packets can be sent to the network interface. The filter can also guard the network traffic and drop illegal packets (forged by some malicious users) from pfinet or some other programs.
+
+
+### To create a virtual network interface:
+* Implement the RPC interface defined in device.defs.
+* The multiplexer works as a translator and other programs can get the port to it by calling file_name_port().
+* Other programs can use this port as a master device port to open the virtual interface.
+
+
+### The routing inside the multiplexer:
+* when the multiplexer gets a packet, it forwards it to every interface.
+* BPF is ported to the multiplexer. BPF delivers the packet to the right pfinet (according to the filter set by the pfinet) just as the BPF in Mach does.
+* All packets are forwarded to the interface which the multiplexer sits on.
+
+
+### The implementation of the filter translator:
+* The filter works as a proxy, forwarding the packet between the interface and the pfinet server.
+* BPF is also ported to the filter translator. There are two filers in the translator, one for outgoing packets, the other for incoming packets.
+* Only one pfinet can connect to the translator at a time.
+
+
+---
+
+## TODO
+### Coding
+
+ - make subhurds running without root privileges
+ - merge BPF rules from the filter translator and the multiplexer
+
+---
+
+## Completed tasks
+
+### Coding
+
+The patch of glibc (pfinet server overriding) is [here](http://www.assembla.com/spaces/VNetHurd/documents/aJidqKp6ur3z-Nab7jnrAJ/download/A%20patch%20of%20glibc).
+
+The patch of pfinet (open the virtual network interface) is [here](http://www.assembla.com/spaces/VNetHurd/documents/aWqYwYATKr3BBOab7jnrAJ/download/patch%20of%20pfinet%201%20(to%20use%20the%20virtual%20interface)).
+
+The patch of pfinet (fix pfinet to use the proper filter rule) is [here](http://www.assembla.com/spaces/VNetHurd/documents/besb-qATKr3AIxab7jnrAJ/download/patch%20of%20pfinet%202%20(to%20add%20an%20IP%20filter)).
+
+The patch of pfinet (set the mach device in the promiscuous mode) is [here](http://www.assembla.com/spaces/VNetHurd/documents/bEovN6ATKr3B8uab7jnrAJ/download/patch%20of%20pfinet%203%20(to%20set%20the%20mach%20device%20into%20the%20promiscuous%20mode)).
+
+The patch of boot (open the virtual network interface) is [here](http://www.assembla.com/spaces/VNetHurd/documents/cWkeEixHar3AdKab7jnrAJ/download/A%20patch%20of%20boot).
+
+The patch of gnumach (set the network device into the promiscuous mode) is [here](http://www.assembla.com/spaces/VNetHurd/documents/b0eLzUxHmr3ymXab7jnrAJ/download/A%20patch%20of%20gnumach).
+
+the multiplexer:
+
+- Create multiple virtual network interfaces.
+- Port BPF to the multiplexer.
+- Finish the routing among the pfinet servers.
+
+the filter translator:
+
+- Forward the packet between the interface and the pfinet server.
+- Filter the packet.
+
+the proxy of the proc server:
+
+- Forward all requests from the process to its proc server.
+- The proxy doesn't do any real work except returning the host private port and the master device port of the proxy (shown as an example).
+
+the devnode translator:
+
+- Create a device file to help open the network device.
+
+
+### The Code Read
+
+- boot
+
+### Documentation Read
+
+
+- [A Programmer's Guide to the Mach System Calls](ftp://ftp.cs.cmu.edu/afs/cs/project/mach/public/doc/unpublished/machsys.doc)
+- [Meet Mach](http://www.stepwise.com/Articles/Technical/MeetMach.html) by James Scott
+- [A Programmer's Guide to the Mach User Environment](ftp://ftp.cs.cmu.edu/afs/cs/project/mach/public/doc/unpublished/machuse.doc), the MIG part
+- Part of The GNU Mach Reference Manual and The GNU Hurd Reference Manual
+- The Hurd, a presentation by Marcus Brinkmann
+- Towards a New Strategy of OS Design, an architectural overview by Thomas Bushnell, BSG.
+- GNU/Hurd User's Guide
+- The Hurd Hacking Guide
diff --git a/user/zhengda/howto.mdwn b/user/zhengda/howto.mdwn
new file mode 100644
index 00000000..3f0d0d13
--- /dev/null
+++ b/user/zhengda/howto.mdwn
@@ -0,0 +1,95 @@
+[[meta copyright="Copyright © 2008 Free Software Foundation, Inc."]]
+
+[[meta license="""[[toggle id="license" text="GFDL 1.2+"]][[toggleable
+id="license" text="Permission is granted to copy, distribute and/or modify this
+document under the terms of the GNU Free Documentation License, Version 1.2 or
+any later version published by the Free Software Foundation; with no Invariant
+Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license
+is included in the section entitled
+[[GNU_Free_Documentation_License|/fdl]]."]]"""]]
+
+
+This document briefly introduces how to set up the virtual network and connect the subhurd with the main hurd.
+
+
+### 1. Set up the virtual network.
+
+####1.1 Patch and install GNU Hurd, GNU Mach and the GNU C library.
+
+Step 1: Get the Hurd and compile it.
+
+ cvs -z3 -d:ext:username@cvs.savannah.gnu.org:/sources/hurd co -r zhengda-soc2008-virt-branch
+
+
+Step 2: apply the [patch](http://www.assembla.com/spaces/VNetHurd/documents/b0eLzUxHmr3ymXab7jnrAJ/download/A%20patch%20of%20gnumach) on the GNU Mach.
+
+In order to connect the virtual network created in hurd with the external network, we need this patch. It enables the Hurd to set the Mach device into the promiscuous mode, so the real device can accept the packet that goes to the virtual device in hurd.
+(This step is optional if we are only interested in creating a internal virtual network.)
+
+Step 3: apply the [patch](http://www.assembla.com/spaces/VNetHurd/documents/aJidqKp6ur3z-Nab7jnrAJ/download/A%20patch%20of%20glibc) on glibc.
+
+This patch enables the user to override the default socket server by using the environment variables SOCK_SERV_DIR or SOCK_SERV_%d (%d is the domain of the socket server).
+
+
+#### 1.2 Set up the Hurd components to build the virtual network.
+
+In this section, I show how to create two virtual interfaces and run three pfinet servers. I assume that the source code of Hurd is in /root/hurd.
+
+Step 4: create the network device file in /dev with devnode.
+The network device file is used to help other translators open the device.
+
+ # settrans -acfg /dev/eth0 /root/hurd/devnode/devnode -d eth0
+
+Step 5: create the virtual network device with eth-multiplexer.
+
+eth-multiplexer is responsible to create the virtual network device and dispatch the packet to the right clients that connect to the virtual device. It also connects the virtual network and the external network.
+
+ # settrans -acfg /root/multiplexer /root/hurd/eth-multiplexer/eth-multiplexer -v 2 -i /dev/eth0
+
+Step 6: create the network device files for the virtual network device with devnode.
+
+ # settrans -acfg /dev/veth0 /root/hurd/devnode/devnode -d veth0 -M /root/multiplexer
+ # settrans -acfg /dev/veth1 /root/hurd/devnode/devnode -d veth1 -M /root/multiplexer
+
+Step 7: setup the filter translator eth-filter on the network device. This step is optional.
+eth-filter is used to set up the traffic policy on the network device.
+
+ # settrans -acfg /dev/fveth0 /root/hurd/eth-filter/eth-filter -i /dev/veth0 -S 192.168.8.0/24 -R 192.168.8.0/24
+ # settrans -acfg /dev/fveth1 /root/hurd/eth-filter/eth-filter -i /dev/veth1 -S 192.168.8.0/24 -R 192.168.8.0/24
+
+Step 8: setup the pfinet server on the virtual network device.
+
+ # settrans -afgc /root/socket0/2 /root/hurd/pfinet/pfinet -i /dev/fveth0 -a 192.168.8.10 -g 192.168.8.1 -m 255.255.255.0
+ # settrans -afgc /root/socket1/2 /root/hurd/pfinet/pfinet -i /dev/fveth1 -a 192.168.8.11 -g 192.168.8.1 -m 255.255.255.0
+ # settrans -afgc /root/socket2/2 /root/hurd/pfinet/pfinet -i /dev/fveth1 -a 192.168.8.12 -g 192.168.8.1 -m 255.255.255.0
+
+
+#### 1.3 Run the command with the customized pfinet server.
+
+Step 9: Set environment variables to use the customized pfinet server.
+
+The environment variable of SOCK_SERV_DIR is used to override all socket servers and SOCK_SERV_%d to override a specific socket server. %d after SOCK_SERV_ is the domain of the protocol that the socket server supports. The environment variable SOCK_SERV_%d has the higher priority than SOCK_SERV_DIR.
+
+ # export SOCK_SERV_2=/root/socket1/2
+
+If the modified glibc isn't installed as the system default C library, set LD_LIBRARY_PATH environment.
+
+ # export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/the/path/of/glibc
+
+We can run any command now, for example, ping.
+
+A SHELL script is provided to run all translators I mentioned automatically: http://www.assembla.com/spaces/VNetHurd/documents/c2W71ABser3AIxab7jnrAJ/download/runmultiplexer. To use this script, the user must specify the source of the hurd tree (the default value is /root/hurd) and the path of the servers (the default value is /root) where they should be created. This script is only used to test all translators I mentioned above and shows all steps to set up the virtual network.
+
+
+### 2. Connect the subhurd with the main hurd.
+
+In the main hurd, we still need to do Step 1-9.
+We run subhurd,
+
+ # /root/hurd/boot/boot -m eth0=/dev/fveth0 -m eth1=/dev/fveth1 servers.boot /dev/hd1s1
+
+In the subhurd, we do Step 1, 4, 8.
+Step 4: # settrans -acfg /dev/veth0 /root/hurd/devnode/devnode -d veth0
+Step 8: # settrans -afgc /servers/socket/2 /root/hurd/pfinet/pfinet -i /dev/veth0 -a 192.168.8.20 -g 192.168.8.1 -m 255.255.255.0
+
+Now we can communicate from the subhurd with any pfinet server of the main Hurd that runs in the virtual network.