From owner-freebsd-hackers Wed Jul 1 05:47:56 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id FAA11912 for freebsd-hackers-outgoing; Wed, 1 Jul 1998 05:47:56 -0700 (PDT) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from terra.Sarnoff.COM (terra.sarnoff.com [130.33.11.203]) by hub.freebsd.org (8.8.8/8.8.8) with SMTP id FAA11905 for ; Wed, 1 Jul 1998 05:47:55 -0700 (PDT) (envelope-from rminnich@Sarnoff.COM) Received: (from rminnich@localhost) by terra.Sarnoff.COM (8.6.12/8.6.12) id IAA23084; Wed, 1 Jul 1998 08:46:45 -0400 Date: Wed, 1 Jul 1998 08:46:45 -0400 (EDT) From: "Ron G. Minnich" X-Sender: rminnich@terra To: "Jordan K. Hubbard" cc: hackers@FreeBSD.ORG Subject: Re: Anyone interested in an "interesting" project idea? In-Reply-To: <11704.899261964@time.cdrom.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG jordan proposes: > typedef struct _pid_t { u_int hostid : 8; u_int pid : 24; } pid_t; And the you fix things so that there is a "route" between the hostid and the ip address. Then you fix commands so they can handle it. You can do this, but 8 bits is too small. I have a solution that has worked much more nicely for me, using the private name space code I have working. Namely, you mount into your name space as follows: /proc/ is from :/proc and so on, for any and all hosts you are interested in. To get status of all procs on all the machines, you just cat /proc/*/*/status Then you can have a ps that understands how to do this too. No 8-bit limits, no need for sysadmin involvment, and in fact every user can build their own /proc tree for their needs. Obviously the sysadmin builds one which includes his machines of interest. So if we could change the format of /proc as follows: /proc/, where the default is /proc/localhost and other hosts come in as needed, then you don't need to change pid formats, and yet you get something that is very fast. /proc/localhost is the moral equivalent in hosts of /proc/curproc. To see who you are, look at /proc/localhost/curproc Also, the "global /proc" is in fact a specialized instance of a very general mechanism. No special mods needed. Lots of other potential uses. This is working now in user mode on freebsd, and user and kernel on linux. What I desperately need is help, so if anyone is interested, let me know. Oh yes: since it is private name spaces, the usual NFS problems need not (and do not) apply. Which is why I did this stuff in the first place. Second oh yes: to control a set of procs across the cluster, obviously you write to /proc//pid/ctl. ron Ron Minnich |Java: an operating-system-independent, rminnich@sarnoff.com |architecture-independent programming language (609)-734-3120 |for Windows/95 and Windows/NT on the Pentium ftp://ftp.sarnoff.com/pub/mnfs/www/docs/cluster.html To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message