[Netnice-kernels] NNFS was: Re: Sourceforge Account
Status: Alpha
Brought to you by:
taost6
From: Scott B. <sco...@ve...> - 2004-09-28 15:55:31
|
On Tue, 28 Sep 2004, Takashi Okumura wrote: > hi, > > thanks for the message. i feel better by a message like that, because > i can sense your progress :-) > > > I will need to see if I can simply modify the existing /proc in order > > to support the socket files without having to add process ids to nnfs. > > i actually do not understand your question. you may reuse code from > linux-procfs, as much as you want, as log as your NNFS follows the > specification of NNFS. > > you may send the question to the kernel ML, because others may have > good answers. > > thanks! > > > -- taka > Hi Takashi, When I ask this question I am referring to the API description on the web page at http://www.netnice.org/pukiwiki-e.php?API%20overview . There is an illustration and text description under the heading 'File System Representation' . Mounted directly under /proc is the nnfs network/ directory which holds the VIF interfaces themselves. However under /proc are directories corresponding to the PIDs of running processes and under them are sockets/ directories that contain links to the VIF interfaces under network/. I am new to this project so my understanding may be wrong, but to create this structure on linux my idea is to create the nnfs network/ directory and mount it and then modify the existing /proc adding a sockets/ virtual directory under each PID and under each sockets/ directory establish links to the VIF interface under network/ . From the text description on the web page I read: A directory under /proc/network/ represents a VIF. ... Then, in the next paragraph: Directories under /proc/[pid]/ are process entries, as usual. We added a sockets directory under each process entry. ... On Linux, /proc/[pid] exists and it has been my intention to figure out if a sockets directory can be added under each one. Now maybe this will not be possible due to the design of linux procfs but at this point I have not seen that it is not possible to create this sockets directory. Now, from your response, I am reasoning that your approach here would be to copy the code from linux procfs that exposes the PIDS and put that code into the new nnfs thus creating a directory structure under the new nnfs that contains both the VIFS and the PIDs that are using the VIFS. This structure is different from the illustration and the high level description of the API as far as I can tell. However, I am just starting out here and trying to get up to speed quickly so I am perhaps rushing my understanding. I am CC'ing sending this reply to netnice-kernels so perhaps someone there can set me straight. Thanks, Scott Brumbaugh |