From owner-freebsd-hackers@FreeBSD.ORG Sat Jul 29 20:47:42 2006 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7D13416A4DA for ; Sat, 29 Jul 2006 20:47:42 +0000 (UTC) (envelope-from dan@dan.emsphone.com) Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by mx1.FreeBSD.org (Postfix) with ESMTP id 25D9F43D49 for ; Sat, 29 Jul 2006 20:47:42 +0000 (GMT) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.13.1/8.13.4) id k6TKlfQh063868; Sat, 29 Jul 2006 15:47:41 -0500 (CDT) (envelope-from dan) Date: Sat, 29 Jul 2006 15:47:41 -0500 From: Dan Nelson To: Jaye Mathisen Message-ID: <20060729204741.GD15827@dan.emsphone.com> References: <20060729034359.GL15569@main.mathisen.org> <20060729041848.GC15827@dan.emsphone.com> <20060729061653.GM15569@main.mathisen.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20060729061653.GM15569@main.mathisen.org> X-OS: FreeBSD 5.5-PRERELEASE X-message-flag: Outlook Error User-Agent: Mutt/1.5.12-2006-07-14 Cc: hackers@freebsd.org Subject: Re: fdescfs functional in 6.1? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Jul 2006 20:47:42 -0000 In the last episode (Jul 28), Jaye Mathisen said: > On Fri, Jul 28, 2006 at 11:18:48PM -0500, Dan Nelson wrote: > > In the last episode (Jul 28), Jaye Mathisen said: > > > s2# mount -t fdescfs fdescfs /dev/fd > > > s2# ls -l /dev/fd > > > total 16 > > > crw--w---- 1 root tty 5, 1 Jul 28 18:01 0 > > > crw--w---- 1 root tty 5, 1 Jul 28 18:01 1 > > > crw--w---- 1 root tty 5, 1 Jul 28 18:01 2 > > > d-w------- 1 mailnull mailnull 512 Jul 23 00:01 3 > > > d--------- 1 root wheel 512 Jul 25 03:25 4 > > > s2# umount /dev/fd > > > > > > This thing is all over the map.. permissions changed, a *directory* > > > for fd's 3 and 4? > > > > What do you expect ls to open to print a *directory* listing? :) > > > > fd's 0, 1, and 2 are /dev/tty, and the permissions look fine. > > > > fd 3 is your current directory (so I guess you're in some smtp-related > > directory?), and fd 4 is the directory on the commandline (/dev/fd). > > > > I guess I just expected it to print all character device entries for > the file descriptors open by my process. fdescfs prints all file desriptors open by your process, and displays the correct info for each of them. > Kind of like the old /dev/fd/1 /dev/fd/2 directories used to be under > MAKEDEV... Before devfs, /dev/fd was populated with dummy entries from 0 to 63 and running ls on the directory had no correspondence with what your process actually had open. -- Dan Nelson dnelson@allantgroup.com