Unix
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
Go Back   Web Development Archives Mailing Lists Unix

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Web Development Archives Sponsor:
  #1  
Old June 24th, 2008, 05:30 PM
zhengda
Guest
Dev Archives Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
A proxy of the proc server for translators

Hi everyone,

I want to write a proxy of the proc server (proc_proxy), so I can
provide a pseudo master device port to the translator without changing
its code.

My first idea was to create a message server which handles all RPCs in
process.defs. When a request comes, the message server calls the
corresponding RPC to the real process server.
The proxy forks a child process, override the proc port of the child
process to point to itself so the proxy can get the request from the
child process, and executes the user's command in the child process.
For example, to run a pfinet server, the command can be like this:
proc_proxy settrans -afgpc /root/socket2/2 /root/hurd/pfinet/pfinet -i
eth0 -a 192.168.2.11 -g 192.168.2.1 -m 255.255.255.0

There are some problems:
1. the proxy does override the proc port of the child process where runs
settrans, but it seems the translator still uses the original proc
server. The task of the translator is created directly by task_create()
so it doesn't inherit the proc server from its parent. I still haven't
find the code where the proc server is set in the process of the translator.
2. when the proc server gets the request, it is always looking for the
process information from the remote port of the caller. When an RPC is
forwarded by the proxy, the process information of the proxy is changed
and the real proc server still doesn't know anything about the process
who sends the request.
3. If the translator is set in the passive mode, it is started by the
file system server. It seems that I don't have a chance to override its
proc server.

Maybe I can run a second proc server for the translator, and change the
master device port in the second proc server. However, the translator is
completely isolated from other processes and this solution still cannot
solve Problem 3 as I mentioned above.
I'm totally lost. Could anyone give me some ideas?

Best,
Zheng Da

Reply With Quote
Reply

Viewing: Web Development Archives Mailing Lists Unix > A proxy of the proc server for translators


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway