From owner-freebsd-current Thu Mar 13 13:26:12 2003 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 91F2937B401 for ; Thu, 13 Mar 2003 13:26:10 -0800 (PST) Received: from paladin.fortunaty.net (fortunaty.net [217.160.129.175]) by mx1.FreeBSD.org (Postfix) with SMTP id 67A6E43F85 for ; Thu, 13 Mar 2003 13:26:09 -0800 (PST) (envelope-from ah@paladin.fortunaty.net) Received: (qmail 18788 invoked by uid 501); 13 Mar 2003 21:26:08 -0000 Date: Thu, 13 Mar 2003 22:26:08 +0100 From: Andy To: Poul-Henning Kamp Cc: freebsd-current@FreeBSD.ORG Subject: Re: MAKEDEV lost in 5.0-CURRENT? Message-ID: <20030313212608.GA15179@splashground.de> Mail-Followup-To: Poul-Henning Kamp , freebsd-current@FreeBSD.ORG References: <20030313111027.GA13250@splashground.de> <1678.1047555924@critter.freebsd.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: <1678.1047555924@critter.freebsd.dk> User-Agent: Mutt/1.4i X-Addicted: yeah X-License: BSD Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Mar 13, 2003 at 12:45:24PM +0100, Poul-Henning Kamp wrote: > In message <20030313111027.GA13250@splashground.de>, Andy writes: > >On Wed, Mar 12, 2003 at 12:18:08PM -0500, Hiten Pandya wrote: [...] > >On 5.0-RELEASE-p4 I have > >/usr/src/etc/MAKEDEV > >and i use it for making the devices in jails. > >Is there a jail devfs or is the way described in the > >jail(8) man page still the right(tm) one? > > See devfs(8) After reading it it seems the answer is "no" there is no special jail devfs, but you can create your own rules for a jail. More informative on this subject was /usr/share/doc/papers/devfs.ascii.gz which i quote here: ----8<---- These behaviours will be controlled with mount options, but these have not yet been implemented because FreeBSD has run out of bitmap flags for mount options, and a new unlimited mount option implementation is still not in place at the time of writing. One mount option ``jaildevfs'', will restrict the contents of the DEVFS mount- point to the ``normal set'' of devices for a jail and automatically hide all future devices and make it impossible for a jailed root to un-hide hidden entries while letting an un-jailed root do so. ---->8---- OK. What a pity. So we have to create our own, based on "MAKEDEV jail" maybe: 100 path * hide 200 path tty* unhide 300 path random unhide 400 path zero unhide 500 path null unhide 600 path fd/* unhide 700 path mdctl unhide 800 path ptyp* unhide Now the problem is ptyp* and mdctl don't show up, even so they got unhidden. Also symlinking seems to require special actions: $ ln -s null mem $ echo mem* mem mem $ ls -la mem* ls: mem: No such file or directory ls: mem: No such file or directory Obviously some magick happens with hidden devices, so how can you make those links or don't we need them anymore? Andy To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message