From owner-freebsd-arch Sun Jun 17 0:18:48 2001 Delivered-To: freebsd-arch@freebsd.org Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by hub.freebsd.org (Postfix) with ESMTP id 794C137B401; Sun, 17 Jun 2001 00:18:44 -0700 (PDT) (envelope-from imp@harmony.village.org) Received: from harmony.village.org (localhost.village.org [127.0.0.1]) by harmony.village.org (8.11.3/8.11.1) with ESMTP id f5H7IhV45149; Sun, 17 Jun 2001 01:18:43 -0600 (MDT) (envelope-from imp@harmony.village.org) Message-Id: <200106170718.f5H7IhV45149@harmony.village.org> To: obrien@FreeBSD.ORG Subject: Re: first cut at /etc/rc.d diff Cc: freebsd-arch@FreeBSD.ORG In-reply-to: Your message of "Sat, 16 Jun 2001 01:03:49 PDT." <20010616010349.A40011@dragon.nuxi.com> References: <20010616010349.A40011@dragon.nuxi.com> Date: Sun, 17 Jun 2001 01:18:43 -0600 From: Warner Losh Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <20010616010349.A40011@dragon.nuxi.com> "David O'Brien" writes: : All this patch does is add FreeBSD ID's. Some members of the NetBSD community may freak out at this. I added $FreeBSD$ to the pccard stuff to indicate where I'd merged to and one person just freaked. Turned into a big pita, but in the end precident was set and it remained. Just a warning. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Jun 17 0:23:25 2001 Delivered-To: freebsd-arch@freebsd.org Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by hub.freebsd.org (Postfix) with ESMTP id E91E937B403 for ; Sun, 17 Jun 2001 00:23:15 -0700 (PDT) (envelope-from imp@harmony.village.org) Received: from harmony.village.org (localhost.village.org [127.0.0.1]) by harmony.village.org (8.11.3/8.11.1) with ESMTP id f5H7NAV45188; Sun, 17 Jun 2001 01:23:11 -0600 (MDT) (envelope-from imp@harmony.village.org) Message-Id: <200106170723.f5H7NAV45188@harmony.village.org> To: assar@stacken.kth.se Subject: Re: kern/17613: impossible to build FS KLD without kernel source Cc: freebsd-arch@FreeBSD.ORG In-reply-to: Your message of "08 Jun 2001 14:11:17 +0200." <5l3d9buq6y.fsf@assaris.sics.se> References: <5l3d9buq6y.fsf@assaris.sics.se> <5512.991994609@critter> Date: Sun, 17 Jun 2001 01:23:10 -0600 From: Warner Losh Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <5l3d9buq6y.fsf@assaris.sics.se> assar@stacken.kth.se writes: : My proposed way of solving this is by having include/Makefile generate : this file so that it can be installed, along the lines of the patch : below. Comments? I don't think it is a good idea. You need to have the kernel sources to build loadable modules. This is the camel's nose, and there's a lot more camel after this one file. What about all the _if.h files? No, this path lies madness, imho. The bsd.kmod.mk/kmod.mk already deals with this properly. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Jun 17 2: 8:48 2001 Delivered-To: freebsd-arch@freebsd.org Received: from axl.seasidesoftware.co.za (axl.seasidesoftware.co.za [196.31.7.201]) by hub.freebsd.org (Postfix) with ESMTP id 8C97837B410; Sun, 17 Jun 2001 02:08:38 -0700 (PDT) (envelope-from sheldonh@starjuice.net) Received: from sheldonh (helo=axl.seasidesoftware.co.za) by axl.seasidesoftware.co.za with local-esmtp (Exim 3.22 #1) id 15BYXy-0004Io-00; Sun, 17 Jun 2001 11:08:42 +0200 From: Sheldon Hearn To: obrien@freebsd.org Cc: freebsd-arch@freebsd.org Subject: Re: `rcorder' patch In-reply-to: Your message of "Sat, 16 Jun 2001 00:52:05 MST." <20010616005205.A39714@dragon.nuxi.com> Date: Sun, 17 Jun 2001 11:08:42 +0200 Message-ID: <16541.992768922@axl.seasidesoftware.co.za> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sat, 16 Jun 2001 00:52:05 MST, "David O'Brien" wrote: > This is the patch I sent to a NetBSD contact to see if they are willing > to apply this to their sources. Was the NetBSD contact Luke Mewburn, the guy Doug Barton and I have been chatting to about this import? If not, please make sure you chat to Luke, who's very keen on NetBSD and FreeBSD staying "near" each other on this one. Ciao, Sheldon. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Jun 17 11:23:20 2001 Delivered-To: freebsd-arch@freebsd.org Received: from winston.osd.bsdi.com (adsl-64-173-15-98.dsl.sntc01.pacbell.net [64.173.15.98]) by hub.freebsd.org (Postfix) with ESMTP id 31A5337B407; Sun, 17 Jun 2001 11:23:10 -0700 (PDT) (envelope-from jkh@osd.bsdi.com) Received: from localhost (jkh@localhost [127.0.0.1]) by winston.osd.bsdi.com (8.11.4/8.11.3) with ESMTP id f5HIMlt83259; Sun, 17 Jun 2001 11:22:47 -0700 (PDT) (envelope-from jkh@osd.bsdi.com) To: imp@harmony.village.org Cc: obrien@FreeBSD.ORG, freebsd-arch@FreeBSD.ORG Subject: Re: first cut at /etc/rc.d diff In-Reply-To: <200106170718.f5H7IhV45149@harmony.village.org> References: <20010616010349.A40011@dragon.nuxi.com> <200106170718.f5H7IhV45149@harmony.village.org> X-Mailer: Mew version 1.94.1 on Emacs 20.7 / Mule 4.0 (HANANOEN) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-Id: <20010617112247S.jkh@osd.bsdi.com> Date: Sun, 17 Jun 2001 11:22:47 -0700 From: Jordan Hubbard X-Dispatcher: imput version 20000228(IM140) Lines: 13 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG From: Warner Losh Subject: Re: first cut at /etc/rc.d diff Date: Sun, 17 Jun 2001 01:18:43 -0600 > Some members of the NetBSD community may freak out at this. I added > $FreeBSD$ to the pccard stuff to indicate where I'd merged to and one Those people should simply be pointed at the equivalent $NetBSD$ lines in our ports collection (the lineage of that particular software NOT being in dispute) and told to shut up. We're willing to adopt their changes in the name of closer syncronization and they should be too. - Jordan To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Jun 17 11:49: 2 2001 Delivered-To: freebsd-arch@freebsd.org Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by hub.freebsd.org (Postfix) with ESMTP id CE9A337B40A; Sun, 17 Jun 2001 11:48:51 -0700 (PDT) (envelope-from imp@harmony.village.org) Received: from harmony.village.org (localhost.village.org [127.0.0.1]) by harmony.village.org (8.11.3/8.11.1) with ESMTP id f5HImlV47806; Sun, 17 Jun 2001 12:48:47 -0600 (MDT) (envelope-from imp@harmony.village.org) Message-Id: <200106171848.f5HImlV47806@harmony.village.org> To: Sheldon Hearn Subject: Re: `rcorder' patch Cc: obrien@FreeBSD.ORG, freebsd-arch@FreeBSD.ORG In-reply-to: Your message of "Sun, 17 Jun 2001 11:08:42 +0200." <16541.992768922@axl.seasidesoftware.co.za> References: <16541.992768922@axl.seasidesoftware.co.za> Date: Sun, 17 Jun 2001 12:48:47 -0600 From: Warner Losh Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <16541.992768922@axl.seasidesoftware.co.za> Sheldon Hearn writes: : Was the NetBSD contact Luke Mewburn, the guy Doug Barton and I have been : chatting to about this import? If not, please make sure you chat to : Luke, who's very keen on NetBSD and FreeBSD staying "near" each other on : this one. Yes. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Jun 17 12:11:51 2001 Delivered-To: freebsd-arch@freebsd.org Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by hub.freebsd.org (Postfix) with ESMTP id B839137B40A; Sun, 17 Jun 2001 12:11:41 -0700 (PDT) (envelope-from des@ofug.org) Received: (from des@localhost) by flood.ping.uio.no (8.9.3/8.9.3) id VAA46279; Sun, 17 Jun 2001 21:11:35 +0200 (CEST) (envelope-from des@ofug.org) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: Sheldon Hearn Cc: obrien@FreeBSD.ORG, freebsd-arch@FreeBSD.ORG Subject: Re: `rcorder' patch References: <16541.992768922@axl.seasidesoftware.co.za> From: Dag-Erling Smorgrav Date: 17 Jun 2001 21:11:34 +0200 In-Reply-To: <16541.992768922@axl.seasidesoftware.co.za> Message-ID: Lines: 11 User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Sheldon Hearn writes: > Was the NetBSD contact Luke Mewburn, the guy Doug Barton and I have been > chatting to about this import? If not, please make sure you chat to > Luke, who's very keen on NetBSD and FreeBSD staying "near" each other on > this one. Hmm, it might be a good idea to give lukem FreeBSD commit privs. DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Jun 17 14: 1:17 2001 Delivered-To: freebsd-arch@freebsd.org Received: from area51.v-wave.com (area51.v-wave.com [24.108.173.252]) by hub.freebsd.org (Postfix) with SMTP id B45C637B401 for ; Sun, 17 Jun 2001 14:00:51 -0700 (PDT) (envelope-from flatline@area51.v-wave.com) Received: (qmail 38198 invoked by uid 1001); 17 Jun 2001 21:00:50 -0000 Date: Sun, 17 Jun 2001 15:00:50 -0600 From: Chris Wasser To: arch@FreeBSD.org Subject: netbsd rc system diff Message-ID: <20010617150050.F582@skunkworks.arpa.mil> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="envbJBWh7q8WU6mo" Content-Disposition: inline User-Agent: Mutt/1.2.5i X-Operating-System: FreeBSD 4.2-STABLE i386 X-Subliminal: On the count of 3, you will bark like a dog. 1.. 2.. 3.. Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --envbJBWh7q8WU6mo Content-Type: text/plain; charset=us-ascii Content-Disposition: inline I'm not sure how many people will agree with this, but here's a diff to rc.subr that applies the following premise: a) services started from init generally will be started with absolute path. For example: in /etc/rc.conf: sshd_enable="YES" sshd_program="/usr/sbin/sshd" sshd_flags="-p 22" A process report will show that indeed, sshd has been started with absolute path: # ps -ax -o 'pid,command' | grep sshd PID COMMAND 25063 /usr/sbin/sshd -p 22 38124 grep sshd b) some processes use setproctitle(3) to change how the process report will show up in a report, to overcome this problem, we sort the process report so that () and // are placed first in the report, reducing potential false positive matches: # ps -ax -o 'pid,command' | sort +1 4 (bufdaemon) 2 (pagedaemon) 0 (swapper) 5 (syncer) 3 (vmdaemon) 157 /sbin/dhclient dc0 1 /sbin/init -- 15041 /sbin/ipmon -Ds 30809 /usr/sbin/cron 16699 /usr/sbin/inetd -wW -l -c 100 -C 10 18072 /usr/sbin/named -u bind -g bind 60441 /usr/sbin/sshd -p 2222 22947 /usr/sbin/syslogd -ss PID COMMAND 24 adjkerntz -i 44231 ps -ax -o pid,command 17173 sshd: flatline (sshd) 34624 sshd: flatline (sshd) 34630 sshd: flatline (sshd) 44219 sshd: flatline@ttyp0 (sshd) ...etc Attached is a diff to rc.subr which applies the aforementioned implementation. Ofcourse this isn't a end-all-be-all solution, ideally a specialized tool would be used to differentiate which is an actual parent process and which are children/threads. - Chris --envbJBWh7q8WU6mo Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="rc.subr.diff" --- rc.subr Sun Jun 17 14:14:16 2001 +++ rc.subr.new Sun Jun 17 14:29:23 2001 @@ -116,12 +116,13 @@ return fi _procnamebn=${_procname##*/} - ps -p $_pid -o 'pid,command' | while read _npid _arg0 _argv; do + ps -p $_pid -o 'pid,command' | sort +1 | while read _npid _arg0 _argv; do if [ "$_npid" = "PID" ]; then continue fi if [ "$_arg0" = "$_procname" \ -o "$_arg0" = "$_procnamebn" \ + -o "$_arg0" = "/${_procnamebn}" \ -o "$_arg0" = "${_procnamebn}:" \ -o "$_arg0" = "(${_procnamebn})" ]; then echo $_npid @@ -143,12 +144,13 @@ fi _procnamebn=${_procname##*/} _pref= - ps -ax -o 'pid,command' | while read _npid _arg0 _argv; do + ps -ax -o 'pid,command' | sort +1 | while read _npid _arg0 _argv; do if [ "$_npid" = "PID" ]; then continue fi if [ "$_arg0" = "$_procname" \ -o "$_arg0" = "$_procnamebn" \ + -o "$_arg0" = "/${_procnamebn}" \ -o "$_arg0" = "${_procnamebn}:" \ -o "$_arg0" = "(${_procnamebn})" ]; then echo -n "$_pref$_npid" --envbJBWh7q8WU6mo-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Jun 17 15:12:41 2001 Delivered-To: freebsd-arch@freebsd.org Received: from gateway.posi.net (c1096725-a.smateo1.sfba.home.com [24.250.130.228]) by hub.freebsd.org (Postfix) with ESMTP id BF83C37B409 for ; Sun, 17 Jun 2001 15:12:36 -0700 (PDT) (envelope-from kbyanc@posi.net) Received: from localhost (kbyanc@localhost) by gateway.posi.net (8.11.3/8.11.3) with ESMTP id f5HMCK568155; Sun, 17 Jun 2001 15:12:20 -0700 (PDT) (envelope-from kbyanc@posi.net) X-Authentication-Warning: gateway.posi.net: kbyanc owned process doing -bs Date: Sun, 17 Jun 2001 15:12:19 -0700 (PDT) From: Kelly Yancey To: Chris Wasser Cc: arch@FreeBSD.ORG Subject: Re: netbsd rc system diff In-Reply-To: <20010617150050.F582@skunkworks.arpa.mil> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun, 17 Jun 2001, Chris Wasser wrote: > b) some processes use setproctitle(3) to change how the process > report will show up in a report, to overcome this problem, we > sort the process report so that () and // are placed first in the > report, reducing potential false positive matches: > > # ps -ax -o 'pid,command' | sort +1 > Minor nit: would you mind running the ps output through tail first to trim off the header. It doesn't correlate well in the sorted output. # ps -ax -o 'pid,command' | tail +2 | sort +1 -- Kelly Yancey - kbyanc@posi.net - Belmont, CA Lead Engineer, Backplane, Inc. http://www.backplane.com/ Maintainer, BSD Driver Database http://www.posi.net/freebsd/drivers/ Coordinator, Team FreeBSD http://www.posi.net/freebsd/Team-FreeBSD/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Jun 17 15:34:43 2001 Delivered-To: freebsd-arch@freebsd.org Received: from area51.v-wave.com (area51.v-wave.com [24.108.173.252]) by hub.freebsd.org (Postfix) with SMTP id 6F76637B409 for ; Sun, 17 Jun 2001 15:34:32 -0700 (PDT) (envelope-from flatline@area51.v-wave.com) Received: (qmail 38631 invoked by uid 1001); 17 Jun 2001 22:34:31 -0000 Date: Sun, 17 Jun 2001 16:34:31 -0600 From: Chris Wasser To: Kelly Yancey Cc: arch@FreeBSD.ORG Subject: Re: netbsd rc system diff Message-ID: <20010617163431.G582@skunkworks.arpa.mil> References: <20010617150050.F582@skunkworks.arpa.mil> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: ; from kbyanc@posi.net on Sun, Jun 17, 2001 at 03:12:19PM -0700 X-Operating-System: FreeBSD 4.2-STABLE i386 X-Subliminal: On the count of 3, you will bark like a dog. 1.. 2.. 3.. Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun 17 Jun 2001, Kelly Yancey wrote: > On Sun, 17 Jun 2001, Chris Wasser wrote: > > > b) some processes use setproctitle(3) to change how the process > > report will show up in a report, to overcome this problem, we > > sort the process report so that () and // are placed first in the > > report, reducing potential false positive matches: > > > > # ps -ax -o 'pid,command' | sort +1 > > > > Minor nit: would you mind running the ps output through tail first to trim > off the header. It doesn't correlate well in the sorted output. > > # ps -ax -o 'pid,command' | tail +2 | sort +1 > That would remove the check in rc.subr for the header: if [ "$_npid" = "PID" ]; then continue fi Seems like a good idea to me :) -Chris To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Jun 17 15:47:33 2001 Delivered-To: freebsd-arch@freebsd.org Received: from area51.v-wave.com (area51.v-wave.com [24.108.173.252]) by hub.freebsd.org (Postfix) with SMTP id BFFA037B406 for ; Sun, 17 Jun 2001 15:47:17 -0700 (PDT) (envelope-from flatline@area51.v-wave.com) Received: (qmail 38691 invoked by uid 1001); 17 Jun 2001 22:47:17 -0000 Date: Sun, 17 Jun 2001 16:47:17 -0600 From: Chris Wasser To: arch@freebsd.org Subject: netbsd rc.subr diff #2 Message-ID: <20010617164716.H582@skunkworks.arpa.mil> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="UHN/qo2QbUvPLonB" Content-Disposition: inline User-Agent: Mutt/1.2.5i X-Operating-System: FreeBSD 4.2-STABLE i386 X-Subliminal: On the count of 3, you will bark like a dog. 1.. 2.. 3.. Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --UHN/qo2QbUvPLonB Content-Type: text/plain; charset=us-ascii Content-Disposition: inline I hate to spam the list with repetitious emails; attached is my current running diff against /etc/rc.subr which now implements the change suggested by Kelly Yancey which removes the header from the ps output, thus removing the check for it. --UHN/qo2QbUvPLonB Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="rc.subr.diff" --- rc.subr Sun Jun 17 14:14:16 2001 +++ rc.subr.new Sun Jun 17 16:40:12 2001 @@ -116,12 +116,10 @@ return fi _procnamebn=${_procname##*/} - ps -p $_pid -o 'pid,command' | while read _npid _arg0 _argv; do - if [ "$_npid" = "PID" ]; then - continue - fi + ps -p $_pid -o 'pid,command' | tail +2 | sort +1 | while read _npid _arg0 _argv; do if [ "$_arg0" = "$_procname" \ -o "$_arg0" = "$_procnamebn" \ + -o "$_arg0" = "/${_procnamebn}" \ -o "$_arg0" = "${_procnamebn}:" \ -o "$_arg0" = "(${_procnamebn})" ]; then echo $_npid @@ -143,12 +141,10 @@ fi _procnamebn=${_procname##*/} _pref= - ps -ax -o 'pid,command' | while read _npid _arg0 _argv; do - if [ "$_npid" = "PID" ]; then - continue - fi + ps -ax -o 'pid,command' | tail +2 | sort +1 | while read _npid _arg0 _argv; do if [ "$_arg0" = "$_procname" \ -o "$_arg0" = "$_procnamebn" \ + -o "$_arg0" = "/${_procnamebn}" \ -o "$_arg0" = "${_procnamebn}:" \ -o "$_arg0" = "(${_procnamebn})" ]; then echo -n "$_pref$_npid" --UHN/qo2QbUvPLonB-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Jun 18 1:29:26 2001 Delivered-To: freebsd-arch@freebsd.org Received: from axl.seasidesoftware.co.za (axl.seasidesoftware.co.za [196.31.7.201]) by hub.freebsd.org (Postfix) with ESMTP id 1EF0937B401 for ; Mon, 18 Jun 2001 01:29:24 -0700 (PDT) (envelope-from sheldonh@starjuice.net) Received: from sheldonh (helo=axl.seasidesoftware.co.za) by axl.seasidesoftware.co.za with local-esmtp (Exim 3.22 #1) id 15BuPZ-000JJq-00; Mon, 18 Jun 2001 10:29:29 +0200 From: Sheldon Hearn To: Chris Wasser Cc: arch@FreeBSD.org Subject: Re: netbsd rc system diff In-reply-to: Your message of "Sun, 17 Jun 2001 15:00:50 CST." <20010617150050.F582@skunkworks.arpa.mil> Date: Mon, 18 Jun 2001 10:29:29 +0200 Message-ID: <74265.992852969@axl.seasidesoftware.co.za> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun, 17 Jun 2001 15:00:50 CST, Chris Wasser wrote: > I'm not sure how many people will agree with this, but here's a diff to > rc.subr that applies the following premise: Please run your patches by Luke Mewburn and let us know what the outcome is. Thanks, Sheldon. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Jun 18 5:17:27 2001 Delivered-To: freebsd-arch@freebsd.org Received: from whale.sunbay.crimea.ua (whale.sunbay.crimea.ua [212.110.138.65]) by hub.freebsd.org (Postfix) with ESMTP id A9B7337B401; Mon, 18 Jun 2001 05:15:16 -0700 (PDT) (envelope-from ru@whale.sunbay.crimea.ua) Received: (from ru@localhost) by whale.sunbay.crimea.ua (8.11.2/8.11.2) id f5ICEeX96556; Mon, 18 Jun 2001 15:14:40 +0300 (EEST) (envelope-from ru) Date: Mon, 18 Jun 2001 15:13:24 +0300 From: Ruslan Ermilov To: Peter Pentchev Cc: audit@FreeBSD.ORG, arch@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path Message-ID: <20010618151324.A94281@sunbay.com> Mail-Followup-To: Peter Pentchev , audit@FreeBSD.ORG, arch@FreeBSD.ORG References: <20010615150639.D94445@ringworld.oblivion.bg> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010615150639.D94445@ringworld.oblivion.bg>; from roam@orbitel.bg on Fri, Jun 15, 2001 at 03:06:39PM +0300 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Jun 15, 2001 at 03:06:39PM +0300, Peter Pentchev wrote: [...] > XMAN8= kldpath.8 > s/MAN8/MAN/ > X.Os FreeBSD > Leave the .Os empty, it's now handled automatically. > X.It Fl S Ar name > XSpecify the sysctl name to use instead of the default > X.Sy kern.module_path . > s/Sy/Va/ > X.Sh SEE ALSO > X.Xr kldload 2 , > X.Xr kldload 8 , > X.Xr sysctl 8 . > Remove the final "dot". > XThe > X.Nm > Xcommand first appeared in > You should decide: "command" or "utility"? :-) Excuse me, but what's wrong with sysctl(8) editing kern.module_path? Cheers, -- Ruslan Ermilov Oracle Developer/DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Jun 18 5:20: 7 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id C1B0C37B40A for ; Mon, 18 Jun 2001 05:20:00 -0700 (PDT) (envelope-from roam@ringworld.nanolink.com) Received: (qmail 24935 invoked by uid 1000); 18 Jun 2001 12:18:31 -0000 Date: Mon, 18 Jun 2001 15:18:31 +0300 From: Peter Pentchev To: audit@FreeBSD.ORG, arch@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path Message-ID: <20010618151831.J1713@ringworld.oblivion.bg> Mail-Followup-To: audit@FreeBSD.ORG, arch@FreeBSD.ORG References: <20010615150639.D94445@ringworld.oblivion.bg> <20010618151324.A94281@sunbay.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010618151324.A94281@sunbay.com>; from ru@FreeBSD.ORG on Mon, Jun 18, 2001 at 03:13:24PM +0300 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, Jun 18, 2001 at 03:13:24PM +0300, Ruslan Ermilov wrote: > > Excuse me, but what's wrong with sysctl(8) editing kern.module_path? Well, as I noted at the start of the message, this is a scripts-friendly utility - it allows adding/removing/inserting individual paths without the need to parse the whole. Thanks for the mdoc fixes! G'luck, Peter -- You have, of course, just begun reading the sentence that you have just finished reading. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Jun 18 17:19:45 2001 Delivered-To: freebsd-arch@freebsd.org Received: from point.osg.gov.bc.ca (point.osg.gov.bc.ca [142.32.102.44]) by hub.freebsd.org (Postfix) with ESMTP id 75E6137B401; Mon, 18 Jun 2001 17:19:40 -0700 (PDT) (envelope-from Cy.Schubert@uumail.gov.bc.ca) Received: (from daemon@localhost) by point.osg.gov.bc.ca (8.8.7/8.8.8) id RAA21612; Mon, 18 Jun 2001 17:19:36 -0700 Received: from passer.osg.gov.bc.ca(142.32.110.29) via SMTP by point.osg.gov.bc.ca, id smtpda21610; Mon Jun 18 17:19:20 2001 Received: (from uucp@localhost) by passer.osg.gov.bc.ca (8.11.4/8.9.1) id f5J0JET63799; Mon, 18 Jun 2001 17:19:14 -0700 (PDT) Received: from UNKNOWN(10.1.2.1), claiming to be "cwsys.cwsent.com" via SMTP by passer9.cwsent.com, id smtpdf63797; Mon Jun 18 17:18:33 2001 Received: (from uucp@localhost) by cwsys.cwsent.com (8.11.4/8.9.1) id f5J0H8R17337; Mon, 18 Jun 2001 17:17:08 -0700 (PDT) Message-Id: <200106190017.f5J0H8R17337@cwsys.cwsent.com> Received: from localhost.cwsent.com(127.0.0.1), claiming to be "cwsys" via SMTP by localhost.cwsent.com, id smtpdR17333; Mon Jun 18 17:16:46 2001 X-Mailer: exmh version 2.3.1 01/18/2001 with nmh-1.0.4 Reply-To: Cy Schubert - ITSD Open Systems Group From: Cy Schubert - ITSD Open Systems Group X-Sender: schubert To: Peter Pentchev Cc: audit@FreeBSD.ORG, arch@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path In-reply-to: Your message of "Mon, 18 Jun 2001 15:18:31 +0300." <20010618151831.J1713@ringworld.oblivion.bg> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Mon, 18 Jun 2001 17:16:46 -0700 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <20010618151831.J1713@ringworld.oblivion.bg>, Peter Pentchev writes: > On Mon, Jun 18, 2001 at 03:13:24PM +0300, Ruslan Ermilov wrote: > > > > Excuse me, but what's wrong with sysctl(8) editing kern.module_path? > > Well, as I noted at the start of the message, this is a scripts-friendly > utility - it allows adding/removing/inserting individual paths without > the need to parse the whole. But it could be a script friendly Perl script that calls sysctl. Right? Regards, Phone: (250)387-8437 Cy Schubert Fax: (250)387-5766 Team Leader, Sun/Alpha Team Internet: Cy.Schubert@osg.gov.bc.ca Open Systems Group, ITSD, ISTA Province of BC To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Jun 18 17:59: 6 2001 Delivered-To: freebsd-arch@freebsd.org Received: from dragon.nuxi.com (trang.nuxi.com [206.40.252.115]) by hub.freebsd.org (Postfix) with ESMTP id CBF4F37B401 for ; Mon, 18 Jun 2001 17:59:03 -0700 (PDT) (envelope-from obrien@NUXI.com) Received: (from obrien@localhost) by dragon.nuxi.com (8.11.3/8.11.1) id f5J0wvb00656; Mon, 18 Jun 2001 17:58:57 -0700 (PDT) (envelope-from obrien) Date: Mon, 18 Jun 2001 17:58:57 -0700 From: "David O'Brien" To: Sheldon Hearn Cc: Chris Wasser , arch@FreeBSD.org Subject: Re: netbsd rc system diff Message-ID: <20010618175856.A540@dragon.nuxi.com> Reply-To: obrien@FreeBSD.org References: <20010617150050.F582@skunkworks.arpa.mil> <74265.992852969@axl.seasidesoftware.co.za> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <74265.992852969@axl.seasidesoftware.co.za>; from sheldonh@starjuice.net on Mon, Jun 18, 2001 at 10:29:29AM +0200 X-Operating-System: FreeBSD 5.0-CURRENT Organization: The NUXI BSD group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, Jun 18, 2001 at 10:29:29AM +0200, Sheldon Hearn wrote: > > I'm not sure how many people will agree with this, but here's a diff to > > rc.subr that applies the following premise: > > Please run your patches by Luke Mewburn and > let us know what the outcome is. NO! Please discuss them here first to make sure the proposed patch does something needed. People should post the patches they have to -arch, then WAIT until people have a chance to review them; AND USENIX has passed by so that we can invite Luke into the picture at his convenience -- -- David (obrien@FreeBSD.org) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Jun 18 18: 1: 0 2001 Delivered-To: freebsd-arch@freebsd.org Received: from dragon.nuxi.com (trang.nuxi.com [206.40.252.115]) by hub.freebsd.org (Postfix) with ESMTP id 46AA437B406 for ; Mon, 18 Jun 2001 18:00:54 -0700 (PDT) (envelope-from obrien@NUXI.com) Received: (from obrien@localhost) by dragon.nuxi.com (8.11.3/8.11.1) id f5J10q900728; Mon, 18 Jun 2001 18:00:52 -0700 (PDT) (envelope-from obrien) Date: Mon, 18 Jun 2001 18:00:52 -0700 From: "David O'Brien" To: Chris Wasser Cc: arch@freebsd.org Subject: Re: netbsd rc.subr diff #2 Message-ID: <20010618180052.B540@dragon.nuxi.com> Reply-To: arch@freebsd.org References: <20010617164716.H582@skunkworks.arpa.mil> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010617164716.H582@skunkworks.arpa.mil>; from cwasser@v-wave.com on Sun, Jun 17, 2001 at 04:47:17PM -0600 X-Operating-System: FreeBSD 5.0-CURRENT Organization: The NUXI BSD group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun, Jun 17, 2001 at 04:47:17PM -0600, Chris Wasser wrote: > - ps -p $_pid -o 'pid,command' | while read _npid _arg0 _argv; do > - if [ "$_npid" = "PID" ]; then > - continue > - fi > + ps -p $_pid -o 'pid,command' | tail +2 | sort +1 | while read _npid _arg0 _argv; do Will people say the 2 added |'s slows things down [too much]? Remember NetBSD runs on some rather slow, old hardware. -- -- David (obrien@FreeBSD.org) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Jun 18 18:12:11 2001 Delivered-To: freebsd-arch@freebsd.org Received: from dt051n37.san.rr.com (dt051n37.san.rr.com [204.210.32.55]) by hub.freebsd.org (Postfix) with ESMTP id 6853637B407; Mon, 18 Jun 2001 18:12:05 -0700 (PDT) (envelope-from DougB@DougBarton.net) Received: from slave (Studded@slave [10.0.0.1]) by dt051n37.san.rr.com (8.9.3/8.9.3) with ESMTP id SAA37533; Mon, 18 Jun 2001 18:12:04 -0700 (PDT) (envelope-from DougB@DougBarton.net) Date: Mon, 18 Jun 2001 18:12:04 -0700 (PDT) From: Doug Barton X-X-Sender: To: , Subject: Changes to the /etc/rc* boot system Message-ID: <20010618175638.L37408-100000@dt051n37.san.rr.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG [Please follow up on this discussion in -arch] Gang, Several people are leaping into the fray with enthusiasm for this project all of a sudden, which is a good thing. However, I'm a little concerned that it's not getting enough of a "big picture" view. What may seem like lack of progress at this point is actually an effort to do several things before we proceed. A) Examine what we have (most of us understand that pretty well) B) Figure out what we need (in progress, nowhere near done yet) C) Take a hard look at NetBSD's code to determine if it meets our needs D) If we decide C) is "yes," figure out how to port/improve it C is pretty much a given in most people's minds at this point. Whether that is a good thing or not I'm not sure, but let's take that as a starting point for now. Given that there will be no small effort in porting their code to our system, and given that we already have the cooperation of one of the NetBSD developers to help with D), I would like to suggest that people bend their efforts away from trying to be the first one to get some code into our tree and onto some of the more general topics. Unfortunately, Luke from NetBSD is both very busy, and busier still until after Usenix. He's asked us to hold off on this till then, and I think that's reasonable. What I'd really like to focus on at this point are three questions. 1. What needs to be done differently on our system than theirs? 2. What would we like to improve on in their current system? 3. How can we take the current code and make it easier to maintain across both platforms? If we can have some good answers to those questions ready for after usenix, then we can start off the "What would the NetBSD developers do differently knowing what they know now?" conversation with some intelligent points of our own. Just a thought, Doug -- If you're never wrong, you're not trying hard enough. Do YOU Yahoo!? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Jun 18 21:52: 2 2001 Delivered-To: freebsd-arch@freebsd.org Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by hub.freebsd.org (Postfix) with ESMTP id D41FF37B401; Mon, 18 Jun 2001 21:51:54 -0700 (PDT) (envelope-from imp@harmony.village.org) Received: from harmony.village.org (localhost.village.org [127.0.0.1]) by harmony.village.org (8.11.3/8.11.1) with ESMTP id f5J4ppV59574; Mon, 18 Jun 2001 22:51:51 -0600 (MDT) (envelope-from imp@harmony.village.org) Message-Id: <200106190451.f5J4ppV59574@harmony.village.org> To: Doug Barton Subject: Re: Changes to the /etc/rc* boot system Cc: freebsd-hackers@FreeBSD.ORG, freebsd-arch@FreeBSD.ORG In-reply-to: Your message of "Mon, 18 Jun 2001 18:12:04 PDT." <20010618175638.L37408-100000@dt051n37.san.rr.com> References: <20010618175638.L37408-100000@dt051n37.san.rr.com> Date: Mon, 18 Jun 2001 22:51:50 -0600 From: Warner Losh Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <20010618175638.L37408-100000@dt051n37.san.rr.com> Doug Barton writes: : A) Examine what we have (most of us understand that pretty well) : B) Figure out what we need (in progress, nowhere near done yet) : C) Take a hard look at NetBSD's code to determine if it meets our needs : D) If we decide C) is "yes," figure out how to port/improve it : : C is pretty much a given in most people's minds at this point. Whether : that is a good thing or not I'm not sure, but let's take that as a : starting point for now. Given that it is pretty much a given in the minds of many of the grey beards of the project, the snide comments like the above are irrelevant. :-) I'm sorry to be so blunt, but David asked a subset of core members that were on IRC at the time (3) if he could do a vendor branch import of NetBSD rc.d and we all said go for it so long as you coordinate the back migration with NetBSD. That's one reason why he's been so adamant about talking about it amoung ourselves first before we approach the NetBSD developers with every little possible improvement. We're trying hard to prevent a fork here. That's a little more important than necessarily having something that is technically perfect in someone's mind. : Given that there will be no small effort in : porting their code to our system It actually is looking like it isn't a huge effort, appart from writing a few more scripts or doing some minor rearrangement. : given that we already have the : cooperation of one of the NetBSD developers to help with D), More than one. I have NetBSD commit privs :-) Of course, I'd have to run the changes by the responsible parties of for those parts of the NetBSD tree. I've had experience with integrating code into the NetBSD tree, so I have some perspective that most people don't have. : 1. What needs to be done differently on our system than theirs? : 2. What would we like to improve on in their current system? : 3. How can we take the current code and make it easier to maintain : across both platforms? Good questions, but they imply that we want to do a lot of work on the NetBSD rc.d system. We don't. We do not want the second system effect to overwhelm the nice, clean simple design that NetBSD has right now. : If we can have some good answers to those questions ready for after : usenix, then we can start off the "What would the NetBSD developers do : differently knowing what they know now?" conversation with some : intelligent points of our own. Right, but we should let the right people do the talking as well. The last thing we need is 10 different people to go up to Luke and give him 10 different stories. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Jun 18 23:32:40 2001 Delivered-To: freebsd-arch@freebsd.org Received: from dt051n37.san.rr.com (dt051n37.san.rr.com [204.210.32.55]) by hub.freebsd.org (Postfix) with ESMTP id 703FF37B408; Mon, 18 Jun 2001 23:32:28 -0700 (PDT) (envelope-from DougB@DougBarton.net) Received: from DougBarton.net (master [10.0.0.2]) by dt051n37.san.rr.com (8.9.3/8.9.3) with ESMTP id XAA39115; Mon, 18 Jun 2001 23:32:24 -0700 (PDT) (envelope-from DougB@DougBarton.net) Message-ID: <3B2EF1F8.9710CC61@DougBarton.net> Date: Mon, 18 Jun 2001 23:32:24 -0700 From: Doug Barton Organization: Triborough Bridge & Tunnel Authority X-Mailer: Mozilla 4.77 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Warner Losh Cc: freebsd-hackers@FreeBSD.ORG, freebsd-arch@FreeBSD.ORG Subject: Re: Changes to the /etc/rc* boot system References: <20010618175638.L37408-100000@dt051n37.san.rr.com> <200106190451.f5J4ppV59574@harmony.village.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG [Prelude, Warner and I discussed this off line... ] Warner Losh wrote: > > In message <20010618175638.L37408-100000@dt051n37.san.rr.com> Doug Barton writes: > : A) Examine what we have (most of us understand that pretty well) > : B) Figure out what we need (in progress, nowhere near done yet) > : C) Take a hard look at NetBSD's code to determine if it meets our needs > : D) If we decide C) is "yes," figure out how to port/improve it > : > : C is pretty much a given in most people's minds at this point. Whether > : that is a good thing or not I'm not sure, but let's take that as a > : starting point for now. > > Given that it is pretty much a given in the minds of many of the grey > beards of the project, the snide comments like the above are > irrelevant. :-) Not snide, just disappointed, frankly. But I'll learn to live with it. :) > I'm sorry to be so blunt, but David asked a subset of > core members that were on IRC at the time (3) if he could do a vendor > branch import of NetBSD rc.d and we all said go for it so long as you > coordinate the back migration with NetBSD. That's one reason why he's > been so adamant about talking about it amoung ourselves first before > we approach the NetBSD developers with every little possible > improvement. I think that we're closer to agreement here than it may appear. Last I heard from obrien he was overloaded, and wasn't looking to head this up himself unless no one else was going to do it. We don't want to overload him with stuff that "only he can do" if there are other alternatives. > We're trying hard to prevent a fork here. That's a little more > important than necessarily having something that is technically > perfect in someone's mind. Once again, closer together than apart. My goal (restated) is to _improve_ the netbsd system, including input from the team that put the thing together so that we can improve the system itself and the portability of it. > : Given that there will be no small effort in > : porting their code to our system > > It actually is looking like it isn't a huge effort, appart from > writing a few more scripts or doing some minor rearrangement. Everyone I've talked to has a different story on this. My take on it is that the amount of work involved in the port justifies a careful look at it before the import. > : given that we already have the > : cooperation of one of the NetBSD developers to help with D), > > More than one. I have NetBSD commit privs :-) I was speaking specifically of the NetBSD developers who developed the rc system they are using currently. > Of course, I'd have to > run the changes by the responsible parties of for those parts of the > NetBSD tree. I've had experience with integrating code into the > NetBSD tree, so I have some perspective that most people don't have. That is definitely the kind of help we need. I have some limited experience in working with openbsd folks on cross-platform issues, but the more the merrier. > : 1. What needs to be done differently on our system than theirs? > : 2. What would we like to improve on in their current system? > : 3. How can we take the current code and make it easier to maintain > : across both platforms? > > Good questions, but they imply that we want to do a lot of work on the > NetBSD rc.d system. We don't. We do not want the second system > effect to overwhelm the nice, clean simple design that NetBSD has > right now. See above. > : If we can have some good answers to those questions ready for after > : usenix, then we can start off the "What would the NetBSD developers do > : differently knowing what they know now?" conversation with some > : intelligent points of our own. > > Right, but we should let the right people do the talking as well. The > last thing we need is 10 different people to go up to Luke and give > him 10 different stories. Right, this is my goal as well. We'll work on this off line. Doug To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 0:27: 7 2001 Delivered-To: freebsd-arch@freebsd.org Received: from area51.v-wave.com (area51.v-wave.com [24.108.173.252]) by hub.freebsd.org (Postfix) with SMTP id 28BC037B403 for ; Tue, 19 Jun 2001 00:26:59 -0700 (PDT) (envelope-from flatline@area51.v-wave.com) Received: (qmail 53623 invoked by uid 1001); 19 Jun 2001 07:26:58 -0000 Date: Tue, 19 Jun 2001 01:26:58 -0600 From: Chris Wasser To: arch@FreeBSD.org Subject: changes to /etc/rc* Message-ID: <20010619012658.A53486@skunkworks.arpa.mil> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i X-Operating-System: FreeBSD 4.2-STABLE i386 X-Subliminal: On the count of 3, you will bark like a dog. 1.. 2.. 3.. Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Ok, since there is a lot for me to cover here, I'm going to answer everyone in one big related email so please bear with me (it's a long read to various parties). I will only be sending this to -arch so if someone feels others should receive this, then please forward it to the appropiate parties. Everyone else is more then welcome to put their two cents into what I have to say :) (original message from lukem@wasabisystems.com has remained unabridged) >Date: Tue, 19 Jun 2001 10:23:06 +1000 >From: Luke Mewburn >To: Chris Wasser >Subject: Re: NetBSD /etc/rc.subr diff >Cc: Sheldon Hearn >Reply-To: Luke Mewburn > >>On Mon, Jun 18, 2001 at 02:15:24PM -0600, Chris Wasser wrote: >> Hi, >> >> Attached is a diff to /etc/rc.subr for NetBSD (and recently imported >> into FreeBSD) which is designed to reduce the potential for false >> positive hits in gathering process information for the rc init >> system. >> >> Please note the diff is applied against the rc.subr in FreeBSD's >> tag=HEAD rather then the actual NetBSD /etc/rc.subr, however the >> differences between the two are very minor and should have no >> problems merging this diff. >> >> I'm interested to hear any comments, suggestions or just general >> questions you may have on this diff and would be happy to answer any >> posed. > >Hi Chris. > >I'm not sure which version of rc.subr was used in the FreeBSD import, >but it looks a little old, because in rev 1.30 in NetBSD I changed >that particular code to use "case" instead of "if", etc. I based my diff off the rc.subr (v1.28) found at: http://www.FreeBSD.org/cgi/cvsweb.cgi/src/etc/rc.subr?only_with_tag=HEAD Again, I noted this diff was made against rc.subr that I found in the FreeBSD cvs tree. > >Other comments: > > - There's no need to check if a command matches > "*/$_procnamebn" > because $_procnamebn is the basename of $_procname > (that's that > _procnamebn=${_procname##*/} > does) > In this I disagree entirely. Not that in $_procnamebn isn't a valid match-term, but that searching for */$_procnamebn is also perfectly valid, and can reduce the potential for false matches, consider the following processes 'qmail-smtpd' and 'cron': /root# ps -ax -o pid,command | grep cron 24404 /usr/sbin/cron 53287 grep cron /root# ps -ax -o pid,command | grep qmail-smtpd 53289 grep qmail-smtpd As you can see, cron is found, but only grep is displayed for qmail-smtpd, this matching system would fail to discover the process id for qmail-smtpd which indeed is running using my calling and matching scheme for process checks: /root# ps -axwww -o pid,command | grep cron 24404 /usr/sbin/cron 53293 grep cron /root# ps -axwww -o pid,command | grep qmail-smtpd 53373 grep qmail-smtpd 328 /usr/local/bin/tcpserver -v -R -x/etc/tcp.smtp.cdb -u82 -g81 0 smtp /usr/local/bin/fixcrio /usr/local/bin/rblsmtpd -b -rrelays.mail-abuse.org /var/qmail/bin/qmail-smtpd By matching for leading / (and thus, indicative of absolute pathed execution) it's quite easy to find the correct PID of the process in question. Almost all the services started from FreeBSD (unsure about NetBSD, I imagine it's the same) rc are absolutely pathed when they're executed [if that's the correct term] for example, sshd in which I've only configured sshd_flags and sshd_enable in /etc/rc.conf: /root# ps -axwww -o pid,command | grep sshd 25063 /usr/sbin/sshd -p 22 53375 grep sshd Which in turn is set up initially from /etc/default/rc.conf: /root# grep sshd /etc/defaults/rc.conf sshd_enable="NO" # Enable sshd sshd_program="/usr/sbin/sshd" # path to sshd, if you want a different one. sshd_flags="" # Additional flags for sshd. So matching for a leading / is not only a good thing, but can produce results faster and more accurately (because search 'term' has been increased, more characters to match is a better match no?) I have tested your theory about not needing this matching, and removing the relevant section of shellcode which preforms the check against */_procnamebn fails to find qmail-smtpd in the above example, thus rc will fail to find the process, or mark it as down or handle it however it chooses. You can find a shellscript designed to preform this same check @ http://plaza.v-wave.com/cwasser/proc-read.sh (see script for details) to test this theory yourself. > - I use the test for pid == "PID" to skip the first entry > which is the header line from ps because > a) there's no valid PID called "PID", so my test isn't > going to get a false match > b) tail and sort are in /usr/bin, which may not be > mounted when this code runs. > c) the current code (using case not if) is fast > > > - I'm not sure why you call "ps -www ...", and also check all > the command arguments of the process for matching process names > to find a PID. > What's the rationale here? By using sort and tail, this check for pid == "PID" is uneccessary as unneeded information is weeded out before it's processed by the shellcode. Not only does it remove the need to check for ps(1) headers, but it also sorts the output in a manner most efficient to producing matches, what I mean by this is the same matches /etc/rc.subr is trying to make: $_procname|$_procnamebn|${_procnamebn}:|"(${_procnamebn})" Are logically sorted to the top of the list after tail and sort are finished, producing matches on these somewhat ambigious matches (a good example is sendmail, or tcpserver) which use setproctitle(3) and again, I re-iterate, it's my feeling that adding another match-term for absolute pathed process entries will also produce faster, more accurate results (to some extent): For example (I will show only relevant sections as they appear): /root# ps -axwww -o pid,command | tail +2 | sort +1 4 (bufdaemon) 2 (pagedaemon) 53396 (sh) 388 -csh (csh) 440 -csh (csh) 470 ./irc -p 6667 TDF irc.powersurfr.com 24404 /usr/sbin/cron 300 /usr/sbin/moused -3 -F 200 -r high -p /dev/psm0 210 /usr/sbin/portmap 25063 /usr/sbin/sshd -p 22 381 /usr/sbin/syslogd -ss 53514 ps -axwww -o pid,command 325 qmail-clean 17173 sshd: flatline (sshd) 34624 sshd: flatline (sshd) However, seeing as how sort and tail may not be available for usage due to unmounted filesystem, the logical choice then is instead of matching against _npid one could match against _arg0 as a measure to removing irrelevant information. For example: NetBSD cvsweb directory for /etc/rc.subr (v1.37): http://cvsweb.netbsd.org/bsdweb.cgi/basesrc/etc/rc.subr?only_with_tag=HEAD In check_process() and check_pidfile() you use similar checks: case "$_npid" in PID) continue ;; esac case "$_arg0" in $_procname|$_procnamebn|${_procnamebn}:|"(${_procnamebn})") echo $_npid return ;; esac This would be more efficient if you matched COMMAND in $_arg0 case-select, for example: case "$_arg0" in COMMAND) continue ;; $_procname|$_procnamebn ... ... ... esac Unless 'ps -ax ...' on other platforms produce different headers then on say x86, I don't see this creating a problem or adding to false-positive matches since COMMAND is also a invalid pid like PID is, and thus it's more efficient to remove it in one check rather then two independant case-select's. As for the rationale behind using 'ps -axwww ...' it's quite simple, without it, it's impossible to match examples like qmail-smtpd above, if the method I proposed fails to match any valid likelies in _arg0 then _argv is parsed by word matching against the same values as _arg0 was, producing a valid and relative match, using 'www' ensures that full path is displayed, producing more text to match against for each process being parsed. >I strongly suggest ensuring that you're working with rc.subr from >NetBSD-current, because I've made significant portability, performance >and functionality enhancements to it since NetBSD 1.5. In this I agree that the case-select used in v1.30+ for both check_process() and check_pidfile() is better then the if-then used in the FreeBSD-current /etc/rc.subr (v1.28) and the NetBSD 1.5 /etc/rc.subr (v1.20.2.4) for both functions. >By the way, I'm going to be at USENIX next week talking about rc.d. If >you (or any other FreeBSD developer who is going to be there) wants to >chat about this stuff then, feel free to find me and bend my ear! > >Luke. It should be noted that I foolishly emailed Luke instead of keeping this in -arch so I apologize to Luke (and those who got annoyed by me doing this) for stepping on whatever and whomever's toes. I feel these are valid reasons for the various changes I've proposed in order what I know will be a ongoing problem until a specialized tool is written to handle this properly. David O'Brien also mentioned that some people might say that the two extra pipes used in filtering out the unwanted data in the ps report might slow things down (as NetBSD runs on some slow, older hardware) in this I really can't say what the impact would be, again, lending itself toward the creation of a tool which exists in /bin (thus should be OK in all mounting suituations) that can pull the specific process id in question. (There was some talk of this on IRC a while ago...) - Chris To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 0:53:27 2001 Delivered-To: freebsd-arch@freebsd.org Received: from axl.seasidesoftware.co.za (axl.seasidesoftware.co.za [196.31.7.201]) by hub.freebsd.org (Postfix) with ESMTP id B441237B403; Tue, 19 Jun 2001 00:53:24 -0700 (PDT) (envelope-from sheldonh@starjuice.net) Received: from sheldonh (helo=axl.seasidesoftware.co.za) by axl.seasidesoftware.co.za with local-esmtp (Exim 3.30 #1) id 15CGKO-000Nk3-00; Tue, 19 Jun 2001 09:53:36 +0200 From: Sheldon Hearn To: obrien@FreeBSD.org Cc: Chris Wasser , arch@FreeBSD.org Subject: Re: netbsd rc system diff In-reply-to: Your message of "Mon, 18 Jun 2001 17:58:57 MST." <20010618175856.A540@dragon.nuxi.com> Date: Tue, 19 Jun 2001 09:53:36 +0200 Message-ID: <91266.992937216@axl.seasidesoftware.co.za> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, 18 Jun 2001 17:58:57 MST, "David O'Brien" wrote: > NO! Please discuss them here first to make sure the proposed patch does > something needed. I don't think it's a biggy. Effectively, Chris was suggesting a patch to NetBSD's rc. Luke's smart enough to understand that, I think. Chris copied me on his message to Luke, and Luke response was level-headed. He basically questioned the usefulness of the patch and came up with some solid arguments against it. My plan is still to ignore all non-critical changes until we have exactly what NetBSD has, modulo necessary porting changes. Ciao, Sheldon. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 3:17:37 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id B171937B403 for ; Tue, 19 Jun 2001 03:17:34 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 39895 invoked by uid 1000); 19 Jun 2001 10:16:01 -0000 Date: Tue, 19 Jun 2001 13:16:01 +0300 From: Peter Pentchev To: Cy Schubert - ITSD Open Systems Group Cc: audit@FreeBSD.ORG, arch@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path Message-ID: <20010619131601.A39467@ringworld.oblivion.bg> Mail-Followup-To: Cy Schubert - ITSD Open Systems Group , audit@FreeBSD.ORG, arch@FreeBSD.ORG References: <20010618151831.J1713@ringworld.oblivion.bg> <200106190017.f5J0H8R17337@cwsys.cwsent.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <200106190017.f5J0H8R17337@cwsys.cwsent.com>; from Cy.Schubert@uumail.gov.bc.ca on Mon, Jun 18, 2001 at 05:16:46PM -0700 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, Jun 18, 2001 at 05:16:46PM -0700, Cy Schubert - ITSD Open Systems Group wrote: > In message <20010618151831.J1713@ringworld.oblivion.bg>, Peter Pentchev > writes: > > On Mon, Jun 18, 2001 at 03:13:24PM +0300, Ruslan Ermilov wrote: > > > > > > Excuse me, but what's wrong with sysctl(8) editing kern.module_path? > > > > Well, as I noted at the start of the message, this is a scripts-friendly > > utility - it allows adding/removing/inserting individual paths without > > the need to parse the whole. > > But it could be a script friendly Perl script that calls sysctl. Right? Not really; not if it's in /sbin, not if it's used at startup time. Perl might not be available early in the boot process. Well, ok, so the modules path does not really need not be changed so early, but why not give admins the chance to create bullet-shaped holes in their lower appendages, if they should so desire.. G'luck, Peter -- This sentence contradicts itself - or rather - well, no, actually it doesn't! To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 3:29: 5 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id B99A037B406 for ; Tue, 19 Jun 2001 03:28:59 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 40054 invoked by uid 1000); 19 Jun 2001 10:27:28 -0000 Date: Tue, 19 Jun 2001 13:27:28 +0300 From: Peter Pentchev To: arch@FreeBSD.org Cc: Chris Wasser Subject: Re: netbsd rc.subr diff #2 Message-ID: <20010619132728.A40002@ringworld.oblivion.bg> Mail-Followup-To: arch@FreeBSD.org, Chris Wasser References: <20010617164716.H582@skunkworks.arpa.mil> <20010618180052.B540@dragon.nuxi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010618180052.B540@dragon.nuxi.com>; from arch@freebsd.org on Mon, Jun 18, 2001 at 06:00:52PM -0700 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, Jun 18, 2001 at 06:00:52PM -0700, David O'Brien wrote: > On Sun, Jun 17, 2001 at 04:47:17PM -0600, Chris Wasser wrote: > > - ps -p $_pid -o 'pid,command' | while read _npid _arg0 _argv; do > > - if [ "$_npid" = "PID" ]; then > > - continue > > - fi > > + ps -p $_pid -o 'pid,command' | tail +2 | sort +1 | while read _npid _arg0 _argv; do > > > Will people say the 2 added |'s slows things down [too much]? > Remember NetBSD runs on some rather slow, old hardware. And also.. Apologies for the stupid question, but - could this ever be invoked before /usr is mounted and /usr/bin/tail and /usr/bin/sort are available? G'luck, Peter -- This inert sentence is my body, but my soul is alive, dancing in the sparks of your brain. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 4:58:51 2001 Delivered-To: freebsd-arch@freebsd.org Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by hub.freebsd.org (Postfix) with ESMTP id 0832537B401 for ; Tue, 19 Jun 2001 04:58:48 -0700 (PDT) (envelope-from des@ofug.org) Received: (from des@localhost) by flood.ping.uio.no (8.9.3/8.9.3) id NAA54534; Tue, 19 Jun 2001 13:58:43 +0200 (CEST) (envelope-from des@ofug.org) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: arch@FreeBSD.ORG Cc: Chris Wasser Subject: Re: netbsd rc.subr diff #2 References: <20010617164716.H582@skunkworks.arpa.mil> <20010618180052.B540@dragon.nuxi.com> From: Dag-Erling Smorgrav Date: 19 Jun 2001 13:58:43 +0200 In-Reply-To: <20010618180052.B540@dragon.nuxi.com> Message-ID: Lines: 10 User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG "David O'Brien" writes: > Will people say the 2 added |'s slows things down [too much]? On the contrary - two additional forks are nothing compared to what you save by not forking off /bin/test for every line of ps output ([ is not a builtin in ash). DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 8:58:14 2001 Delivered-To: freebsd-arch@freebsd.org Received: from rover.village.org (rover.bsdimp.com [204.144.255.66]) by hub.freebsd.org (Postfix) with ESMTP id 411A537B401; Tue, 19 Jun 2001 08:58:08 -0700 (PDT) (envelope-from imp@billy-club.village.org) Received: from billy-club.village.org (billy-club.village.org [10.0.0.3]) by rover.village.org (8.11.3/8.11.3) with ESMTP id f5JFw6695192; Tue, 19 Jun 2001 09:58:06 -0600 (MDT) (envelope-from imp@billy-club.village.org) Received: from billy-club.village.org (localhost [127.0.0.1]) by billy-club.village.org (8.11.2/8.8.3) with ESMTP id f5JFw1l61591; Tue, 19 Jun 2001 09:58:05 -0600 (MDT) Message-Id: <200106191558.f5JFw1l61591@billy-club.village.org> To: Doug Barton Subject: Re: Changes to the /etc/rc* boot system Cc: freebsd-hackers@FreeBSD.ORG, freebsd-arch@FreeBSD.ORG In-reply-to: Your message of "Mon, 18 Jun 2001 23:32:24 PDT." <3B2EF1F8.9710CC61@DougBarton.net> References: <3B2EF1F8.9710CC61@DougBarton.net> <20010618175638.L37408-100000@dt051n37.san.rr.com> <200106190451.f5J4ppV59574@harmony.village.org> Date: Tue, 19 Jun 2001 09:58:01 -0600 From: Warner Losh Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <3B2EF1F8.9710CC61@DougBarton.net> Doug Barton writes: : [Prelude, Warner and I discussed this off line... ] Yea. I'm getting too grumpy for reasons that are outside the list. Doug is aware of my concerns, and I'm sure he'll take them into account as he moves forward. : > Of course, I'd have to : > run the changes by the responsible parties of for those parts of the : > NetBSD tree. I've had experience with integrating code into the : > NetBSD tree, so I have some perspective that most people don't have. : : That is definitely the kind of help we need. I have some limited : experience in working with openbsd folks on cross-platform issues, but : the more the merrier. Working with the OpenBSD folks and the NetBSD folks are worlds apart in many ways. This is both good and bad :-). And it usually isn't the person you are working directly with that will cause problems for you. Someone else in the project will freak at something that is totally insane, or so it seems, and you'll have to deal. However, all projects are weird in some way, and the other BSDs are really no worse than FreeBSD in this respect for most poeple. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 10:54:45 2001 Delivered-To: freebsd-arch@freebsd.org Received: from falcon.mail.pas.earthlink.net (falcon.mail.pas.earthlink.net [207.217.120.74]) by hub.freebsd.org (Postfix) with ESMTP id 8E90A37B403; Tue, 19 Jun 2001 10:54:42 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from mindspring.com (dialup-209.244.104.1.Dial1.SanJose1.Level3.net [209.244.104.1]) by falcon.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id KAA06513; Tue, 19 Jun 2001 10:54:39 -0700 (PDT) Message-ID: <3B2F91FE.3C54D2FB@mindspring.com> Date: Tue, 19 Jun 2001 10:55:10 -0700 From: Terry Lambert Reply-To: tlambert2@mindspring.com X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Garrett Wollman Cc: msmith@FreeBSD.ORG, arch@FreeBSD.ORG Subject: Re: sysorg: sys/modules References: <200106151216.IAA22612@khavrinen.lcs.mit.edu> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Garrett Wollman wrote: > >This pushes us back to a single filename namespace, which is > >less than a wonderful idea. 8( > > We're always going to have that so long as we continue to expect > static linkage to work. A convincing, if brief, argument. Let's rip it out; it has always been a barrier to progress, not to mention the lack of a dlopen() in many programs which need one, simply because they are statically linked. I guess it would be nice if linkinging libraries against libraries, and the "ldd" comand worked everywhere, too. I'm sold. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 11: 9:59 2001 Delivered-To: freebsd-arch@freebsd.org Received: from falcon.mail.pas.earthlink.net (falcon.mail.pas.earthlink.net [207.217.120.74]) by hub.freebsd.org (Postfix) with ESMTP id 5611137B406; Tue, 19 Jun 2001 11:09:54 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from mindspring.com (dialup-209.244.104.1.Dial1.SanJose1.Level3.net [209.244.104.1]) by falcon.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id LAA27797; Tue, 19 Jun 2001 11:09:51 -0700 (PDT) Message-ID: <3B2F958E.BC556A1E@mindspring.com> Date: Tue, 19 Jun 2001 11:10:22 -0700 From: Terry Lambert Reply-To: tlambert2@mindspring.com X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: John Baldwin Cc: Peter Pentchev , arch@FreeBSD.ORG, audit@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG John Baldwin wrote: > To me, it seems more sensible to use the same interface that > ldconfig uses. Noooooooooooooooooooooooooooooooooooooooooooooooooooooooooo! ldconfig is a serious pain in the ass, ever since the "fix" that made it not look in the linkage or configured directories on a lookup miss. This is particularly aggregious if you have a "/opt" or some other place where you prefer to install your ports or locally developed software. Having to reboot to make things work really, really sucks -- and that is often necessary if you build code from the net, which FreeBSD has mistakenly included as part os the base system monolith. OpenSSL, OpenSSH, and the resolver library are three examples that leap lithely to mind. It is a serious pain that the default compilation options enable the machine specific optimizations and higher compile levels in the Linux OpenSSL, rendering it 2-3 time faster than the FreeBSD version, depending on hardware. I _do not want_ the FreeBSD version of this library when I'm linking my stuff. Likewise, the lack of a parallel, asynchronous resolver is a serious deficit in FreeBSD, which is the result of jamming the recolver into libc "because libresolv is how SVR4 and Linux do it, and it would be a pain to go through and change the network using ports to include the library linkage for the one time it would be necessary". UGH. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 11:42:20 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id 4E2F437B406 for ; Tue, 19 Jun 2001 11:42:13 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 5337 invoked by uid 1000); 19 Jun 2001 18:40:41 -0000 Date: Tue, 19 Jun 2001 21:40:41 +0300 From: Peter Pentchev To: Terry Lambert Cc: John Baldwin , arch@FreeBSD.ORG, audit@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path Message-ID: <20010619214041.E3535@ringworld.oblivion.bg> Mail-Followup-To: Terry Lambert , John Baldwin , arch@FreeBSD.ORG, audit@FreeBSD.ORG References: <3B2F958E.BC556A1E@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <3B2F958E.BC556A1E@mindspring.com>; from tlambert2@mindspring.com on Tue, Jun 19, 2001 at 11:10:22AM -0700 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, Jun 19, 2001 at 11:10:22AM -0700, Terry Lambert wrote: > John Baldwin wrote: > > To me, it seems more sensible to use the same interface that > > ldconfig uses. > > Noooooooooooooooooooooooooooooooooooooooooooooooooooooooooo! > > ldconfig is a serious pain in the ass, ever since the "fix" > that made it not look in the linkage or configured directories > on a lookup miss. > > This is particularly aggregious if you have a "/opt" or some > other place where you prefer to install your ports or locally > developed software. Uh.. Terry.. have you even looked to check what this new kldconfig thing is supposed to do? :) kldconfig(8) does not traverse any directories; it just modifies a list of paths. As other posters in this thread have made me believe, it doesn't even need to check for the existence of the paths. The only kind of path traversing in the KLD case is done at module-load time, by the linker_search_path() function in sys/kern/kern_linker.c, invoked by kldload() syscall defined in the same file. It is there that any kind of checks should be made (currently none, though I plan on addressing this soon, in a very-very-very simple way, if Robert Watson doesn't do his MAC thing first :). kldconfig(8) just reads a sysctl value, parses it into a list of paths, parses some user-specified options, adds or removes paths as appropriate, and sets the sysctl value back. G'luck, Peter -- This sentence is false. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 11:52:40 2001 Delivered-To: freebsd-arch@freebsd.org Received: from meow.osd.bsdi.com (meow.osd.bsdi.com [204.216.28.88]) by hub.freebsd.org (Postfix) with ESMTP id 39D8137B409; Tue, 19 Jun 2001 11:52:33 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: from laptop.baldwin.cx (john@jhb-laptop.osd.bsdi.com [204.216.28.241]) by meow.osd.bsdi.com (8.11.3/8.11.2) with ESMTP id f5JIqQ113690; Tue, 19 Jun 2001 11:52:26 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.4.0 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <3B2F958E.BC556A1E@mindspring.com> Date: Tue, 19 Jun 2001 11:09:44 -0700 (PDT) From: John Baldwin To: Terry Lambert Subject: Re: new kldpath(8): display/modify the module search path Cc: audit@FreeBSD.org, arch@FreeBSD.org, Peter Pentchev Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 19-Jun-01 Terry Lambert wrote: > John Baldwin wrote: >> To me, it seems more sensible to use the same interface that >> ldconfig uses. > > Noooooooooooooooooooooooooooooooooooooooooooooooooooooooooo! Terry, I mean interface in terms of having the command switches be the same. I.e., dont' have -r do a rescan for one but remove a path for the other. This has nothing to do with your difficulties with certain libraries. -- John Baldwin -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.baldwin.cx/~john/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 12: 5: 0 2001 Delivered-To: freebsd-arch@freebsd.org Received: from nothing-going-on.demon.co.uk (pc-62-31-42-140-hy.blueyonder.co.uk [62.31.42.140]) by hub.freebsd.org (Postfix) with ESMTP id D7CB337B401 for ; Tue, 19 Jun 2001 12:04:53 -0700 (PDT) (envelope-from nik@nothing-going-on.demon.co.uk) Received: (from nik@localhost) by nothing-going-on.demon.co.uk (8.11.3/8.11.3) id f5JIqNf59846 for arch@freebsd.org; Tue, 19 Jun 2001 19:52:23 +0100 (BST) (envelope-from nik) Date: Tue, 19 Jun 2001 19:52:23 +0100 From: Nik Clayton To: arch@freebsd.org Subject: [PATCH] Show login(1) how to execute programs at start up Message-ID: <20010619195223.E68877@clan.nothing-going-on.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-md5; protocol="application/pgp-signature"; boundary="sDKAb4OeUBrWWL6P" Content-Disposition: inline User-Agent: Mutt/1.2.5i Organization: FreeBSD Project Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --sDKAb4OeUBrWWL6P Content-Type: multipart/mixed; boundary="ILuaRSyQpoVaJ1HG" Content-Disposition: inline --ILuaRSyQpoVaJ1HG Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I want to make the new 'tips' fortunes the default for new users at system startup. During IRC discussion, a number of ways of doing this were knocked back and forth. Several people voiced the opinion that this should be selectable in some way when adding users, particularly when using either sysinstall or adduser. * Dropping the code in the standard /usr/share/skel files. Trivial to implement. Trivial for an SA to change, difficult to teach sysinstall/adduser about. * Having a different set of skeleton files (or components that are cat(1)'ed together. Less trivial to implement, and now a lot of tools that do user addition would need to know about it as well. * Putting the functionality in to login.conf. Now you can have classes of users who will or will not receive tips at startup. Sysinstall and adduser already know enough to=20 ask you about classes when adding users. Provides additional functionality over and above what we already have. Attached is a small diff to login.c to do this. With this patch, the "welcome" capability is now a comma-delimited string of files or programs (and command line arguments). Files are referenced as before, programs have a leading "|" symbol. To add fortunes at startup for everybody you'd put ... welcome=3D/etc/motd,|/usr/games/fortune freebsd-tips:\ ... A hypothetical guru class would just have ... welcome=3D/etc/motd:\ ... instead. This patch also removes a small bit of functionality. Prior to the patch, if no welcome capability was set, or the file referenced in the=20 welcome capability didn't exist, or access( , F_OK) failed then=20 _PATH_MOTDFILE was automatically used. With this patch, that's only done= =20 if the welcome capability was not set. N --=20 FreeBSD: The Power to Serve http://www.freebsd.org/ FreeBSD Documentation Project http://www.freebsd.org/docproj/ --- 15B8 3FFC DDB4 34B0 AA5F 94B7 93A8 0764 2C37 E375 --- --ILuaRSyQpoVaJ1HG Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="login.c.diff" Content-Transfer-Encoding: quoted-printable Index: login.c =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/ncvs/src/usr.bin/login/login.c,v retrieving revision 1.63 diff -u -r1.63 login.c --- login.c 2001/05/22 06:20:27 1.63 +++ login.c 2001/06/19 18:48:02 @@ -125,6 +125,7 @@ static int auth_traditional __P((void)); extern void login __P((struct utmp *)); static void usage __P((void)); +static void welcome __P((char *)); =20 #define TTYGRPNAME "tty" /* name of group to own ttys */ #define DEFAULT_BACKOFF 3 @@ -669,9 +670,9 @@ (void)printf("\n"); =20 cw =3D login_getcapstr(lc, "welcome", NULL, NULL); - if (cw =3D=3D NULL || access(cw, F_OK) !=3D 0) + if (cw =3D=3D NULL) cw =3D _PATH_MOTDFILE; - motd(cw); + welcome(cw); =20 cw =3D getenv("MAIL"); /* $MAIL may have been set by class */ if (cw !=3D NULL) { @@ -938,6 +939,24 @@ int signo; { motdinterrupt =3D 1; +} + +static void +welcome(w) + char *w; +{ + char *p; + + p =3D strtok(w, ","); + if (p =3D=3D NULL) + return; + do { + if (*p =3D=3D '|')=20 + system(++p); + else=20 + if (access(p, F_OK) =3D=3D 0) + motd(p); + } while ((p =3D strtok(NULL, ",")) !=3D NULL); } =20 void --ILuaRSyQpoVaJ1HG-- --sDKAb4OeUBrWWL6P Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (FreeBSD) Comment: For info see http://www.gnupg.org iEYEARECAAYFAjsvn2cACgkQk6gHZCw343WEHQCfRlGmSh2JVT+1y3M5v/8XdwOd OLcAn0XhHBAuia6WBAGDfpO/o1izcIBo =JDs0 -----END PGP SIGNATURE----- --sDKAb4OeUBrWWL6P-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 12: 5:24 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ns.yogotech.com (ns.yogotech.com [206.127.123.66]) by hub.freebsd.org (Postfix) with ESMTP id 18E4837B403; Tue, 19 Jun 2001 12:05:17 -0700 (PDT) (envelope-from nate@yogotech.com) Received: from nomad.yogotech.com (nomad.yogotech.com [206.127.123.131]) by ns.yogotech.com (8.9.3/8.9.3) with ESMTP id NAA20484; Tue, 19 Jun 2001 13:05:12 -0600 (MDT) (envelope-from nate@nomad.yogotech.com) Received: (from nate@localhost) by nomad.yogotech.com (8.8.8/8.8.8) id NAA16251; Tue, 19 Jun 2001 13:05:09 -0600 (MDT) (envelope-from nate) From: Nate Williams MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15151.41572.721434.703837@nomad.yogotech.com> Date: Tue, 19 Jun 2001 13:05:08 -0600 (MDT) To: tlambert2@mindspring.com Cc: John Baldwin , Peter Pentchev , arch@FreeBSD.ORG, audit@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path In-Reply-To: <3B2F958E.BC556A1E@mindspring.com> References: <3B2F958E.BC556A1E@mindspring.com> X-Mailer: VM 6.75 under 21.1 (patch 12) "Channel Islands" XEmacs Lucid Reply-To: nate@yogotech.com (Nate Williams) Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > > To me, it seems more sensible to use the same interface that > > ldconfig uses. > > Noooooooooooooooooooooooooooooooooooooooooooooooooooooooooo! > > ldconfig is a serious pain in the ass, ever since the "fix" > that made it not look in the linkage or configured directories > on a lookup miss. > > This is particularly aggregious if you have a "/opt" or some > other place where you prefer to install your ports or locally > developed software. > > Having to reboot to make things work really, really sucks -- > and that is often necessary if you build code from the net, > which FreeBSD has mistakenly included as part os the base > system monolith. OpenSSL, OpenSSH, and the resolver library > are three examples that leap lithely to mind. Terry, it's simple to not have to reboot. Many ports already do this, but a 'ldconfig -R' tells it to re-scan the known directories to pickup new entries, which can be done at any time (as root of course). Nate To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 12:20:18 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id 001F537B401 for ; Tue, 19 Jun 2001 12:20:11 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 5819 invoked by uid 1000); 19 Jun 2001 19:18:40 -0000 Date: Tue, 19 Jun 2001 22:18:40 +0300 From: Peter Pentchev To: arch@FreeBSD.org Cc: audit@FreeBSD.org Subject: Re: new kldpath(8): display/modify the module search path Message-ID: <20010619221840.C5573@ringworld.oblivion.bg> Mail-Followup-To: arch@FreeBSD.org, audit@FreeBSD.org References: <3B2F958E.BC556A1E@mindspring.com> <20010619214041.E3535@ringworld.oblivion.bg> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010619214041.E3535@ringworld.oblivion.bg>; from roam@orbitel.bg on Tue, Jun 19, 2001 at 09:40:41PM +0300 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, Jun 19, 2001 at 09:40:41PM +0300, Peter Pentchev wrote: > On Tue, Jun 19, 2001 at 11:10:22AM -0700, Terry Lambert wrote: > > John Baldwin wrote: > > > To me, it seems more sensible to use the same interface that > > > ldconfig uses. > > > > Noooooooooooooooooooooooooooooooooooooooooooooooooooooooooo! > > > > ldconfig is a serious pain in the ass, ever since the "fix" > > that made it not look in the linkage or configured directories > > on a lookup miss. > > > > This is particularly aggregious if you have a "/opt" or some > > other place where you prefer to install your ports or locally > > developed software. > > Uh.. Terry.. have you even looked to check what this new > kldconfig thing is supposed to do? :) > > kldconfig(8) does not traverse any directories; it just modifies > a list of paths. As other posters in this thread have made me > believe, it doesn't even need to check for the existence of the paths. And for those who still haven't seen it, and would want to review another version (basically kldconfig-01 with ru's mdoc fixes), here's the new one: http://people.FreeBSD.org/~roam/devel/sys/kldconfig/kldconfig-02.tar.gz The index of http://people.FreeBSD.org/~roam/devel/sys/kldconfig/ has a brief history and links to this and the previous versions :) G'luck, Peter -- When you are not looking at it, this sentence is in Spanish. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 22:25:22 2001 Delivered-To: freebsd-arch@freebsd.org Received: from phaidor.thuvia.org (thuvia.demon.co.uk [193.237.34.248]) by hub.freebsd.org (Postfix) with ESMTP id 1C62D37B403; Tue, 19 Jun 2001 22:25:18 -0700 (PDT) (envelope-from mark@thuvia.demon.co.uk) Received: from dotar-sojat.thuvia.org (dotar-sojat.thuvia.org [10.0.0.4]) by phaidor.thuvia.org (8.11.3/8.11.3) with ESMTP id f5K5PRS17240; Wed, 20 Jun 2001 06:25:27 +0100 (BST) (envelope-from mark@dotar-sojat.thuvia.org) Received: (from mark@localhost) by dotar-sojat.thuvia.org (8.11.4/8.11.4) id f5K5P9Y31720; Wed, 20 Jun 2001 06:25:09 +0100 (BST) (envelope-from mark) Date: Wed, 20 Jun 2001 06:25:09 +0100 (BST) From: Mark Valentine Message-Id: <200106200525.f5K5P9Y31720@dotar-sojat.thuvia.org> In-Reply-To: Nik Clayton's message of Jun 19, 7:09pm X-Mailer: Mail User's Shell (7.2.6 beta(5) 10/07/98) To: nik@freebsd.org (Nik Clayton), arch@freebsd.org Subject: Re: [PATCH] Show login(1) how to execute programs at start up Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > From: nik@freebsd.org (Nik Clayton) > Date: Tue 19 Jun, 2001 > Subject: [PATCH] Show login(1) how to execute programs at start up > * Dropping the code in the standard /usr/share/skel files. I don't believe in /usr/share/skel; the default behaviour should not depend on startup files in a user's home directory. (Too easy to break, next to impossible to upgrade past.) > * Having a different set of skeleton files (or components that are > cat(1)'ed together. Evil^2. > * Putting the functionality in to login.conf. Yes, but policy, not implementation! > Attached is a small diff to login.c to do this. Hacking login(1) doesn't help xdm(1) users. Neither does specifying programs which spit terminal output in login.conf(5). (An xdm(1) user should get the contents of the file specified by the welcome capability displayed in a popup window or something; whatever programs can do this will break if you change the meaning of the welcome capability.) I would probably do this by adding a new boolean login capability "tips" (does this even need any code!?), and have a command line utility interface to getcap(3), then let /etc/profile, /etc/login, Xsession and friends do what they will to implement the policy, e.g. getcap tips && /usr/games/fortunes freebsd-tips Icing on the the cake would be a simple interface for the novice user to edit $HOME/.login.conf to disable/enable tips (among other things). Before login.conf(5) this would probably have beeb done similar to .hushlogin, with a nice simple user interface, e.g. test -f ~/.notips || /usr/games/fortunes freebsd-tips $ touch ~/.notips Cheers, Mark. -- Mark Valentine, Thuvia Labs "Tigers will do ANYTHING for a tuna fish sandwich." Mark Valentine uses "We're kind of stupid that way." *munch* *munch* and endorses FreeBSD -- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 23:18:29 2001 Delivered-To: freebsd-arch@freebsd.org Received: from harrier.mail.pas.earthlink.net (harrier.mail.pas.earthlink.net [207.217.121.12]) by hub.freebsd.org (Postfix) with ESMTP id 14D8837B403; Tue, 19 Jun 2001 23:18:26 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from mindspring.com (dialup-209.247.138.115.Dial1.SanJose1.Level3.net [209.247.138.115]) by harrier.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id XAA20892; Tue, 19 Jun 2001 23:18:19 -0700 (PDT) Message-ID: <3B304000.800BBCF5@mindspring.com> Date: Tue, 19 Jun 2001 23:17:36 -0700 From: Terry Lambert Reply-To: tlambert2@mindspring.com X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Nik Clayton Cc: arch@FreeBSD.ORG Subject: Re: [PATCH] Show login(1) how to execute programs at start up References: <20010619195223.E68877@clan.nothing-going-on.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Nik Clayton wrote: > Attached is a small diff to login.c to do this. > > With this patch, the "welcome" capability is now a comma-delimited > string of files or programs (and command line arguments). Files are > referenced as before, programs have a leading "|" symbol. To add > fortunes at startup for everybody you'd put > > ... > welcome=/etc/motd,|/usr/games/fortune freebsd-tips:\ > ... What happens if the program won't run; can you still login? The login.conf is important for rebadging FreeBSD based embedded systems; it seems that putting the code in /usr/share/skel is really the best bet. Maybe I'm not understanding the sysinstall/adduser problem? Why is there any teaching necessary? Last time I checked, the root login skeleton ran fortunes, if it was installed, by doing a test for the binary. This seems more reasonable. Alternately, could you limit it to _only_ MOTD, or _only_ running a program, and going back to the prior behavior in case of the program to run not being present? That would just ass a "|xxx" option as an addition, which would have the least impact. You could also put it in the file spewing code, which means that it would work for any option where a file was to be spewed, with the behaviour being as-if-not-specified, as in the missing file case, historically. For an example, the /etc/COPYRIGHT file replaces the login Copyright in the unmodified login.c today. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 23:26:28 2001 Delivered-To: freebsd-arch@freebsd.org Received: from harrier.mail.pas.earthlink.net (harrier.mail.pas.earthlink.net [207.217.121.12]) by hub.freebsd.org (Postfix) with ESMTP id 4229637B406; Tue, 19 Jun 2001 23:26:21 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from mindspring.com (dialup-209.247.138.115.Dial1.SanJose1.Level3.net [209.247.138.115]) by harrier.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id XAA14036; Tue, 19 Jun 2001 23:24:55 -0700 (PDT) Message-ID: <3B3041D7.28CB375E@mindspring.com> Date: Tue, 19 Jun 2001 23:25:27 -0700 From: Terry Lambert Reply-To: tlambert2@mindspring.com X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Nate Williams Cc: John Baldwin , Peter Pentchev , arch@FreeBSD.ORG, audit@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path References: <3B2F958E.BC556A1E@mindspring.com> <15151.41572.721434.703837@nomad.yogotech.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Nate Williams wrote: > > Having to reboot to make things work really, really sucks -- > > and that is often necessary if you build code from the net, > > which FreeBSD has mistakenly included as part os the base > > system monolith. OpenSSL, OpenSSH, and the resolver library > > are three examples that leap lithely to mind. > > Terry, it's simple to not have to reboot. Many ports already > do this, but a 'ldconfig -R' tells it to re-scan the known > directories to pickup new entries, which can be done at any > time (as root of course). It was pointed out that the code just sets a path (or adds to one, which makes the most sense in the case of multiple rc.d's). I still have a small problem with the path setting automating load of things installed in /usr/local (e.g. the vmware modules), since there isn't a "rebuild requirement" for the modules which are not themselves built as part of the kernel build. I also have a slight problem with the module path being capable of being set to include some directory before /modules. What is the interaction with /etc/modules.old, when you are booting a /kernel.old? It seems to me that it would be very easy to boot a /kernel.old, and end up with mismatched modules from an rc file setting the path to /modules instead of /modules.old... This seems like something that should maybe be a sysctl, instead, and have a default behaviour of "append to path" in the rc file implementation, to ensure that the booted kernel and modules directory matched, no matter what kernel you booted. I might even go so far as to say that if a kernel other than /kernel was being booted, that it ought to become read-only, to prevent a mismatched module from being loaded unintentionally... -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 23:26:51 2001 Delivered-To: freebsd-arch@freebsd.org Received: from harrier.mail.pas.earthlink.net (harrier.mail.pas.earthlink.net [207.217.121.12]) by hub.freebsd.org (Postfix) with ESMTP id BE6D137B406; Tue, 19 Jun 2001 23:26:44 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from mindspring.com (dialup-209.247.138.115.Dial1.SanJose1.Level3.net [209.247.138.115]) by harrier.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id XAA19809; Tue, 19 Jun 2001 23:26:40 -0700 (PDT) Message-ID: <3B304241.DE787305@mindspring.com> Date: Tue, 19 Jun 2001 23:27:13 -0700 From: Terry Lambert Reply-To: tlambert2@mindspring.com X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Nate Williams Cc: John Baldwin , Peter Pentchev , arch@FreeBSD.ORG, audit@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path References: <3B2F958E.BC556A1E@mindspring.com> <15151.41572.721434.703837@nomad.yogotech.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Nate Williams wrote: > > Having to reboot to make things work really, really sucks -- > > and that is often necessary if you build code from the net, > > which FreeBSD has mistakenly included as part os the base > > system monolith. OpenSSL, OpenSSH, and the resolver library > > are three examples that leap lithely to mind. > > Terry, it's simple to not have to reboot. Many ports already > do this, but a 'ldconfig -R' tells it to re-scan the known > directories to pickup new entries, which can be done at any > time (as root of course). Didn't address this... This doesn't fix the "replace /lib with /lib.new" problem; think "mount(2)"... -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 23:39:11 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id AF51D37B403 for ; Tue, 19 Jun 2001 23:39:02 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 4878 invoked by uid 1000); 20 Jun 2001 06:37:30 -0000 Date: Wed, 20 Jun 2001 09:37:30 +0300 From: Peter Pentchev To: Terry Lambert Cc: Nate Williams , John Baldwin , arch@FreeBSD.ORG, audit@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path Message-ID: <20010620093730.C558@ringworld.oblivion.bg> Mail-Followup-To: Terry Lambert , Nate Williams , John Baldwin , arch@FreeBSD.ORG, audit@FreeBSD.ORG References: <3B2F958E.BC556A1E@mindspring.com> <15151.41572.721434.703837@nomad.yogotech.com> <3B3041D7.28CB375E@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <3B3041D7.28CB375E@mindspring.com>; from tlambert2@mindspring.com on Tue, Jun 19, 2001 at 11:25:27PM -0700 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, Jun 19, 2001 at 11:25:27PM -0700, Terry Lambert wrote: > Nate Williams wrote: > > > Having to reboot to make things work really, really sucks -- > > > and that is often necessary if you build code from the net, > > > which FreeBSD has mistakenly included as part os the base > > > system monolith. OpenSSL, OpenSSH, and the resolver library > > > are three examples that leap lithely to mind. > > > > Terry, it's simple to not have to reboot. Many ports already > > do this, but a 'ldconfig -R' tells it to re-scan the known > > directories to pickup new entries, which can be done at any > > time (as root of course). > > It was pointed out that the code just sets a path (or adds > to one, which makes the most sense in the case of multiple > rc.d's). > > I still have a small problem with the path setting automating > load of things installed in /usr/local (e.g. the vmware > modules), since there isn't a "rebuild requirement" for the > modules which are not themselves built as part of the kernel > build. If you are not prepared to rebuild them automatically, don't autoload them. Just setting the path does NOT cause module autoloading, you have to explicitly invoke kldload() to load a module. If the module was loaded automatically before, it will be loaded automatically now, too, regardless of the path setting. > I also have a slight problem with the module path being > capable of being set to include some directory before > /modules. If you don't want to do this, don't do it. It's as simple as that. > What is the interaction with /etc/modules.old, when you are > booting a /kernel.old? > > It seems to me that it would be very easy to boot a /kernel.old, > and end up with mismatched modules from an rc file setting the > path to /modules instead of /modules.old... In -current, booting a /boot/kernel.old/ automatically sets the module search path to /boot/kernel.old/. There are no rc files involved, the default search path is set by the loader and the kernel themselves (look at sys/kern/kern_linker.c). > This seems like something that should maybe be a sysctl, > instead, and have a default behaviour of "append to path" > in the rc file implementation, to ensure that the booted > kernel and modules directory matched, no matter what > kernel you booted. It is a sysctl already, and the kernel does ensure the booted kernel and modules directory match. If you later call kldconfig(8) without a -m option, you shoot yourself in the foot. If you call ldconfig(8) without an -m option, you shoot yourself in the foot. > I might even go so far as to say that if a kernel other > than /kernel was being booted, that it ought to become > read-only, to prevent a mismatched module from being > loaded unintentionally... Hmm.. this, at last, is a really interesting idea that does deserve some thought :) However, it is a part of the next round of changes - the kernel linker itself validating the module search paths set by kldconfig(8), or (currently and since forever) by the sysctl. G'luck, Peter -- This would easier understand fewer had omitted. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Jun 19 23:41:34 2001 Delivered-To: freebsd-arch@freebsd.org Received: from meow.osd.bsdi.com (meow.osd.bsdi.com [204.216.28.88]) by hub.freebsd.org (Postfix) with ESMTP id 1BAAB37B401 for ; Tue, 19 Jun 2001 23:41:32 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: from laptop.baldwin.cx (john@jhb-laptop.osd.bsdi.com [204.216.28.241]) by meow.osd.bsdi.com (8.11.3/8.11.2) with ESMTP id f5K6fEI22418; Tue, 19 Jun 2001 23:41:14 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.4.0 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <3B3041D7.28CB375E@mindspring.com> Date: Tue, 19 Jun 2001 23:23:27 -0700 (PDT) From: John Baldwin To: Terry Lambert Subject: Re: new kldpath(8): display/modify the module search path Cc: arch@FreeBSD.org, Peter Pentchev , Nate Williams Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 20-Jun-01 Terry Lambert wrote: > What is the interaction with /etc/modules.old, when you are > booting a /kernel.old? In -current (which is where kldconfig(8) is going, btw) all modules live with their correspnding kernel in the same directory under /boot. Thus modules and kernel are in sync for kernel.old, kernel, and kernel.fix_it_after_joe_random_committer_broke_it. -- John Baldwin -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.baldwin.cx/~john/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 0:12:24 2001 Delivered-To: freebsd-arch@freebsd.org Received: from harrier.mail.pas.earthlink.net (harrier.mail.pas.earthlink.net [207.217.121.12]) by hub.freebsd.org (Postfix) with ESMTP id 2BC4337B401; Wed, 20 Jun 2001 00:12:22 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from mindspring.com (dialup-209.247.138.115.Dial1.SanJose1.Level3.net [209.247.138.115]) by harrier.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id AAA08471; Wed, 20 Jun 2001 00:12:20 -0700 (PDT) Message-ID: <3B304CF4.3A57593E@mindspring.com> Date: Wed, 20 Jun 2001 00:12:52 -0700 From: Terry Lambert Reply-To: tlambert2@mindspring.com X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: John Baldwin Cc: arch@FreeBSD.org, Peter Pentchev , Nate Williams Subject: Re: new kldpath(8): display/modify the module search path References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG John Baldwin wrote: > > On 20-Jun-01 Terry Lambert wrote: > > What is the interaction with /etc/modules.old, when you are > > booting a /kernel.old? > > In -current (which is where kldconfig(8) is going, btw) all > modules live with their correspnding kernel in the same > directory under /boot. Thus modules and kernel are in sync > for kernel.old, kernel, and > kernel.fix_it_after_joe_random_committer_broke_it. I thought this change was backed out, after everyone hated it? Even so, what ensures that the path is not reset by some rc file to /boot/kernel, when the kernel that you booted was /boot/kernel.old/kernel.ko? I don't see that putting the modules under /boot with the kernel module itself grants any protection from a bogus mismatched module coming in as the result of a kldpath command in an rc file in /usr/local/etc/rc.d, or /etc, for that matter. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 3: 3: 2 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by hub.freebsd.org (Postfix) with ESMTP id 2A58537B401; Wed, 20 Jun 2001 03:02:57 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id UAA17927; Wed, 20 Jun 2001 20:02:53 +1000 Date: Wed, 20 Jun 2001 20:01:04 +1000 (EST) From: Bruce Evans X-Sender: bde@besplex.bde.org To: John Baldwin Cc: Terry Lambert , arch@FreeBSD.ORG, Peter Pentchev , Nate Williams Subject: Re: new kldpath(8): display/modify the module search path In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, 19 Jun 2001, John Baldwin wrote: > On 20-Jun-01 Terry Lambert wrote: > > What is the interaction with /etc/modules.old, when you are > > booting a /kernel.old? > > In -current (which is where kldconfig(8) is going, btw) all modules live with > their correspnding kernel in the same directory under /boot. Thus modules and > kernel are in sync for kernel.old, kernel, and > kernel.fix_it_after_joe_random_committer_broke_it. This means that the existence of a module search path is just a bug. The kernel shouldn't use a search path or add a path prefix for kldload(2) any more than it should for execve(2), but adding a path prefix is necessary for modules loaded directly by the kernel. I used to think that a search path (with one element) was necessary for locating the modules, but now the modules are together with the kernel, the one-element search path can be derived from kernelname[]. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 3:19: 1 2001 Delivered-To: freebsd-arch@freebsd.org Received: from Awfulhak.org (gw.Awfulhak.org [217.204.245.18]) by hub.freebsd.org (Postfix) with ESMTP id 30A1937B406; Wed, 20 Jun 2001 03:18:57 -0700 (PDT) (envelope-from brian@Awfulhak.org) Received: from hak.lan.Awfulhak.org (root@hak.lan.Awfulhak.org [172.16.0.12]) by Awfulhak.org (8.11.4/8.11.4) with ESMTP id f5KAIhi79552; Wed, 20 Jun 2001 11:18:43 +0100 (BST) (envelope-from brian@lan.Awfulhak.org) Received: from hak.lan.Awfulhak.org (brian@localhost [127.0.0.1]) by hak.lan.Awfulhak.org (8.11.4/8.11.4) with ESMTP id f5KAIgh28526; Wed, 20 Jun 2001 11:18:42 +0100 (BST) (envelope-from brian@hak.lan.Awfulhak.org) Message-Id: <200106201018.f5KAIgh28526@hak.lan.Awfulhak.org> X-Mailer: exmh version 2.3.1 01/18/2001 with nmh-1.0.4 To: Bruce Evans Cc: John Baldwin , Terry Lambert , arch@FreeBSD.ORG, Peter Pentchev , Nate Williams , brian@Awfulhak.org Subject: Re: new kldpath(8): display/modify the module search path In-Reply-To: Message from Bruce Evans of "Wed, 20 Jun 2001 20:01:04 +1000." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Wed, 20 Jun 2001 11:18:42 +0100 From: Brian Somers Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > On Tue, 19 Jun 2001, John Baldwin wrote: > > > On 20-Jun-01 Terry Lambert wrote: > > > What is the interaction with /etc/modules.old, when you are > > > booting a /kernel.old? > > > > In -current (which is where kldconfig(8) is going, btw) all modules live with > > their correspnding kernel in the same directory under /boot. Thus modules and > > kernel are in sync for kernel.old, kernel, and > > kernel.fix_it_after_joe_random_committer_broke_it. > > This means that the existence of a module search path is just a bug. > The kernel shouldn't use a search path or add a path prefix for > kldload(2) any more than it should for execve(2), but adding a path > prefix is necessary for modules loaded directly by the kernel. I used > to think that a search path (with one element) was necessary for > locating the modules, but now the modules are together with the kernel, > the one-element search path can be derived from kernelname[]. No. It means that whatever sets the module search path had better be careful to use directories that are consistent with the running kernel. For example, if someone creates a mechanism to build ports modules just after running buildkernel and install them just after running installkernel, they may want to move /usr/local/boot/modules to /usr/local/boot/modules.old before installing and set the module search path appropriately depending on the running kernel. It may also be a good idea to investigate the use of a /usr/boot/kernel* type component for modules that aren't required before /usr is mounted (similar to Solaris's setup). The existence of a module search path is not a bug. Its setting may currently be wrong though. > Bruce -- Brian Don't _EVER_ lose your sense of humour ! To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 9:51: 7 2001 Delivered-To: freebsd-arch@freebsd.org Received: from meow.osd.bsdi.com (meow.osd.bsdi.com [204.216.28.88]) by hub.freebsd.org (Postfix) with ESMTP id 370FB37B401 for ; Wed, 20 Jun 2001 09:51:05 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: from laptop.baldwin.cx (john@jhb-laptop.osd.bsdi.com [204.216.28.241]) by meow.osd.bsdi.com (8.11.3/8.11.2) with ESMTP id f5KGoQI29000; Wed, 20 Jun 2001 09:50:26 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.4.0 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <3B304CF4.3A57593E@mindspring.com> Date: Wed, 20 Jun 2001 09:50:51 -0700 (PDT) From: John Baldwin To: Terry Lambert Subject: Re: new kldpath(8): display/modify the module search path Cc: Nate Williams , Peter Pentchev , arch@FreeBSD.org Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 20-Jun-01 Terry Lambert wrote: > John Baldwin wrote: >> >> On 20-Jun-01 Terry Lambert wrote: >> > What is the interaction with /etc/modules.old, when you are >> > booting a /kernel.old? >> >> In -current (which is where kldconfig(8) is going, btw) all >> modules live with their correspnding kernel in the same >> directory under /boot. Thus modules and kernel are in sync >> for kernel.old, kernel, and >> kernel.fix_it_after_joe_random_committer_broke_it. > > I thought this change was backed out, after everyone > hated it? Nope. Mostly cause everyone didn't hate it. > Even so, what ensures that the path is not reset by some rc > file to /boot/kernel, when the kernel that you booted was > /boot/kernel.old/kernel.ko? > > I don't see that putting the modules under /boot with the > kernel module itself grants any protection from a bogus > mismatched module coming in as the result of a kldpath > command in an rc file in /usr/local/etc/rc.d, or /etc, > for that matter. Unix has traditionally allowed foot shooting. -- John Baldwin -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.baldwin.cx/~john/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 10:19:31 2001 Delivered-To: freebsd-arch@freebsd.org Received: from swan.mail.pas.earthlink.net (swan.mail.pas.earthlink.net [207.217.120.123]) by hub.freebsd.org (Postfix) with ESMTP id 5EB9F37B401; Wed, 20 Jun 2001 10:19:28 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from mindspring.com (dialup-209.244.104.7.Dial1.SanJose1.Level3.net [209.244.104.7]) by swan.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id KAA13907; Wed, 20 Jun 2001 10:19:18 -0700 (PDT) Message-ID: <3B30DB35.493B0D92@mindspring.com> Date: Wed, 20 Jun 2001 10:19:49 -0700 From: Terry Lambert Reply-To: tlambert2@mindspring.com X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Bruce Evans Cc: John Baldwin , arch@FreeBSD.ORG, Peter Pentchev , Nate Williams Subject: Re: new kldpath(8): display/modify the module search path References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bruce Evans wrote: > This means that the existence of a module search path is just a bug. > The kernel shouldn't use a search path or add a path prefix for > kldload(2) any more than it should for execve(2), but adding a path > prefix is necessary for modules loaded directly by the kernel. I used > to think that a search path (with one element) was necessary for > locating the modules, but now the modules are together with the kernel, > the one-element search path can be derived from kernelname[]. My impression is that the intent is to (ab)use this mechanism to hint to the kernel where to get modules so that it can demand-load them itself. I'm not opposed to the idea of the kernel doing this (I'm all for it, and have been since 1994, when I was shouted doun from puting a KLD-like linker into the newly released LKM infrastructure), but I'm very opposed to the kernel/loader being able to do this without giving me an opportunity to override to recover from a foot-shooting/shoot-footing. John Baldwin says that UNIX has traditionally permitted foot-shooting. Yes. But even in the worst cases, it has never offered to hold your foot for you. I think this code is premature. I think that the module/kernel version mismatch needs to be addressed (minimally, by gross version number and date) and the seperate, discardable "probe" segments first, so that: 1) The kernel can know it is demanding a bad thing, and refuse to do it, and 2) There is a way for the kernel to know that what it is demanding will end up having a positive overall effect. Only after that, does it make sense to provide a path for it to use for demand-loading. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 12:42:58 2001 Delivered-To: freebsd-arch@freebsd.org Received: from scaup.mail.pas.earthlink.net (scaup.mail.pas.earthlink.net [207.217.121.49]) by hub.freebsd.org (Postfix) with ESMTP id 8C66337B401 for ; Wed, 20 Jun 2001 12:42:56 -0700 (PDT) (envelope-from kway@overtone.org) Received: from bean.overtone.org (user-2inime5.dialup.mindspring.com [165.121.89.197]) by scaup.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id MAA06725; Wed, 20 Jun 2001 12:42:48 -0700 (PDT) Received: by bean.overtone.org (Postfix, from userid 1001) id 462805BABF; Wed, 20 Jun 2001 15:42:32 -0400 (EDT) Date: Wed, 20 Jun 2001 15:42:32 -0400 From: Kevin Way To: Doug Barton Cc: freebsd-arch@freebsd.org Subject: Re: Changes to the /etc/rc* boot system Message-ID: <20010620154231.A54685@bean.overtone.org> References: <20010618175638.L37408-100000@dt051n37.san.rr.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010618175638.L37408-100000@dt051n37.san.rr.com>; from DougB@DougBarton.net on Mon, Jun 18, 2001 at 06:12:04PM -0700 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG At one point, there was a notion of a temporary mailing list being setup so all the relevant people could share their thoughts and their patches, so that perhaps NetBSD and FreeBSD could both end up with an improved boot system. Is this still the plan? Even if it has to stay ultra-low-traffic for a while, due to people's schedules, at least we could start having our thoughts/initial patches be publicly archived. Kevin Way To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 17:50:45 2001 Delivered-To: freebsd-arch@freebsd.org Received: from dragon.nuxi.com (trang.nuxi.com [206.40.252.115]) by hub.freebsd.org (Postfix) with ESMTP id C3E2C37B401; Wed, 20 Jun 2001 17:50:40 -0700 (PDT) (envelope-from obrien@NUXI.com) Received: (from obrien@localhost) by dragon.nuxi.com (8.11.3/8.11.1) id f5L0o6C00456; Wed, 20 Jun 2001 17:50:06 -0700 (PDT) (envelope-from obrien) Date: Wed, 20 Jun 2001 17:50:06 -0700 From: "David O'Brien" To: Doug Barton Cc: Warner Losh , freebsd-hackers@FreeBSD.ORG, freebsd-arch@FreeBSD.ORG Subject: Re: Changes to the /etc/rc* boot system Message-ID: <20010620175006.A99923@dragon.nuxi.com> Reply-To: obrien@FreeBSD.ORG References: <20010618175638.L37408-100000@dt051n37.san.rr.com> <200106190451.f5J4ppV59574@harmony.village.org> <3B2EF1F8.9710CC61@DougBarton.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <3B2EF1F8.9710CC61@DougBarton.net>; from DougB@DougBarton.net on Mon, Jun 18, 2001 at 11:32:24PM -0700 X-Operating-System: FreeBSD 5.0-CURRENT Organization: The NUXI BSD group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, Jun 18, 2001 at 11:32:24PM -0700, Doug Barton wrote: > I think that we're closer to agreement here than it may appear. Last I > heard from obrien he was overloaded, and wasn't looking to head this up > himself unless no one else was going to do it. At this point I view myself as more of a facilitator than the one coming up with the patches. -- -- David (obrien@FreeBSD.org) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 17:56:39 2001 Delivered-To: freebsd-arch@freebsd.org Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by hub.freebsd.org (Postfix) with ESMTP id C580037B403; Wed, 20 Jun 2001 17:56:33 -0700 (PDT) (envelope-from des@ofug.org) Received: (from des@localhost) by flood.ping.uio.no (8.9.3/8.9.3) id CAA62331; Thu, 21 Jun 2001 02:56:32 +0200 (CEST) (envelope-from des@ofug.org) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: obrien@FreeBSD.ORG Cc: Doug Barton , Warner Losh , freebsd-hackers@FreeBSD.ORG, freebsd-arch@FreeBSD.ORG Subject: Re: Changes to the /etc/rc* boot system References: <20010618175638.L37408-100000@dt051n37.san.rr.com> <200106190451.f5J4ppV59574@harmony.village.org> <3B2EF1F8.9710CC61@DougBarton.net> <20010620175006.A99923@dragon.nuxi.com> From: Dag-Erling Smorgrav Date: 21 Jun 2001 02:56:31 +0200 In-Reply-To: <20010620175006.A99923@dragon.nuxi.com> Message-ID: Lines: 17 User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG "David O'Brien" writes: > On Mon, Jun 18, 2001 at 11:32:24PM -0700, Doug Barton wrote: > > I think that we're closer to agreement here than it may appear. Last I > > heard from obrien he was overloaded, and wasn't looking to head this up > > himself unless no one else was going to do it. > At this point I view myself as more of a facilitator than the one coming > up with the patches. I think a step in the right direction might be to fiddle with our Makefiles so that developers have the option to install the NetBSD rc stuff instead of our own. I know that it won't work properly for a while, but it would lower the amount of effort needed for anyone to start hacking on it. DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 18:36:34 2001 Delivered-To: freebsd-arch@freebsd.org Received: from relay.nuxi.com (nuxi.cs.ucdavis.edu [169.237.7.38]) by hub.freebsd.org (Postfix) with ESMTP id 44D5837B401 for ; Wed, 20 Jun 2001 18:36:23 -0700 (PDT) (envelope-from obrien@nuxi.ucdavis.edu) Received: from dragon.nuxi.com (root@trang.nuxi.com [206.40.252.115]) by relay.nuxi.com (8.11.2/8.11.2) with ESMTP id f5L1aCR05600 for ; Wed, 20 Jun 2001 18:36:12 -0700 (PDT) (envelope-from obrien@NUXI.com) Received: (from obrien@localhost) by dragon.nuxi.com (8.11.3/8.11.1) id f5L1W3x01197; Wed, 20 Jun 2001 18:32:03 -0700 (PDT) (envelope-from obrien) Date: Wed, 20 Jun 2001 18:31:59 -0700 From: "David O'Brien" To: Kevin Way Cc: Doug Barton , freebsd-arch@freebsd.org Subject: Re: Changes to the /etc/rc* boot system Message-ID: <20010620183159.A1158@dragon.nuxi.com> Reply-To: obrien@freebsd.org References: <20010618175638.L37408-100000@dt051n37.san.rr.com> <20010620154231.A54685@bean.overtone.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010620154231.A54685@bean.overtone.org>; from kevin.way@overtone.org on Wed, Jun 20, 2001 at 03:42:32PM -0400 X-Operating-System: FreeBSD 5.0-CURRENT Organization: The NUXI BSD group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, Jun 20, 2001 at 03:42:32PM -0400, Kevin Way wrote: > At one point, there was a notion of a temporary mailing list being setup > so all the relevant people could share their thoughts and their patches, > so that perhaps NetBSD and FreeBSD could both end up with an improved > boot system. Is this still the plan? Not that I know of. Unless people have a problem with it, I think -arch is the best place to talk about this. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 18:36:35 2001 Delivered-To: freebsd-arch@freebsd.org Received: from relay.nuxi.com (nuxi.cs.ucdavis.edu [169.237.7.38]) by hub.freebsd.org (Postfix) with ESMTP id DAEA537B409; Wed, 20 Jun 2001 18:36:15 -0700 (PDT) (envelope-from obrien@nuxi.ucdavis.edu) Received: from dragon.nuxi.com (root@trang.nuxi.com [206.40.252.115]) by relay.nuxi.com (8.11.2/8.11.2) with ESMTP id f5L1aER05606; Wed, 20 Jun 2001 18:36:14 -0700 (PDT) (envelope-from obrien@NUXI.com) Received: (from obrien@localhost) by dragon.nuxi.com (8.11.3/8.11.1) id f5L1L6700954; Wed, 20 Jun 2001 18:21:06 -0700 (PDT) (envelope-from obrien) Date: Wed, 20 Jun 2001 18:21:06 -0700 From: "David O'Brien" To: Dag-Erling Smorgrav Cc: Doug Barton , Warner Losh , freebsd-hackers@freebsd.org, freebsd-arch@freebsd.org Subject: Re: Changes to the /etc/rc* boot system Message-ID: <20010620182106.C99923@dragon.nuxi.com> Reply-To: obrien@freebsd.org References: <20010618175638.L37408-100000@dt051n37.san.rr.com> <200106190451.f5J4ppV59574@harmony.village.org> <3B2EF1F8.9710CC61@DougBarton.net> <20010620175006.A99923@dragon.nuxi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: ; from des@ofug.org on Thu, Jun 21, 2001 at 02:56:31AM +0200 X-Operating-System: FreeBSD 5.0-CURRENT Organization: The NUXI BSD group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Jun 21, 2001 at 02:56:31AM +0200, Dag-Erling Smorgrav wrote: > I think a step in the right direction might be to fiddle with our > Makefiles so that developers have the option to install the NetBSD rc > stuff instead of our own. I have patches for `rcorder' (posted to -arch). I will either commit them, or a new vendor import after USENIX. Once that is done, I'll add rcorder to src/sbin/Makefile. Here is a patch that will get the rc.d files install in the minimal amount of changes. Index: Makefile =================================================================== RCS file: /home/ncvs/src/etc/Makefile,v retrieving revision 1.255 diff -u -r1.255 Makefile --- Makefile 2001/06/13 16:39:23 1.255 +++ Makefile 2001/06/21 01:19:15 @@ -131,6 +131,8 @@ set -x; \ ln -s mail/aliases ${DESTDIR}/etc/aliases; \ fi + cd ${.CURDIR}/rc.d; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \ + ${RC_D} ${DESTDIR}/etc/rc.d ${INSTALL} -c -o ${BINOWN} -g operator -m 664 /dev/null \ ${DESTDIR}/etc/dumpdates ${INSTALL} -c -o nobody -g ${BINGRP} -m 644 /dev/null \ @@ -211,3 +213,6 @@ ${DESTDIR}/usr/share/examples/etc/defaults) .include + +.include "${.CURDIR}/rc.d/Makefile" +RC_D= ${FILES} To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 18:36:46 2001 Delivered-To: freebsd-arch@freebsd.org Received: from relay.nuxi.com (nuxi.cs.ucdavis.edu [169.237.7.38]) by hub.freebsd.org (Postfix) with ESMTP id 9FAAC37B403 for ; Wed, 20 Jun 2001 18:36:14 -0700 (PDT) (envelope-from obrien@nuxi.ucdavis.edu) Received: from dragon.nuxi.com (root@trang.nuxi.com [206.40.252.115]) by relay.nuxi.com (8.11.2/8.11.2) with ESMTP id f5L1aDR05603 for ; Wed, 20 Jun 2001 18:36:13 -0700 (PDT) (envelope-from obrien@NUXI.com) Received: (from obrien@localhost) by dragon.nuxi.com (8.11.3/8.11.1) id f5L1NKX01017 for arch@freebsd.org; Wed, 20 Jun 2001 18:23:20 -0700 (PDT) (envelope-from obrien) Date: Wed, 20 Jun 2001 18:23:20 -0700 From: "David O'Brien" To: arch@freebsd.org Subject: (FWD) Re: import NetBSD rc system Message-ID: <20010620182320.D99923@dragon.nuxi.com> Reply-To: obrien@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i X-Operating-System: FreeBSD 5.0-CURRENT Organization: The NUXI BSD group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Does anyone have any problems with this patch? If not I'd like to commit it. (I might make "rc_new" rc_ng" since everything else we have seems to be named that way) ----- Forwarded message from Gordon Tetlow ----- From: Gordon Tetlow Subject: Re: import NetBSD rc system Date: Sun, 17 Jun 2001 21:28:02 -0700 (PDT) To: "David O'Brien" Cc: "David O'Brien -Hackers" X-X-Sender: List-ID: List-Archive: (Web Archive) On Sat, 16 Jun 2001, David O'Brien wrote: > On Sat, Jun 16, 2001 at 07:58:06AM -0700, Gordon Tetlow wrote: > > I like Matt's idea (I think it was Matt) to have a new_rc switch. I'll > > look at adding the code for it and submitting a patch, > > You are going off on a tangent. You are worried about the flag day > before we even have a flag to run up the poll. Actually, this makes the import of the new rc system much easier. I've attached the patch against an older (may 11th) world. It should make it pretty clear. After this, all you need to do is import the rc.subr and the rc.d directory from the NetBSD project. Then to test the new boot system, all you need is rcorder and new_rc switched on in /etc/rc.conf. If you need to get back to the old boot system, just change the new_rc knob to off and you can boot normally. > > > > /etc/rc.subr ported > > > > > > What changes were needed here? > > > > I basically added a function called checkwildno() that is similar to > > checkyesno that returns 1 for NO (plus variants) or '' and returns 0 for > > anything else. This gets rid of alot of case statements in the modules, > > making them simple if's. > > Again, why don't we just concentrate on porting the NetBSD scripts and > not the second system enhancements? I agree. I'm a little further ahead on my local box than where we are on the repo. My big question is, do we want to keep the current boot order/logic or are we going with NetBSDs? Either way is fine by me, although I've tried to keep FreeBSDs system more than NetBSDs. -gordon diff -ur /usr/src/etc/defaults/rc.conf etc/defaults/rc.conf --- /usr/src/etc/defaults/rc.conf Wed May 9 22:30:33 2001 +++ etc/defaults/rc.conf Sat Jun 16 08:39:43 2001 @@ -19,6 +19,7 @@ ### Important initial Boot-time options #################### ############################################################## +new_rc="NO" # Set to YES to enable new-style rc. Experimental. swapfile="NO" # Set to name of swapfile if aux swapfile desired. apm_enable="NO" # Set to YES to enable APM BIOS functions (or NO). apmd_enable="NO" # Run apmd to handle APM event from userland. diff -ur /usr/src/etc/rc etc/rc --- /usr/src/etc/rc Fri May 11 12:06:55 2001 +++ etc/rc Sat Jun 16 15:46:27 2001 @@ -52,6 +52,39 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin export HOME PATH +# If there is a global system configuration file, suck it in. +# +if [ -r /etc/defaults/rc.conf ]; then + . /etc/defaults/rc.conf + source_rc_confs +elif [ -r /etc/rc.conf ]; then + . /etc/rc.conf +fi + +case ${new_rc} in +[Yy][Ee][Ss]) + . /etc/rc.subr + + _rc_conf_loaded=YES + + if [ "$1" = autoboot ]; then + autoboot=yes + _rc_fast_run=yes # run_rc_command(): do fast booting + fi + + files=`rcorder -s nostart /etc/rc.d/*` + + for _rc_elem in $files; do + run_rc_script $_rc_elem start + done + + exit 0 + ;; +*) + # fall-through to the old rc scripts + ;; +esac + # BOOTP diskless boot. We have to run the rc file early in order to # retarget various config files. # @@ -60,15 +93,6 @@ if [ ${dlv:=0} != 0 ]; then . /etc/rc.diskless1 fi -fi - -# If there is a global system configuration file, suck it in. -# -if [ -r /etc/defaults/rc.conf ]; then - . /etc/defaults/rc.conf - source_rc_confs -elif [ -r /etc/rc.conf ]; then - . /etc/rc.conf fi feed_dev_random() { diff -ur /usr/src/etc/rc.shutdown etc/rc.shutdown --- /usr/src/etc/rc.shutdown Sun Dec 17 00:15:57 2000 +++ etc/rc.shutdown Sat Jun 16 15:46:32 2001 @@ -52,6 +52,26 @@ . /etc/rc.conf fi +case ${new_rc} in +[Yy][Ee][Ss]) + . /etc/rc.subr + + files=`rcorder -k shutdown /etc/rc.d/*` + for i in $files; do # reverse order of files + nfiles="$i $nfiles" + done + files=$nfiles + + for i in $files; do + run_rc_script $i stop + done + + exit 0 + ;; +*) + ;; +esac + # Write some entropy so the rebooting /dev/random can reseed # case ${entropy_file} in ----- End forwarded message ----- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Jun 20 21:10: 7 2001 Delivered-To: freebsd-arch@freebsd.org Received: from takhus.dyn.mind.net (AFN-Dyn-63151110123.pc.ashlandfiber.net [63.151.110.123]) by hub.freebsd.org (Postfix) with ESMTP id 520D537B401; Wed, 20 Jun 2001 21:10:04 -0700 (PDT) (envelope-from takhus@takhus.mind.net) Received: from localhost (fleisher@localhost) by takhus.dyn.mind.net (8.11.4/8.11.4) with ESMTP id f5L49qb18856; Wed, 20 Jun 2001 21:09:53 -0700 (PDT) (envelope-from takhus@takhus.mind.net) X-Authentication-Warning: takhus.dyn.mind.net: fleisher owned process doing -bs Date: Wed, 20 Jun 2001 21:09:52 -0700 (PDT) From: Tony Fleisher X-Sender: fleisher@takhus.dyn.mind.net To: Bruce Evans Cc: John Baldwin , Terry Lambert , arch@FreeBSD.ORG, Peter Pentchev , Nate Williams Subject: Re: new kldpath(8): display/modify the module search path In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, 20 Jun 2001, Bruce Evans wrote: > > This means that the existence of a module search path is just a bug. > The kernel shouldn't use a search path or add a path prefix for > kldload(2) any more than it should for execve(2), but adding a path > prefix is necessary for modules loaded directly by the kernel. I used > to think that a search path (with one element) was necessary for > locating the modules, but now the modules are together with the kernel, > the one-element search path can be derived from kernelname[]. > > Bruce > The primary value (at least as I see it) in having the search path is to be able to keep 3rd party kernel modules outside of /boot/kernel (or where ever your kernel happens to be) and still be able to have them loaded. I believe that the existence of the module search path (at least its current form) was explained in this commit message (abreviated to include only the most relevant sections to conserve space here)... dcs 2000/09/08 21:52:35 PDT Modified files: sys/boot/forth loader.4th loader.conf support.4th Log: First tackle at trying to handle the New Deal on kernels. [...] After a kernel was loaded, the variable module_path may get changed. Such change will happen if the kernel was found with a directory prefix. In that case, the module path will be set to ${directory};${module_path}. Next, the modules are loaded as usual. This is intended so kernel="xyzzy" in /boot/loader.conf will load /boot/xyzzy/kernel.ko, load system modules from /boot/xyzzy/, and load third party modules from /boot/modules or /modules. If that doesn't work, it's a bug. [...] The semantics introduced here are experimental. Even if the code works, we might decide this is not the prefered behavior. If you feel so, send your feedback. (Yeah, this belongs in a HEADS UP or something, but I've been working for the past 16 hours on this stuff, so gimme a break.) Revision Changes Path 1.12 +15 -113 src/sys/boot/forth/loader.4th 1.32 +3 -3 src/sys/boot/forth/loader.conf 1.7 +265 -5 src/sys/boot/forth/support.4th To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 0: 9:37 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mail.high-tech-communications.com (mail.high-tech-communications.com [216.133.228.90]) by hub.freebsd.org (Postfix) with ESMTP id 52B7037B403 for ; Thu, 21 Jun 2001 00:09:30 -0700 (PDT) (envelope-from content-management@mail.high-tech-communications.com) Received: (from content-management@localhost) by mail.high-tech-communications.com (8.11.2/8.11.2) id f5L7Hpv02548; Thu, 21 Jun 2001 00:17:51 -0700 Date: Thu, 21 Jun 2001 00:17:51 -0700 Message-Id: <200106210717.f5L7Hpv02548@mail.high-tech-communications.com> To: freebsd-arch@FreeBSD.org From: Victor Black Subject: New web utility Content-Type: text/html; charset=iso-8859-1 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG

I noticed your email address on a list serve related to technology and web development.  With your permission, we
would like to send you information regarding new web tools and utilities based on your interests.  Please click the
following link and opt-in to our product updates and e-newsletter, click here:
http://216.133.228.90/

Cordially,

Victor Black
High-Tech-Communications.com

If you would like to be removed from our database, please click here: http://216.133.228.90/remove.cgi

 

To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 2:39:53 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id 4639D37B407 for ; Thu, 21 Jun 2001 02:39:51 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 12191 invoked by uid 1000); 21 Jun 2001 09:38:18 -0000 Date: Thu, 21 Jun 2001 12:38:18 +0300 From: Peter Pentchev To: David O'Brien Cc: arch@freebsd.org Subject: Re: (FWD) Re: import NetBSD rc system Message-ID: <20010621123818.E772@ringworld.oblivion.bg> Mail-Followup-To: David O'Brien , arch@freebsd.org References: <20010620182320.D99923@dragon.nuxi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010620182320.D99923@dragon.nuxi.com>; from obrien@freebsd.org on Wed, Jun 20, 2001 at 06:23:20PM -0700 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, Jun 20, 2001 at 06:23:20PM -0700, David O'Brien wrote: > Does anyone have any problems with this patch? > If not I'd like to commit it. (I might make "rc_new" rc_ng" since > everything else we have seems to be named that way) Wouldn't "rc_netbsd" scale better in the long run? G'luck, Peter -- "yields falsehood, when appended to its quotation." yields falsehood, when appended to its quotation. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 4:11:42 2001 Delivered-To: freebsd-arch@freebsd.org Received: from peter3.wemm.org (c1315225-a.plstn1.sfba.home.com [65.0.135.147]) by hub.freebsd.org (Postfix) with ESMTP id 9009037B406; Thu, 21 Jun 2001 04:11:37 -0700 (PDT) (envelope-from peter@wemm.org) Received: from overcee.netplex.com.au (overcee.wemm.org [10.0.0.3]) by peter3.wemm.org (8.11.0/8.11.0) with ESMTP id f5LBBbM14305; Thu, 21 Jun 2001 04:11:37 -0700 (PDT) (envelope-from peter@wemm.org) Received: from wemm.org (localhost [127.0.0.1]) by overcee.netplex.com.au (Postfix) with ESMTP id 816E33808; Thu, 21 Jun 2001 04:11:37 -0700 (PDT) (envelope-from peter@wemm.org) X-Mailer: exmh version 2.3.1 01/18/2001 with nmh-1.0.4 To: tlambert2@mindspring.com Cc: John Baldwin , Peter Pentchev , arch@FreeBSD.ORG, audit@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path In-Reply-To: <3B2F958E.BC556A1E@mindspring.com> Date: Thu, 21 Jun 2001 04:11:37 -0700 From: Peter Wemm Message-Id: <20010621111137.816E33808@overcee.netplex.com.au> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Terry Lambert wrote: > Likewise, the lack of a parallel, asynchronous resolver is a > serious deficit in FreeBSD, which is the result of jamming > the recolver into libc "because libresolv is how SVR4 and > Linux do it, and it would be a pain to go through and change > the network using ports to include the library linkage for > the one time it would be necessary". Full, complete patches to remove res_* from libc would be welcome. "Full" and "Complete" means the *entire* tree. For it to be useful it needs to be relative to -current. You probably need to do some tweaks to the ports *.mk files for ports that do a 'getXXXbyYYY()'. I await your submission. If not, then shut up. -Peter To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 4:15:18 2001 Delivered-To: freebsd-arch@freebsd.org Received: from peter3.wemm.org (c1315225-a.plstn1.sfba.home.com [65.0.135.147]) by hub.freebsd.org (Postfix) with ESMTP id 5A9D137B401; Thu, 21 Jun 2001 04:15:13 -0700 (PDT) (envelope-from peter@wemm.org) Received: from overcee.netplex.com.au (overcee.wemm.org [10.0.0.3]) by peter3.wemm.org (8.11.0/8.11.0) with ESMTP id f5LBFDM14326; Thu, 21 Jun 2001 04:15:13 -0700 (PDT) (envelope-from peter@wemm.org) Received: from wemm.org (localhost [127.0.0.1]) by overcee.netplex.com.au (Postfix) with ESMTP id 355F93808; Thu, 21 Jun 2001 04:15:13 -0700 (PDT) (envelope-from peter@wemm.org) X-Mailer: exmh version 2.3.1 01/18/2001 with nmh-1.0.4 To: nate@yogotech.com (Nate Williams) Cc: tlambert2@mindspring.com, John Baldwin , Peter Pentchev , arch@FreeBSD.ORG, audit@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path In-Reply-To: <15151.41572.721434.703837@nomad.yogotech.com> Date: Thu, 21 Jun 2001 04:15:13 -0700 From: Peter Wemm Message-Id: <20010621111513.355F93808@overcee.netplex.com.au> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Nate Williams wrote: > > > To me, it seems more sensible to use the same interface that > > > ldconfig uses. > > > > Noooooooooooooooooooooooooooooooooooooooooooooooooooooooooo! > > > > ldconfig is a serious pain in the ass, ever since the "fix" > > that made it not look in the linkage or configured directories > > on a lookup miss. > > > > This is particularly aggregious if you have a "/opt" or some > > other place where you prefer to install your ports or locally > > developed software. > > > > Having to reboot to make things work really, really sucks -- > > and that is often necessary if you build code from the net, > > which FreeBSD has mistakenly included as part os the base > > system monolith. OpenSSL, OpenSSH, and the resolver library > > are three examples that leap lithely to mind. > > Terry, it's simple to not have to reboot. Many ports already do this, > but a 'ldconfig -R' tells it to re-scan the known directories to pickup > new entries, which can be done at any time (as root of course). For the record, this is for 2.2.x and earlier systems only. 3.0 and above does not 'scan' the directories with ldconfig and do not create a cache of any sort. ldconfig -R has done nothing since 3.0-RELEASE. Only 'ldconfig -aout -R' actually does something these days. Cheers, -Peter -- Peter Wemm - peter@FreeBSD.org; peter@yahoo-inc.com; peter@netplex.com.au "All of this is for nothing if we don't go to the stars" - JMS/B5 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 4:19:51 2001 Delivered-To: freebsd-arch@freebsd.org Received: from peter3.wemm.org (c1315225-a.plstn1.sfba.home.com [65.0.135.147]) by hub.freebsd.org (Postfix) with ESMTP id EC9FD37B40A; Thu, 21 Jun 2001 04:19:47 -0700 (PDT) (envelope-from peter@wemm.org) Received: from overcee.netplex.com.au (overcee.wemm.org [10.0.0.3]) by peter3.wemm.org (8.11.0/8.11.0) with ESMTP id f5LBJlM14348; Thu, 21 Jun 2001 04:19:47 -0700 (PDT) (envelope-from peter@wemm.org) Received: from wemm.org (localhost [127.0.0.1]) by overcee.netplex.com.au (Postfix) with ESMTP id D8EE13808; Thu, 21 Jun 2001 04:19:47 -0700 (PDT) (envelope-from peter@wemm.org) X-Mailer: exmh version 2.3.1 01/18/2001 with nmh-1.0.4 To: John Baldwin Cc: Terry Lambert , audit@FreeBSD.ORG, arch@FreeBSD.ORG, Peter Pentchev Subject: Re: new kldpath(8): display/modify the module search path In-Reply-To: Date: Thu, 21 Jun 2001 04:19:47 -0700 From: Peter Wemm Message-Id: <20010621111947.D8EE13808@overcee.netplex.com.au> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG John Baldwin wrote: > > On 19-Jun-01 Terry Lambert wrote: > > John Baldwin wrote: > >> To me, it seems more sensible to use the same interface that > >> ldconfig uses. > > > > Noooooooooooooooooooooooooooooooooooooooooooooooooooooooooo! > > Terry, I mean interface in terms of having the command switches be the same. > I.e., dont' have -r do a rescan for one but remove a path for the other. FWIW, the 'module name' to 'kld file' mapping work-in-progress would make good use of a kldconfig/kldpath/whatever interface. Cheers, -Peter -- Peter Wemm - peter@FreeBSD.org; peter@yahoo-inc.com; peter@netplex.com.au "All of this is for nothing if we don't go to the stars" - JMS/B5 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 5:47: 9 2001 Delivered-To: freebsd-arch@freebsd.org Received: from Awfulhak.org (gw.Awfulhak.org [217.204.245.18]) by hub.freebsd.org (Postfix) with ESMTP id 3082F37B403; Thu, 21 Jun 2001 05:47:01 -0700 (PDT) (envelope-from brian@Awfulhak.org) Received: from hak.lan.Awfulhak.org (root@hak.lan.Awfulhak.org [172.16.0.12]) by Awfulhak.org (8.11.4/8.11.4) with ESMTP id f5LCkvi07562; Thu, 21 Jun 2001 13:46:57 +0100 (BST) (envelope-from brian@lan.Awfulhak.org) Received: from hak.lan.Awfulhak.org (brian@localhost [127.0.0.1]) by hak.lan.Awfulhak.org (8.11.4/8.11.4) with ESMTP id f5LCkuS02614; Thu, 21 Jun 2001 13:46:56 +0100 (BST) (envelope-from brian@hak.lan.Awfulhak.org) Message-Id: <200106211246.f5LCkuS02614@hak.lan.Awfulhak.org> X-Mailer: exmh version 2.3.1 01/18/2001 with nmh-1.0.4 To: Peter Wemm Cc: John Baldwin , Terry Lambert , audit@FreeBSD.ORG, arch@FreeBSD.ORG, Peter Pentchev , brian@Awfulhak.org Subject: Re: new kldpath(8): display/modify the module search path In-Reply-To: Message from Peter Wemm of "Thu, 21 Jun 2001 04:19:47 PDT." <20010621111947.D8EE13808@overcee.netplex.com.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 21 Jun 2001 13:46:56 +0100 From: Brian Somers Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > John Baldwin wrote: > > > > On 19-Jun-01 Terry Lambert wrote: > > > John Baldwin wrote: > > >> To me, it seems more sensible to use the same interface that > > >> ldconfig uses. > > > > > > Noooooooooooooooooooooooooooooooooooooooooooooooooooooooooo! > > > > Terry, I mean interface in terms of having the command switches be the same. > > I.e., dont' have -r do a rescan for one but remove a path for the other. > > FWIW, the 'module name' to 'kld file' mapping work-in-progress would make > good use of a kldconfig/kldpath/whatever interface. Hah ! Caught you ! I knew someone knew something about this ! Can you say anything about how this work is progressing and who is progressing it ? I recently committed a linker_reference_module() function to use from the digi driver (after getting no response to the question I sent to -arch on May 10), but didn't know if I was stepping on anyones toes.... > Cheers, > -Peter > -- > Peter Wemm - peter@FreeBSD.org; peter@yahoo-inc.com; peter@netplex.com.au > "All of this is for nothing if we don't go to the stars" - JMS/B5 -- Brian Don't _EVER_ lose your sense of humour ! To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 10:21:27 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id 9079737B401 for ; Thu, 21 Jun 2001 10:21:18 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 22358 invoked by uid 1000); 21 Jun 2001 17:19:45 -0000 Date: Thu, 21 Jun 2001 20:19:45 +0300 From: Peter Pentchev To: Jordan Hubbard Cc: arch@FreeBSD.org Subject: src/release/Makefile NO_SENDMAIL fix Message-ID: <20010621201945.A22338@ringworld.oblivion.bg> Mail-Followup-To: Jordan Hubbard , arch@FreeBSD.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, Is there an overwhelming reason this should not go into the tree, thus enabling custom NO_SENDMAIL release builds? G'luck, Peter -- If I were you, who would be reading this sentence? Index: src/release/Makefile =================================================================== RCS file: /home/ncvs/src/release/Makefile,v retrieving revision 1.624 diff -u -r1.624 Makefile --- src/release/Makefile 2001/06/14 23:48:13 1.624 +++ src/release/Makefile 2001/06/21 17:20:01 @@ -184,6 +184,12 @@ CD_DISC1= ${CD}/disc1 CD_DISC2= ${CD}/disc2 +# Things that need to be compiled without crypto support in releases +FIXCRYPTO= bin/ed usr.sbin/ppp usr.sbin/pppd usr.sbin/tcpdump/tcpdump +.if !defined(NO_SENDMAIL) +FIXCRYPTO+= usr.sbin/sendmail +.endif + # Where the bootstrap ports (see DOCPORTS) get installed. LOCALDIR= /usr/local/bin @@ -466,7 +472,7 @@ # release.5: # Handle some grief caused by the munition braindeadness. - for i in bin/ed usr.sbin/ppp usr.sbin/pppd usr.sbin/sendmail usr.sbin/tcpdump/tcpdump ; do \ + for i in ${FIXCRYPTO}; do \ ( cd ${.CURDIR}/../$$i; \ make -DNOCRYPT clean all distribute DISTDIR=${RD}/trees ) ; \ done To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 12:50: 8 2001 Delivered-To: freebsd-arch@freebsd.org Received: from smtp05.primenet.com (smtp05.primenet.com [64.211.219.54]) by hub.freebsd.org (Postfix) with ESMTP id 8FB3537B401; Thu, 21 Jun 2001 12:50:00 -0700 (PDT) (envelope-from tlambert@usr05.primenet.com) Received: (from daemon@localhost) by smtp05.primenet.com (8.9.3/8.9.3) id MAA15823; Thu, 21 Jun 2001 12:49:58 -0700 (MST) Received: from usr05.primenet.com(206.165.6.205) via SMTP by smtp05.primenet.com, id smtpdAAArmay3E; Thu Jun 21 12:49:52 2001 Received: (from tlambert@localhost) by usr05.primenet.com (8.8.5/8.8.5) id MAA11812; Thu, 21 Jun 2001 12:52:15 -0700 (MST) From: Terry Lambert Message-Id: <200106211952.MAA11812@usr05.primenet.com> Subject: Re: new kldpath(8): display/modify the module search path To: peter@wemm.org Date: Thu, 21 Jun 2001 19:52:15 +0000 (GMT) Cc: arch@FreeBSD.ORG, audit@FreeBSD.ORG X-Mailer: ELM [version 2.5 PL2] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Peter Wemm wrote: ] > Likewise, the lack of a parallel, asynchronous resolver is a ] > serious deficit in FreeBSD, which is the result of jamming ] > the recolver into libc "because libresolv is how SVR4 and ] > Linux do it, and it would be a pain to go through and change ] > the network using ports to include the library linkage for ] > the one time it would be necessary". ] ] Full, complete patches to remove res_* from libc would be welcome. ] "Full" and "Complete" means the *entire* tree. For it to be useful ] it needs to be relative to -current. You probably need to do ] some tweaks to the ports *.mk files for ports that do a 'getXXXbyYYY()'. ] ] I await your submission. If not, then shut up. What an absolutely brilliant approach to solving the problem. I had only considered importing a libresolv into /usr/src/lib/libresolv, and then switching ports and programs over gradually, and then at the end, when everything worked, removing the old, lousy resolver code from libc so that the transition would have the least possible impact on everyone. Your idea of switching everything over all at once, and breaking the world and pissing everyone off to the point of the changes being reverted, and keeping the old, buggy resolver code in libc for all eternity is _clearly_ much, much, better. PS: The approach you first think of when you go to solve a problem is not always the best approach; other people may in fact have ideas which aren't stupid. PPS: I would not have been this rude in pointing out the errors in your assumptions, had you not been that rude about allowing anyone to even present the idea. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 12:56:10 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mail.disney.com (mail.disney.com [204.128.192.15]) by hub.freebsd.org (Postfix) with ESMTP id ADD4537B401; Thu, 21 Jun 2001 12:56:04 -0700 (PDT) (envelope-from Jim.Pirzyk@disney.com) Received: from pain10.corp.disney.com (root@pain10.corp.disney.com [153.7.110.100]) by mail.disney.com (Switch-2.0.1/Switch-2.0.1) with SMTP id f5LJtII26384; Thu, 21 Jun 2001 12:55:18 -0700 (PDT) Received: from [172.30.50.86] by pain.corp.disney.com with ESMTP; Thu, 21 Jun 2001 12:56:50 -0700 Received: from mercury.fan.fa.disney.com (mercury.fan.fa.disney.com [153.7.119.1]) by louie.fa.disney.com (8.9.2/8.9.2) with ESMTP id MAA16915; Thu, 21 Jun 2001 12:55:57 -0700 (PDT) (envelope-from Jim.Pirzyk@disney.com) Received: from brother.fan.fa.disney.com by mercury.fan.fa.disney.com; Thu, 21 Jun 2001 12:55:57 -0700 Content-Type: text/plain; charset="iso-8859-1" From: Jim Pirzyk Organization: Walt Disney Feature Animation To: Terry Lambert , peter@wemm.org Subject: new resolver libraries (Was: Re: new kldpath(8): display/modify the module search path) Date: Thu, 21 Jun 2001 12:55:57 -0700 X-Mailer: KMail [version 1.2] Cc: arch@FreeBSD.ORG, audit@FreeBSD.ORG References: <200106211952.MAA11812@usr05.primenet.com> In-Reply-To: <200106211952.MAA11812@usr05.primenet.com> MIME-Version: 1.0 Message-Id: <01062112555704.43555@brother> Content-Transfer-Encoding: 8bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thursday 21 June 2001 12:52 pm, Terry Lambert wrote: > Peter Wemm wrote: > ] > Likewise, the lack of a parallel, asynchronous resolver is a > ] > serious deficit in FreeBSD, which is the result of jamming > ] > the recolver into libc "because libresolv is how SVR4 and > ] > Linux do it, and it would be a pain to go through and change > ] > the network using ports to include the library linkage for > ] > the one time it would be necessary". > ] > ] Full, complete patches to remove res_* from libc would be welcome. > ] "Full" and "Complete" means the *entire* tree. For it to be useful > ] it needs to be relative to -current. You probably need to do > ] some tweaks to the ports *.mk files for ports that do a 'getXXXbyYYY()'. > ] > ] I await your submission. If not, then shut up. > > What an absolutely brilliant approach to solving the problem. > > I had only considered importing a libresolv into /usr/src/lib/libresolv, > and then switching ports and programs over gradually, and then at the > end, when everything worked, removing the old, lousy resolver code from > libc so that the transition would have the least possible impact on > everyone. So if the resolver is going to be replaced, please, please include the DNS sortlist code in the new resolver. I have seen cases were that has been broken (getaddrinfo(3)). It is an absoulte requirement for us to have this. - JimP -- --- @(#) $Id: dot.signature,v 1.10 2001/05/17 23:38:49 Jim.Pirzyk Exp $ __o Jim.Pirzyk@disney.com ------------- pirzyk@freebsd.org _'\<,_ Senior Systems Engineer, Walt Disney Feature Animation (*)/ (*) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 12:59:25 2001 Delivered-To: freebsd-arch@freebsd.org Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by hub.freebsd.org (Postfix) with ESMTP id 971F237B401; Thu, 21 Jun 2001 12:59:20 -0700 (PDT) (envelope-from des@ofug.org) Received: (from des@localhost) by flood.ping.uio.no (8.9.3/8.9.3) id VAA66607; Thu, 21 Jun 2001 21:59:12 +0200 (CEST) (envelope-from des@ofug.org) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: Jim Pirzyk Cc: Terry Lambert , peter@wemm.org, arch@FreeBSD.ORG, audit@FreeBSD.ORG Subject: Re: new resolver libraries (Was: Re: new kldpath(8): display/modify the module search path) References: <200106211952.MAA11812@usr05.primenet.com> <01062112555704.43555@brother> From: Dag-Erling Smorgrav Date: 21 Jun 2001 21:59:11 +0200 In-Reply-To: <01062112555704.43555@brother> Message-ID: Lines: 11 User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Jim Pirzyk writes: > So if the resolver is going to be replaced, please, please include > the DNS sortlist code in the new resolver. I have seen cases were > that has been broken (getaddrinfo(3)). It is an absoulte requirement > for us to have this. Hey, Jim, you got commit privs for a *reason* ;) DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 13:28:34 2001 Delivered-To: freebsd-arch@freebsd.org Received: from winston.osd.bsdi.com (adsl-64-173-15-98.dsl.sntc01.pacbell.net [64.173.15.98]) by hub.freebsd.org (Postfix) with ESMTP id D88A037B401 for ; Thu, 21 Jun 2001 13:27:49 -0700 (PDT) (envelope-from jkh@osd.bsdi.com) Received: from localhost (jkh@localhost [127.0.0.1]) by winston.osd.bsdi.com (8.11.4/8.11.3) with ESMTP id f5LKRNt04442; Thu, 21 Jun 2001 13:27:23 -0700 (PDT) (envelope-from jkh@osd.bsdi.com) To: roam@orbitel.bg Cc: jkh@winston.osd.bsdi.com, arch@FreeBSD.org Subject: Re: src/release/Makefile NO_SENDMAIL fix In-Reply-To: <20010621201945.A22338@ringworld.oblivion.bg> References: <20010621201945.A22338@ringworld.oblivion.bg> X-Mailer: Mew version 1.94.1 on Emacs 20.7 / Mule 4.0 (HANANOEN) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-Id: <20010621132723P.jkh@osd.bsdi.com> Date: Thu, 21 Jun 2001 13:27:23 -0700 From: Jordan Hubbard X-Dispatcher: imput version 20000228(IM140) Lines: 12 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG From: Peter Pentchev Subject: src/release/Makefile NO_SENDMAIL fix Date: Thu, 21 Jun 2001 20:19:45 +0300 > Is there an overwhelming reason this should not go into the tree, > thus enabling custom NO_SENDMAIL release builds? If FIXCRYPTO were also user overridable, I'd support the change. It should be a more general knob than just something to switch sendmail on and off with. - Jordan To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 16:11:57 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (diskworld.nanolink.com [195.24.48.189]) by hub.freebsd.org (Postfix) with SMTP id 1F31137B403 for ; Thu, 21 Jun 2001 16:11:51 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 2492 invoked by uid 1000); 21 Jun 2001 23:10:13 -0000 Date: Fri, 22 Jun 2001 02:10:13 +0300 From: Peter Pentchev To: Jordan Hubbard Cc: arch@FreeBSD.org Subject: Re: src/release/Makefile NO_SENDMAIL fix Message-ID: <20010622021013.A626@ringworld.oblivion.bg> Mail-Followup-To: Jordan Hubbard , arch@FreeBSD.org References: <20010621201945.A22338@ringworld.oblivion.bg> <20010621132723P.jkh@osd.bsdi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010621132723P.jkh@osd.bsdi.com>; from jkh@osd.bsdi.com on Thu, Jun 21, 2001 at 01:27:23PM -0700 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Jun 21, 2001 at 01:27:23PM -0700, Jordan Hubbard wrote: > From: Peter Pentchev > Subject: src/release/Makefile NO_SENDMAIL fix > Date: Thu, 21 Jun 2001 20:19:45 +0300 > > > Is there an overwhelming reason this should not go into the tree, > > thus enabling custom NO_SENDMAIL release builds? > > If FIXCRYPTO were also user overridable, I'd support the change. It > should be a more general knob than just something to switch sendmail > on and off with. Heh.. actually I was thinking about just this, on my way home :) Well, how about the attached patch? Just a simple 'FIXCRYPTO?=...' doesn't work here, because if FIXCRYPTO was not defined in the first place, we need the NO_SENDMAIL test; if it is defined, then we have to assume that whoever defined it knew what they were doing, and we should not blindly add sendmail in there. And btw, this is not 'just something to switch sendmail on and off with'. The whole release build process supports local patches, and it supports local patches to etc/defaults/make.conf. The whole build process goes perfectly well with NO_BIND, NO_OBJC, NO_UUCP, NOPROFILE and NO_FORTRAN defined; all the build framework references to BIND, ObjC, UUCP, profiled libs or Fortran respectively are wrapped in tests for those knobs. The FIXCRYPTO conditional inclusion of sendmail is a fix, not a new feature - it is a fix prompted by the fact that sendmail should also not be referenced anywhere in the tree without checking for the NO_SENDMAIL knob first. There is precedet for this in src/release/Makefile - in the release.2 target, Kerberos 4 and 5 are not built, unless the make.conf knobs allow this. Taking this out into a variable also helps matters in case someone decides to make a NO_PPP or NO_LIBPCAP knob - in that case, those would also be ifdef'd out, instead of being blindly referenced without checking if they've been built at all :) G'luck, Peter -- If wishes were fishes, the antecedent of this conditional would be true. Index: src/release/Makefile =================================================================== RCS file: /home/ncvs/src/release/Makefile,v retrieving revision 1.624 diff -u -r1.624 Makefile --- src/release/Makefile 2001/06/14 23:48:13 1.624 +++ src/release/Makefile 2001/06/21 23:01:32 @@ -174,6 +174,14 @@ ZIPNSPLIT= gzip --no-name -9 -c | split -b 240640 - +# Things that need to be compiled without crypto support in releases +.if !defined(FIXCRYPTO) +FIXCRYPTO= bin/ed usr.sbin/ppp usr.sbin/pppd usr.sbin/tcpdump/tcpdump +.if !defined(NO_SENDMAIL) +FIXCRYPTO+= usr.sbin/sendmail +.endif +.endif + # Things which may get you into trouble if you change them MTREEFILES= ${.CURDIR}/../etc/mtree @@ -466,7 +474,7 @@ # release.5: # Handle some grief caused by the munition braindeadness. - for i in bin/ed usr.sbin/ppp usr.sbin/pppd usr.sbin/sendmail usr.sbin/tcpdump/tcpdump ; do \ + for i in ${FIXCRYPTO}; do \ ( cd ${.CURDIR}/../$$i; \ make -DNOCRYPT clean all distribute DISTDIR=${RD}/trees ) ; \ done To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 18: 1:47 2001 Delivered-To: freebsd-arch@freebsd.org Received: from avocet.mail.pas.earthlink.net (avocet.mail.pas.earthlink.net [207.217.121.50]) by hub.freebsd.org (Postfix) with ESMTP id 201C037B403; Thu, 21 Jun 2001 18:01:44 -0700 (PDT) (envelope-from kway@overtone.org) Received: from bean.overtone.org (user-2iniksg.dialup.mindspring.com [165.121.83.144]) by avocet.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id SAA03424; Thu, 21 Jun 2001 18:01:41 -0700 (PDT) Received: by bean.overtone.org (Postfix, from userid 1001) id 48E315B47D; Thu, 21 Jun 2001 21:01:50 -0400 (EDT) Date: Thu, 21 Jun 2001 21:01:49 -0400 From: Kevin Way To: "David O'Brien" Cc: freebsd-arch@freebsd.org Subject: Re: (FWD) Re: import NetBSD rc system Message-ID: <20010621210149.A87391@bean.overtone.org> References: <20010620182320.D99923@dragon.nuxi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010620182320.D99923@dragon.nuxi.com>; from obrien@FreeBSD.ORG on Wed, Jun 20, 2001 at 06:23:20PM -0700 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > Does anyone have any problems with this patch? No problems with it, but seeing as it officially means that the rc_new way to load configuration is the same as FreeBSD's way, the following patch should probably be included as well. -Kevin Way RCS file: /home/ncvs/src/etc/rc.subr,v retrieving revision 1.1.1.1 diff -u -r1.1.1.1 rc.subr --- rc.subr 2001/06/16 07:16:14 1.1.1.1 +++ rc.subr 2001/06/22 00:59:04 @@ -536,7 +536,13 @@ err 3 'USAGE: load_rc_config command' fi - . /etc/rc.conf + if [ -r /etc/defaults/rc.conf ]; then + . /etc/defaults/rc.conf + source_rc_confs + elif [ -r /etc/rc.conf ]; then + . /etc/rc.conf + fi + if [ -f /etc/rc.conf.d/"$_command" ]; then . /etc/rc.conf.d/"$_command" To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 18:10: 8 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mail.tgd.net (rand.tgd.net [64.81.67.117]) by hub.freebsd.org (Postfix) with SMTP id A22FC37B401 for ; Thu, 21 Jun 2001 18:10:04 -0700 (PDT) (envelope-from sean@mailhost.tgd.net) Received: (qmail 93704 invoked by uid 1001); 22 Jun 2001 01:09:57 -0000 Date: Thu, 21 Jun 2001 18:09:57 -0700 From: Sean Chittenden To: Kevin Way Cc: freebsd-arch@freebsd.org Subject: Re: import NetBSD rc system Message-ID: <20010621180957.R90900@rand.tgd.net> References: <20010620182320.D99923@dragon.nuxi.com> <20010621210149.A87391@bean.overtone.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="vvRocJ6whMXXNc9q" Content-Disposition: inline In-Reply-To: <20010621210149.A87391@bean.overtone.org>; from "kevin.way@overtone.org" on Thu, Jun 21, 2001 at = 09:01:49PM X-PGP-Key: 0x1EDDFAAD X-PGP-Fingerprint: C665 A17F 9A56 286C 5CFB 1DEA 9F4F 5CEF 1EDD FAAD X-Web-Homepage: http://sean.chittenden.org/ Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --vvRocJ6whMXXNc9q Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Are you sure you don't mean something like the following? -sc - . /etc/rc.conf + if [ -r /etc/defaults/rc.conf ]; then =20 + . /etc/defaults/rc.conf + source_rc_confs + fi + + if [ -r /etc/rc.conf ]; then + . /etc/rc.conf + fi + --=20 Sean Chittenden --vvRocJ6whMXXNc9q Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Comment: Sean Chittenden iEYEARECAAYFAjsymuQACgkQn09c7x7d+q2UowCgmtklQNVWaX2VleQC/9AMOCBF 99gAoMHxfPinhZm68GBigVeXKBFrh6dB =tZAs -----END PGP SIGNATURE----- --vvRocJ6whMXXNc9q-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Thu Jun 21 18:20:27 2001 Delivered-To: freebsd-arch@freebsd.org Received: from scaup.mail.pas.earthlink.net (scaup.mail.pas.earthlink.net [207.217.121.49]) by hub.freebsd.org (Postfix) with ESMTP id 99F7437B406 for ; Thu, 21 Jun 2001 18:20:25 -0700 (PDT) (envelope-from kway@overtone.org) Received: from bean.overtone.org (user-2iniksg.dialup.mindspring.com [165.121.83.144]) by scaup.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id SAA16564; Thu, 21 Jun 2001 18:20:22 -0700 (PDT) Received: by bean.overtone.org (Postfix, from userid 1001) id 66C245B47D; Thu, 21 Jun 2001 21:20:15 -0400 (EDT) Date: Thu, 21 Jun 2001 21:20:15 -0400 From: Kevin Way To: Sean Chittenden Cc: freebsd-arch@freebsd.org Subject: Re: import NetBSD rc system Message-ID: <20010621212015.A87496@bean.overtone.org> References: <20010620182320.D99923@dragon.nuxi.com> <20010621210149.A87391@bean.overtone.org> <20010621180957.R90900@rand.tgd.net> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-md5; protocol="application/pgp-signature"; boundary="SUOF0GtieIMvvwua" Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010621180957.R90900@rand.tgd.net>; from sean-freebsd-arch@chittenden.org on Thu, Jun 21, 2001 at 06:09:57PM -0700 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --SUOF0GtieIMvvwua Content-Type: text/plain; charset=us-ascii Content-Disposition: inline > Are you sure you don't mean something like the following? -sc Yep, quite certain. source_rc_confs iterates over the array of ${rc_conf_files}, which /etc/defaults/rc.conf defines as rc_conf_files="/etc/rc.conf /etc/rc.conf.local" so we're already good to go. -k --SUOF0GtieIMvvwua Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (FreeBSD) Comment: For info see http://www.gnupg.org iD8DBQE7Mp1PKxA01iDoLN4RAgvzAKCchSW45RVFXKsql3oZ/LKfnEK42QCfZKqo 3sZVBZeT1l7WBdM31b4pMds= =k8Sz -----END PGP SIGNATURE----- --SUOF0GtieIMvvwua-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 3:27:46 2001 Delivered-To: freebsd-arch@freebsd.org Received: from whale.sunbay.crimea.ua (whale.sunbay.crimea.ua [212.110.138.65]) by hub.freebsd.org (Postfix) with ESMTP id C270E37B401 for ; Fri, 22 Jun 2001 03:27:40 -0700 (PDT) (envelope-from ru@whale.sunbay.crimea.ua) Received: (from ru@localhost) by whale.sunbay.crimea.ua (8.11.2/8.11.2) id f5MAREk05138; Fri, 22 Jun 2001 13:27:14 +0300 (EEST) (envelope-from ru) Date: Fri, 22 Jun 2001 13:27:14 +0300 From: Ruslan Ermilov To: Peter Pentchev Cc: Jordan Hubbard , arch@FreeBSD.ORG Subject: Re: src/release/Makefile NO_SENDMAIL fix Message-ID: <20010622132714.A1016@sunbay.com> Mail-Followup-To: Peter Pentchev , Jordan Hubbard , arch@FreeBSD.ORG References: <20010621201945.A22338@ringworld.oblivion.bg> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010621201945.A22338@ringworld.oblivion.bg>; from roam@orbitel.bg on Thu, Jun 21, 2001 at 08:19:45PM +0300 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Jun 21, 2001 at 08:19:45PM +0300, Peter Pentchev wrote: > Hi, > > Is there an overwhelming reason this should not go into the tree, > thus enabling custom NO_SENDMAIL release builds? > I think that NO_'s are in general bad with release building. Cheers, -- Ruslan Ermilov Oracle Developer/DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 4:19: 5 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id C545237B403 for ; Fri, 22 Jun 2001 04:19:02 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 5020 invoked by uid 1000); 22 Jun 2001 11:17:25 -0000 Date: Fri, 22 Jun 2001 14:17:25 +0300 From: Peter Pentchev To: arch@FreeBSD.ORG Subject: Re: src/release/Makefile NO_SENDMAIL fix Message-ID: <20010622141725.A4992@ringworld.oblivion.bg> Mail-Followup-To: arch@FreeBSD.ORG References: <20010621201945.A22338@ringworld.oblivion.bg> <20010622132714.A1016@sunbay.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010622132714.A1016@sunbay.com>; from ru@FreeBSD.ORG on Fri, Jun 22, 2001 at 01:27:14PM +0300 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Jun 22, 2001 at 01:27:14PM +0300, Ruslan Ermilov wrote: > On Thu, Jun 21, 2001 at 08:19:45PM +0300, Peter Pentchev wrote: > > Hi, > > > > Is there an overwhelming reason this should not go into the tree, > > thus enabling custom NO_SENDMAIL release builds? > > > I think that NO_'s are in general bad with release building. Any particular reason? I'm building a custom release to use for an automated indoors office installation. It works just fine without Sendmail (and please, no religious threads here :), and there's no real reason to have Sendmail installed on any of the machines. G'luck, Peter -- I am the thought you are now thinking. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 7:14:20 2001 Delivered-To: freebsd-arch@freebsd.org Received: from sdmail0.sd.bmarts.com (sdmail0.sd.bmarts.com [209.247.77.155]) by hub.freebsd.org (Postfix) with ESMTP id 13D6237B401; Fri, 22 Jun 2001 07:14:12 -0700 (PDT) (envelope-from gordont@bluemtn.net) Received: from localhost (gordont@localhost) by sdmail0.sd.bmarts.com (8.11.3/8.11.2/BMA1.1) with ESMTP id f5MEDuc82007; Fri, 22 Jun 2001 07:13:57 -0700 (PDT) Date: Fri, 22 Jun 2001 07:13:56 -0700 (PDT) From: Gordon Tetlow X-X-Sender: To: "David O'Brien" Cc: Subject: Re: (FWD) Re: import NetBSD rc system In-Reply-To: <20010620182320.D99923@dragon.nuxi.com> Message-ID: MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="0-2121145011-993219236=:25983" Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. Send mail to mime@docserver.cac.washington.edu for more info. --0-2121145011-993219236=:25983 Content-Type: TEXT/PLAIN; charset=US-ASCII I've been staring at this patch some more and it occurs to me that it breaks rc.diskless1 in all cases. I've attached a new patch that moves rc.diskless1 to before the sourcing of /etc/defaults/rc.conf. It also changes the rc.conf variable to rc_ng. -gordon On Wed, 20 Jun 2001, David O'Brien wrote: > Does anyone have any problems with this patch? > If not I'd like to commit it. (I might make "rc_new" rc_ng" since > everything else we have seems to be named that way) > > > > ----- Forwarded message from Gordon Tetlow ----- > > From: Gordon Tetlow > Subject: Re: import NetBSD rc system > Date: Sun, 17 Jun 2001 21:28:02 -0700 (PDT) > To: "David O'Brien" > Cc: "David O'Brien -Hackers" > X-X-Sender: > List-ID: > List-Archive: (Web Archive) > > On Sat, 16 Jun 2001, David O'Brien wrote: > > > On Sat, Jun 16, 2001 at 07:58:06AM -0700, Gordon Tetlow wrote: > > > I like Matt's idea (I think it was Matt) to have a new_rc switch. I'll > > > look at adding the code for it and submitting a patch, > > > > You are going off on a tangent. You are worried about the flag day > > before we even have a flag to run up the poll. > > Actually, this makes the import of the new rc system much easier. I've > attached the patch against an older (may 11th) world. It should make it > pretty clear. After this, all you need to do is import the rc.subr and the > rc.d directory from the NetBSD project. Then to test the new boot system, > all you need is rcorder and new_rc switched on in /etc/rc.conf. If you > need to get back to the old boot system, just change the new_rc knob to > off and you can boot normally. > > > > > > /etc/rc.subr ported > > > > > > > > What changes were needed here? > > > > > > I basically added a function called checkwildno() that is similar to > > > checkyesno that returns 1 for NO (plus variants) or '' and returns 0 for > > > anything else. This gets rid of alot of case statements in the modules, > > > making them simple if's. > > > > Again, why don't we just concentrate on porting the NetBSD scripts and > > not the second system enhancements? > > I agree. I'm a little further ahead on my local box than where we are on > the repo. My big question is, do we want to keep the current boot > order/logic or are we going with NetBSDs? Either way is fine by me, > although I've tried to keep FreeBSDs system more than NetBSDs. > > -gordon > > diff -ur /usr/src/etc/defaults/rc.conf etc/defaults/rc.conf > --- /usr/src/etc/defaults/rc.conf Wed May 9 22:30:33 2001 > +++ etc/defaults/rc.conf Sat Jun 16 08:39:43 2001 > @@ -19,6 +19,7 @@ > ### Important initial Boot-time options #################### > ############################################################## > > +new_rc="NO" # Set to YES to enable new-style rc. Experimental. > swapfile="NO" # Set to name of swapfile if aux swapfile desired. > apm_enable="NO" # Set to YES to enable APM BIOS functions (or NO). > apmd_enable="NO" # Run apmd to handle APM event from userland. > diff -ur /usr/src/etc/rc etc/rc > --- /usr/src/etc/rc Fri May 11 12:06:55 2001 > +++ etc/rc Sat Jun 16 15:46:27 2001 > @@ -52,6 +52,39 @@ > PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin > export HOME PATH > > +# If there is a global system configuration file, suck it in. > +# > +if [ -r /etc/defaults/rc.conf ]; then > + . /etc/defaults/rc.conf > + source_rc_confs > +elif [ -r /etc/rc.conf ]; then > + . /etc/rc.conf > +fi > + > +case ${new_rc} in > +[Yy][Ee][Ss]) > + . /etc/rc.subr > + > + _rc_conf_loaded=YES > + > + if [ "$1" = autoboot ]; then > + autoboot=yes > + _rc_fast_run=yes # run_rc_command(): do fast booting > + fi > + > + files=`rcorder -s nostart /etc/rc.d/*` > + > + for _rc_elem in $files; do > + run_rc_script $_rc_elem start > + done > + > + exit 0 > + ;; > +*) > + # fall-through to the old rc scripts > + ;; > +esac > + > # BOOTP diskless boot. We have to run the rc file early in order to > # retarget various config files. > # > @@ -60,15 +93,6 @@ > if [ ${dlv:=0} != 0 ]; then > . /etc/rc.diskless1 > fi > -fi > - > -# If there is a global system configuration file, suck it in. > -# > -if [ -r /etc/defaults/rc.conf ]; then > - . /etc/defaults/rc.conf > - source_rc_confs > -elif [ -r /etc/rc.conf ]; then > - . /etc/rc.conf > fi > > feed_dev_random() { > diff -ur /usr/src/etc/rc.shutdown etc/rc.shutdown > --- /usr/src/etc/rc.shutdown Sun Dec 17 00:15:57 2000 > +++ etc/rc.shutdown Sat Jun 16 15:46:32 2001 > @@ -52,6 +52,26 @@ > . /etc/rc.conf > fi > > +case ${new_rc} in > +[Yy][Ee][Ss]) > + . /etc/rc.subr > + > + files=`rcorder -k shutdown /etc/rc.d/*` > + for i in $files; do # reverse order of files > + nfiles="$i $nfiles" > + done > + files=$nfiles > + > + for i in $files; do > + run_rc_script $i stop > + done > + > + exit 0 > + ;; > +*) > + ;; > +esac > + > # Write some entropy so the rebooting /dev/random can reseed > # > case ${entropy_file} in > > > ----- End forwarded message ----- > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-arch" in the body of the message > --0-2121145011-993219236=:25983 Content-Type: TEXT/PLAIN; charset=US-ASCII; name="rc.diff" Content-Transfer-Encoding: BASE64 Content-ID: Content-Description: Content-Disposition: attachment; filename="rc.diff" ZGlmZiAtdXIgL3Vzci9zcmMvZXRjL2RlZmF1bHRzL3JjLmNvbmYgZXRjL2Rl ZmF1bHRzL3JjLmNvbmYNCi0tLSAvdXNyL3NyYy9ldGMvZGVmYXVsdHMvcmMu Y29uZglXZWQgTWF5ICA5IDIyOjMwOjMzIDIwMDENCisrKyBldGMvZGVmYXVs dHMvcmMuY29uZglGcmkgSnVuIDIyIDA3OjA3OjU5IDIwMDENCkBAIC0xOSw2 ICsxOSw3IEBADQogIyMjICBJbXBvcnRhbnQgaW5pdGlhbCBCb290LXRpbWUg b3B0aW9ucyAgIyMjIyMjIyMjIyMjIyMjIyMjIyMNCiAjIyMjIyMjIyMjIyMj IyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMj IyMjIw0KIA0KK3JjX25nPSJOTyIJCSMgU2V0IHRvIFlFUyB0byBlbmFibGUg bmV3LXN0eWxlIHJjLiBFeHBlcmltZW50YWwuDQogc3dhcGZpbGU9Ik5PIgkJ IyBTZXQgdG8gbmFtZSBvZiBzd2FwZmlsZSBpZiBhdXggc3dhcGZpbGUgZGVz aXJlZC4NCiBhcG1fZW5hYmxlPSJOTyIJCSMgU2V0IHRvIFlFUyB0byBlbmFi bGUgQVBNIEJJT1MgZnVuY3Rpb25zIChvciBOTykuDQogYXBtZF9lbmFibGU9 Ik5PIgkjIFJ1biBhcG1kIHRvIGhhbmRsZSBBUE0gZXZlbnQgZnJvbSB1c2Vy bGFuZC4NCmRpZmYgLXVyIC91c3Ivc3JjL2V0Yy9yYyBldGMvcmMNCi0tLSAv dXNyL3NyYy9ldGMvcmMJRnJpIE1heSAxMSAxMjowNjo1NSAyMDAxDQorKysg ZXRjL3JjCUZyaSBKdW4gMjIgMDc6MTE6NTEgMjAwMQ0KQEAgLTcxLDYgKzcx LDMwIEBADQogCS4gL2V0Yy9yYy5jb25mDQogZmkNCiANCitjYXNlICR7bmV3 X3JjfSBpbg0KK1tZeV1bRWVdW1NzXSkNCisJLiAvZXRjL3JjLnN1YnINCisN CisJX3JjX2NvbmZfbG9hZGVkPVlFUw0KKw0KKwlpZiBbICIkMSIgPSBhdXRv Ym9vdCBdOyB0aGVuDQorCQlhdXRvYm9vdD15ZXMNCisJCV9yY19mYXN0X3J1 bj15ZXMgICAgICAgICMgcnVuX3JjX2NvbW1hbmQoKTogZG8gZmFzdCBib290 aW5nDQorCWZpDQorDQorCWZpbGVzPWByY29yZGVyIC1zIG5vc3RhcnQgL2V0 Yy9yYy5kLypgDQorDQorCWZvciBfcmNfZWxlbSBpbiAkZmlsZXM7IGRvDQor CQlydW5fcmNfc2NyaXB0ICRfcmNfZWxlbSBzdGFydA0KKwlkb25lDQorDQor CWV4aXQgMA0KKwk7Ow0KKyopDQorCSMgZmFsbC10aHJvdWdoIHRvIHRoZSBv bGQgcmMgc2NyaXB0cw0KKwk7Ow0KK2VzYWMNCisNCiBmZWVkX2Rldl9yYW5k b20oKSB7DQogCWlmIFsgLWYgIiR7MX0iIC1hIC1yICIkezF9IiAtYSAtcyAi JHsxfSIgXTsgdGhlbg0KIAkJZWNobyAiVXNpbmcgJHsxfSBhcyBhbiBlbnRy b3B5IGZpbGUiDQpkaWZmIC11ciAvdXNyL3NyYy9ldGMvcmMuc2h1dGRvd24g ZXRjL3JjLnNodXRkb3duDQotLS0gL3Vzci9zcmMvZXRjL3JjLnNodXRkb3du CVN1biBEZWMgMTcgMDA6MTU6NTcgMjAwMA0KKysrIGV0Yy9yYy5zaHV0ZG93 bglGcmkgSnVuIDIyIDA3OjA3OjE5IDIwMDENCkBAIC01Miw2ICs1MiwyNiBA QA0KIAkuIC9ldGMvcmMuY29uZg0KIGZpDQogDQorY2FzZSAke3JjX25nfSBp bg0KK1tZeV1bRWVdW1NzXSkNCisJLiAvZXRjL3JjLnN1YnINCisNCisJZmls ZXM9YHJjb3JkZXIgLWsgc2h1dGRvd24gL2V0Yy9yYy5kLypgDQorCWZvciBp IGluICRmaWxlczsgZG8gICAgICAgICAgICAgICAgICAgICAjIHJldmVyc2Ug b3JkZXIgb2YgZmlsZXMNCisJCW5maWxlcz0iJGkgJG5maWxlcyINCisJZG9u ZQ0KKwlmaWxlcz0kbmZpbGVzDQorDQorCWZvciBpIGluICRmaWxlczsgZG8N CisJCXJ1bl9yY19zY3JpcHQgJGkgc3RvcA0KKwlkb25lDQorDQorCWV4aXQg MA0KKwk7Ow0KKyopDQorCTs7DQorZXNhYw0KKw0KICMgV3JpdGUgc29tZSBl bnRyb3B5IHNvIHRoZSByZWJvb3RpbmcgL2Rldi9yYW5kb20gY2FuIHJlc2Vl ZA0KICMNCiBjYXNlICR7ZW50cm9weV9maWxlfSBpbg0K --0-2121145011-993219236=:25983-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 8: 7:27 2001 Delivered-To: freebsd-arch@freebsd.org Received: from whale.sunbay.crimea.ua (whale.sunbay.crimea.ua [212.110.138.65]) by hub.freebsd.org (Postfix) with ESMTP id 7E69137B401; Fri, 22 Jun 2001 08:05:13 -0700 (PDT) (envelope-from ru@whale.sunbay.crimea.ua) Received: (from ru@localhost) by whale.sunbay.crimea.ua (8.11.2/8.11.2) id f5MF59u40028; Fri, 22 Jun 2001 18:05:09 +0300 (EEST) (envelope-from ru) Date: Fri, 22 Jun 2001 18:05:09 +0300 From: Ruslan Ermilov To: arch@FreeBSD.org, current@FreeBSD.org Subject: ucred.cr_gid Message-ID: <20010622180509.D31008@sunbay.com> Mail-Followup-To: arch@FreeBSD.org, current@FreeBSD.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="nFreZHaLTZJo0R7j" Content-Disposition: inline User-Agent: Mutt/1.2.5i Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --nFreZHaLTZJo0R7j Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi! The attached patch replaces ucred.cr_groups[0] with ucred.cr_gid. This is mostly needed for POSIX alignment. setegid(2) etc. should not change supplementary groups set. Also, type of 's group.gr_gid changed to a more natural gid_t (also as in POSIX). getgrouplist(3)'s and initgroups(3)'s prototypes fixed. getgrouplist(3) has been also fixed to not duplicate the primary group, and always return number of suplementary groups, even if ngroups is zero (similar to sysctl(3)). Assorted changes: cmsgcred.cmcred_egid New kproc_info.ki_gid New portal_cred.pcr_gid New xucred.cr_gid New I'm not sure what to do with xucred. Also, I'm not sure about KINFO_PROC_SIZE on ia64 and PowerPC. Please review. See also ChangeLog. Cheers, -- Ruslan Ermilov Oracle Developer/DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age --nFreZHaLTZJo0R7j Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=p Index: include/grp.h =================================================================== RCS file: /home/ncvs/src/include/grp.h,v retrieving revision 1.3 diff -u -p -r1.3 grp.h --- include/grp.h 1997/05/07 19:59:59 1.3 +++ include/grp.h 2001/06/22 14:50:40 @@ -48,7 +48,7 @@ struct group { char *gr_name; /* group name */ char *gr_passwd; /* group password */ - int gr_gid; /* group id */ + gid_t gr_gid; /* group id */ char **gr_mem; /* group members */ }; Index: include/unistd.h =================================================================== RCS file: /home/ncvs/src/include/unistd.h,v retrieving revision 1.41 diff -u -p -r1.41 unistd.h --- include/unistd.h 2001/05/27 19:57:36 1.41 +++ include/unistd.h 2001/06/22 14:50:40 @@ -138,7 +138,7 @@ int ftruncate __P((int, off_t)); #endif int getdomainname __P((char *, int)); int getdtablesize __P((void)); -int getgrouplist __P((const char *, int, int *, int *)); +int getgrouplist __P((const char *, gid_t, gid_t *, int *)); long gethostid __P((void)); int gethostname __P((char *, int)); int getlogin_r __P((char *, int)); @@ -151,7 +151,7 @@ int getresuid __P((uid_t *, uid_t *, ui int getsid __P((pid_t _pid)); char *getusershell __P((void)); char *getwd __P((char *)); /* obsoleted by getcwd() */ -int initgroups __P((const char *, int)); +int initgroups __P((const char *, gid_t)); int iruserok __P((unsigned long, int, const char *, const char *)); int iruserok_sa __P((const void *, int, int, const char *, const char *)); int issetugid __P((void)); Index: lib/libc/gen/getgrent.3 =================================================================== RCS file: /home/ncvs/src/lib/libc/gen/getgrent.3,v retrieving revision 1.15 diff -u -p -r1.15 getgrent.3 --- lib/libc/gen/getgrent.3 2000/11/20 16:18:45 1.15 +++ lib/libc/gen/getgrent.3 2001/06/22 14:50:41 @@ -78,7 +78,7 @@ file struct group { char *gr_name; /* group name */ char *gr_passwd; /* group password */ - int gr_gid; /* group id */ + gid_t gr_gid; /* group id */ char **gr_mem; /* group members */ }; .Ed Index: lib/libc/gen/getgrouplist.3 =================================================================== RCS file: /home/ncvs/src/lib/libc/gen/getgrouplist.3,v retrieving revision 1.6 diff -u -p -r1.6 getgrouplist.3 --- lib/libc/gen/getgrouplist.3 2000/10/30 13:23:18 1.6 +++ lib/libc/gen/getgrouplist.3 2001/06/22 14:50:41 @@ -43,18 +43,18 @@ .Sh SYNOPSIS .Fd #include .Ft int -.Fn getgrouplist "const char *name" "int basegid" "int *groups" "int *ngroups" +.Fn getgrouplist "const char *name" "gid_t basegid" "gid_t *groups" "int *ngroups" .Sh DESCRIPTION The .Fn getgrouplist -function reads through the group file and calculates +function reads through the group database and calculates the group access list for the user specified in .Fa name . The .Fa basegid is automatically included in the groups list. Typically this value is given as -the group number from the password file. +the group number from the password database. .Pp The resulting group list is returned in the integer array pointed to by .Fa groups . @@ -64,6 +64,8 @@ array in the integer pointed to by .Fa ngroups ; the actual number of groups found is returned in .Fa ngroups . +.Pp +Duplicate group IDs will be suppressed from the result. .Sh RETURN VALUES The .Fn getgrouplist @@ -94,3 +96,11 @@ If the invoking program uses any of thes the group structure will be overwritten in the call to .Fn getgrouplist . +.Pp +In the case where the group array is too small and duplicate GIDs +have been suppressed, the returned +.Fa ngroups +will be too large by a factor of the difference between the given +size and the number of matches. +This is not considered to be a major problem, since it's still going +to be a smaller figure than when duplicates were not suppressed. Index: lib/libc/gen/getgrouplist.c =================================================================== RCS file: /home/ncvs/src/lib/libc/gen/getgrouplist.c,v retrieving revision 1.7 diff -u -p -r1.7 getgrouplist.c --- lib/libc/gen/getgrouplist.c 1997/03/12 14:54:22 1.7 +++ lib/libc/gen/getgrouplist.c 2001/06/22 14:50:41 @@ -32,58 +32,66 @@ */ #if defined(LIBC_SCCS) && !defined(lint) +#if 0 static char sccsid[] = "@(#)getgrouplist.c 8.2 (Berkeley) 12/8/94"; +#else +static const char rcsid[] = + "$FreeBSD$"; +#endif #endif /* LIBC_SCCS and not lint */ /* * get credential */ -#include -#include +#include #include int getgrouplist(uname, agroup, groups, grpcnt) const char *uname; - int agroup; - register int *groups; + gid_t agroup; + gid_t *groups; int *grpcnt; { - register struct group *grp; - register int i, ngroups; + struct group *grp; + int i, ngroups; int ret, maxgroups; ret = 0; ngroups = 0; maxgroups = *grpcnt; + /* - * When installing primary group, duplicate it; - * the first element of groups is the effective gid - * and will be overwritten when a setgid file is executed. + * Install primary group. */ - groups[ngroups++] = agroup; - if (maxgroups > 1) - groups[ngroups++] = agroup; + if (ngroups < maxgroups) + groups[ngroups] = agroup; + else + ret = -1; + ngroups++; + /* * Scan the group file to find additional groups. */ setgrent(); - while (grp = getgrent()) { - for (i = 0; i < ngroups; i++) { - if (grp->gr_gid == groups[i]) - goto skip; - } +nextgroup: + while ((grp = getgrent()) != NULL) { + if (grp->gr_gid == agroup) + continue; for (i = 0; grp->gr_mem[i]; i++) { if (!strcmp(grp->gr_mem[i], uname)) { - if (ngroups >= maxgroups) { - ret = -1; - break; + for (i = 0; i < MIN(ngroups, maxgroups); i++) { + if (grp->gr_gid == groups[i]) + goto nextgroup; } - groups[ngroups++] = grp->gr_gid; + if (ngroups < maxgroups) + groups[ngroups] = grp->gr_gid; + else + ret = -1; + ngroups++; break; } } -skip: } endgrent(); *grpcnt = ngroups; Index: lib/libc/gen/initgroups.3 =================================================================== RCS file: /home/ncvs/src/lib/libc/gen/initgroups.3,v retrieving revision 1.8 diff -u -p -r1.8 initgroups.3 --- lib/libc/gen/initgroups.3 2000/10/30 13:23:18 1.8 +++ lib/libc/gen/initgroups.3 2001/06/22 14:50:41 @@ -32,9 +32,9 @@ .\" @(#)initgroups.3 8.1 (Berkeley) 6/4/93 .\" $FreeBSD: src/lib/libc/gen/initgroups.3,v 1.8 2000/10/30 13:23:18 asmodai Exp $ .\" -.Dd June 4, 1993 +.Dd June 21, 2001 .Dt INITGROUPS 3 -.Os BSD 4.2 +.Os .Sh NAME .Nm initgroups .Nd initialize group access list @@ -43,7 +43,7 @@ .Sh SYNOPSIS .Fd #include .Ft int -.Fn initgroups "const char *name" "int basegid" +.Fn initgroups "const char *name" "gid_t basegid" .Sh DESCRIPTION The .Fn initgroups Index: lib/libc/gen/initgroups.c =================================================================== RCS file: /home/ncvs/src/lib/libc/gen/initgroups.c,v retrieving revision 1.3 diff -u -p -r1.3 initgroups.c --- lib/libc/gen/initgroups.c 1996/07/12 18:53:56 1.3 +++ lib/libc/gen/initgroups.c 2001/06/22 14:50:41 @@ -32,27 +32,33 @@ */ #if defined(LIBC_SCCS) && !defined(lint) +#if 0 static char sccsid[] = "@(#)initgroups.c 8.1 (Berkeley) 6/4/93"; +#else +static const char rcsid[] = + "$FreeBSD$"; +#endif #endif /* LIBC_SCCS and not lint */ #include -#include #include +#include #include int initgroups(uname, agroup) const char *uname; - int agroup; + gid_t agroup; { - int groups[NGROUPS], ngroups; + int ngroups; + gid_t groups[NGROUPS]; ngroups = NGROUPS; if (getgrouplist(uname, agroup, groups, &ngroups) < 0) warnx("%s is in too many groups, using first %d", uname, ngroups); - if (setgroups(ngroups, groups) < 0) { + if (setgroups(ngroups, groups) == -1) { warn("setgroups"); return (-1); } Index: lib/libc/sys/recv.2 =================================================================== RCS file: /home/ncvs/src/lib/libc/sys/recv.2,v retrieving revision 1.12 diff -u -p -r1.12 recv.2 --- lib/libc/sys/recv.2 2001/02/01 16:29:44 1.12 +++ lib/libc/sys/recv.2 2001/06/22 14:50:41 @@ -225,6 +225,7 @@ struct cmsgcred { uid_t cmcred_uid; /* real UID of sending process */ uid_t cmcred_euid; /* effective UID of sending process */ gid_t cmcred_gid; /* real GID of sending process */ + gid_t cmcred_egid; /* effective GID of sending process */ short cmcred_ngroups; /* number or groups */ gid_t cmcred_groups[CMGROUP_MAX]; /* groups */ }; Index: lib/libkvm/kvm_proc.c =================================================================== RCS file: /home/ncvs/src/lib/libkvm/kvm_proc.c,v retrieving revision 1.36 diff -u -p -r1.36 kvm_proc.c --- lib/libkvm/kvm_proc.c 2001/05/25 16:58:46 1.36 +++ lib/libkvm/kvm_proc.c 2001/06/22 14:50:41 @@ -135,6 +135,7 @@ kvm_proclist(kd, what, arg, p, bp, maxcn bcopy(ucred.cr_groups, kp->ki_groups, NGROUPS * sizeof(gid_t)); kp->ki_uid = ucred.cr_uid; + kp->ki_gid = ucred.cr_gid; } switch(what) { Index: sbin/mount_portalfs/pt_file.c =================================================================== RCS file: /home/ncvs/src/sbin/mount_portalfs/pt_file.c,v retrieving revision 1.8 diff -u -p -r1.8 pt_file.c --- sbin/mount_portalfs/pt_file.c 1999/08/28 00:13:38 1.8 +++ sbin/mount_portalfs/pt_file.c 2001/06/22 14:50:41 @@ -69,7 +69,7 @@ int *fdp; strcpy(pbuf+1, key + (v[1] ? strlen(v[1]) : 0)); #ifdef DEBUG - printf("path = %s, uid = %d, gid = %d\n", pbuf, pcr->pcr_uid, pcr->pcr_groups[0]); + printf("path = %s, uid = %d, gid = %d\n", pbuf, pcr->pcr_uid, pcr->pcr_gid); printf ("fflag = %x, oflag = %x\n", pcr->pcr_flag, (pcr->pcr_flag)-1); #endif @@ -80,6 +80,9 @@ int *fdp; return (errno); if (seteuid(pcr->pcr_uid) < 0) + return (errno); + + if (setegid(pcr->pcr_gid) < 0) return (errno); /* dmb convert kernel flags to oflags, see */ Index: sbin/mountd/mountd.c =================================================================== RCS file: /home/ncvs/src/sbin/mountd/mountd.c,v retrieving revision 1.55 diff -u -p -r1.55 mountd.c --- sbin/mountd/mountd.c 2001/06/01 10:57:24 1.55 +++ sbin/mountd/mountd.c 2001/06/22 14:50:41 @@ -214,9 +214,9 @@ char exname[MAXPATHLEN]; struct xucred def_anon = { 0, (uid_t)-2, - 1, - { (gid_t)-2 }, - NULL + (gid_t)-2, + 0, + { (gid_t)0 } }; int force_v2 = 0; int resvport_only = 1; @@ -2072,8 +2072,8 @@ parsecred(namelist, cr) * Set up the unprivileged user. */ cr->cr_uid = -2; - cr->cr_groups[0] = -2; - cr->cr_ngroups = 1; + cr->cr_gid = -2; + cr->cr_ngroups = 0; /* * Get the user's password table entry. */ @@ -2098,9 +2098,9 @@ parsecred(namelist, cr) /* * Convert from int's to gid_t's and compress out duplicate */ + cr->cr_gid = groups[0]; cr->cr_ngroups = ngroups - 1; - cr->cr_groups[0] = groups[0]; - for (cnt = 2; cnt < ngroups; cnt++) + for (cnt = 1; cnt < ngroups; cnt++) cr->cr_groups[cnt - 1] = groups[cnt]; return; } Index: sbin/nfsd/nfsd.c =================================================================== RCS file: /home/ncvs/src/sbin/nfsd/nfsd.c,v retrieving revision 1.19 diff -u -p -r1.19 nfsd.c --- sbin/nfsd/nfsd.c 2001/03/25 23:32:55 1.19 +++ sbin/nfsd/nfsd.c 2001/06/22 14:50:45 @@ -433,11 +433,11 @@ main(argc, argv, envp) (pwd = getpwnam(lnam)) != NULL) { cr = &nsd.nsd_cr; cr->cr_uid = pwd->pw_uid; - cr->cr_groups[0] = pwd->pw_gid; - cr->cr_ngroups = 1; + cr->cr_gid = pwd->pw_gid; + cr->cr_ngroups = 0; setgrent(); while ((grp = getgrent()) != NULL) { - if (grp->gr_gid == cr->cr_groups[0]) + if (grp->gr_gid == cr->cr_gid) continue; for (cpp = grp->gr_mem; *cpp != NULL; ++cpp) Index: sys/alpha/osf1/osf1_misc.c =================================================================== RCS file: /home/ncvs/src/sys/alpha/osf1/osf1_misc.c,v retrieving revision 1.16 diff -u -p -r1.16 osf1_misc.c --- sys/alpha/osf1/osf1_misc.c 2001/06/06 14:07:52 1.16 +++ sys/alpha/osf1/osf1_misc.c 2001/06/22 14:50:45 @@ -1119,7 +1119,7 @@ osf1_setgid(p, uap) setsugid(p); } } - if (newcred->cr_groups[0] != gid) { + if (newcred->cr_gid != gid) { change_egid(newcred, gid); setsugid(p); } Index: sys/coda/coda_vnops.c =================================================================== RCS file: /home/ncvs/src/sys/coda/coda_vnops.c,v retrieving revision 1.34 diff -u -p -r1.34 coda_vnops.c --- sys/coda/coda_vnops.c 2001/06/14 09:28:30 1.34 +++ sys/coda/coda_vnops.c 2001/06/22 14:50:47 @@ -1928,7 +1928,8 @@ print_cred(cred) int i; - myprintf(("ref %d\tuid %d\n",cred->cr_ref,cred->cr_uid)); + myprintf(("ref %d\tuid %d\tgid %d\n",cred->cr_ref,cred->cr_uid, + cred->cr_gid)); for (i=0; i < cred->cr_ngroups; i++) myprintf(("\tgroup %d: (%d)\n",i,cred->cr_groups[i])); Index: sys/compat/linux/linux_misc.c =================================================================== RCS file: /home/ncvs/src/sys/compat/linux/linux_misc.c,v retrieving revision 1.103 diff -u -p -r1.103 linux_misc.c --- sys/compat/linux/linux_misc.c 2001/06/15 07:46:18 1.103 +++ sys/compat/linux/linux_misc.c 2001/06/22 14:50:47 @@ -966,16 +966,10 @@ linux_setgroups(p, uap) ngrp = uap->gidsetsize; oldcred = p->p_ucred; - /* - * cr_groups[0] holds egid. Setting the whole set from - * the supplied set will cause egid to be changed too. - * Keep cr_groups[0] unchanged to prevent that. - */ - if ((error = suser_xxx(oldcred, NULL, PRISON_ROOT)) != 0) return (error); - if (ngrp >= NGROUPS) + if (ngrp > NGROUPS) return (EINVAL); newcred = crdup(oldcred); @@ -985,17 +979,16 @@ linux_setgroups(p, uap) if (error) return (error); - newcred->cr_ngroups = ngrp + 1; + newcred->cr_ngroups = ngrp; bsd_gidset = newcred->cr_groups; - ngrp--; while (ngrp >= 0) { - bsd_gidset[ngrp + 1] = linux_gidset[ngrp]; + bsd_gidset[ngrp] = linux_gidset[ngrp]; ngrp--; } } else - newcred->cr_ngroups = 1; + newcred->cr_ngroups = 0; setsugid(p); p->p_ucred = newcred; @@ -1015,13 +1008,7 @@ linux_getgroups(p, uap) cred = p->p_ucred; bsd_gidset = cred->cr_groups; - bsd_gidsetsz = cred->cr_ngroups - 1; - - /* - * cr_groups[0] holds egid. Returning the whole set - * here will cause a duplicate. Exclude cr_groups[0] - * to prevent that. - */ + bsd_gidsetsz = cred->cr_ngroups; if ((ngrp = uap->gidsetsize) == 0) { p->p_retval[0] = bsd_gidsetsz; @@ -1033,7 +1020,7 @@ linux_getgroups(p, uap) ngrp = 0; while (ngrp < bsd_gidsetsz) { - linux_gidset[ngrp] = bsd_gidset[ngrp + 1]; + linux_gidset[ngrp] = bsd_gidset[ngrp]; ngrp++; } Index: sys/fs/portalfs/portal.h =================================================================== RCS file: /home/ncvs/src/sys/fs/portalfs/portal.h,v retrieving revision 1.7 diff -u -p -r1.7 portal.h --- sys/fs/portalfs/portal.h 1999/12/29 04:54:45 1.7 +++ sys/fs/portalfs/portal.h 2001/06/22 14:50:47 @@ -46,6 +46,7 @@ struct portal_args { struct portal_cred { int pcr_flag; /* File open mode */ uid_t pcr_uid; /* From ucred */ + gid_t pcr_gid; /* From ucred */ short pcr_ngroups; /* From ucred */ gid_t pcr_groups[NGROUPS]; /* From ucred */ }; Index: sys/fs/portalfs/portal_vnops.c =================================================================== RCS file: /home/ncvs/src/sys/fs/portalfs/portal_vnops.c,v retrieving revision 1.42 diff -u -p -r1.42 portal_vnops.c --- sys/fs/portalfs/portal_vnops.c 2001/06/15 00:38:03 1.42 +++ sys/fs/portalfs/portal_vnops.c 2001/06/22 14:50:48 @@ -305,6 +305,7 @@ portal_open(ap) pcred.pcr_flag = ap->a_mode; pcred.pcr_uid = ap->a_cred->cr_uid; + pcred.pcr_gid = ap->a_cred->cr_gid; pcred.pcr_ngroups = ap->a_cred->cr_ngroups; bcopy(ap->a_cred->cr_groups, pcred.pcr_groups, NGROUPS * sizeof(gid_t)); aiov[0].iov_base = (caddr_t) &pcred; Index: sys/fs/procfs/procfs_mem.c =================================================================== RCS file: /home/ncvs/src/sys/fs/procfs/procfs_mem.c,v retrieving revision 1.50 diff -u -p -r1.50 procfs_mem.c --- sys/fs/procfs/procfs_mem.c 2001/05/23 09:42:11 1.50 +++ sys/fs/procfs/procfs_mem.c 2001/06/22 14:50:49 @@ -312,7 +312,6 @@ procfs_findtextvp(p) int procfs_kmemaccess(curp) struct proc *curp; { - int i; struct ucred *cred; cred = curp->p_ucred; @@ -320,9 +319,5 @@ int procfs_kmemaccess(curp) return 1; /* XXX: Why isn't this done with file-perms ??? */ - for (i = 0; i < cred->cr_ngroups; i++) - if (cred->cr_groups[i] == KMEM_GROUP) - return 1; - - return 0; + return (groupmember((gid_t)KMEM_GROUP, cred)); } Index: sys/fs/procfs/procfs_status.c =================================================================== RCS file: /home/ncvs/src/sys/fs/procfs/procfs_status.c,v retrieving revision 1.31 diff -u -p -r1.31 procfs_status.c --- sys/fs/procfs/procfs_status.c 2001/05/25 16:59:04 1.31 +++ sys/fs/procfs/procfs_status.c 2001/06/22 14:50:49 @@ -157,9 +157,9 @@ procfs_dostatus(curp, p, pfs, uio) (u_long)cr->cr_rgid); DOCHECK(); - /* egid (cr->cr_svgid) is equal to cr_ngroups[0] - see also getegid(2) in /sys/kern/kern_prot.c */ - + ps += snprintf(ps, psbuf + sizeof(psbuf) - ps, + ",%lu", (u_long)cr->cr_gid); + DOCHECK(); for (i = 0; i < cr->cr_ngroups; i++) { ps += snprintf(ps, psbuf + sizeof(psbuf) - ps, ",%lu", (u_long)cr->cr_groups[i]); Index: sys/fs/umapfs/umap_subr.c =================================================================== RCS file: /home/ncvs/src/sys/fs/umapfs/umap_subr.c,v retrieving revision 1.25 diff -u -p -r1.25 umap_subr.c --- sys/fs/umapfs/umap_subr.c 2001/05/23 09:42:13 1.25 +++ sys/fs/umapfs/umap_subr.c 2001/06/22 14:50:49 @@ -373,9 +373,6 @@ umap_mapids(v_mount, credp) else credp->cr_uid = (uid_t) NOBODY; -#ifdef notdef - /* cr_gid is the same as cr_groups[0] in 4BSD */ - /* Find gid entry in map */ gid = (gid_t) umap_findid(credp->cr_gid, @@ -386,7 +383,6 @@ umap_mapids(v_mount, credp) credp->cr_gid = gid; else credp->cr_gid = NULLGROUP; -#endif /* Now we must map each of the set of groups in the cr_groups structure. */ Index: sys/gnu/ext2fs/ext2_vnops.c =================================================================== RCS file: /home/ncvs/src/sys/gnu/ext2fs/ext2_vnops.c,v retrieving revision 1.56 diff -u -p -r1.56 ext2_vnops.c --- sys/gnu/ext2fs/ext2_vnops.c 2001/05/01 08:34:27 1.56 +++ sys/gnu/ext2fs/ext2_vnops.c 2001/06/22 14:50:49 @@ -855,8 +855,8 @@ ext2_mkdir(ap) */ ucred.cr_ref = 1; ucred.cr_uid = ip->i_uid; - ucred.cr_ngroups = 1; - ucred.cr_groups[0] = dp->i_gid; + ucred.cr_ngroups = 0; + ucred.cr_gid = dp->i_gid; ucp = &ucred; } #endif I @@ -1120,8 +1120,8 @@ ext2_makeinode(mode, dvp, vpp, cnp) */ ucred.cr_ref = 1; ucred.cr_uid = ip->i_uid; - ucred.cr_ngroups = 1; - ucred.cr_groups[0] = pdir->i_gid; + ucred.cr_ngroups = 0; + ucred.cr_gid = pdir->i_gid; ucp = &ucred; #endif I } else { Index: sys/kern/kern_proc.c =================================================================== RCS file: /home/ncvs/src/sys/kern/kern_proc.c,v retrieving revision 1.95 diff -u -p -r1.95 kern_proc.c --- sys/kern/kern_proc.c 2001/06/20 23:10:06 1.95 +++ sys/kern/kern_proc.c 2001/06/22 14:50:50 @@ -431,6 +431,7 @@ fill_kinfo_proc(p, kp) kp->ki_ngroups = p->p_ucred->cr_ngroups; bcopy(p->p_ucred->cr_groups, kp->ki_groups, NGROUPS * sizeof(gid_t)); + kp->ki_gid = p->p_ucred->cr_gid; kp->ki_rgid = p->p_ucred->cr_rgid; kp->ki_svgid = p->p_ucred->cr_svgid; } Index: sys/kern/kern_prot.c =================================================================== RCS file: /home/ncvs/src/sys/kern/kern_prot.c,v retrieving revision 1.93 diff -u -p -r1.93 kern_prot.c --- sys/kern/kern_prot.c 2001/06/06 13:58:03 1.93 +++ sys/kern/kern_prot.c 2001/06/22 14:50:50 @@ -255,15 +255,13 @@ getgid(p, uap) p->p_retval[0] = p->p_ucred->cr_rgid; #if defined(COMPAT_43) || defined(COMPAT_SUNOS) - p->p_retval[1] = p->p_ucred->cr_groups[0]; + p->p_retval[1] = p->p_ucred->cr_gid; #endif return (0); } /* - * Get effective group ID. The "egid" is groups[0], and could be obtained - * via getgroups. This syscall exists because it is somewhat painful to do - * correctly in a library function. + * Get effective group ID. */ #ifndef _SYS_SYSPROTO_H_ struct getegid_args { @@ -278,7 +276,7 @@ getegid(p, uap) struct getegid_args *uap; { - p->p_retval[0] = p->p_ucred->cr_groups[0]; + p->p_retval[0] = p->p_ucred->cr_gid; return (0); } @@ -574,7 +572,7 @@ setgid(p, uap) gid != oldcred->cr_svgid && /* allow setgid(saved gid) */ #endif #ifdef POSIX_APPENDIX_B_4_2_2 /* Use BSD-compat clause from B.4.2.2 */ - gid != oldcred->cr_groups[0] && /* allow setgid(getegid()) */ + gid != oldcred->cr_gid && /* allow setgid(getegid()) */ #endif (error = suser_xxx(oldcred, NULL, PRISON_ROOT))) return (error); @@ -587,7 +585,7 @@ setgid(p, uap) */ if ( #ifdef POSIX_APPENDIX_B_4_2_2 /* use the clause from B.4.2.2 */ - gid == oldcred->cr_groups[0] || + gid == oldcred->cr_gid || #endif suser_xxx(oldcred, NULL, PRISON_ROOT) == 0) /* we are using privs */ #endif @@ -615,7 +613,7 @@ setgid(p, uap) * In all cases permitted cases, we are changing the egid. * Copy credentials so other references do not see our changes. */ - if (oldcred->cr_groups[0] != gid) { + if (oldcred->cr_gid != gid) { change_egid(newcred, gid); setsugid(p); } @@ -646,7 +644,7 @@ setegid(p, uap) (error = suser_xxx(oldcred, NULL, PRISON_ROOT))) return (error); newcred = crdup(oldcred); - if (oldcred->cr_groups[0] != egid) { + if (oldcred->cr_gid != egid) { change_egid(newcred, egid); setsugid(p); } @@ -769,13 +767,13 @@ setregid(p, uap) oldcred = p->p_ucred; if (((rgid != (gid_t)-1 && rgid != oldcred->cr_rgid && rgid != oldcred->cr_svgid) || - (egid != (gid_t)-1 && egid != oldcred->cr_groups[0] && + (egid != (gid_t)-1 && egid != oldcred->cr_gid && egid != oldcred->cr_rgid && egid != oldcred->cr_svgid)) && (error = suser_xxx(oldcred, NULL, PRISON_ROOT)) != 0) return (error); newcred = crdup(oldcred); - if (egid != (gid_t)-1 && oldcred->cr_groups[0] != egid) { + if (egid != (gid_t)-1 && oldcred->cr_gid != egid) { change_egid(newcred, egid); setsugid(p); } @@ -783,9 +781,9 @@ setregid(p, uap) change_rgid(newcred, rgid); setsugid(p); } - if ((rgid != (gid_t)-1 || newcred->cr_groups[0] != newcred->cr_rgid) && - newcred->cr_svgid != newcred->cr_groups[0]) { - change_svgid(newcred, newcred->cr_groups[0]); + if ((rgid != (gid_t)-1 || newcred->cr_gid != newcred->cr_rgid) && + newcred->cr_svgid != newcred->cr_gid) { + change_svgid(newcred, newcred->cr_gid); setsugid(p); } p->p_ucred = newcred; @@ -877,18 +875,18 @@ setresgid(p, uap) oldcred = p->p_ucred; if (((rgid != (gid_t)-1 && rgid != oldcred->cr_rgid && rgid != oldcred->cr_svgid && - rgid != oldcred->cr_groups[0]) || + rgid != oldcred->cr_gid) || (egid != (gid_t)-1 && egid != oldcred->cr_rgid && egid != oldcred->cr_svgid && - egid != oldcred->cr_groups[0]) || + egid != oldcred->cr_gid) || (sgid != (gid_t)-1 && sgid != oldcred->cr_rgid && sgid != oldcred->cr_svgid && - sgid != oldcred->cr_groups[0])) && + sgid != oldcred->cr_gid)) && (error = suser_xxx(oldcred, NULL, PRISON_ROOT)) != 0) return (error); newcred = crdup(oldcred); - if (egid != (gid_t)-1 && oldcred->cr_groups[0] != egid) { + if (egid != (gid_t)-1 && oldcred->cr_gid != egid) { change_egid(newcred, egid); setsugid(p); } @@ -953,8 +951,8 @@ getresgid(p, uap) error1 = copyout((caddr_t)&cred->cr_rgid, (caddr_t)uap->rgid, sizeof(cred->cr_rgid)); if (uap->egid) - error2 = copyout((caddr_t)&cred->cr_groups[0], - (caddr_t)uap->egid, sizeof(cred->cr_groups[0])); + error2 = copyout((caddr_t)&cred->cr_gid, + (caddr_t)uap->egid, sizeof(cred->cr_gid)); if (uap->sgid) error3 = copyout((caddr_t)&cred->cr_svgid, (caddr_t)uap->sgid, sizeof(cred->cr_svgid)); @@ -1018,6 +1016,8 @@ groupmember(gid, cred) register gid_t *gp; gid_t *egp; + if (cred->cr_gid == gid) + return (1); egp = &(cred->cr_groups[cred->cr_ngroups]); for (gp = cred->cr_groups; gp < egp; gp++) if (*gp == gid) @@ -1447,7 +1447,7 @@ change_egid(newcred, egid) gid_t egid; { - newcred->cr_groups[0] = egid; + newcred->cr_gid = egid; } /* Index: sys/kern/uipc_usrreq.c =================================================================== RCS file: /home/ncvs/src/sys/kern/uipc_usrreq.c,v retrieving revision 1.66 diff -u -p -r1.66 uipc_usrreq.c --- sys/kern/uipc_usrreq.c 2001/05/25 16:59:07 1.66 +++ sys/kern/uipc_usrreq.c 2001/06/22 14:50:50 @@ -991,6 +991,7 @@ unp_internalize(control, p) cmcred->cmcred_uid = p->p_ucred->cr_ruid; cmcred->cmcred_gid = p->p_ucred->cr_rgid; cmcred->cmcred_euid = p->p_ucred->cr_uid; + cmcred->cmcred_egid = p->p_ucred->cr_gid; cmcred->cmcred_ngroups = MIN(p->p_ucred->cr_ngroups, CMGROUP_MAX); for (i = 0; i < cmcred->cmcred_ngroups; i++) Index: sys/kern/vfs_aio.c =================================================================== RCS file: /home/ncvs/src/sys/kern/vfs_aio.c,v retrieving revision 1.98 diff -u -p -r1.98 vfs_aio.c --- sys/kern/vfs_aio.c 2001/04/18 22:18:39 1.98 +++ sys/kern/vfs_aio.c 2001/06/22 14:50:51 @@ -694,8 +694,8 @@ aio_daemon(void *uproc) mycp->p_ucred->cr_uid = 0; uifree(mycp->p_ucred->cr_uidinfo); mycp->p_ucred->cr_uidinfo = uifind(0); - mycp->p_ucred->cr_ngroups = 1; - mycp->p_ucred->cr_groups[0] = 1; + mycp->p_ucred->cr_ngroups = 0; + mycp->p_ucred->cr_gid = 1; /* The daemon resides in its own pgrp. */ enterpgrp(mycp, mycp->p_pid, 1); Index: sys/kern/vfs_export.c =================================================================== RCS file: /home/ncvs/src/sys/kern/vfs_export.c,v retrieving revision 1.311 diff -u -p -r1.311 vfs_export.c --- sys/kern/vfs_export.c 2001/05/29 17:46:52 1.311 +++ sys/kern/vfs_export.c 2001/06/22 14:50:51 @@ -99,6 +99,7 @@ vfs_hang_addrlist(mp, nep, argp) np->netc_exflags = argp->ex_flags; bzero(&np->netc_anon, sizeof(np->netc_anon)); np->netc_anon.cr_uid = argp->ex_anon.cr_uid; + np->netc_anon.cr_gid = argp->ex_anon.cr_gid; np->netc_anon.cr_ngroups = argp->ex_anon.cr_ngroups; bcopy(argp->ex_anon.cr_groups, np->netc_anon.cr_groups, sizeof(np->netc_anon.cr_groups)); @@ -147,6 +148,7 @@ vfs_hang_addrlist(mp, nep, argp) np->netc_exflags = argp->ex_flags; bzero(&np->netc_anon, sizeof(np->netc_anon)); np->netc_anon.cr_uid = argp->ex_anon.cr_uid; + np->netc_anon.cr_gid = argp->ex_anon.cr_gid; np->netc_anon.cr_ngroups = argp->ex_anon.cr_ngroups; bcopy(argp->ex_anon.cr_groups, np->netc_anon.cr_groups, sizeof(np->netc_anon.cr_groups)); Index: sys/kern/vfs_syscalls.c =================================================================== RCS file: /home/ncvs/src/sys/kern/vfs_syscalls.c,v retrieving revision 1.194 diff -u -p -r1.194 vfs_syscalls.c --- sys/kern/vfs_syscalls.c 2001/06/06 23:34:38 1.194 +++ sys/kern/vfs_syscalls.c 2001/06/22 14:50:53 @@ -1711,7 +1711,7 @@ access(p, uap) */ tmpcred = crdup(cred); tmpcred->cr_uid = cred->cr_ruid; - tmpcred->cr_groups[0] = cred->cr_rgid; + tmpcred->cr_gid = cred->cr_rgid; p->p_ucred = tmpcred; NDINIT(&nd, LOOKUP, FOLLOW | LOCKLEAF | NOOBJ, UIO_USERSPACE, SCARG(uap, path), p); Index: sys/netinet/tcp_subr.c =================================================================== RCS file: /home/ncvs/src/sys/netinet/tcp_subr.c,v retrieving revision 1.105 diff -u -p -r1.105 tcp_subr.c --- sys/netinet/tcp_subr.c 2001/06/20 12:32:48 1.105 +++ sys/netinet/tcp_subr.c 2001/06/22 14:50:53 @@ -898,6 +898,7 @@ tcp_getcred(SYSCTL_HANDLER_ARGS) } bzero(&xuc, sizeof(xuc)); xuc.cr_uid = inp->inp_socket->so_cred->cr_uid; + xuc.cr_gid = inp->inp_socket->so_cred->cr_gid; xuc.cr_ngroups = inp->inp_socket->so_cred->cr_ngroups; bcopy(inp->inp_socket->so_cred->cr_groups, xuc.cr_groups, sizeof(xuc.cr_groups)); @@ -950,6 +951,7 @@ tcp6_getcred(SYSCTL_HANDLER_ARGS) } bzero(&xuc, sizeof(xuc)); xuc.cr_uid = inp->inp_socket->so_cred->cr_uid; + xuc.cr_gid = inp->inp_socket->so_cred->cr_gid; xuc.cr_ngroups = inp->inp_socket->so_cred->cr_ngroups; bcopy(inp->inp_socket->so_cred->cr_groups, xuc.cr_groups, sizeof(xuc.cr_groups)); Index: sys/netinet/udp_usrreq.c =================================================================== RCS file: /home/ncvs/src/sys/netinet/udp_usrreq.c,v retrieving revision 1.90 diff -u -p -r1.90 udp_usrreq.c --- sys/netinet/udp_usrreq.c 2001/06/11 19:48:18 1.90 +++ sys/netinet/udp_usrreq.c 2001/06/22 14:50:55 @@ -643,6 +643,7 @@ udp_getcred(SYSCTL_HANDLER_ARGS) } bzero(&xuc, sizeof(xuc)); xuc.cr_uid = inp->inp_socket->so_cred->cr_uid; + xuc.cr_gid = inp->inp_socket->so_cred->cr_gid; xuc.cr_ngroups = inp->inp_socket->so_cred->cr_ngroups; bcopy(inp->inp_socket->so_cred->cr_groups, xuc.cr_groups, sizeof(xuc.cr_groups)); Index: sys/netinet6/udp6_usrreq.c =================================================================== RCS file: /home/ncvs/src/sys/netinet6/udp6_usrreq.c,v retrieving revision 1.15 diff -u -p -r1.15 udp6_usrreq.c --- sys/netinet6/udp6_usrreq.c 2001/06/11 12:39:06 1.15 +++ sys/netinet6/udp6_usrreq.c 2001/06/22 14:50:57 @@ -493,6 +493,7 @@ udp6_getcred(SYSCTL_HANDLER_ARGS) } bzero(&xuc, sizeof(xuc)); xuc.cr_uid = inp->inp_socket->so_cred->cr_uid; + xuc.cr_gid = inp->inp_socket->so_cred->cr_gid; xuc.cr_ngroups = inp->inp_socket->so_cred->cr_ngroups; bcopy(inp->inp_socket->so_cred->cr_groups, xuc.cr_groups, sizeof(xuc.cr_groups)); Index: sys/netncp/ncp_conn.c =================================================================== RCS file: /home/ncvs/src/sys/netncp/ncp_conn.c,v retrieving revision 1.16 diff -u -p -r1.16 ncp_conn.c --- sys/netncp/ncp_conn.c 2001/06/13 10:58:37 1.16 +++ sys/netncp/ncp_conn.c 2001/06/22 14:50:57 @@ -245,7 +245,7 @@ ncp_conn_alloc(struct ncp_conn_args *cap ncp->connid = 0xFFFF; ncp->li = *cap; ncp->nc_group = (cap->group != NCP_DEFAULT_GROUP) ? - cap->group : cred->cr_groups[0]; + cap->group : cred->cr_gid; if (cap->retry_count == 0) ncp->li.retry_count = NCP_RETRY_COUNT; Index: sys/netsmb/smb_conn.c =================================================================== RCS file: /home/ncvs/src/sys/netsmb/smb_conn.c,v retrieving revision 1.2 diff -u -p -r1.2 smb_conn.c --- sys/netsmb/smb_conn.c 2001/06/13 10:58:38 1.2 +++ sys/netsmb/smb_conn.c 2001/06/22 14:50:57 @@ -407,7 +407,7 @@ smb_vc_create(struct smb_vcspec *vcspec, if (uid == SMBM_ANY_OWNER) uid = realuid; if (gid == SMBM_ANY_GROUP) - gid = cred->cr_groups[0]; + gid = cred->cr_gid; vcp->vc_uid = uid; vcp->vc_grp = gid; @@ -689,7 +689,7 @@ smb_share_create(struct smb_vc *vcp, str if (uid == SMBM_ANY_OWNER) uid = realuid; if (gid == SMBM_ANY_GROUP) - gid = cred->cr_groups[0]; + gid = cred->cr_gid; ssp = smb_zmalloc(sizeof(*ssp), M_SMBCONN, M_WAITOK); smb_co_init(SSTOCP(ssp), SMBL_SHARE, "smbss", p); ssp->obj.co_free = smb_share_free; Index: sys/nfs/nfs_socket.c =================================================================== RCS file: /home/ncvs/src/sys/nfs/nfs_socket.c,v retrieving revision 1.66 diff -u -p -r1.66 nfs_socket.c --- sys/nfs/nfs_socket.c 2001/05/01 08:13:14 1.66 +++ sys/nfs/nfs_socket.c 2001/06/22 14:50:58 @@ -1824,12 +1824,12 @@ nfs_getreq(nd, nfsd, has_header) return (EBADRPC); } nfsm_dissect(tl, u_int32_t *, (len + 2) * NFSX_UNSIGNED); - for (i = 1; i <= len; i++) + for (i = 0; i < len; i++) if (i < NGROUPS) nd->nd_cr.cr_groups[i] = fxdr_unsigned(gid_t, *tl++); else tl++; - nd->nd_cr.cr_ngroups = (len >= NGROUPS) ? NGROUPS : (len + 1); + nd->nd_cr.cr_ngroups = (len > NGROUPS) ? NGROUPS : len; if (nd->nd_cr.cr_ngroups > 1) nfsrvw_sort(nd->nd_cr.cr_groups, nd->nd_cr.cr_ngroups); len = fxdr_unsigned(int, *++tl); Index: sys/nfs/nfs_subs.c =================================================================== RCS file: /home/ncvs/src/sys/nfs/nfs_subs.c,v retrieving revision 1.101 diff -u -p -r1.101 nfs_subs.c --- sys/nfs/nfs_subs.c 2001/05/19 01:28:07 1.101 +++ sys/nfs/nfs_subs.c 2001/06/22 14:51:00 @@ -701,10 +701,10 @@ nfsm_rpchead(cr, nmflag, procid, auth_ty *tl++ = 0; /* stamp ?? */ *tl++ = 0; /* NULL hostname */ *tl++ = txdr_unsigned(cr->cr_uid); - *tl++ = txdr_unsigned(cr->cr_groups[0]); + *tl++ = txdr_unsigned(cr->cr_gid); grpsiz = (auth_len >> 2) - 5; *tl++ = txdr_unsigned(grpsiz); - for (i = 1; i <= grpsiz; i++) + for (i = 0; i < grpsiz; i++) *tl++ = txdr_unsigned(cr->cr_groups[i]); break; case RPCAUTH_KERB4: @@ -1976,6 +1976,7 @@ nfsrv_fhtovp(fhp, lockflag, vpp, cred, s return (NFSERR_AUTHERR | AUTH_TOOWEAK); } else if (cred->cr_uid == 0 || (exflags & MNT_EXPORTANON)) { cred->cr_uid = credanon->cr_uid; + cred->cr_gid = credanon->cr_gid; for (i = 0; i < credanon->cr_ngroups && i < NGROUPS; i++) cred->cr_groups[i] = credanon->cr_groups[i]; cred->cr_ngroups = i; @@ -2233,6 +2234,7 @@ nfsrv_setcred(incred, outcred) bzero((caddr_t)outcred, sizeof (struct ucred)); outcred->cr_ref = 1; outcred->cr_uid = incred->cr_uid; + outcred->cr_gid = incred->cr_gid; outcred->cr_ngroups = incred->cr_ngroups; for (i = 0; i < incred->cr_ngroups; i++) outcred->cr_groups[i] = incred->cr_groups[i]; Index: sys/nfs/nfs_syscalls.c =================================================================== RCS file: /home/ncvs/src/sys/nfs/nfs_syscalls.c,v retrieving revision 1.68 diff -u -p -r1.68 nfs_syscalls.c --- sys/nfs/nfs_syscalls.c 2001/04/29 02:45:08 1.68 +++ sys/nfs/nfs_syscalls.c 2001/06/22 14:51:01 @@ -271,6 +271,7 @@ nfssvc(p, uap) nuidp->nu_flag = 0; bzero(&nuidp->nu_cr, sizeof(nuidp->nu_cr)); nuidp->nu_cr.cr_uid = nsd->nsd_cr.cr_uid; + nuidp->nu_cr.cr_gid = nsd->nsd_cr.cr_gid; nuidp->nu_cr.cr_ngroups = nsd->nsd_cr.cr_ngroups; bcopy(nsd->nsd_cr.cr_groups, Index: sys/nfs/nfs_vnops.c =================================================================== RCS file: /home/ncvs/src/sys/nfs/nfs_vnops.c,v retrieving revision 1.171 diff -u -p -r1.171 nfs_vnops.c --- sys/nfs/nfs_vnops.c 2001/05/23 09:42:05 1.171 +++ sys/nfs/nfs_vnops.c 2001/06/22 14:51:02 @@ -3131,12 +3131,10 @@ nfsspec_access(ap) } */ *ap; { register struct vattr *vap; - register gid_t *gp; register struct ucred *cred = ap->a_cred; struct vnode *vp = ap->a_vp; mode_t mode = ap->a_mode; struct vattr vattr; - register int i; int error; /* @@ -3171,13 +3169,8 @@ nfsspec_access(ap) */ if (cred->cr_uid != vap->va_uid) { mode >>= 3; - gp = cred->cr_groups; - for (i = 0; i < cred->cr_ngroups; i++, gp++) - if (vap->va_gid == *gp) - goto found; - mode >>= 3; -found: - ; + if (!groupmember(vap->va_gid, cred)) + mode >>= 3; } error = (vap->va_mode & mode) == mode ? 0 : EACCES; return (error); Index: sys/sys/socket.h =================================================================== RCS file: /home/ncvs/src/sys/sys/socket.h,v retrieving revision 1.56 diff -u -p -r1.56 socket.h --- sys/sys/socket.h 2001/06/12 11:12:23 1.56 +++ sys/sys/socket.h 2001/06/22 14:51:02 @@ -359,14 +359,14 @@ struct cmsghdr { * Credentials structure, used to verify the identity of a peer * process that has sent us a message. This is allocated by the * peer process but filled in by the kernel. This prevents the - * peer from lying about its identity. (Note that cmcred_groups[0] - * is the effective GID.) + * peer from lying about its identity. */ struct cmsgcred { pid_t cmcred_pid; /* PID of sending process */ uid_t cmcred_uid; /* real UID of sending process */ uid_t cmcred_euid; /* effective UID of sending process */ gid_t cmcred_gid; /* real GID of sending process */ + gid_t cmcred_egid; /* effective GID of sending process */ short cmcred_ngroups; /* number or groups */ gid_t cmcred_groups[CMGROUP_MAX]; /* groups */ }; Index: sys/sys/ucred.h =================================================================== RCS file: /home/ncvs/src/sys/sys/ucred.h,v retrieving revision 1.24 diff -u -p -r1.24 ucred.h --- sys/sys/ucred.h 2001/05/25 16:59:10 1.24 +++ sys/sys/ucred.h 2001/06/22 14:51:02 @@ -54,6 +54,7 @@ struct ucred { uid_t cr_svuid; /* saved user id */ short cr_ngroups; /* number of groups */ gid_t cr_groups[NGROUPS]; /* groups */ + gid_t cr_gid; /* effective group id */ gid_t cr_rgid; /* real group id */ gid_t cr_svgid; /* saved user id */ struct uidinfo *cr_uidinfo; /* per euid resource consumption */ @@ -61,21 +62,18 @@ struct ucred { struct prison *cr_prison; /* jail(4) */ struct mtx cr_mtx; /* protect refcount */ }; -#define cr_gid cr_groups[0] #define NOCRED ((struct ucred *)0) /* no credential available */ #define FSCRED ((struct ucred *)-1) /* filesystem credential */ /* - * This is the external representation of struct ucred, based upon the - * size of a 4.2-RELEASE struct ucred. There will probably never be - * any need to change the size of this or layout of its used fields. + * This is the external representation of struct ucred. */ struct xucred { u_short _cr_unused0; /* compatibility with old ucred */ uid_t cr_uid; /* effective user id */ + gid_t cr_gid; /* effective group id */ short cr_ngroups; /* number of groups */ gid_t cr_groups[NGROUPS]; /* groups */ - void *_cr_unused1; /* compatibility with old ucred */ }; #ifdef _KERNEL Index: sys/sys/user.h =================================================================== RCS file: /home/ncvs/src/sys/sys/user.h,v retrieving revision 1.38 diff -u -p -r1.38 user.h --- sys/sys/user.h 2001/06/10 02:08:36 1.38 +++ sys/sys/user.h 2001/06/22 14:51:02 @@ -74,16 +74,16 @@ * fill_kinfo_proc and in lib/libkvm/kvm_proc.c in the function kvm_proclist. */ #ifdef __alpha__ -#define KINFO_PROC_SIZE 912 /* the correct size for kinfo_proc */ +#define KINFO_PROC_SIZE 920 /* the correct size for kinfo_proc */ #endif #ifdef __ia64__ -#define KINFO_PROC_SIZE 888 +#define KINFO_PROC_SIZE 896 #endif #ifdef __i386__ -#define KINFO_PROC_SIZE 648 /* the correct size for kinfo_proc */ +#define KINFO_PROC_SIZE 652 /* the correct size for kinfo_proc */ #endif #ifdef __powerpc__ -#define KINFO_PROC_SIZE 656 +#define KINFO_PROC_SIZE 660 #endif #ifndef KINFO_PROC_SIZE #error "Unknown architecture" @@ -117,6 +117,7 @@ struct kinfo_proc { uid_t ki_uid; /* effective user id */ uid_t ki_ruid; /* Real user id */ uid_t ki_svuid; /* Saved effective user id */ + gid_t ki_gid; /* Effective group id */ gid_t ki_rgid; /* Real group id */ gid_t ki_svgid; /* Saved effective group id */ short ki_ngroups; /* number of groups */ Index: sys/ufs/ufs/ufs_vnops.c =================================================================== RCS file: /home/ncvs/src/sys/ufs/ufs/ufs_vnops.c,v retrieving revision 1.169 diff -u -p -r1.169 ufs_vnops.c --- sys/ufs/ufs/ufs_vnops.c 2001/06/06 17:40:57 1.169 +++ sys/ufs/ufs/ufs_vnops.c 2001/06/22 14:51:03 @@ -1389,8 +1389,8 @@ ufs_mkdir(ap) */ ucred.cr_ref = 1; ucred.cr_uid = ip->i_uid; - ucred.cr_ngroups = 1; - ucred.cr_groups[0] = dp->i_gid; + ucred.cr_ngroups = 0; + ucred.cr_gid = dp->i_gid; ucp = &ucred; } #endif @@ -2264,8 +2264,8 @@ ufs_makeinode(mode, dvp, vpp, cnp) */ ucred.cr_ref = 1; ucred.cr_uid = ip->i_uid; - ucred.cr_ngroups = 1; - ucred.cr_groups[0] = pdir->i_gid; + ucred.cr_ngroups = 0; + ucred.cr_gid = pdir->i_gid; ucp = &ucred; #endif } else Index: usr.sbin/rpc.lockd/kern.c =================================================================== RCS file: /home/ncvs/src/usr.sbin/rpc.lockd/kern.c,v retrieving revision 1.3 diff -u -p -r1.3 kern.c --- usr.sbin/rpc.lockd/kern.c 2001/04/25 18:40:38 1.3 +++ usr.sbin/rpc.lockd/kern.c 2001/06/22 14:51:03 @@ -229,9 +229,9 @@ set_auth( cl->cl_auth->ah_ops->ah_destroy(cl->cl_auth); cl->cl_auth = authunix_create(hostname, ucred->cr_uid, - ucred->cr_groups[0], - ucred->cr_ngroups-1, - &ucred->cr_groups[1]); + ucred->cr_gid, + ucred->cr_ngroups, + ucred->cr_groups); } --nFreZHaLTZJo0R7j Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=ChangeLog include/grp.h group.gr_gid's type change: int -> gid_t include/unistd.h getgrouplist(), initgroups() prototypes fixed lib/libc/gen/getgrent.3 reflected grp.h change lib/libc/gen/getgrouplist.3 getgrouplist() prototype and and Hesiod changes lib/libc/gen/getgrouplist.c getgrouplist(): prototype, don't panic if grpcnt == 0, groups[0] is no more egid lib/libc/gen/initgroups.3 initgroups() prototype changed lib/libc/gen/initgroups.c initgroups() prototype changed lib/libc/sys/recv.2 New: cmsgcred.cmcred_egid lib/libkvm/kvm_proc.c New: kproc_info.ki_gid sbin/mount_portalfs/pt_file.c New: portal_cred.pcr_gid sbin/mountd/mountd.c ucred.cr_groups[0] -> ucred.cr_gid sbin/nfsd/nfsd.c ucred.cr_groups[0] -> ucred.cr_gid (XXX: getgroups()) sys/alpha/osf1/osf1_misc.c ucred.cr_groups[0] -> ucred.cr_gid sys/coda/coda_vnops.c debug print of ucred.cr_gid sys/compat/linux/linux_misc.c ucred.cr_groups[0] -> ucred.cr_gid sys/fs/portalfs/portal.h New: portal_cred.pcr_gid sys/fs/portalfs/portal_vnops.c New: portal_cred.pcr_gid sys/fs/procfs/procfs_mem.c ucred.cr_groups[0] -> ucred.cr_gid; simplify sys/fs/procfs/procfs_status.c ucred.cr_groups[0] -> ucred.cr_gid sys/fs/umapfs/umap_subr.c ucred.cr_groups[0] -> ucred.cr_gid sys/gnu/ext2fs/ext2_vnops.c ucred.cr_groups[0] -> ucred.cr_gid sys/kern/kern_proc.c New: kproc_info.ki_gid sys/kern/kern_prot.c ucred.cr_groups[0] -> ucred.cr_gid sys/kern/uipc_usrreq.c New: cmsgcred.cmcred_egid sys/kern/vfs_aio.c ucred.cr_groups[0] -> ucred.cr_gid sys/kern/vfs_export.c ucred.cr_groups[0] -> ucred.cr_gid sys/kern/vfs_syscalls.c ucred.cr_groups[0] -> ucred.cr_gid sys/netinet/tcp_subr.c New: xucred.cr_gid sys/netinet/udp_usrreq.c New: xucred.cr_gid sys/netinet6/udp6_usrreq.c New: xucred.cr_gid sys/netncp/ncp_conn.c ucred.cr_groups[0] -> ucred.cr_gid sys/netsmb/smb_conn.c ucred.cr_groups[0] -> ucred.cr_gid sys/nfs/nfs_socket.c ucred.cr_groups[0] -> ucred.cr_gid sys/nfs/nfs_subs.c ucred.cr_groups[0] -> ucred.cr_gid sys/nfs/nfs_syscalls.c ucred.cr_groups[0] -> ucred.cr_gid sys/nfs/nfs_vnops.c ucred.cr_groups[0] -> ucred.cr_gid; simplify sys/sys/socket.h New: cmsgcred.cmcred_egid sys/sys/ucred.h New: ucred.cr_gid, xucred.cr_gid (XXX) sys/sys/user.h New: kinfo_proc.ki_gid (XXX) sys/ufs/ufs/ufs_vnops.c ucred.cr_groups[0] -> ucred.cr_gid usr.sbin/rpc.lockd/kern.c ucred.cr_groups[0] -> ucred.cr_gid --nFreZHaLTZJo0R7j-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 8:36:40 2001 Delivered-To: freebsd-arch@freebsd.org Received: from hawk.mail.pas.earthlink.net (hawk.mail.pas.earthlink.net [207.217.120.22]) by hub.freebsd.org (Postfix) with ESMTP id 556AA37B407 for ; Fri, 22 Jun 2001 08:36:37 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from mindspring.com (dialup-209.244.104.237.Dial1.SanJose1.Level3.net [209.244.104.237]) by hawk.mail.pas.earthlink.net (EL-8_9_3_3/8.9.3) with ESMTP id IAA10408; Fri, 22 Jun 2001 08:36:33 -0700 (PDT) Message-ID: <3B336622.ABAB7FC1@mindspring.com> Date: Fri, 22 Jun 2001 08:37:06 -0700 From: Terry Lambert Reply-To: tlambert2@mindspring.com X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Peter Pentchev Cc: arch@FreeBSD.ORG Subject: Re: src/release/Makefile NO_SENDMAIL fix References: <20010621201945.A22338@ringworld.oblivion.bg> <20010622132714.A1016@sunbay.com> <20010622141725.A4992@ringworld.oblivion.bg> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Peter Pentchev wrote: > I'm building a custom release to use for > an automated indoors office installation. It works just fine > without Sendmail (and please, no religious threads here :), and > there's no real reason to have Sendmail installed on any of > the machines. The problem you are trying to solve via this "NO" cruft is the problem of building a custom distribution. The time to do this is at the time the distribution image is created, not at the time the compilation occurs. It countinues to be really annoying that FreeBSD does not have a layered software installation mechanism (this is finally being addressed with the import of the NetBSD "rc file" system), and that FreeBSD base system components are not registered into a layered software installation mechanism, such that they become optional. Using a "NO_" kludge to get rid of base system components is a hack, and it discourages a more correct soloution, once you have one that is "good enough" (this is why sysinstall lives on like the police chief/zombie from Plan 9 From Outer Space -- well, that, and no one is permitted by TPTB to make any money off replacing it, so they don't). Given the NetBSD "rc file" system, the remaining tasks are configuration control, which is going to take some more work, and configuration data. The configuration data is going to be relatively straight forward, since the FreeBSD95^H^H Registry^W rc. conf system uses underscores as hierarchy delimiters to achieve the ability to specify name/value pairs in a hierarchical database, albeit without the schema that you would ordinarily use in such a system to enforce correctness^W^W hinder free-form creativity, as in UC Berkeley psycho-pharmacology^W organic chemistry students. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 12:16:40 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mail2in.giga.net.tw (mail2in.giga.net.tw [203.133.1.16]) by hub.freebsd.org (Postfix) with ESMTP id E853937B442 for ; Fri, 22 Jun 2001 12:15:34 -0700 (PDT) (envelope-from e10233@ms60.url.com.tw) Received: from enter (u182-136.u203-203.giga.net.tw [203.203.182.136]) by mail2in.giga.net.tw (Postfix) with SMTP id 34E1651985 for ; Sat, 23 Jun 2001 03:15:02 +0800 (CST) To: e10233@ms60.url.com.tw From: e10233@ms60.url.com.tw Subject: ¶W¸£¤O¤ß´¼¬ì§Þ Date: Sat, 23 Jun 2001 03:12:32 +0800 Message-Id: <37065.133705324071300.2393400@localhost> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary=ueunuommfqhajsag Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --ueunuommfqhajsag Content-Type: text/plain; charset=big5 Content-Transfer-Encoding: 8bit ¿Ë·RªºªB¤Í; ¦b¦¹´£¨Ñ2001¦~³Ì·s¸£¤O¶}µo§Þ³N «e¨¥: ®Ú¾Ú¬ì¾Ç¬ã¨sÅã¥Ü¡A§Ú­Ì¤HÃþ¤j¸£¥i§l¦¬°O¾Ð2000¸U¥»¹Ï®Ñ¤j·§10­Ó¹Ï®ÑÀ] ¤§¶q¡A¥u­n²ß±o¥¿½Tªº°O¾Ð¤èªk¡A¥²¯à±N§Ú­Ì¤j¸£µo´§²OºvºÉ­P¡A¹ï¤H¡A¨Æ ¡Aª«¥t¦³¤@µf¤£¦P¨¤«×¨£¸Ñ¡AÂǦ¹½Òµ{¦@¦P±´¯Á¤j¸£¤F¯«©_¡C ¡·"§Ú­Ìªº±M·~ §Ú­Ì¨ã¦³¥¿²Îªº­^°êMind Maps¤ß´¼Ã¸¹Ïªkªº±Â½ÒÃҮѡA±Ð±z¾Ç²ß­±¹ï21¥@¬ö ªºÄvª§¥²³Æªº§Þ¥©¡B±´¯ÁÁA¸Ñ§Ú­Ì¯«©_ªº¤j¸£¡A½Õ¾ã¾Ç²ßªº¹LÂo¾¹"¶W±j°O¾Ð" ¾Ç²ß¤ß´¼¹Ïªº³W«h¤Î¦p¦ó¹B¥Î¤ß´¼Ã¸¹Ï Mind Maps ªº¤èªk¥´³y¤@Áûª÷ÀY¸£¥Hªï±µ21¥@¬öªº¬D¾Ô¡B°l¨D¥þ¤è¦ì¦¨¥\ªº¤H¥Í¡C ¡·"§Ú­Ìªº¥Øªº ¬°±Ð¾É¥¿½Tªº¾Ç²ß°O¾Ð¤è¦¡¡A¨Ï©ÒŪªº¬ì¥Ø¥i§¹¥þªº°O¦í¤Î¹B¥Î¡A´î¤Ö¾Ç²ß¤§ ®À§é·P¡A¨Ã´£°ª§A¾Ç²ßªº¿³½ì¡C ¤HÃþªº¤j¸£¥u¥Î¨ì3%~6%©|¦³94%¥H¤W³£¨S°V½m¶}µo¨Ï¥Î¡C §Ú­Ì¹B¥Î¤@®M«e±Mªù°V½m±¡³ø¤H­ûªº¤èªk¡A²×¥Í¨ü¥ÎµL½a¡A¦p°O¡G ©m¦W¡B¹q¸Ü¡(«P¶i¤H»ÚÃö«Y¡^¡B­I³æ¦r¡B¾Ç»y¨¥¡B°O¤½¦¡¡B¾ú¥v¡B¦a²z µ¥.... ·Ó§Ú­Ì±Ð§Aªº¤èªk¡A¥u»Ý30%ªº®É¶¡¡A¹F¦¨¦Ê¤À¤§¦Êªº¥\®Ä¡A¥u­n¦³¤ß¦¨ªø¡A ±q10·³¡ã75·³¬Ò «OÃÒ¼W¥[2~15­¿¥H¤Wªº°O¾Ð¤O(°ò¦°V½m)¡C §A·Q¾Ö¦³¶W±j¹L¤Hªº°O¾Ð¶Ü¡H ¹B¥Î¶W±j°O¾Ð°V½m¡B¤ß´¼ ¹Ï°V½m¤ÎÀu¶Õ¸£ªi°V½m¡A ¥i¥HÅý§Aªº°O¾Ð¤O¥ß¨è´£¤É2~15­¿¡C§AÁÙ¦b¬Ý¶Ü¡H§OµS¿Ý»°§Ö¦æ°Ê.... Åwªï¦³§Ó°l¨D¥þ¤è¦ì¦¨¥\¤§¦U¬ÉªB¤ÍÄâ®a(ªB)±a²²(¤Í)°Ñ¥[ª÷ÀY¸£°ò¦°V½m ½Òµ{¡A¸Ô²Ó±¡§Î½Ð¤Wºô¬d¸ß: http://98.to/super2100 ©ÎÀH«Hªþ¥ó µ¹¦Û¤v·Q¤@­Ó¨Ó¤W½Òªº²z¥Ñ: ¥Î³}®Ñ§½ªº®É¶¡¤Î¶R¤@¥»®Ñªº¿ú¡A°Ñ¥[§Ú­ÌÁ|¿ìªº°ò¦½Òµ{¡A «OÃÒ±z°O¾Ð¤O´£¤É2-15­¿¡A(±z¦h¤[¨S¤W®Ñ§½¶R®Ñ¤F©O?)µ´¹ïÅý±zª«¶W©Ò­È¡C ¡@ §Ú­Ì±N¤£©w´Á¦b¥x¥_¡A®ç¶é ¡A·s¦Ë¡A­]®ß¡A¥x¤¤¡A°ª¶¯Á|¿ì¥Ü½d½Òµ{,Åwªï¨Ó¹q¹w¬ù °ª¶¯:7¤ë¥÷¶}½Ò¤é´Á¤À§O¬°:7/4¬P´Á¤T¡A7/13¬P´Á¤­¡A7/26¬P´Á¥| ¥x¤¤Á`¤½¥qTEL¡G04-23165310 FAX:04-23165315 ¬¢ÂŤp©j °ª¶¯¤À¤½¥qTEL¡G07-3861373 0955045803 ¬¢ÂÅ¥ý¥Í ¥þ¬Ù¨ä¥L¦a°Ï ½Ð¬¢ 0965-129085 ¥»°T®§¬O©e°Uµo°e¡A½Ð¤£­nª½±µ¦^ÂÐ¥»«H¡A¦pªG±z¤£·Q¦A±µ¦¬ ¥»°T®§¡A½Ð¦^«H¦Ü¥H¤U«H½cE-mail«H½c¡G:kaohsiung807@edirect168.com:: ¦p¦³¥´ÂZ±z¤§³B¡A½Ð¦h¦h¥]²[¡AÁÂÁ¡I¡I --ueunuommfqhajsag Content-Type: text/html; name="¤W½Òµý.htm" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="¤W½Òµý.htm" PGh0bWw+DQoNCjxoZWFkPg0KPG1ldGEgaHR0cC1lcXVpdj0iQ29udGVudC1UeXBl IiBjb250ZW50PSJ0ZXh0L2h0bWw7IGNoYXJzZXQ9YmlnNSI+DQo8dGl0bGU+t3O6 9K22OTwvdGl0bGU+DQo8bWV0YSBuYW1lPSJHRU5FUkFUT1IiIGNvbnRlbnQ9Ik1p Y3Jvc29mdCBGcm9udFBhZ2UgNC4wIj4NCjxtZXRhIG5hbWU9IlByb2dJZCIgY29u dGVudD0iRnJvbnRQYWdlLkVkaXRvci5Eb2N1bWVudCI+DQo8bWV0YSBuYW1lPSJN aWNyb3NvZnQgVGhlbWUiIGNvbnRlbnQ9Im5vbmUsIGRlZmF1bHQiPg0KPG1ldGEg bmFtZT0iTWljcm9zb2Z0IEJvcmRlciIgY29udGVudD0ibm9uZSwgZGVmYXVsdCI+ DQo8L2hlYWQ+DQoNCjxib2R5Pg0KDQo8cD690LFOprmq7a7mpkOmTCYjMjI2MjU7 vGer4bbHr3Wm3DA0LTIzMTY1MzE1pXikpMFgpL2lcbl3rPkspbukvaVxsU6md7HG pM6naaq+sPLCpr3StXuuybahqu27UKZVv6Slq6RXvdKmYcJJLLtQsXqxtayiqkGw yC7BwsHCIQ0KDQo8cD6hQA0KDQo8dGFibGUgYm9yZGVyPSIxIiB3aWR0aD0iMTAw JSIgaGVpZ2h0PSIyODAiPg0KICA8dHI+DQogICAgPHRkIHdpZHRoPSIzNCUiIGNv bHNwYW49IjIiIGhlaWdodD0iNDUiPjxzcGFuIHN0eWxlPSJGT05ULUZBTUlMWTog t3Oy06n6xek7IG1zby1hc2NpaS1mb250LWZhbWlseTogJ1RpbWVzIE5ldyBSb21h biciPqfarW6w0aVbpmHCSTogDQogICAgICA8L3NwYW4+PC90ZD4NCiAgICA8dGQg d2lkdGg9IjM5JSIgY29sc3Bhbj0iMiIgaGVpZ2h0PSI0NSI+PHNwYW4gc3R5bGU9 IkZPTlQtRkFNSUxZOiC3c7LTqfrF6SI+PGlucHV0IHR5cGU9ImNoZWNrYm94IiB2 YWx1ZT0iT04iIG5hbWU9IkMxIj48L3NwYW4+PGZvbnQgc2l6ZT0iMyI+PHNwYW4g c3R5bGU9IkZPTlQtRkFNSUxZOiC3c7LTqfrF6TsgbXNvLWFzY2lpLWZvbnQtZmFt aWx5OiAnVGltZXMgTmV3IFJvbWFuJyI+Jm5ic3A7pWu4ozwvc3Bhbj48L2ZvbnQ+ PGZvbnQgc2l6ZT0iMyI+PHNwYW4gc3R5bGU9IkxFVFRFUi1TUEFDSU5HOiAycHgi Pq7Er+CwVr1tPC9zcGFuPjxzcGFuIHN0eWxlPSJGT05ULUZBTUlMWTogt3Oy06n6 xek7IG1zby1hc2NpaS1mb250LWZhbWlseTogJ1RpbWVzIE5ldyBSb21hbiciPrDy wqa90rV7PC9zcGFuPjwvZm9udD6hQDwvdGQ+DQogICAgPHRkIHdpZHRoPSIyNyUi IHJvd3NwYW49IjYiIGhlaWdodD0iMjc0Ij4mbmJzcDsmbmJzcDsmbmJzcDsmbmJz cDsmbmJzcDsmbmJzcDsgIA0KICAgICAgPGZvbnQgc2l6ZT0iNSIgZmFjZT0itles 479Bssq2wiI+PGI+sKq2r7r0r7g8L2I+PC9mb250Pg0KICAgICAgPHA+PGZvbnQg Y29sb3I9IiNmZjAwMDAiPjxzcGFuIHN0eWxlPSJGT05ULUZBTUlMWTogt3Oy06n6 xek7IG1zby1iaWRpLWZvbnQtc2l6ZTogMTIuMHB0OyBtc28tYXNjaWktZm9udC1m YW1pbHk6IFRpbWVzIE5ldyBSb21hbiI+PGZvbnQgc2l6ZT0iMiI+pXilX6FBt3Om y6FBrue26aFBpXikpDwvZm9udD48L3NwYW4+PC9mb250PjxzcGFuIHN0eWxlPSJG T05ULUZBTUlMWTogt3Oy06n6xek7IG1zby1iaWRpLWZvbnQtc2l6ZTogMTIuMHB0 OyBtc28tYXNjaWktZm9udC1mYW1pbHk6IFRpbWVzIE5ldyBSb21hbiI+PGZvbnQg c2l6ZT0iMiI+PGZvbnQgY29sb3I9IiNmZjAwMDAiPqFBsKq2rzwvZm9udD6oQ7P1 PGZvbnQgY29sb3I9IiNmZjAwMDAiPq2tpEekUTwvZm9udD6kSKFBqEOsULTBpXW2 fTxmb250IGNvbG9yPSIjZmYwMDAwIj6kQKa4PC9mb250PqFBvdC0o6tluXes+aFB wcLBwqFJPC9mb250Pjwvc3Bhbj6hQDwvcD4NCiAgICA8L3RkPg0KICA8L3RyPg0K ICA8dHI+DQogICAgPHRkIHdpZHRoPSIzNCUiIGNvbHNwYW49IjIiIHJvd3NwYW49 IjIiIGhlaWdodD0iNDEiPjxzcGFuIHN0eWxlPSJGT05ULUZBTUlMWTogt3Oy06n6 xek7IG1zby1hc2NpaS1mb250LWZhbWlseTogJ1RpbWVzIE5ldyBSb21hbiciPqlt plc7PC9zcGFuPjwvdGQ+DQogICAgPHRkIHdpZHRoPSIxMyUiIGhlaWdodD0iMzUi IHJvd3NwYW49IjIiPjxzcGFuIHN0eWxlPSJGT05ULUZBTUlMWTogt3Oy06n6xek7 IG1zby1hc2NpaS1mb250LWZhbWlseTogJ1RpbWVzIE5ldyBSb21hbiciPsFwtbi5 cbjcOjwvc3Bhbj6hQKFAPC90ZD4NCiAgICA8dGQgd2lkdGg9IjI2JSIgaGVpZ2h0 PSIxNyI+oUA8L3RkPg0KICA8L3RyPg0KICA8dHI+DQogICAgPHRkIHdpZHRoPSIy NiUiIGhlaWdodD0iMTgiPqFAPC90ZD4NCiAgPC90cj4NCiAgPHRyPg0KICAgIDx0 ZCB3aWR0aD0iNzMlIiBjb2xzcGFuPSI0IiBoZWlnaHQ9IjUxIj48c3BhbiBzdHls ZT0iRk9OVC1GQU1JTFk6ILdzstOp+sXpOyBtc28tYXNjaWktZm9udC1mYW1pbHk6 ICdUaW1lcyBOZXcgUm9tYW4nIj6m7ad9Ozwvc3Bhbj48L3RkPg0KICA8L3RyPg0K ICA8dHI+DQogICAgPHRkIHdpZHRoPSIxMSUiIHJvd3NwYW49IjIiIGhlaWdodD0i MTE5Ij48c3BhbiBzdHlsZT0iRk9OVC1GQU1JTFk6ILdzstOp+sXpOyBtc28tYXNj aWktZm9udC1mYW1pbHk6ICdUaW1lcyBOZXcgUm9tYW4nIj6kdadAqcq96Dwvc3Bh bj48L3RkPg0KICAgIDx0ZCB3aWR0aD0iMjMlIiBoZWlnaHQ9IjExMyIgcm93c3Bh bj0iMiI+PHNwYW4gc3R5bGU9IkZPTlQtRkFNSUxZOiC3c7LTqfrF6SI+PGlucHV0 IHR5cGU9ImNoZWNrYm94IiB2YWx1ZT0iT04iIG5hbWU9IkMxIj6+x6XNPGlucHV0 IHR5cGU9ImNoZWNrYm94IiB2YWx1ZT0iT04iIG5hbWU9IkMxIj6kvTxpbnB1dCB0 eXBlPSJjaGVja2JveCIgdmFsdWU9Ik9OIiBuYW1lPSJDMSI+PC9zcGFuPrDToUAN CiAgICAgIDxwPjxpbnB1dCB0eXBlPSJjaGVja2JveCIgdmFsdWU9Ik9OIiBuYW1l PSJDMSI+pHU8aW5wdXQgdHlwZT0iY2hlY2tib3giIHZhbHVlPSJPTiIgbmFtZT0i QzEiPjxpbnB1dCB0eXBlPSJjaGVja2JveCIgdmFsdWU9Ik9OIiBuYW1lPSJDMSI+ qkGwyLd+oUA8L3A+DQogICAgPC90ZD4NCiAgICA8dGQgd2lkdGg9IjEzJSIgaGVp Z2h0PSI1MiI+PHNwYW4gc3R5bGU9IkZPTlQtRkFNSUxZOiC3c7LTqfrF6TsgbXNv LWFzY2lpLWZvbnQtZmFtaWx5OiAnVGltZXMgTmV3IFJvbWFuJyI+pn7E1jo8L3Nw YW4+oUA8L3RkPg0KICAgIDx0ZCB3aWR0aD0iMjYlIiBoZWlnaHQ9IjUyIj48c3Bh biBzdHlsZT0iRk9OVC1GQU1JTFk6ILdzstOp+sXpOyBtc28tYXNjaWktZm9udC1m YW1pbHk6ICdUaW1lcyBOZXcgUm9tYW4nIj6zxrX5PC9zcGFuPjxzcGFuIHN0eWxl PSJmb250LWZhbWlseTogt3Oy06n6xek7IG1zby1hc2NpaS1mb250LWZhbWlseTog VGltZXMgTmV3IFJvbWFuIj6hRzwvc3Bhbj6hQDwvdGQ+DQogIDwvdHI+DQogIDx0 cj4NCiAgICA8dGQgd2lkdGg9IjM5JSIgaGVpZ2h0PSI2MSIgY29sc3Bhbj0iMiI+ oUA8Zm9udCBzaXplPSI1Ij7AdbRmvXO4uaFHPGZvbnQgY29sb3I9IiNGRjAwMDAi PjAwPGI+NTYwMzAzPC9iPjwvZm9udD48L2ZvbnQ+oUA8L3RkPg0KICA8L3RyPg0K PC90YWJsZT4NCg0KPHA+PGZvbnQgY29sb3I9IiNGRjAwMDAiPiAgICAgDQoxLr7M prmkV73Stf3DuqXmMzUwpLjBv7hxtk+hQbP1pmG2TyAgIDIutUykV73Stf2qzKRX vdKrZbvdw7ql5jE1MDCkuKzjst+2TzwvZm9udD48L3A+ICANCjxkaXYgYWxpZ249 ImNlbnRlciI+DQogIDxjZW50ZXI+IA0KICA8dGFibGU+IA0KICAgIDx0cj4gDQog DQo8Zm9udCBmYWNlPSK3c7LTqfrF6SI+IA0KICAgICAgPHRkIHdpZHRoPSIxMDAl Ij6leKSkwWCkvaVxVEVMoUcwNC0yMzE2NTMxMCZuYnNwOyBGQVg6MDQtMjMxNjUz MTUgICAgICANCiAgICAgICAgrKI8Zm9udCBjb2xvcj0iIzAwMDBmZiI+wsWkcKlq PC9mb250PjwvdGQ+IA0KPC9mb250PiANCg0KICAgIDwvdHI+IA0KICAgIDx0cj4g DQogDQo8Zm9udCBmYWNlPSK3c7LTqfrF6SI+IA0KICAgICAgPHRkIHdpZHRoPSIx MDAlIj6wqravpMCkvaVxVEVMoUcwNy0zODYxMzczJm5ic3A7Jm5ic3A7Jm5ic3A7 ICAgICAgDQogICAgICAgIDA5NTUwNDU4MDMmbmJzcDsmbmJzcDsmbmJzcDsmbmJz cDsmbmJzcDsmbmJzcDsmbmJzcDsmbmJzcDsmbmJzcDsmbmJzcDsgICAgICANCiAg ICAgICAgrKI8Zm9udCBjb2xvcj0iIzAwMDBmZiI+wsWl/aXNPC9mb250PjwvdGQ+ IA0KPC9mb250PiANCg0KICAgIDwvdHI+IA0KICAgIDx0cj4gDQogDQo8Zm9udCBm YWNlPSK3c7LTqfrF6SI+IA0KICAgICAgPHRkIHdpZHRoPSIxMDAlIj48Zm9udCBj b2xvcj0iIzAwMDBmZiI+pf6s2ajkpUymYbDPvdCsoiZuYnNwOyA8L2ZvbnQ+PGI+ PGZvbnQgY29sb3I9IiNmZjk5MDAiIGZhY2U9IkFyaWFsIiBjbGFzcz0iZm9udDE2 cHgiIHNpemU9IjMiPjA5NjUtMTI5MDg1PC9mb250PjwvYj4gIA0KPGZvbnQgY29s b3I9IiMwMDAwZmYiPsLFpf2lzSZuYnNwOyZuYnNwOyA8L2ZvbnQ+PGEgaHJlZj0i bWFpbHRvOnN1cGVyXzIxMDBAc2luYW1haWwuY29tIj48Zm9udCBjb2xvcj0iI0ZG MDAwMCI+qc6o06tIPC9mb250PjwvYT4gIA0KPC9mb250PiANCg0KICAgICAgPC90 ZD4gDQogICAgPC90cj4NCiAgPC90YWJsZT4NCiAgPC9jZW50ZXI+DQo8L2Rpdj4N Cg0KPC9ib2R5Pg0KDQo8L2h0bWw+DQo= --ueunuommfqhajsag-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 12:17:47 2001 Delivered-To: freebsd-arch@freebsd.org Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by hub.freebsd.org (Postfix) with ESMTP id 181A537B406 for ; Fri, 22 Jun 2001 12:17:36 -0700 (PDT) (envelope-from imp@harmony.village.org) Received: from harmony.village.org (localhost.village.org [127.0.0.1]) by harmony.village.org (8.11.3/8.11.1) with ESMTP id f5MJHZV76094 for ; Fri, 22 Jun 2001 13:17:35 -0600 (MDT) (envelope-from imp@harmony.village.org) Message-Id: <200106221917.f5MJHZV76094@harmony.village.org> To: arch@freebsd.org Subject: Proposed sys/compile change Date: Fri, 22 Jun 2001 13:17:35 -0600 From: Warner Losh Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG There was a thread in hackers@ that suggested that someone put together patches to move the compile area to sys/compile/MACHINE or sys/MACHINE/compile. I chose the latter since it is more orthogonal, imho, and similar to how otherbsd has done it. I generally reject the former since it uglifies things, imho, and has less going for it. Please comment on my patches. Warner Index: sys/conf/Makefile.alpha =================================================================== RCS file: /home/imp/FreeBSD/CVS/src/sys/conf/Makefile.alpha,v retrieving revision 1.102 diff -u -r1.102 Makefile.alpha --- sys/conf/Makefile.alpha 2001/06/13 10:58:28 1.102 +++ sys/conf/Makefile.alpha 2001/06/22 19:01:39 @@ -29,7 +29,7 @@ .if exists(./@/.) S= ./@ .else -S= ../.. +S= ../../.. .endif .endif M= ${MACHINE_ARCH} Index: sys/conf/Makefile.i386 =================================================================== RCS file: /home/imp/FreeBSD/CVS/src/sys/conf/Makefile.i386,v retrieving revision 1.236 diff -u -r1.236 Makefile.i386 --- sys/conf/Makefile.i386 2001/06/13 10:58:28 1.236 +++ sys/conf/Makefile.i386 2001/06/22 18:47:09 @@ -29,7 +29,7 @@ .if exists(./@/.) S= ./@ .else -S= ../.. +S= ../../.. .endif .endif M= ${MACHINE_ARCH} Index: sys/conf/Makefile.ia64 =================================================================== RCS file: /home/imp/FreeBSD/CVS/src/sys/conf/Makefile.ia64,v retrieving revision 1.25 diff -u -r1.25 Makefile.ia64 --- sys/conf/Makefile.ia64 2001/06/13 10:58:28 1.25 +++ sys/conf/Makefile.ia64 2001/06/22 19:02:04 @@ -39,7 +39,7 @@ .if exists(./@/.) S= ./@ .else -S= ../.. +S= ../../.. .endif .endif M= ${MACHINE_ARCH} Index: sys/conf/Makefile.pc98 =================================================================== RCS file: /home/imp/FreeBSD/CVS/src/sys/conf/Makefile.pc98,v retrieving revision 1.135 diff -u -r1.135 Makefile.pc98 --- sys/conf/Makefile.pc98 2001/06/13 10:58:28 1.135 +++ sys/conf/Makefile.pc98 2001/06/22 19:01:48 @@ -31,7 +31,7 @@ .if exists(./@/.) S= ./@ .else -S= ../.. +S= ../../.. .endif .endif M= ${MACHINE_ARCH} Index: sys/conf/Makefile.powerpc =================================================================== RCS file: /home/imp/FreeBSD/CVS/src/sys/conf/Makefile.powerpc,v retrieving revision 1.236 diff -u -r1.236 Makefile.powerpc --- sys/conf/Makefile.powerpc 2001/06/13 10:58:28 1.236 +++ sys/conf/Makefile.powerpc 2001/06/22 19:02:16 @@ -29,7 +29,7 @@ .if exists(./@/.) S= ./@ .else -S= ../.. +S= ../../.. .endif .endif M= ${MACHINE_ARCH} Index: usr.sbin/config/config.8 =================================================================== RCS file: /home/imp/FreeBSD/CVS/src/usr.sbin/config/config.8,v retrieving revision 1.26 diff -u -r1.26 config.8 --- usr.sbin/config/config.8 2001/01/22 07:03:06 1.26 +++ usr.sbin/config/config.8 2001/06/22 18:46:38 @@ -110,7 +110,7 @@ .Fx . .Nm creates the directory -.Pa ../../compile/SYSTEM_NAME +.Pa ../compile/SYSTEM_NAME or the one given with the .Fl d option Index: usr.sbin/config/main.c =================================================================== RCS file: /home/imp/FreeBSD/CVS/src/usr.sbin/config/main.c,v retrieving revision 1.50 diff -u -r1.50 main.c --- usr.sbin/config/main.c 2001/02/23 00:22:04 1.50 +++ usr.sbin/config/main.c 2001/06/22 18:52:03 @@ -67,7 +67,7 @@ #define FALSE (0) #endif -#define CDIR "../../compile/" +#define CDIR "../compile/" char * PREFIX; char destdir[MAXPATHLEN]; @@ -158,8 +158,7 @@ { char xxx[MAXPATHLEN]; if (*srcdir == '\0') - (void)snprintf(xxx, sizeof(xxx), "../../%s/include", - machinename); + (void)snprintf(xxx, sizeof(xxx), "../../include"); else (void)snprintf(xxx, sizeof(xxx), "%s/%s/include", srcdir, machinename); To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 12:44:16 2001 Delivered-To: freebsd-arch@freebsd.org Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by hub.freebsd.org (Postfix) with ESMTP id C46EF37B406 for ; Fri, 22 Jun 2001 12:44:14 -0700 (PDT) (envelope-from imp@harmony.village.org) Received: from harmony.village.org (localhost.village.org [127.0.0.1]) by harmony.village.org (8.11.3/8.11.1) with ESMTP id f5MJiEV76359 for ; Fri, 22 Jun 2001 13:44:14 -0600 (MDT) (envelope-from imp@harmony.village.org) Message-Id: <200106221944.f5MJiEV76359@harmony.village.org> Subject: Re: Proposed sys/compile change Cc: arch@FreeBSD.ORG In-reply-to: Your message of "Fri, 22 Jun 2001 13:17:35 MDT." <200106221917.f5MJHZV76094@harmony.village.org> References: <200106221917.f5MJHZV76094@harmony.village.org> Date: Fri, 22 Jun 2001 13:44:14 -0600 From: Warner Losh Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <200106221917.f5MJHZV76094@harmony.village.org> Warner Losh writes: : There was a thread in hackers@ that suggested that someone put : together patches to move the compile area to sys/compile/MACHINE or : sys/MACHINE/compile. I chose the latter since it is more orthogonal, : imho, and similar to how otherbsd has done it. I generally reject the : former since it uglifies things, imho, and has less going for it. : : Please comment on my patches. I also looked at Makefile.inc1 to see if that needed changing, and it appears that it is good no matter how we do the in tree compiles. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 12:51:27 2001 Delivered-To: freebsd-arch@freebsd.org Received: from odin.ac.hmc.edu (Odin.AC.HMC.Edu [134.173.32.75]) by hub.freebsd.org (Postfix) with ESMTP id 5094737B407; Fri, 22 Jun 2001 12:51:21 -0700 (PDT) (envelope-from brdavis@odin.ac.hmc.edu) Received: (from brdavis@localhost) by odin.ac.hmc.edu (8.11.0/8.11.0) id f5MJpDe06722; Fri, 22 Jun 2001 12:51:13 -0700 Date: Fri, 22 Jun 2001 12:51:13 -0700 From: Brooks Davis To: Hajimu UMEMOTO Cc: hackers@FreeBSD.ORG, brian@Awfulhak.org, phk@critter.freebsd.dk, arch@FreeBSD.ORG Subject: Re: cloning network interfaces Message-ID: <20010622125113.A30459@Odin.AC.HMC.Edu> References: <20010608191904.A18847@Odin.AC.HMC.Edu> <20010610.232907.74740159.ume@mahoroba.org> <20010611142030.A15283@Odin.AC.HMC.Edu> <20010613.040716.115941864.ume@mahoroba.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-md5; protocol="application/pgp-signature"; boundary="zhXaljGHf11kAtnf" Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010613.040716.115941864.ume@mahoroba.org>; from ume@mahoroba.org on Wed, Jun 13, 2001 at 04:07:16AM +0900 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --zhXaljGHf11kAtnf Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jun 13, 2001 at 04:07:16AM +0900, Hajimu UMEMOTO wrote: > I like your idea. > I'm serving tunnel broker using DTCP (Dynamic Tunnel Configuration > Protocol) in our ISP. So, I'm grad if we have dynamic gif creation, > too. Ok, after a week and a half of doing other things, I've got a patch together which adds interface cloning based on NetBSD's code. The difference is that you may pass an interface of the from gif# if you don't need a specific number. The ioctl now returns a potentialy modified ifreq which contains the new interface name. This changes the way drivers implement cloning in that they may return a different unit then they were passed and they must do their own resource management rather then relying on the clone functionality in sys/net/if.c to do it for them. The patch is at: http://people.freebsd.org/~brooks/patches/gif.diff The patch can be applied as follows (you need to make the directories): cd /usr/src mkdir sys/modules/if_gif sys/modules/if_stf patch < /tmp/gif.diff The patch does the following: - adds interface cloning support to the kernel - adds interface cloning support to ifconfig - makes gif clonable - makes gif usable as a module - removes the need for NGIF and gif.h - removes va_args usage in in_gif_input to remove a warning - removes gif dependencies from stf - makes stf usable as a module -- Brooks --=20 Any statement of the form "X is the one, true Y" is FALSE. PGP fingerprint 655D 519C 26A7 82E7 2529 9BF0 5D8E 8BE9 F238 1AD4 --zhXaljGHf11kAtnf Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.4 (GNU/Linux) Comment: For info see http://www.gnupg.org iD8DBQE7M6GxXY6L6fI4GtQRAk2oAKDkCdhGxDAZS1q+F7P+dk7cNx5lkACcCxL9 8vq8z+ZPJeSt8+WFubuJpsA= =LY+F -----END PGP SIGNATURE----- --zhXaljGHf11kAtnf-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 18:46:48 2001 Delivered-To: freebsd-arch@freebsd.org Received: from magnesium.net (toxic.magnesium.net [207.154.84.15]) by hub.freebsd.org (Postfix) with SMTP id 0ABFE37B406 for ; Fri, 22 Jun 2001 18:46:47 -0700 (PDT) (envelope-from jasone@magnesium.net) Received: (qmail 8754 invoked by uid 1142); 23 Jun 2001 01:47:48 -0000 Date: 22 Jun 2001 18:47:48 -0700 Date: Fri, 22 Jun 2001 18:46:26 -0700 From: Jason Evans To: arch@freebsd.org Subject: Updated KSEs paper Message-ID: <20010622184626.B47186@canonware.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG A number of people are going to discuss various subjects at a meeting during USENIX, one of them being KSEs. I won't be able to attend (a sister is getting married that day), but wanted to make an updated version of the paper available to avoid others having to fix the same design problems as I've already fixed. The paper still is not by any means perfect, but it addresses most of the issues that people brought up in previous discussions on this mailing list. Feedback and suggestions are welcome. http://people.freebsd.org/~jasone/refs/freebsd_kse/freebsd_kse.html http://people.freebsd.org/~jasone/refs/freebsd_kse.ps Jason To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 20:24: 8 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mail.noos.fr (descartes.noos.net [212.198.2.74]) by hub.freebsd.org (Postfix) with ESMTP id 3081537B407 for ; Fri, 22 Jun 2001 20:24:00 -0700 (PDT) (envelope-from clefevre@redirect.to) Received: (qmail 7561468 invoked by uid 0); 23 Jun 2001 03:23:58 -0000 Received: from unknown (HELO gits.dyndns.org) ([212.198.231.187]) (envelope-sender ) by 212.198.2.74 (qmail-ldap-1.03) with SMTP for ; 23 Jun 2001 03:23:58 -0000 Received: (from root@localhost) by gits.dyndns.org (8.11.4/8.11.4) id f5LJt4k11924; Thu, 21 Jun 2001 21:55:04 +0200 (CEST) (envelope-from clefevre@redirect.to) To: Chris Wasser Cc: Kelly Yancey , arch@FreeBSD.ORG Subject: Re: netbsd rc system diff References: <20010617150050.F582@skunkworks.arpa.mil> <20010617163431.G582@skunkworks.arpa.mil> X-Face: V|+c;4!|B?E%BE^{E6);aI.[<97Zd*>^#%Y5Cxv;%Y[PT-LW3;A:fRrJ8+^k"e7@+30g0YD0*^^3jgyShN7o?a]C la*Zv'5NA,=963bM%J^o]C Reply-To: Cyrille Lefevre In-Reply-To: <20010617163431.G582@skunkworks.arpa.mil> Mail-Copies-To: never From: Cyrille Lefevre Date: 21 Jun 2001 21:55:02 +0200 Message-ID: <8zilfw15.fsf@gits.dyndns.org> Lines: 24 User-Agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.1 (Cuyahoga Valley) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Chris Wasser writes: > On Sun 17 Jun 2001, Kelly Yancey wrote: [snip] > > Minor nit: would you mind running the ps output through tail first to trim > > off the header. It doesn't correlate well in the sorted output. > > > > # ps -ax -o 'pid,command' | tail +2 | sort +1 > > That would remove the check in rc.subr for the header: > > if [ "$_npid" = "PID" ]; then > continue > fi > > Seems like a good idea to me :) this fork an unneeded process and I'm not sure this speed up things. the test should suffice. Cyrille. -- home: mailto:clefevre@redirect.to UNIX is user-friendly; it's just particular work: mailto:Cyrille.Lefevre@edf.fr about who it chooses to be friends with. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Jun 22 20:24:11 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mail.noos.fr (descartes.noos.net [212.198.2.74]) by hub.freebsd.org (Postfix) with ESMTP id 4308F37B408 for ; Fri, 22 Jun 2001 20:24:00 -0700 (PDT) (envelope-from clefevre@redirect.to) Received: (qmail 7532218 invoked by uid 0); 23 Jun 2001 03:23:58 -0000 Received: from unknown (HELO gits.dyndns.org) ([212.198.231.187]) (envelope-sender ) by 212.198.2.74 (qmail-ldap-1.03) with SMTP for ; 23 Jun 2001 03:23:58 -0000 Received: (from root@localhost) by gits.dyndns.org (8.11.4/8.11.4) id f5LKh3W13812; Thu, 21 Jun 2001 22:43:03 +0200 (CEST) (envelope-from clefevre@redirect.to) To: obrien@FreeBSD.ORG Cc: arch@FreeBSD.ORG Subject: Re: (FWD) Re: import NetBSD rc system References: <20010620182320.D99923@dragon.nuxi.com> X-Face: V|+c;4!|B?E%BE^{E6);aI.[<97Zd*>^#%Y5Cxv;%Y[PT-LW3;A:fRrJ8+^k"e7@+30g0YD0*^^3jgyShN7o?a]C la*Zv'5NA,=963bM%J^o]C Reply-To: Cyrille Lefevre In-Reply-To: <20010620182320.D99923@dragon.nuxi.com> Mail-Copies-To: never From: Cyrille Lefevre Date: 21 Jun 2001 22:43:02 +0200 Message-ID: <3d8tftt5.fsf@gits.dyndns.org> Lines: 112 User-Agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.1 (Cuyahoga Valley) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG "David O'Brien" writes: [snip] > diff -ur /usr/src/etc/rc etc/rc > --- /usr/src/etc/rc Fri May 11 12:06:55 2001 > +++ etc/rc Sat Jun 16 15:46:27 2001 > @@ -52,6 +52,39 @@ > PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin > export HOME PATH > > +# If there is a global system configuration file, suck it in. > +# > +if [ -r /etc/defaults/rc.conf ]; then > + . /etc/defaults/rc.conf > + source_rc_confs > +elif [ -r /etc/rc.conf ]; then > + . /etc/rc.conf > +fi > + > +case ${new_rc} in > +[Yy][Ee][Ss]) maybe a check of the existance of /etc/rc.subr have to be done ? > + . /etc/rc.subr > + > + _rc_conf_loaded=YES > + > + if [ "$1" = autoboot ]; then > + autoboot=yes > + _rc_fast_run=yes # run_rc_command(): do fast booting > + fi > + > + files=`rcorder -s nostart /etc/rc.d/*` > + > + for _rc_elem in $files; do > + run_rc_script $_rc_elem start > + done > + > + exit 0 > + ;; > +*) > + # fall-through to the old rc scripts > + ;; IMHO, the above three lines aren't needed. > +esac > + > # BOOTP diskless boot. We have to run the rc file early in order to > # retarget various config files. > # > @@ -60,15 +93,6 @@ > if [ ${dlv:=0} != 0 ]; then > . /etc/rc.diskless1 > fi > -fi > - > -# If there is a global system configuration file, suck it in. > -# > -if [ -r /etc/defaults/rc.conf ]; then > - . /etc/defaults/rc.conf > - source_rc_confs > -elif [ -r /etc/rc.conf ]; then > - . /etc/rc.conf > fi > > feed_dev_random() { > diff -ur /usr/src/etc/rc.shutdown etc/rc.shutdown > --- /usr/src/etc/rc.shutdown Sun Dec 17 00:15:57 2000 > +++ etc/rc.shutdown Sat Jun 16 15:46:32 2001 > @@ -52,6 +52,26 @@ > . /etc/rc.conf > fi > > +case ${new_rc} in > +[Yy][Ee][Ss]) > + . /etc/rc.subr > + > + files=`rcorder -k shutdown /etc/rc.d/*` > + for i in $files; do # reverse order of files > + nfiles="$i $nfiles" > + done > + files=$nfiles > + > + for i in $files; do > + run_rc_script $i stop > + done > + > + exit 0 > + ;; > +*) > + ;; same assertion here. > +esac > + > # Write some entropy so the rebooting /dev/random can reseed > # > case ${entropy_file} in > ---------- see you. Cyrille. -- home: mailto:clefevre@redirect.to UNIX is user-friendly; it's just particular work: mailto:Cyrille.Lefevre@edf.fr about who it chooses to be friends with. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sat Jun 23 0:17:31 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by hub.freebsd.org (Postfix) with ESMTP id 201B637B408 for ; Sat, 23 Jun 2001 00:17:27 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id RAA11500; Sat, 23 Jun 2001 17:17:19 +1000 Date: Sat, 23 Jun 2001 17:15:27 +1000 (EST) From: Bruce Evans X-Sender: bde@besplex.bde.org To: Warner Losh Cc: arch@FreeBSD.ORG Subject: Re: Proposed sys/compile change In-Reply-To: <200106221917.f5MJHZV76094@harmony.village.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 22 Jun 2001, Warner Losh wrote: > There was a thread in hackers@ that suggested that someone put > together patches to move the compile area to sys/compile/MACHINE or > sys/MACHINE/compile. I chose the latter since it is more orthogonal, > imho, and similar to how otherbsd has done it. I generally reject the > former since it uglifies things, imho, and has less going for it. I would prefer to use the canonical place in the object tree: /usr/obj/usr/src/sys/${MACHINE}/conf (with adjustments for the obj and src trees not being in the usual places). The main problem with this is that config files in sys/${MACHINE}/conf are not directories, so things like `make objlink' and not using a separate object directory wouldn't work right. > Index: sys/conf/Makefile.alpha > =================================================================== > RCS file: /home/imp/FreeBSD/CVS/src/sys/conf/Makefile.alpha,v > retrieving revision 1.102 > diff -u -r1.102 Makefile.alpha > --- sys/conf/Makefile.alpha 2001/06/13 10:58:28 1.102 > +++ sys/conf/Makefile.alpha 2001/06/22 19:01:39 > @@ -29,7 +29,7 @@ > .if exists(./@/.) > S= ./@ > .else > -S= ../.. > +S= ../../.. > .endif > .endif > M= ${MACHINE_ARCH} You can prepare for putting things in the obj tree by changing config(8) to generate `@' (a symlink which points to the sys directory via an absolute path) and changing kernel Makefiles to use `@' instead of $S and not have the above ifdef. This method is already used for modules (except `@' is generated by kmod.mk in a less reliable way than config(8) can do). Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sat Jun 23 5:14:56 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id DB39937B407 for ; Sat, 23 Jun 2001 05:14:48 -0700 (PDT) (envelope-from roam@ringworld.nanolink.com) Received: (qmail 616 invoked by uid 1000); 23 Jun 2001 12:13:10 -0000 Date: Sat, 23 Jun 2001 15:13:10 +0300 From: Peter Pentchev To: arch@FreeBSD.org Cc: audit@FreeBSD.org Subject: patch for '%lld' handling in *scanf(3) Message-ID: <20010623151310.A497@ringworld.oblivion.bg> Mail-Followup-To: arch@FreeBSD.org, audit@FreeBSD.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, scanf(3) does not understand %lld for 'long long', it only understands %qd, and it treats %lld as plain %ld. printf(3) prints out %lld just fine. The fix needed is just three lines of code, which have been in both NetBSD and OpenBSD for some time. Demonstration: the following program: #include #include int main(void) { quad_t x = 0xeFFFFFFFFFFFFFFe; scanf("%lld", &x); printf("%llx\n", x); return (0); } Before: [roam@freefall ~/c/misc/foo]$ ./foo7 5 efffffff00000005 [roam@freefall ~/c/misc/foo]$ After: [roam@ringworld:v4 ~/c/misc/foo]$ ./foo7 5 5 [roam@ringworld:v4 ~/c/misc/foo]$ The patch is attached. OK, so maybe this patch is not quite semantically correct; it tends to assume that 'long long' is the same as 'quad', or at least, that the programmer asked for 'quad' by using %lld. A 'real' fix would be defining a LONGLONG flag for scanf(). G'luck, Peter -- When you are not looking at it, this sentence is in Spanish. Index: src/lib/libc/stdio/vfscanf.c =================================================================== RCS file: /home/ncvs/src/lib/libc/stdio/vfscanf.c,v retrieving revision 1.16 diff -u -r1.16 vfscanf.c --- src/lib/libc/stdio/vfscanf.c 2001/02/10 05:46:05 1.16 +++ src/lib/libc/stdio/vfscanf.c 2001/06/23 12:12:30 @@ -186,7 +186,12 @@ flags |= SUPPRESS; goto again; case 'l': - flags |= LONG; + if (*fmt == 'l') { + fmt++; + flags |= QUAD; + } else { + flags |= LONG; + } goto again; case 'q': flags |= QUAD; To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sat Jun 23 6: 9:35 2001 Delivered-To: freebsd-arch@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id 4E01137B407 for ; Sat, 23 Jun 2001 06:09:27 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 1823 invoked by uid 1000); 23 Jun 2001 13:07:48 -0000 Date: Sat, 23 Jun 2001 16:07:48 +0300 From: Peter Pentchev To: arch@FreeBSD.org Cc: audit@FreeBSD.org Subject: Re: patch for '%lld' handling in *scanf(3) Message-ID: <20010623160748.C497@ringworld.oblivion.bg> Mail-Followup-To: arch@FreeBSD.org, audit@FreeBSD.org References: <20010623151310.A497@ringworld.oblivion.bg> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010623151310.A497@ringworld.oblivion.bg>; from roam@orbitel.bg on Sat, Jun 23, 2001 at 03:13:10PM +0300 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sat, Jun 23, 2001 at 03:13:10PM +0300, Peter Pentchev wrote: > Hi, > > scanf(3) does not understand %lld for 'long long', it only understands > %qd, and it treats %lld as plain %ld. printf(3) prints out %lld just fine. > The fix needed is just three lines of code, which have been in both NetBSD > and OpenBSD for some time. [snip] > The patch is attached. > > OK, so maybe this patch is not quite semantically correct; it tends > to assume that 'long long' is the same as 'quad', or at least, that > the programmer asked for 'quad' by using %lld. A 'real' fix would > be defining a LONGLONG flag for scanf(). Well, here's a patch that implements %lld the proper way :) G'luck, Peter -- If you think this sentence is confusing, then change one pig. Index: src/lib/libc/stdio/vfscanf.c =================================================================== RCS file: /home/ncvs/src/lib/libc/stdio/vfscanf.c,v retrieving revision 1.16 diff -u -r1.16 vfscanf.c --- src/lib/libc/stdio/vfscanf.c 2001/02/10 05:46:05 1.16 +++ src/lib/libc/stdio/vfscanf.c 2001/06/23 13:09:23 @@ -77,6 +77,7 @@ #define POINTER 0x10 /* weird %p pointer (`fake hex') */ #define NOSKIP 0x20 /* do not skip blanks */ #define QUAD 0x400 +#define LONGLONG 0x800 /* * The following are used in numeric conversions only: @@ -186,7 +187,12 @@ flags |= SUPPRESS; goto again; case 'l': - flags |= LONG; + if (*fmt == 'l') { + fmt++; + flags |= LONGLONG; + } else { + flags |= LONG; + } goto again; case 'q': flags |= QUAD; @@ -290,6 +296,8 @@ *va_arg(ap, short *) = nread; else if (flags & LONG) *va_arg(ap, long *) = nread; + else if (flags & LONGLONG) + *va_arg(ap, long long *) = nread; else if (flags & QUAD) *va_arg(ap, quad_t *) = nread; else @@ -580,6 +588,8 @@ *va_arg(ap, short *) = res; else if (flags & LONG) *va_arg(ap, long *) = res; + else if (flags & LONGLONG) + *va_arg(ap, long long *) = res; else if (flags & QUAD) *va_arg(ap, quad_t *) = res; else To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message