Doors -- a new file type under Solaris 2.5

Doors -- a new file type under Solaris 2.5

Post by Bart Smaalde » Thu, 18 Jul 1996 04:00:00




Quote:

>Hello,

>shortly, one of my scripts failed under Solaris 2.5 due to a strange
>looking file named

>   /etc/.name_service_door

>which turned out to be of a newly introduced file type named door (see
>S_IFDOOR in /usr/include/sys/stat.h). The associated documentation is
>nearly non-existant (see door(2)) and just states that it is
>intentionally undocumented because it represents a new IPC mechanism
>which is subject to future changes (or to be removed). This mechanism
>is used at least for one new daemon named nscd which improves some name
>server lookups by caching it.

>Neither door(2) nor one of the other manual pages mention or document
>the new file type -- just /usr/include/sys/stat.h has a macro for it.
>Likewise, neither ls nor any other commands seem to honor this new
>file type.

>The general questions are:

>- Why introducing now just another IPC mechanism, and

Doors provides a very fast (30 usec round trip) inherently threaded
ipc mechanism.  Doors were developed as part of Spring and have
been adapted to Solaris.  In 2.6 the API has been changed and made
publicly usable.  Note that a door call to a server causes the caller's
lwp to effectively begin execution in the server's address space
as a user level thread.  This thread can retrieve the caller's
unix credentials, so it is possible to replace many setuid programs
with a doors-based daemon.  The nscd uses this feature to serve
as it's own administration tool and secure allow only root to perform
certain actions.

Quote:>- why creating a new file type?

The door is attached to a file via a fattach call.  A door is not
a socket or a pipe or a directory or ..., so it gets a new type.

Quote:

>The latter breaks upward-compatibility for many tools (GNU-tar,
>for example, returns a non-zero exit status).

This argument would preclude us from ever introducing a new file
type...  perhaps some of these tools should anticipate change and
assume that this will happen over time.

Quote:

>Further, following questions arise:

>- Are ncsd and /etc/.name_service_door the only instances of this
>  new mechanism?

In 2.5 and 2.5.1, yes.  Given the advantages of doors, I expect
them to be used widely.

Quote:

>- Are ncsd or clients of ncsd able to create this file on their
>  own if it is missing, or, if not, how to create such nodes,
>  i.e. is mknod(2) able to do the job?

The nscd creates this file as needed at startup eg boot.  It's just
a regular empty file with a door "fattached" onto it...

 - Bart

"I wrote the nscd..."

---
Bart Smaalders                  Solaris Clustering      SunSoft

http://playground.sun.com/~barts                   2550 Garcia Ave
                                                        Mt View, CA 94043-1100

 
 
 

Doors -- a new file type under Solaris 2.5

Post by Andreas Borche » Thu, 18 Jul 1996 04:00:00


Hello,

shortly, one of my scripts failed under Solaris 2.5 due to a strange
looking file named

   /etc/.name_service_door

which turned out to be of a newly introduced file type named door (see
S_IFDOOR in /usr/include/sys/stat.h). The associated documentation is
nearly non-existant (see door(2)) and just states that it is
intentionally undocumented because it represents a new IPC mechanism
which is subject to future changes (or to be removed). This mechanism
is used at least for one new daemon named nscd which improves some name
server lookups by caching it.

Neither door(2) nor one of the other manual pages mention or document
the new file type -- just /usr/include/sys/stat.h has a macro for it.
Likewise, neither ls nor any other commands seem to honor this new
file type.

The general questions are:

- Why introducing now just another IPC mechanism, and

- why creating a new file type?

The latter breaks upward-compatibility for many tools (GNU-tar,
for example, returns a non-zero exit status).

Further, following questions arise:

- Are ncsd and /etc/.name_service_door the only instances of this
  new mechanism?

- Are ncsd or clients of ncsd able to create this file on their
  own if it is missing, or, if not, how to create such nodes,
  i.e. is mknod(2) able to do the job?

Andreas.

--
Andreas Borchert, Universitaet Ulm, SAI, Helmholtzstr. 18, 89069 Ulm,  Germany

WWW:    http://www.mathematik.uni-ulm.de/sai/borchert/


 
 
 

Doors -- a new file type under Solaris 2.5

Post by Alan L. Stang » Sat, 20 Jul 1996 04:00:00



> "I wrote the nscd..."

As long as we're talking about nscd, I think it's great as it
certainly is offloading the DNS servers.  But, here is the line
from "top" for nscd on our main e-mail hub.

 5256 root      28    0   36M   12M sleep  15:50  0.13%  0.05% nscd

36M virtual, 12M resident.

I don't mind the size as we have memory to spare.  I just want to make
sure that it's not unbounded :-)

--

 
 
 

Doors -- a new file type under Solaris 2.5

Post by Greg Linda » Sun, 21 Jul 1996 04:00:00



Quote:>As long as we're talking about nscd, I think it's great as it
>certainly is offloading the DNS servers.  But, here is the line
>from "top" for nscd on our main e-mail hub.

> 5256 root      28    0   36M   12M sleep  15:50  0.13%  0.05% nscd

>36M virtual, 12M resident.

>I don't mind the size as we have memory to spare.  I just want to make
>sure that it's not unbounded :-)

I suppose you didn't notice the memory leak in Sun's named?

If you look in the nscd.conf manpage, it seems that you can set some
things that will bound memory usage.

 
 
 

Doors -- a new file type under Solaris 2.5

Post by Davin Mil » Tue, 30 Jul 1996 04:00:00


?"I wrote the nscd..."

Ok - then let me ask a question.

We have some DNS hostnames that are using the round-robin feature of the
newer DNS servers (in order to do some vague load balancing over a set of
SS20s).  They have the TTL in the DNS entries set down to 0, so that the
hostname is never cached by DNS servers, so that each lookup is able to
return a (possibly) different IP address.

nscd defeats this mechanism. :-(

Is there any way to have nscd look at the DNS TTL field, and cache (or not
cache) specific hostnames accordingly?  Maybe in the next version?

Or is disabling hosts caching the only solution?

Thanks.
Davin.
--

               Fax:       (716) 645-3464
               WWW:       http://www.cs.buffalo.edu/~milun/

 
 
 

1. Install a new file system type on VFS in Solaris 2.5 ?

Dear all,

        We are working in a new file system type and we want now to port it to Solaris
2.5, but we don't have too much experience with system V like operating
systems.

        We are looking for information about how to do it, specially with respect to
Solaris 2.5 internal interfaces, debugging techniques ...

Please if you have worked in related topics, I would appreciate any help,

thanks in advance ...
                                                        Juanjo,
   ____________________________________________________________________
        Juan Jos'e P'erez Segado / DATSI         Voice: +34 1 336 7450
        Facultad de Informatica / UPM            Alter: +34 1 336 7376
        E-28660 Boadilla del Monte                 Fax: +34 1 336 7373

        WWW page:  http://laurel.datsi.fi.upm.es/~jsegado/jsegado.html

2. My new home brew computer

3. Solaris 2.5 door interface - how to create .file???

4. Courier New fonts in X

5. What is a file type of door used for in Solaris 8

6. Switching Between ISP's

7. File type "door" on Solaris

8. Backup Device for LINUX

9. Solaris 2.5 won't render extra Type-1 fonts

10. JetAdmin, Solaris 2.5 & "Unkown link type" error mesg.

11. FS: Solaris 2.5 Desktop (CDE) and/or Solaris 2.5 Server Packages for x86 desktops

12. Q: adding Type 1 fonts to Solaris 2.5 OpenWindows

13. Solaris 2.5 system file table and file lock info for alerting on thresholds