From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 00:59:01 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9FA0D106566B for ; Sun, 9 Jan 2011 00:59:01 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from esa-jnhn.mail.uoguelph.ca (esa-jnhn.mail.uoguelph.ca [131.104.91.44]) by mx1.freebsd.org (Postfix) with ESMTP id 31A7A8FC16 for ; Sun, 9 Jan 2011 00:59:00 +0000 (UTC) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApwEAJKQKE2DaFvO/2dsb2JhbACDd6E/rVWMTIJ3gWF0BIRnhiM X-IronPort-AV: E=Sophos;i="4.60,295,1291611600"; d="scan'208";a="106388397" Received: from erie.cs.uoguelph.ca (HELO zcs3.mail.uoguelph.ca) ([131.104.91.206]) by esa-jnhn-pri.mail.uoguelph.ca with ESMTP; 08 Jan 2011 19:29:57 -0500 Received: from zcs3.mail.uoguelph.ca (localhost.localdomain [127.0.0.1]) by zcs3.mail.uoguelph.ca (Postfix) with ESMTP id 7E113B3F82; Sat, 8 Jan 2011 19:29:57 -0500 (EST) Date: Sat, 8 Jan 2011 19:29:57 -0500 (EST) From: Rick Macklem To: Mark Saad Message-ID: <113335458.8956.1294532997422.JavaMail.root@erie.cs.uoguelph.ca> In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_8955_1251955688.1294532997410" X-Originating-IP: [172.17.91.201] X-Mailer: Zimbra 6.0.10_GA_2692 (ZimbraWebClient - IE8 (Win)/6.0.10_GA_2692) Cc: george+freebsd@mp5.com, freebsd-hackers@freebsd.org Subject: Re: NFS Performance X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 00:59:01 -0000 ------=_Part_8955_1251955688.1294532997410 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit > George > I remember reading there was some sort of nfs issues in 8.1-RELEASE, > a regression of some sort it was noted early on in the release. Have > you tried this with 8.2-RC1 also what are your nfs client mount > options ? > > On 1/8/11, george+freebsd@m5p.com wrote: > > Among four machines on my network, I'm observing startling > > differences > > in NFS performance. All machines are AMD64, and rpc_statd, > > rpc_lockd, > > and amd are enabled on all four machines. > > > > wonderland: > > hw.model: AMD Athlon(tm) II Dual-Core M32 > > hw.physmem: 293510758 > > ethernet: 100Mb/s > > partition 1: FreeBSD 8.1-STABLE > > partition 2: FreeBSD 7.3-STABLE > > > > scollay: > > hw.model: AMD Sempron(tm) 140 Processor > > hw.physmem: 186312294 > > ethernet: 1000Mb/s > > FreeBSD 8.1-PRERELEASE > > > > sullivan: > > hw.model: AMD Athlon(tm) 64 X2 Dual Core Processor 4800+ > > hw.physmem: 4279980032 > > ethernet 1000Mb/s > > FreeBSD 7.2-RELEASE > > > > mattapan: > > hw.model: AMD Sempron(tm) Processor 2600+ > > hw.physmem: 456380416 > > ethernet: 1000Mb/s > > FreeBSD 7.1-RELEASE > > > > Observed bytes per second (dd if=filename of=/dev/null bs=65536): > > Source machine: mattapan scollay sullivan > > Destination machine: > > wonderland/7.3 870K 5.2M 1.8M > > wonderland/8.1 496K 690K 420K > > mattapan 38M 28M > > scollay 33M 33M > > sullivan 38M 5M > > > > There is one 10/100/1000Mb/s ethernet switch between the various > > pairs > > of machines. > > > > I'm startled by the numbers for wonderland, first because of how > > much the > > 100Mb/s interface slows things down, but even more because of how > > much > > difference there is on the identical hardware between FreeBSD 7 and > > FreeBSD 8. > > > > Even more annoying when running 8.1 on wonderland, NFS simply locks > > up > > at random for roughly a minute and a half under high load (such as > > when > > firefox does a gazillion locked references to my places.sqlite > > file), > > leading to entertaining log message clusters such as: > > > > Dec 29 08:17:41 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:17:41 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:17:41 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:17:41 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:17:47 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:17:47 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:18:01 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:18:01 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:18:02 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:18:02 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:18:02 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:18:02 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:18:08 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:18:08 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:18:09 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:18:09 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:18:09 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:18:09 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:20:21 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:20:21 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:20:21 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:20:21 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:20:21 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:20:21 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:20:21 wonderland last message repeated 2 times > > Dec 29 08:20:22 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:20:22 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:20:36 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:20:36 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:21:05 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:21:10 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:22:20 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:22:20 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:22:20 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:22:20 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:22:20 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:22:20 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:22:22 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:22:22 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:22:24 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:22:24 wonderland last message repeated 2 times > > Dec 29 08:22:24 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:22:24 wonderland last message repeated 2 times > > Dec 29 08:22:24 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:22:24 wonderland kernel: nfs server home:/usr: is alive > > again > > Dec 29 08:22:27 wonderland kernel: nfs server home:/usr: not > > responding > > Dec 29 08:22:27 wonderland kernel: nfs server home:/usr: is alive > > again > > > > The time stamps on the "not responding" messages are lies; the lack > > of > > response in each case was roughly a minute and a half earlier. > > "home" > > equals mattapan in the earlier table. During the periods of NFS lack > > of response, mattapan is still completely functional, and a > > concurrent > > ssh session proceeds without difficulty. I can also make this happen > > (though not as easily) on NFS from sullivan to wonderland, but I > > haven't > > seen it yet from scollay to wonderland. This problem never occurs > > when > > wonderland is running 7.3. > > > > Any suggestions? -- George Mitchell > > > Please try the attached patch. (I don't read hackers, so I didn't see this until to-day.) (I do read stable, current and fs.) rick ps: This patch is not even it head yet. The bug it fixes is in the client side of the krpc, so it could affect the NFS client on any 8.x system. ------=_Part_8955_1251955688.1294532997410 Content-Type: text/x-patch; name=clntvc.patch Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename=clntvc.patch LS0tIHJwYy9jbG50X3ZjLmMuc2F2CTIwMTAtMTItMjkgMTk6MzY6MjAuMDAwMDAwMDAwIC0wNTAw CisrKyBycGMvY2xudF92Yy5jCTIwMTAtMTItMjkgMjA6MDM6MjQuMDAwMDAwMDAwIC0wNTAwCkBA IC05MTYsNiArOTE2LDExIEBACiAJCQkJbXR4X3VubG9jaygmY3QtPmN0X2xvY2spOwogCQkJCWJy ZWFrOwogCQkJfQorCQkJaWYgKG0tPm1fbGVuIDwgc2l6ZW9mKHVpbnQzMl90KSkgeworCQkJCW0g PSBtX3B1bGx1cChtLCBzaXplb2YodWludDMyX3QpKTsKKwkJCQlpZiAobSA9PSBOVUxMKQorCQkJ CQlicmVhazsKKwkJCX0KIAkJCWJjb3B5KG10b2QobSwgdWludDMyX3QgKiksICZoZWFkZXIsIHNp emVvZih1aW50MzJfdCkpOwogCQkJaGVhZGVyID0gbnRvaGwoaGVhZGVyKTsKIAkJCWN0LT5jdF9y ZWNvcmQgPSBOVUxMOwo= ------=_Part_8955_1251955688.1294532997410-- From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 01:42:05 2011 Return-Path: Delivered-To: freebsd-hackers@FreeBSD.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 7CE99106566B; Sun, 9 Jan 2011 01:42:05 +0000 (UTC) Date: Sun, 9 Jan 2011 01:42:05 +0000 From: Alexander Best To: Warner Losh Message-ID: <20110109014205.GA11132@freebsd.org> References: <20110106014046.GA324@freebsd.org> <20110106134531.GA81523@freebsd.org> <4D261299.6090003@bsdimp.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D261299.6090003@bsdimp.com> Cc: freebsd-hackers@FreeBSD.org Subject: Re: broken INCLUDE in sys/conf/kern.pre.mk for opensolaris code? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 01:42:05 -0000 On Thu Jan 6 11, Warner Losh wrote: > On 01/06/2011 06:45, Alexander Best wrote: > >On Thu Jan 6 11, Sergey Kandaurov wrote: > >>On 6 January 2011 04:40, Alexander Best wrote: > >>>hi there, > >>> > >>>while building target buildkernel with 'clang -v' i noticed a lot of > >>>these > >>>lines: > >>> > >>>ignoring nonexistent directory > >>>"/usr/subversion-src/sys/contrib/opensolaris/compat" > >>> > >>>i checked sys/conf/kern.pre.mk and there's a line refering to a > >>>non-existing > >>>directory: > >>> > >>># ... and OpenSolaris > >>>INCLUDES+= -I$S/contrib/opensolaris/compat > >>I guess that's leftover from early dtrace stages in perforce. > >>See //depot/projects/dtrace/src/sys/contrib/opensolaris/compat/sys > >ah i see. whom do i have to ping to get this fixed? i'm not sure if the > >include > >is even necessary, because obviosly a kernel will build without it. the > >only > >issue i had with cddl code is that when you compile and install world with > >WITHOUT_CDDL=true, you cannot rebuild world with cddl support. but i don't > >think that's something the include (even if it points to the correct > >directory) > >can fix. > > Maybe we should just remove it and be on our way. i think so too. i thought maybe with the path pointing to the correct directory one would be able to build world with CDDL support, if the installed world doesn't have CDDL support (WITHOUT_CDDL). but in both cases i got: make: don't know how to make /usr/lib/libctf.a. Stop ...so lets get rid of it. ;) cheers. alex > > Warner > > >cheers. > >alex > > > >>>is suspect this should actually be: > >>> > >>># ... and OpenSolaris > >>>INCLUDES+= -I$S/cddl/compat/opensolaris > >>> > >>>but i'm not sure of it. > >>> > >> > >>-- > >>wbr, > >>pluknet > -- a13x From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 03:58:34 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 63C03106564A for ; Sun, 9 Jan 2011 03:58:34 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from mail2.fluidhosting.com (mx22.fluidhosting.com [204.14.89.5]) by mx1.freebsd.org (Postfix) with ESMTP id EBEA48FC14 for ; Sun, 9 Jan 2011 03:58:33 +0000 (UTC) Received: (qmail 9852 invoked by uid 399); 9 Jan 2011 03:58:32 -0000 Received: from localhost (HELO doug-optiplex.ka9q.net) (dougb@dougbarton.us@127.0.0.1) by localhost with ESMTPAM; 9 Jan 2011 03:58:32 -0000 X-Originating-IP: 127.0.0.1 X-Sender: dougb@dougbarton.us Message-ID: <4D293266.8090906@FreeBSD.org> Date: Sat, 08 Jan 2011 19:58:30 -0800 From: Doug Barton Organization: http://SupersetSolutions.com/ User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.13) Gecko/20101210 Thunderbird/3.1.7 MIME-Version: 1.0 To: george+freebsd@m5p.com References: <201101081819.p08IJmhe001670@m5p.com> In-Reply-To: <201101081819.p08IJmhe001670@m5p.com> X-Enigmail-Version: 1.1.2 OpenPGP: id=1A1ABC84 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: NFS Performance X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 03:58:34 -0000 On 01/08/2011 10:19, george+freebsd@m5p.com wrote: > No, I did not report the problems then. -- George Well we're glad you're reporting them now. :) Doug -- Nothin' ever doesn't change, but nothin' changes much. -- OK Go Breadth of IT experience, and depth of knowledge in the DNS. Yours for the right price. :) http://SupersetSolutions.com/ From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 05:18:12 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DD4B2106566C for ; Sun, 9 Jan 2011 05:18:12 +0000 (UTC) (envelope-from nonesuch@longcount.org) Received: from mail-bw0-f54.google.com (mail-bw0-f54.google.com [209.85.214.54]) by mx1.freebsd.org (Postfix) with ESMTP id 78EFE8FC08 for ; Sun, 9 Jan 2011 05:18:11 +0000 (UTC) Received: by bwz12 with SMTP id 12so11028885bwz.13 for ; Sat, 08 Jan 2011 21:18:11 -0800 (PST) MIME-Version: 1.0 Received: by 10.204.81.72 with SMTP id w8mr13452217bkk.205.1294550290492; Sat, 08 Jan 2011 21:18:10 -0800 (PST) Received: by 10.204.151.212 with HTTP; Sat, 8 Jan 2011 21:18:10 -0800 (PST) X-Originating-IP: [68.171.231.19] In-Reply-To: <4D293266.8090906@FreeBSD.org> References: <201101081819.p08IJmhe001670@m5p.com> <4D293266.8090906@FreeBSD.org> Date: Sun, 9 Jan 2011 00:18:10 -0500 Message-ID: From: Mark Saad To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=UTF-8 Subject: Re: NFS Performance X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 05:18:12 -0000 Rick Do you have more details on the issue is it 8.x only ? Can you point us to the stable thread abourt this ? On 1/8/11, Doug Barton wrote: > On 01/08/2011 10:19, george+freebsd@m5p.com wrote: >> No, I did not report the problems then. -- George > > Well we're glad you're reporting them now. :) > > > Doug > > -- > > Nothin' ever doesn't change, but nothin' changes much. > -- OK Go > > Breadth of IT experience, and depth of knowledge in the DNS. > Yours for the right price. :) http://SupersetSolutions.com/ > > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > -- Sent from my mobile device mark saad | nonesuch@longcount.org From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 06:56:13 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2D8481065670; Sun, 9 Jan 2011 06:56:13 +0000 (UTC) (envelope-from tom@tomjudge.com) Received: from tomjudge.vm.bytemark.co.uk (tomjudge.vm.bytemark.co.uk [80.68.91.100]) by mx1.freebsd.org (Postfix) with ESMTP id C89A18FC0A; Sun, 9 Jan 2011 06:56:12 +0000 (UTC) Received: from localhost (localhost.localdomain [127.0.0.1]) by tomjudge.vm.bytemark.co.uk (Postfix) with ESMTP id 175F711C03B; Sun, 9 Jan 2011 06:39:38 +0000 (GMT) X-Virus-Scanned: Debian amavisd-new at tomjudge.vm.bytemark.co.uk Received: from tomjudge.vm.bytemark.co.uk ([127.0.0.1]) by localhost (tomjudge.vm.bytemark.co.uk [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id NCY3BR9tGCOV; Sun, 9 Jan 2011 06:39:35 +0000 (GMT) Received: from 192-168-200-57.lan.tj.home.tomjudge.com (unknown [192.168.200.57]) by tomjudge.vm.bytemark.co.uk (Postfix) with ESMTP id 9F24A11C03A; Sun, 9 Jan 2011 06:39:34 +0000 (GMT) Message-ID: <4D295820.20807@tomjudge.com> Date: Sun, 09 Jan 2011 00:39:28 -0600 From: Tom Judge User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 To: freebsd-hackers@freebsd.org, luigi@freebsd.org, imp@bsdimp.com X-Enigmail-Version: 1.1.1 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig51B4786EC9D39188BAE04052" Cc: Subject: sys/boot/boot0/boot0.S - r186598 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 06:56:13 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig51B4786EC9D39188BAE04052 Content-Type: multipart/mixed; boundary="------------070003060308030201090207" This is a multi-part message in MIME format. --------------070003060308030201090207 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi, Today I ran into an issue where setting the default slice with boot0cfg -s is broken. This is related to a section of this revision: + commit Warner's patch "orb $NOUPDATE,_FLAGS(%bp)" to avoid writing to disk in case of a timeout/default choice; This issue is quite well documented in bin/134907 which has been open since May 2009. Reproduced with a fresh nanobsd build: Boot 1 - Slice 1 active as set by nanobsd image builder: =3D=3D=3D # boot0cfg -v ad0 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF1 (Slice 1) =3D=3D=3D Update the active slice to 2: =3D=3D=3D # boot0cfg -s 2 -v ad0 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF2 (Slice 2) =3D=3D=3D Reboot and let boot0 time out and boot default slice 2: =3D=3D=3D # boot0cfg -v ad0 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF2 (Slice 2) =3D=3D=3D The system actually booted into slice 1 here. This was verified by dropping to the loader prompt and using show to grab= : loaddev=3Ddisk0s1a: Reboot and hit 2 at the boot0 prompt: =3D=3D=3D # boot0cfg -v ad0 # flag start chs type end chs offset size 1 0x00 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x80 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF2 (Slice 2) =3D=3D=3D This time we really boot into slice 2. The attached patch backs out the relevant part of r186598. There was a post on the embedded list that suggested this work around: echo 'a 2' | fdisk -f /dev/stdin ad0 boot0cfg -s 2 ad0 There are 2 issues with this: 1) It can't be done without setting kern.geom.debugflags to 0x10. 2) It resulted in most/all commands resulting in the error message "Device not configured" including the second command and 'shutdown -r now= '. Both of which leave this really work around fairly broken. Tom --------------070003060308030201090207 Content-Type: text/plain; name="boot0.s.txt" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="boot0.s.txt" Index: boot0.S =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 --- boot0.S (revision 213760) +++ boot0.S (working copy) @@ -373,7 +373,6 @@ * Timed out or default selection */ use_default: movb _OPT(%bp),%al # Load default - orb $NOUPDATE,_FLAGS(%bp) # Disable updates jmp check_selection # Join common code =20 /* --------------070003060308030201090207-- --------------enig51B4786EC9D39188BAE04052 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBAgAGBQJNKVglAAoJEMSwVS7lr0Odc1IIAJlq8MmwSzEWr6Q6DHUUYUQ8 r/WUFK73KUKTMeGR9SJQEAhG49GomzZqbVl5Tu6QNZFz6lzY6uksXLkG8BLw6AQ/ 0oovTCLCoQR/CSDEVcv6f+twR9t8/MZl/nlduHdsCpmQr9RZKvOISILNSwtxR/i0 3b69iwraiXABJFlazIeuNxW77gauvslvnqCgQqQBUsI/tjLFOteuQPnk9mlEkDiJ 1wdHQGVE/l5mntHQCstKHU1KVbeqQhsgDKsvhiiPDRbeESyTKpRfPIANUoPnzY3o n+dF45ql69QfOjKjxC5465B6nlpJBYDWxlbCsgWVczxur/6e/8420+KEORphrFQ= =+O2j -----END PGP SIGNATURE----- --------------enig51B4786EC9D39188BAE04052-- From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 11:20:16 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B784F106566B; Sun, 9 Jan 2011 11:20:16 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from kabab.cs.huji.ac.il (kabab.cs.huji.ac.il [132.65.16.84]) by mx1.freebsd.org (Postfix) with ESMTP id 704738FC1F; Sun, 9 Jan 2011 11:20:16 +0000 (UTC) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1PbsfL-0009ky-QP; Sun, 09 Jan 2011 12:38:27 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: Tom Judge In-reply-to: <4D295820.20807@tomjudge.com> References: <4D295820.20807@tomjudge.com> Comments: In-reply-to Tom Judge message dated "Sun, 09 Jan 2011 00:39:28 -0600." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sun, 09 Jan 2011 12:38:27 +0200 From: Daniel Braniss Message-ID: Cc: freebsd-hackers@freebsd.org, luigi@freebsd.org Subject: Re: sys/boot/boot0/boot0.S - r186598 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 11:20:16 -0000 > This is an OpenPGP/MIME signed message (RFC 2440 and 3156) > --------------enig51B4786EC9D39188BAE04052 > Content-Type: multipart/mixed; boundary="------------070003060308030201090207" > > This is a multi-part message in MIME format. > --------------070003060308030201090207 > Content-Type: text/plain; charset=ISO-8859-1 > Content-Transfer-Encoding: quoted-printable > > Hi, > > Today I ran into an issue where setting the default slice with boot0cfg > -s is broken. > > This is related to a section of this revision: > > + commit Warner's patch "orb $NOUPDATE,_FLAGS(%bp)" > to avoid writing to disk in case of a timeout/default choice; > > This issue is quite well documented in bin/134907 which has been open > since May 2009. > > Reproduced with a fresh nanobsd build: > > Boot 1 - Slice 1 active as set by nanobsd image builder: > > =3D=3D=3D > # boot0cfg -v ad0 > # flag start chs type end chs offset size > 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) > options=3Dpacket,update,nosetdrv > volume serial ID 9090-9090 > default_selection=3DF1 (Slice 1) > =3D=3D=3D > > Update the active slice to 2: > =3D=3D=3D > # boot0cfg -s 2 -v ad0 > # flag start chs type end chs offset size > 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) > options=3Dpacket,update,nosetdrv > volume serial ID 9090-9090 > default_selection=3DF2 (Slice 2) > =3D=3D=3D > > Reboot and let boot0 time out and boot default slice 2: > =3D=3D=3D > # boot0cfg -v ad0 > # flag start chs type end chs offset size > 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) > options=3Dpacket,update,nosetdrv > volume serial ID 9090-9090 > default_selection=3DF2 (Slice 2) > =3D=3D=3D > The system actually booted into slice 1 here. > This was verified by dropping to the loader prompt and using show to grab= > : > loaddev=3Ddisk0s1a: > > Reboot and hit 2 at the boot0 prompt: > =3D=3D=3D > # boot0cfg -v ad0 > # flag start chs type end chs offset size > 1 0x00 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x80 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) > options=3Dpacket,update,nosetdrv > volume serial ID 9090-9090 > default_selection=3DF2 (Slice 2) > =3D=3D=3D > > This time we really boot into slice 2. > > The attached patch backs out the relevant part of r186598. > > There was a post on the embedded list that suggested this work around: > echo 'a 2' | fdisk -f /dev/stdin ad0 > boot0cfg -s 2 ad0 > > There are 2 issues with this: > 1) It can't be done without setting kern.geom.debugflags to 0x10. > 2) It resulted in most/all commands resulting in the error message > "Device not configured" including the second command and 'shutdown -r now= > '. > > Both of which leave this really work around fairly broken. the problem is that boot0cfg -s does NOT update the boot block, it fails! the work around is: boot0cfg -s -t n dev then gpart set -a active -i n dev danny From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 13:31:40 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 06F2E106564A for ; Sun, 9 Jan 2011 13:31:40 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from esa-annu.mail.uoguelph.ca (esa-annu.mail.uoguelph.ca [131.104.91.36]) by mx1.freebsd.org (Postfix) with ESMTP id E9E4B8FC15 for ; Sun, 9 Jan 2011 13:31:38 +0000 (UTC) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApwEAGNHKU2DaFvO/2dsb2JhbACEA6E3rkKMQoEhgzd0BIRnhiM X-IronPort-AV: E=Sophos;i="4.60,296,1291611600"; d="scan'208";a="104731155" Received: from erie.cs.uoguelph.ca (HELO zcs3.mail.uoguelph.ca) ([131.104.91.206]) by esa-annu-pri.mail.uoguelph.ca with ESMTP; 09 Jan 2011 08:31:37 -0500 Received: from zcs3.mail.uoguelph.ca (localhost.localdomain [127.0.0.1]) by zcs3.mail.uoguelph.ca (Postfix) with ESMTP id E33D7B40BD; Sun, 9 Jan 2011 08:31:37 -0500 (EST) Date: Sun, 9 Jan 2011 08:31:37 -0500 (EST) From: Rick Macklem To: Mark Saad Message-ID: <954019999.13143.1294579897823.JavaMail.root@erie.cs.uoguelph.ca> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Originating-IP: [172.17.91.201] X-Mailer: Zimbra 6.0.10_GA_2692 (ZimbraWebClient - IE8 (Win)/6.0.10_GA_2692) Cc: freebsd-hackers@freebsd.org Subject: Re: NFS Performance X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 13:31:40 -0000 > Rick > Do you have more details on the issue is it 8.x only ? Can you point > us to the stable thread abourt this ? > The bug is in the krpc, which means it's 8.x specific (at least for NFS, I'm not sure if the nlm used the krpc in 7.x?). David P. Discher reported a performance problem some time ago when testing the FreeBSD8 client against certain servers. (I can't find the thread, so maybe it never had a freebsd-stable@ cc after all.) Fortutnately John Gemignani spotted the cause (for at least his case, because he tested a patch that seemed to resolve the problem). The bug is basically that the client side krpc for TCP assumed that the 4 bytes of data that hold the length of the RPC message are in one mbuf and don't straddle multiple mbufs. If the 4 bytes does straddle multiple mbufs, the krpc gets a "garbage message length" and then typically wedges and eventually recovers by starting a fresh TCP connection up and retrying the outstanding RPCs. I have no idea if George is seeing the same problem, but the 1.5minute logjams suggest that it might. I emailed him a patch and, hopefully, he will report back on whether or not it helped. A patch for the above bug is "in the works" for head, rick From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 17:15:10 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7413B1065673; Sun, 9 Jan 2011 17:15:10 +0000 (UTC) (envelope-from tom@tomjudge.com) Received: from tomjudge.vm.bytemark.co.uk (tomjudge.vm.bytemark.co.uk [80.68.91.100]) by mx1.freebsd.org (Postfix) with ESMTP id 2D2A38FC15; Sun, 9 Jan 2011 17:15:09 +0000 (UTC) Received: from localhost (localhost.localdomain [127.0.0.1]) by tomjudge.vm.bytemark.co.uk (Postfix) with ESMTP id 1DAD511C03B; Sun, 9 Jan 2011 17:15:09 +0000 (GMT) X-Virus-Scanned: Debian amavisd-new at tomjudge.vm.bytemark.co.uk Received: from tomjudge.vm.bytemark.co.uk ([127.0.0.1]) by localhost (tomjudge.vm.bytemark.co.uk [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id A-d4I75s0JMw; Sun, 9 Jan 2011 17:15:06 +0000 (GMT) Received: from 192-168-200-57.lan.tj.home.tomjudge.com (unknown [192.168.200.57]) by tomjudge.vm.bytemark.co.uk (Postfix) with ESMTP id D2E9611C03A; Sun, 9 Jan 2011 17:15:05 +0000 (GMT) Message-ID: <4D29ED16.7030401@tomjudge.com> Date: Sun, 09 Jan 2011 11:15:02 -0600 From: Tom Judge User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 To: Daniel Braniss References: <4D295820.20807@tomjudge.com> In-Reply-To: X-Enigmail-Version: 1.1.1 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig0AE178BF2380C8CAA3249E0C" Cc: freebsd-hackers@freebsd.org, luigi@freebsd.org Subject: Re: sys/boot/boot0/boot0.S - r186598 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 17:15:10 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig0AE178BF2380C8CAA3249E0C Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 09/01/2011 04:38, Daniel Braniss wrote: >> There was a post on the embedded list that suggested this work around:= >> echo 'a 2' | fdisk -f /dev/stdin ad0 >> boot0cfg -s 2 ad0 >> >> There are 2 issues with this: >> 1) It can't be done without setting kern.geom.debugflags to 0x10. >> 2) It resulted in most/all commands resulting in the error message >> "Device not configured" including the second command and 'shutdown -r = now=3D >> '. >> >> Both of which leave this really work around fairly broken. > the problem is that boot0cfg -s does NOT update the boot block, it fail= s! > the work around is: > boot0cfg -s -t n dev > then > gpart set -a active -i n dev > > danny > Hi Danny, The bug does not seem to be in boot0cfg as: 1) It succeeds to write the new configuration to the boot block every time i have tried. 2) It does not touch the partition table at all only the mbr, so it was never designed to change the active partition. If this is not a bug in boot0 then its a bug in the man pages for boot0cfg as it does make reference to having to change the active slice to make this work. Tom --------------enig0AE178BF2380C8CAA3249E0C Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBAgAGBQJNKe0ZAAoJEMSwVS7lr0OdtV0H/jYzpqLDbtz6GtNahPHZZURL XqE/JQDRJHbDpcVW407N1Y00Z9M6tnOZAh/F6pVVeSdmHTNE6Jd3bM8F699hIhby ib63Zg0MXHGYY4VuMJiVIEbFWr2C9OFHsldDdMQQ3/PXzjK0CIVXKnRy4KIxxtDi gPK0PBLSpe6jzJ6HAg8Wk6sXxYMnqUtTXGKugcxeh1Q9IhwvO9acrU241yK9NIoq kFPfuxQ5xU8T/FwcG+xaMj7DvBo2ymayiDgPXrSxU9TCbr5YIU/GO6KfwhEt/OGh inGxUWgy5WxVgvHSIqOF/v9OoiGwqTzXPAHRIQB+vkdZd93675VbCRHReL8YueY= =dsWc -----END PGP SIGNATURE----- --------------enig0AE178BF2380C8CAA3249E0C-- From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 18:35:56 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E6FF31065672 for ; Sun, 9 Jan 2011 18:35:55 +0000 (UTC) (envelope-from luigi@onelab2.iet.unipi.it) Received: from onelab2.iet.unipi.it (onelab2.iet.unipi.it [131.114.59.238]) by mx1.freebsd.org (Postfix) with ESMTP id 88C3C8FC08 for ; Sun, 9 Jan 2011 18:35:55 +0000 (UTC) Received: by onelab2.iet.unipi.it (Postfix, from userid 275) id 2137873098; Sun, 9 Jan 2011 19:33:16 +0100 (CET) Date: Sun, 9 Jan 2011 19:33:16 +0100 From: Luigi Rizzo To: Tom Judge Message-ID: <20110109183316.GA92631@onelab2.iet.unipi.it> References: <4D295820.20807@tomjudge.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D295820.20807@tomjudge.com> User-Agent: Mutt/1.4.2.3i Cc: freebsd-hackers@freebsd.org, luigi@freebsd.org Subject: Re: sys/boot/boot0/boot0.S - r186598 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 18:35:56 -0000 On Sun, Jan 09, 2011 at 12:39:28AM -0600, Tom Judge wrote: > Hi, > > Today I ran into an issue where setting the default slice with boot0cfg > -s is broken. a few questions inline: > This is related to a section of this revision: > > + commit Warner's patch "orb $NOUPDATE,_FLAGS(%bp)" > to avoid writing to disk in case of a timeout/default choice; > > This issue is quite well documented in bin/134907 which has been open > since May 2009. > > Reproduced with a fresh nanobsd build: > > Boot 1 - Slice 1 active as set by nanobsd image builder: > > === > # boot0cfg -v ad0 > # flag start chs type end chs offset size > 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=2.0 drive=0x80 mask=0x3 ticks=182 bell=# (0x23) > options=packet,update,nosetdrv > volume serial ID 9090-9090 > default_selection=F1 (Slice 1) > === > > Update the active slice to 2: > === > # boot0cfg -s 2 -v ad0 > # flag start chs type end chs offset size > 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=2.0 drive=0x80 mask=0x3 ticks=182 bell=# (0x23) > options=packet,update,nosetdrv > volume serial ID 9090-9090 > default_selection=F2 (Slice 2) > === what do you get here if you re-run boot0cfg -v ad0 before rebooting ? It seems that boot0cfg does not re-read data from disk so if the write for some reason fails (e.g. kern.geom.debugflags=0) you don't see the actual configuration of the boot sector. Looking at the code there should be an error message if writing to disk fails, but maybe the error reporting oes not work well... > Reboot and let boot0 time out and boot default slice 2: > === > # boot0cfg -v ad0 > # flag start chs type end chs offset size > 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=2.0 drive=0x80 mask=0x3 ticks=182 bell=# (0x23) > options=packet,update,nosetdrv > volume serial ID 9090-9090 > default_selection=F2 (Slice 2) > === > The system actually booted into slice 1 here. What does the system show as Default when it reboots ? F1 or F2 ? This is just to check if the update actually went to disk. > This was verified by dropping to the loader prompt and using show to grab: > loaddev=disk0s1a: > > Reboot and hit 2 at the boot0 prompt: > === > # boot0cfg -v ad0 > # flag start chs type end chs offset size > 1 0x00 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x80 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=2.0 drive=0x80 mask=0x3 ticks=182 bell=# (0x23) > options=packet,update,nosetdrv > volume serial ID 9090-9090 > default_selection=F2 (Slice 2) > === > > This time we really boot into slice 2. > > The attached patch backs out the relevant part of r186598. > > There was a post on the embedded list that suggested this work around: > echo 'a 2' | fdisk -f /dev/stdin ad0 > boot0cfg -s 2 ad0 > > There are 2 issues with this: > 1) It can't be done without setting kern.geom.debugflags to 0x10. > 2) It resulted in most/all commands resulting in the error message > "Device not configured" including the second command and 'shutdown -r now'. > > Both of which leave this really work around fairly broken. > > > Tom > cheers luigi From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 18:39:50 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 335AF1065698 for ; Sun, 9 Jan 2011 18:39:50 +0000 (UTC) (envelope-from george@m5p.com) Received: from mailhost.m5p.com (unknown [IPv6:2001:418:3fd::3]) by mx1.freebsd.org (Postfix) with ESMTP id CB2298FC17 for ; Sun, 9 Jan 2011 18:39:49 +0000 (UTC) Received: from m5p.com (wonderland.m5p.com [IPv6:2001:418:3fd::19]) by mailhost.m5p.com (8.14.3/8.14.3) with ESMTP id p09Idi1Q019722 for ; Sun, 9 Jan 2011 13:39:49 -0500 (EST) (envelope-from george@m5p.com) Received: (from george@localhost) by m5p.com (8.14.4/8.13.7/Submit) id p09IdiS2010092; Sun, 9 Jan 2011 13:39:44 -0500 (EST) Date: Sun, 9 Jan 2011 13:39:44 -0500 (EST) Message-Id: <201101091839.p09IdiS2010092@m5p.com> From: george+freebsd@m5p.com To: freebsd-hackers@freebsd.org In-Reply-To: <954019999.13143.1294579897823.JavaMail.root@erie.cs.uoguelph.ca> X-Spam-Score: -1.5 () BAYES_00 X-Scanned-By: MIMEDefang 2.67 on IPv6:2001:418:3fd::f7 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.0 (mailhost.m5p.com [IPv6:2001:418:3fd::f7]); Sun, 09 Jan 2011 13:39:49 -0500 (EST) Subject: Re: NFS performance X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 18:39:50 -0000 As requested earlier, I've moved the thread to freebsd-stable. -- George From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 18:57:34 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A2D87106567A; Sun, 9 Jan 2011 18:57:34 +0000 (UTC) (envelope-from tom@tomjudge.com) Received: from tomjudge.vm.bytemark.co.uk (tomjudge.vm.bytemark.co.uk [80.68.91.100]) by mx1.freebsd.org (Postfix) with ESMTP id 00A568FC19; Sun, 9 Jan 2011 18:57:33 +0000 (UTC) Received: from localhost (localhost.localdomain [127.0.0.1]) by tomjudge.vm.bytemark.co.uk (Postfix) with ESMTP id 01AA911C03B; Sun, 9 Jan 2011 18:57:33 +0000 (GMT) X-Virus-Scanned: Debian amavisd-new at tomjudge.vm.bytemark.co.uk Received: from tomjudge.vm.bytemark.co.uk ([127.0.0.1]) by localhost (tomjudge.vm.bytemark.co.uk [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id phWXFk7+tcLk; Sun, 9 Jan 2011 18:57:29 +0000 (GMT) Received: from 192-168-200-57.lan.tj.home.tomjudge.com (unknown [192.168.200.57]) by tomjudge.vm.bytemark.co.uk (Postfix) with ESMTP id 491A611C03A; Sun, 9 Jan 2011 18:57:28 +0000 (GMT) Message-ID: <4D2A0514.7040305@tomjudge.com> Date: Sun, 09 Jan 2011 12:57:24 -0600 From: Tom Judge User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 To: Luigi Rizzo References: <4D295820.20807@tomjudge.com> <20110109183316.GA92631@onelab2.iet.unipi.it> In-Reply-To: <20110109183316.GA92631@onelab2.iet.unipi.it> X-Enigmail-Version: 1.1.1 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigDBDA50257FABB3808645C194" Cc: freebsd-hackers@freebsd.org, luigi@freebsd.org Subject: Re: sys/boot/boot0/boot0.S - r186598 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 18:57:34 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigDBDA50257FABB3808645C194 Content-Type: multipart/mixed; boundary="------------010107000905080603030701" This is a multi-part message in MIME format. --------------010107000905080603030701 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 09/01/2011 12:33, Luigi Rizzo wrote: > On Sun, Jan 09, 2011 at 12:39:28AM -0600, Tom Judge wrote: >> Hi, >> >> Today I ran into an issue where setting the default slice with boot0cf= g >> -s is broken. > a few questions inline: > Output inline, full script log attached. If you need more info let me know. >> Update the active slice to 2: >> =3D=3D=3D >> # boot0cfg -s 2 -v ad0 >> # flag start chs type end chs offset size >> 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 >> 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 >> 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 >> >> version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) >> options=3Dpacket,update,nosetdrv >> volume serial ID 9090-9090 >> default_selection=3DF2 (Slice 2) >> =3D=3D=3D > what do you get here if you re-run > > boot0cfg -v ad0 > > before rebooting ? It seems that boot0cfg does not re-read > data from disk so if the write for some reason fails > (e.g. kern.geom.debugflags=3D0) you don't see the actual configuration > of the boot sector. > Looking at the code there should be an error message if writing > to disk fails, but maybe the error reporting oes not work well... > > Fresh transcript: # boot0cfg -v ad0 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF1 (Slice 1) # boot0cfg -s 2 -v ad0 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF2 (Slice 2) # boot0cfg -v ad0 =20 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF2 (Slice 2) # >> Reboot and let boot0 time out and boot default slice 2: >> =3D=3D=3D >> # boot0cfg -v ad0 >> # flag start chs type end chs offset size >> 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 >> 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 >> 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 >> >> version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) >> options=3Dpacket,update,nosetdrv >> volume serial ID 9090-9090 >> default_selection=3DF2 (Slice 2) >> =3D=3D=3D >> The system actually booted into slice 1 here. > What does the system show as Default when it reboots ? F1 or F2 ? > This is just to check if the update actually went to disk. > > # boot0cfg -v ad0 =20 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF2 (Slice 2) # shutdown -r now Shutdown NOW! shutdown: [pid 1104] # = =20 Rebooting... 1 FreeBSD 2 FreeBSD F6 PXE Boot: 2 -- Let time out, snip loader/beastie hit 6 at the menu -- OK show loaddev disk0s1a: OK --boot system and login -- # boot0cfg -v ad0 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF2 (Slice 2) # mount /dev/label/nanobsd1 on / (ufs, local, read-only) devfs on /dev (devfs, local, multilabel) /dev/md0 on /etc (ufs, local) /dev/md1 on /var (ufs, local) # glabel status |grep nanobsd label/nanobsd1 N/A ad0s1a label/nanobsd2 N/A ad0s2a # >> This was verified by dropping to the loader prompt and using show to g= rab: >> loaddev=3Ddisk0s1a: >> >> Reboot and hit 2 at the boot0 prompt: >> =3D=3D=3D >> # boot0cfg -v ad0 >> # flag start chs type end chs offset size >> 1 0x00 0: 1: 1 0xa5 494: 15:63 63 498897 >> 2 0x80 495: 1: 1 0xa5 989: 15:63 499023 498897 >> 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 >> >> version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) >> options=3Dpacket,update,nosetdrv >> volume serial ID 9090-9090 >> default_selection=3DF2 (Slice 2) >> =3D=3D=3D >> >> This time we really boot into slice 2. >> >> The attached patch backs out the relevant part of r186598. >> >> There was a post on the embedded list that suggested this work around:= >> echo 'a 2' | fdisk -f /dev/stdin ad0 >> boot0cfg -s 2 ad0 >> >> There are 2 issues with this: >> 1) It can't be done without setting kern.geom.debugflags to 0x10. >> 2) It resulted in most/all commands resulting in the error message >> "Device not configured" including the second command and 'shutdown -r = now'. >> >> Both of which leave this really work around fairly broken. >> >> Thanks Tom --------------010107000905080603030701 Content-Type: text/plain; name="log.txt" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="log.txt" Script started on Sun Jan 9 18:47:17 2011 =1B]0;tj@alix-builder: /usr/local/nanobsd=07=1B[34;1mroot=1B[0m=1B[33;1m@= =1B[0m=1B[32;1malix-builder=1B[0m =1B[31;1m'18:47:17'=1B[0m =1B[34;1m'/us= r/local/nanobsd'=1B[0m =1B[32;1m>=1B[0m # qemu -nographic -drive file=3D/usr/obj/nanobsd.DEV-QEM= U//_.disk.full type=3Draw -net nic,model=3De1000 -net tap,name=3Dtap0,scr= ipt=3Dno 1 FreeBSD 2 FreeBSD F6 PXE Boot: 1=20 /boot.config: -h |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/Con= soles: serial port =20 BIOS drive C: is disk0 BIOS 637kB/130036kB available memory FreeBSD/i386 bootstrap loader, Revision 1.1 (tj@alix-builder.home.tomjudge.com, Fri Jan 7 23:41:11 UTC 2011) |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-Loadin= g /boot/defaults/loader.conf=20 \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-/boot/kernel/kernel text=3D= 0x8c9a23 \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\d= ata=3D0xde2b4+0xa3fb0 |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\syms=3D[0x4+0x98450|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\+0x4+0xd0405|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\] |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/=1B[H=1B[J=1B[4= ;46H ______=1B[5;46H | ____| __ ___ ___ =1B[6;46H | |__ | '__= / _ \/ _ \=1B[7;46H | __|| | | __/ __/=1B[8;46H | | | | | |= |=1B[9;46H |_| |_| \___|\___|=1B[10;46H ____ _____ _____=1B= [11;46H | _ \ / ____| __ \=1B[12;46H | |_) | (___ | | | |=1B[13;= 46H | _ < \___ \| | | |=1B[14;46H | |_) |____) | |__| |=1B[15;46H= | | | |=1B[16;46H |____/|_____/|_____/=1B[3;2H=B3=1B= [4;2H=B3=1B[5;2H=B3=1B[6;2H=B3=1B[7;2H=B3=1B[8;2H=B3=1B[9;2H=B3=1B[10;2H=B3= =1B[11;2H=B3=1B[12;2H=B3=1B[13;2H=B3=1B[14;2H=B3=1B[15;2H=B3=1B[16;2H=B3=1B= [17;2H=B3=1B[18;2H=B3=1B[19;2H=B3=1B[20;2H=B3=1B[21;2H=B3=1B[3;44H=B3=1B[= 4;44H=B3=1B[5;44H=B3=1B[6;44H=B3=1B[7;44H=B3=1B[8;44H=B3=1B[9;44H=B3=1B[1= 0;44H=B3=1B[11;44H=B3=1B[12;44H=B3=1B[13;44H=B3=1B[14;44H=B3=1B[15;44H=B3= =1B[16;44H=B3=1B[17;44H=B3=1B[18;44H=B3=1B[19;44H=B3=1B[20;44H=B3=1B[21;4= 4H=B3=1B[2;3H=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4= =C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=1B[22;3H=C4= =C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4= =C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=1B[2;2H=DA=1B[22;2H=C0=1B[2= ;44H=BF=1B[22;44H=D9=1B[6;13HWelcome to FreeBSD!=1B[9;5H1 =1B[9;6H. Boot = FreeBSD [default]=1B[10;5H2 =1B[10;6H. Boot FreeBSD with ACPI disabled=1B= [11;5H3 =1B[11;6H. Boot FreeBSD in Safe Mode=1B[12;5H4 =1B[12;6H. Boot Fr= eeBSD in single user mode=1B[13;5H5 =1B[13;6H. Boot FreeBSD with verbose = logging=1B[14;5H6 =1B[14;6H. Escape to loader prompt=1B[15;5H7 =1B[15;6H.= Reboot=1B[20;5HSelect option, [Enter] for default=1B[21;5Hor [Space] to = pause timer =1B[21;32H10 =1B[21;32H10 =1B[21;32H9 =1B[21;32H9 =1B[21;3= 2H8 =1B[21;32H8 =1B[21;32H8 =1B[21;32H7 =1B[21;32H7 =1B[21;32H6 =1B[21;32= H6 =1B[21;32H5 =1B[21;32H5 =1B[21;32H4 =1B[21;32H4 =1B[21;32H3 =1B[21;32H= 3 =1B[21;32H2 =1B[21;32H2 =1B[21;32H1 =1B[21;32H1 =1B[21;32H0 =1B[21;32H0= =1B[25;0H-\|/-\|Copyright (c) 1992-2010 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD is a registered trademark of The FreeBSD Foundation. FreeBSD 8.1-RELEASE-p1 #0: Sat Jan 8 00:22:50 UTC 2011 tj@alix-builder.home.tomjudge.com:/usr/obj/nanobsd.DEV-QEMU/usr/src/s= ys/GENERIC i386 Timecounter "i8254" frequency 1193182 Hz quality 0 CPU: QEMU Virtual CPU version 0.13.0 (2499.09-MHz 686-class CPU) Origin =3D "GenuineIntel" Id =3D 0x633 Family =3D 6 Model =3D 3 Ste= pping =3D 3 Features=3D0x781abf9 Features2=3D0x80800001> real memory =3D 134217728 (128 MB) avail memory =3D 116576256 (111 MB) ACPI APIC Table: pnpbios: Bad PnP BIOS data checksum ioapic0: Changing APIC ID to 1 ioapic0 irqs 0-23 on motherboard kbd1 at kbdmux0 acpi0: on motherboard acpi0: [ITHREAD] acpi0: Power Button (fixed) Timecounter "ACPI-safe" frequency 3579545 Hz quality 850 acpi_timer0: <24-bit timer at 3.579545MHz> port 0xb008-0xb00b on acpi0 cpu0: on acpi0 acpi_hpet0: iomem 0xfed00000-0xfed003ff on a= cpi0 Timecounter "HPET" frequency 100000000 Hz quality 900 pcib0: port 0xcf8-0xcff on acpi0 pci0: on pcib0 isab0: at device 1.0 on pci0 isa0: on isab0 atapci0: port 0x1f0-0x1f7,0x3f6,0x170-0x17= 7,0x376,0xc000-0xc00f at device 1.1 on pci0 ata0: on atapci0 ata0: [ITHREAD] ata1: on atapci0 ata1: [ITHREAD] pci0: at device 1.3 (no driver attached) vgapci0: mem 0xf0000000-0xf1ffffff,0xf2000000-0x= f2000fff at device 2.0 on pci0 em0: port 0xc040-0xc0= 7f mem 0xf2020000-0xf203ffff irq 11 at device 3.0 on pci0 em0: Memory Access and/or Bus Master bits were not set! em0: [FILTER] em0: Ethernet address: 52:54:00:12:34:56 atrtc0: port 0x70-0x71,0x72-0x77 irq 8 on acpi0 atkbdc0: port 0x60,0x64 irq 1 on acpi0 atkbd0: irq 1 on atkbdc0 kbd0 at atkbd0 atkbd0: [GIANT-LOCKED] atkbd0: [ITHREAD] psm0: irq 12 on atkbdc0 psm0: [GIANT-LOCKED] psm0: [ITHREAD] psm0: model IntelliMouse Explorer, device ID 4 fdc0: port 0x3f2-0x3f5,0x3f7 irq 6 drq 2 on acp= i0 fdc0: does not respond device_attach: fdc0 attach returned 6 ppc0: port 0x378-0x37f irq 7 on acpi0 ppc0: Generic chipset (NIBBLE-only) in COMPATIBLE mode ppc0: [ITHREAD] ppbus0: on ppc0 plip0: on ppbus0 plip0: [ITHREAD] lpt0: on ppbus0 lpt0: [ITHREAD] lpt0: Interrupt-driven port ppi0: on ppbus0 uart0: <16550 or compatible> port 0x3f8-0x3ff irq 4 flags 0x10 on acpi0 uart0: [FILTER] uart0: console (9600,n,8,1) pmtimer0 on isa0 orm0: at iomem 0xc9000-0xc97ff pnpid ORM0000 on isa0 sc0: at flags 0x100 on isa0 sc0: VGA <16 virtual consoles, flags=3D0x100> vga0: at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0= Timecounter "TSC" frequency 2499094723 Hz quality 800 Timecounters tick every 10.000 msec em0: link state changed to UP ad0: 488MB at ata0-master WDMA2=20 acd0: CDROM at ata1-master WDMA2=20 Trying to mount root from ufs:/dev/label/nanobsd1 Setting hostuuid: 0283d1a9-1c21-11e0-9739-525400123456. Setting hostid: 0x4217687c. Entropy harvesting: interrupts ethernet point_to_point kickstart. Starting file system checks: /dev/label/nanobsd1: FILE SYSTEM CLEAN; SKIPPING CHECKS /dev/label/nanobsd1: clean, 219904 free (1536 frags, 27296 blocks, 0.3% f= ragmentation) /dev/label/cfg: FILE SYSTEM CLEAN; SKIPPING CHECKS /dev/label/cfg: clean, 2828 free (28 frags, 350 blocks, 1.0% fragmentatio= n) Mounting local file systems:. /etc/rc: WARNING: $hostname is not set -- see rc.conf(5). Starting Network: lo0. lo0: flags=3D8049 metric 0 mtu 16384 options=3D3 inet6 fe80::1 prefixlen 64 scopeid 0x3=20 inet6 ::1 prefixlen 128=20 inet 127.0.0.1 netmask 0xff000000=20 nd6 options=3D3 ip6addrctl: not found ip6addrctl: not found ip6addrctl: not found ip6addrctl: not found ip6addrctl: not found ip6addrctl: not found Starting devd. Generating host.conf. Creating and/or trimming log files. Starting syslogd. ELF ldconfig path: /lib /usr/lib a.out ldconfig path: /usr/lib/aout ldconfig: /usr/lib/aout: No such file or directory Clearing /tmp (X related). Updating motd:. Configuring syscons: blanktime. Starting cron. cron: tabs: No such file or directory cron: tabs: created Starting background file system checks in 60 seconds. Sun Jan 9 18:48:33 UTC 2011 FreeBSD/i386 (Amnesiac) (ttyu0) login: root Jan 9 18:48:57 login: ROOT LOGIN (root) ON ttyu0 Copyright (c) 1992-2010 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved.= FreeBSD 8.1-RELEASE-p1 (GENERIC) #0: Sat Jan 8 00:22:50 UTC 2011 Welcome to FreeBSD! Before seeking technical support, please use the following resources: o Security advisories and updated errata information for all releases ar= e at http://www.FreeBSD.org/releases/ - always consult the ERRATA sectio= n for your release first as it's updated frequently. o The Handbook and FAQ documents are at http://www.FreeBSD.org/ and, along with the mailing lists, can be searched by going to http://www.FreeBSD.org/search/. If the doc distribution has been installed, they're also available formatted in /usr/share/doc. If you still have a question or problem, please take the output of `uname -a', along with any relevant error messages, and email it as a question to the questions@FreeBSD.org mailing list. If you are unfamiliar with FreeBSD's directory layout, please refer to the hier(7) manual page. If you are not familiar with manual pages, type `man man'. You may also use sysinstall(8) to re-enter the installation and configuration utility. Edit /etc/motd to change this login announcement.= # boot0cfg -v ad0 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF1 (Slice 1) # boot0cfg -s 2 -v ad0 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF2 (Slice 2) # boot0cfg -s 2 -v ad0v ad0 =20 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF2 (Slice 2) # shutdown -r now Shutdown NOW! shutdown: [pid 1101] # = =20 =07*** FINAL System shutdown message from root@ ***=07 = =20 System going down IMMEDIATELY = =20 = =20 = =20 Jan 9 18:49:25 shutdown: reboot by root:=20 System shutdown time has arrived=07=07 Stopping cron. Stopping devd. Writing entropy file:. Terminated =2E Jan 9 18:49:38 syslogd: exiting on signal 15 Waiting (max 60 seconds) for system process `vnlru' to stop...done Waiting (max 60 seconds) for system process `bufdaemon' to stop...done Waiting (max 60 seconds) for system process `syncer' to stop... Syncing disks, vnodes remaining...0 0 0 0 0 0 done All buffers synced. Uptime: 1m47s Rebooting... 1 FreeBSD 2 FreeBSD F6 PXE Boot: 2=20 /boot.config: -h |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/Con= soles: serial port =20 BIOS drive C: is disk0 BIOS 637kB/130036kB available memory FreeBSD/i386 bootstrap loader, Revision 1.1 (tj@alix-builder.home.tomjudge.com, Fri Jan 7 23:41:11 UTC 2011) |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-Loadin= g /boot/defaults/loader.conf=20 \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-/boot/kernel/kernel text=3D= 0x8c9a23 \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\d= ata=3D0xde2b4+0xa3fb0 |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\syms=3D[0x4+0x98450|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\= |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\+0x4+0xd0405|/-\|/-\|= /-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/= -\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-= \|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\] |/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/=1B[H=1B[J=1B[4= ;46H ______=1B[5;46H | ____| __ ___ ___ =1B[6;46H | |__ | '__= / _ \/ _ \=1B[7;46H | __|| | | __/ __/=1B[8;46H | | | | | |= |=1B[9;46H |_| |_| \___|\___|=1B[10;46H ____ _____ _____=1B= [11;46H | _ \ / ____| __ \=1B[12;46H | |_) | (___ | | | |=1B[13;= 46H | _ < \___ \| | | |=1B[14;46H | |_) |____) | |__| |=1B[15;46H= | | | |=1B[16;46H |____/|_____/|_____/=1B[3;2H=B3=1B= [4;2H=B3=1B[5;2H=B3=1B[6;2H=B3=1B[7;2H=B3=1B[8;2H=B3=1B[9;2H=B3=1B[10;2H=B3= =1B[11;2H=B3=1B[12;2H=B3=1B[13;2H=B3=1B[14;2H=B3=1B[15;2H=B3=1B[16;2H=B3=1B= [17;2H=B3=1B[18;2H=B3=1B[19;2H=B3=1B[20;2H=B3=1B[21;2H=B3=1B[3;44H=B3=1B[= 4;44H=B3=1B[5;44H=B3=1B[6;44H=B3=1B[7;44H=B3=1B[8;44H=B3=1B[9;44H=B3=1B[1= 0;44H=B3=1B[11;44H=B3=1B[12;44H=B3=1B[13;44H=B3=1B[14;44H=B3=1B[15;44H=B3= =1B[16;44H=B3=1B[17;44H=B3=1B[18;44H=B3=1B[19;44H=B3=1B[20;44H=B3=1B[21;4= 4H=B3=1B[2;3H=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4= =C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=1B[22;3H=C4= =C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4= =C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=C4=1B[2;2H=DA=1B[22;2H=C0=1B[2= ;44H=BF=1B[22;44H=D9=1B[6;13HWelcome to FreeBSD!=1B[9;5H1 =1B[9;6H. Boot = FreeBSD [default]=1B[10;5H2 =1B[10;6H. Boot FreeBSD with ACPI disabled=1B= [11;5H3 =1B[11;6H. Boot FreeBSD in Safe Mode=1B[12;5H4 =1B[12;6H. Boot Fr= eeBSD in single user mode=1B[13;5H5 =1B[13;6H. Boot FreeBSD with verbose = logging=1B[14;5H6 =1B[14;6H. Escape to loader prompt=1B[15;5H7 =1B[15;6H.= Reboot=1B[20;5HSelect option, [Enter] for default=1B[21;5Hor [Space] to = pause timer =1B[21;32H10 =1B[21;32H9 =1B[21;32H9 =1B[25;0H Type '?' for a list of commands, 'help' for more detailed help. OK show loaddev disk0s1a: OK boot -\|/-\|Copyright (c) 1992-2010 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD is a registered trademark of The FreeBSD Foundation. FreeBSD 8.1-RELEASE-p1 #0: Sat Jan 8 00:22:50 UTC 2011 tj@alix-builder.home.tomjudge.com:/usr/obj/nanobsd.DEV-QEMU/usr/src/s= ys/GENERIC i386 Timecounter "i8254" frequency 1193182 Hz quality 0 CPU: QEMU Virtual CPU version 0.13.0 (2582.62-MHz 686-class CPU) Origin =3D "GenuineIntel" Id =3D 0x633 Family =3D 6 Model =3D 3 Ste= pping =3D 3 Features=3D0x781abf9 Features2=3D0x80800001> real memory =3D 134217728 (128 MB) avail memory =3D 116576256 (111 MB) ACPI APIC Table: pnpbios: Bad PnP BIOS data checksum ioapic0: Changing APIC ID to 1 ioapic0 irqs 0-23 on motherboard kbd1 at kbdmux0 acpi0: on motherboard acpi0: [ITHREAD] acpi0: Power Button (fixed) Timecounter "ACPI-safe" frequency 3579545 Hz quality 850 acpi_timer0: <24-bit timer at 3.579545MHz> port 0xb008-0xb00b on acpi0 cpu0: on acpi0 acpi_hpet0: iomem 0xfed00000-0xfed003ff on a= cpi0 Timecounter "HPET" frequency 100000000 Hz quality 900 pcib0: port 0xcf8-0xcff on acpi0 pci0: on pcib0 isab0: at device 1.0 on pci0 isa0: on isab0 atapci0: port 0x1f0-0x1f7,0x3f6,0x170-0x17= 7,0x376,0xc000-0xc00f at device 1.1 on pci0 ata0: on atapci0 ata0: [ITHREAD] ata1: on atapci0 ata1: [ITHREAD] pci0: at device 1.3 (no driver attached) vgapci0: mem 0xf0000000-0xf1ffffff,0xf2000000-0x= f2000fff at device 2.0 on pci0 em0: port 0xc040-0xc0= 7f mem 0xf2020000-0xf203ffff irq 11 at device 3.0 on pci0 em0: Memory Access and/or Bus Master bits were not set! em0: [FILTER] em0: Ethernet address: 52:54:00:12:34:56 atrtc0: port 0x70-0x71,0x72-0x77 irq 8 on acpi0 atkbdc0: port 0x60,0x64 irq 1 on acpi0 atkbd0: irq 1 on atkbdc0 kbd0 at atkbd0 atkbd0: [GIANT-LOCKED] atkbd0: [ITHREAD] psm0: irq 12 on atkbdc0 psm0: [GIANT-LOCKED] psm0: [ITHREAD] psm0: model IntelliMouse Explorer, device ID 4 fdc0: port 0x3f2-0x3f5,0x3f7 irq 6 drq 2 on acp= i0 fdc0: does not respond device_attach: fdc0 attach returned 6 ppc0: port 0x378-0x37f irq 7 on acpi0 ppc0: Generic chipset (NIBBLE-only) in COMPATIBLE mode ppc0: [ITHREAD] ppbus0: on ppc0 plip0: on ppbus0 plip0: [ITHREAD] lpt0: on ppbus0 lpt0: [ITHREAD] lpt0: Interrupt-driven port ppi0: on ppbus0 uart0: <16550 or compatible> port 0x3f8-0x3ff irq 4 flags 0x10 on acpi0 uart0: [FILTER] uart0: console (9600,n,8,1) pmtimer0 on isa0 orm0: at iomem 0xc9000-0xc97ff pnpid ORM0000 on isa0 sc0: at flags 0x100 on isa0 sc0: VGA <16 virtual consoles, flags=3D0x100> vga0: at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0= Timecounter "TSC" frequency 2582620532 Hz quality 800 Timecounters tick every 10.000 msec em0: link state changed to UP ad0: 488MB at ata0-master WDMA2=20 acd0: CDROM at ata1-master WDMA2=20 Trying to mount root from ufs:/dev/label/nanobsd1 Setting hostuuid: 5a160696-1c21-11e0-a892-525400123456. Setting hostid: 0xacb1cc36. Entropy harvesting: interrupts ethernet point_to_point kickstart. Starting file system checks: /dev/label/nanobsd1: FILE SYSTEM CLEAN; SKIPPING CHECKS /dev/label/nanobsd1: clean, 219904 free (1536 frags, 27296 blocks, 0.3% f= ragmentation) /dev/label/cfg: FILE SYSTEM CLEAN; SKIPPING CHECKS /dev/label/cfg: clean, 2828 free (28 frags, 350 blocks, 1.0% fragmentatio= n) Mounting local file systems:. /etc/rc: WARNING: $hostname is not set -- see rc.conf(5). Starting Network: lo0. lo0: flags=3D8049 metric 0 mtu 16384 options=3D3 inet6 fe80::1 prefixlen 64 scopeid 0x3=20 inet6 ::1 prefixlen 128=20 inet 127.0.0.1 netmask 0xff000000=20 nd6 options=3D3 ip6addrctl: not found ip6addrctl: not found ip6addrctl: not found ip6addrctl: not found ip6addrctl: not found ip6addrctl: not found Starting devd. Generating host.conf. Creating and/or trimming log files. Starting syslogd. ELF ldconfig path: /lib /usr/lib a.out ldconfig path: /usr/lib/aout ldconfig: /usr/lib/aout: No such file or directory Clearing /tmp (X related). Updating motd:. Configuring syscons: blanktime. Starting cron. cron: tabs: No such file or directory cron: tabs: created Starting background file system checks in 60 seconds. Sun Jan 9 18:51:00 UTC 2011 FreeBSD/i386 (Amnesiac) (ttyu0) login: root Jan 9 18:51:04 login: ROOT LOGIN (root) ON ttyu0 Copyright (c) 1992-2010 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved.= FreeBSD 8.1-RELEASE-p1 (GENERIC) #0: Sat Jan 8 00:22:50 UTC 2011 Welcome to FreeBSD! Before seeking technical support, please use the following resources: o Security advisories and updated errata information for all releases ar= e at http://www.FreeBSD.org/releases/ - always consult the ERRATA sectio= n for your release first as it's updated frequently. o The Handbook and FAQ documents are at http://www.FreeBSD.org/ and, along with the mailing lists, can be searched by going to http://www.FreeBSD.org/search/. If the doc distribution has been installed, they're also available formatted in /usr/share/doc. If you still have a question or problem, please take the output of `uname -a', along with any relevant error messages, and email it as a question to the questions@FreeBSD.org mailing list. If you are unfamiliar with FreeBSD's directory layout, please refer to the hier(7) manual page. If you are not familiar with manual pages, type `man man'. You may also use sysinstall(8) to re-enter the installation and configuration utility. Edit /etc/motd to change this login announcement.= # boot0 cfg -a v am d0 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 version=3D2.0 drive=3D0x80 mask=3D0x3 ticks=3D182 bell=3D# (0x23) options=3Dpacket,update,nosetdrv volume serial ID 9090-9090 default_selection=3DF2 (Slice 2) # mount /dev/label/nanobsd1 on / (ufs, local, read-only) devfs on /dev (devfs, local, multilabel) /dev/md0 on /etc (ufs, local) /dev/md1 on /var (ufs, local) # glabel status Name Status Components label/cfg N/A ad0s3 label/nanobsd1 N/A ad0s1a label/nanobsd2 N/A ad0s2a # shutdown -p now Shutdown NOW! shutdown: [pid 1101] # = =20 =07*** FINAL System shutdown message from root@ ***=07 = =20 System going down IMMEDIATELY = =20 = =20 = =20 Jan 9 18:52:08 shutdown: power-down by root:=20 System shutdown time has arrived=07=07 Stopping cron. Stopping devd. Writing entropy file:. Terminated =2E Jan 9 18:52:21 syslogd: exiting on signal 15 Waiting (max 60 seconds) for system process `vnlru' to stop...done Waiting (max 60 seconds) for system process `bufdaemon' to stop...done Waiting (max 60 seconds) for system process `syncer' to stop... Syncing disks, vnodes remaining...0 0 0 0 0 0 done All buffers synced. Uptime: 2m1s acpi0: Powering system off =1B]0;tj@alix-builder: /usr/local/nanobsd=07=1B[34;1mroot=1B[0m=1B[33;1m@= =1B[0m=1B[32;1malix-builder=1B[0m =1B[31;1m'18:52:44'=1B[0m =1B[34;1m'/us= r/local/nanobsd'=1B[0m =1B[32;1m>=1B[0m # =1B[Kexit Script done on Sun Jan 9 18:52:46 2011 --------------010107000905080603030701-- --------------enigDBDA50257FABB3808645C194 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBAgAGBQJNKgUXAAoJEMSwVS7lr0OdMdAH/jxxFKGI804j9rL/YLj8Kq8N ty/zzshpE7F7Z2Ic5MeoEL4su/hQ+e4zx03ms2x0DIFm2tjsmXig9Y4O7AZuqndU AYrQ8GKkWFnxesIKZ6Z9r3zJeLwgaN3JA2THeBS6GKYkj3x2BhGLt/tvHh1QQtrg 46u0GTIqyNxsW6jH+LIB18BkryHmKhuF6x8DAmiXy4sA++fkbsj+AUrs+12nTHbM qSOaQoSZMKtgviDX1/RBA3QFw26c5hxpb3iLSkXlEcwKx5iy2U16M3t7jZYOfBOL GVRF1FZD8JGUiH6/3eEKfg+9GMoQCdHOq+dLR4k+5UALOtuAhLzVt6Mi4MDW4mo= =ff9K -----END PGP SIGNATURE----- --------------enigDBDA50257FABB3808645C194-- From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 22:29:40 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2DFFA106564A; Sun, 9 Jan 2011 22:29:40 +0000 (UTC) (envelope-from luigi@onelab2.iet.unipi.it) Received: from onelab2.iet.unipi.it (onelab2.iet.unipi.it [131.114.59.238]) by mx1.freebsd.org (Postfix) with ESMTP id E97FC8FC18; Sun, 9 Jan 2011 22:29:39 +0000 (UTC) Received: by onelab2.iet.unipi.it (Postfix, from userid 275) id ABA0073098; Sun, 9 Jan 2011 23:44:01 +0100 (CET) Date: Sun, 9 Jan 2011 23:44:01 +0100 From: Luigi Rizzo To: Tom Judge Message-ID: <20110109224401.GA95358@onelab2.iet.unipi.it> References: <4D295820.20807@tomjudge.com> <20110109183316.GA92631@onelab2.iet.unipi.it> <4D2A0514.7040305@tomjudge.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D2A0514.7040305@tomjudge.com> User-Agent: Mutt/1.4.2.3i Cc: freebsd-hackers@freebsd.org, luigi@freebsd.org Subject: Re: sys/boot/boot0/boot0.S - r186598 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 22:29:40 -0000 On Sun, Jan 09, 2011 at 12:57:24PM -0600, Tom Judge wrote: > On 09/01/2011 12:33, Luigi Rizzo wrote: > > On Sun, Jan 09, 2011 at 12:39:28AM -0600, Tom Judge wrote: > >> Hi, > >> > >> Today I ran into an issue where setting the default slice with boot0cfg > >> -s is broken. > > a few questions inline: > > > Output inline, full script log attached. > > If you need more info let me know. can you take a dump of the boot sector at various stages indicated below: > DUMP #1: ORIGINAL BOOT SECTOR DUMP #2: AFTER THE BOOT SECTOR UPDATE DUMP #3: AFTER A REBOOT WITH NO KEYPRESS DUMP #4: AFTER THE SUCCESSFUL BOOT IN SLICE 2 At least from this we can tell how #4 differs from #2/#3 cheers luigi From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 22:58:11 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F22E3106566C for ; Sun, 9 Jan 2011 22:58:11 +0000 (UTC) (envelope-from joris.dedieu@gmail.com) Received: from mail-fx0-f54.google.com (mail-fx0-f54.google.com [209.85.161.54]) by mx1.freebsd.org (Postfix) with ESMTP id 831568FC18 for ; Sun, 9 Jan 2011 22:58:11 +0000 (UTC) Received: by fxm16 with SMTP id 16so18376886fxm.13 for ; Sun, 09 Jan 2011 14:58:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=LecgpzlWkwbNILo9+YzNQ6AGOt3R0fbjLLFMR3+P7fg=; b=qV1QC6bQ/YjALC8qeI71tia3hgHtrTfxCsZx8mhgQYzJ+aDVdATAN2m9W/C55XQ4hZ c2YEhwOR9goXuN7cin1kfPTEiP3+LktwKauX5qeF9tIlrZF/rza+itTeoD9lZ/XNfpfO mXx7BtVJq8zPt9wddLeS80MOLndFx3asqwnaE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=Qa/2YuNttfG0h2yi/cgW70UkPEsfobVa73hUedS1jjVsmGxHXRMl0Nd+F3aVw9jkRj xfsBkVPlshSsQ7PCkkMpCK+ht6AJGywh8+Q8S3kr5bZzrRPQ4YhbSrOCxyhm70F+n2f6 AGTQxS1vVMsskWXG2cnfu5XHEKvYdIcEfDN20= MIME-Version: 1.0 Received: by 10.223.100.5 with SMTP id w5mr11917658fan.20.1294613888430; Sun, 09 Jan 2011 14:58:08 -0800 (PST) Received: by 10.223.86.207 with HTTP; Sun, 9 Jan 2011 14:58:08 -0800 (PST) In-Reply-To: References: Date: Sun, 9 Jan 2011 23:58:08 +0100 Message-ID: From: joris dedieu To: freebsd-hackers Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: binding non local ip. X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 22:58:12 -0000 2011/1/9 Eygene Ryabinkin : Sorry for my mail client broken that do not send mails to the list :) I'll take care. > Joris, good day. > > Sun, Jan 09, 2011 at 06:29:20PM +0100, joris dedieu wrote: >> Thanks Eygene for this greate review ! > > No problems ;)) > >> 2011/1/7 Eygene Ryabinkin : >> > Fri, Jan 07, 2011 at 01:57:21PM +0100, joris dedieu wrote: >> >> What do you think about it ? >> > [...] >> >> +static int =A0 =A0 bindany =3D 0; /* 1 allows to bind a non local ip= */ >> >> +SYSCTL_INT(_net_inet_ip, OID_AUTO, bindany, CTLFLAG_RW, &bindany, 0, >> >> + =A0 =A0"Allow to bind a non local ip"); >> > >> > On at least 8.x, you will likely want to use VNET_* macros to enable >> > your new sysctl to be virtualized. =A0Something like this: >> > {{{ >> > VNET_DEFINE(int, inp_bindany) =3D 0; >> > SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, bindany, CTLFLAG_RW, >> > =A0 =A0 =A0 =A0&VNET_NAME(inp_bindany), 0, "Force INP_BINDANY on all s= ockets"); >> > }}} >> > and use VNET(inp_bindany) in subsequent code. >> Ok it make sense. I will use VNET_*. There are a lot of SYSCTL_* in >> netinet and netinet6. Is changing this for VNET_* an open task? > > I think that the most of them that are applicable to VNET were > already converted. =A0It is better to ask at freebsd-net@freebsd.org. > >> Greate. It makes me understand the way a lot of things are written. >> Avoid branching if you can. >> I see that OPSET macro in netinet/ip_output.c lock the inp struct. Is >> there a need of it there ? > > Yes. =A0I had overlooked the need of locking here, sorry. I wrote a better patch that avoid locking and inp struct modification. diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c index d742887..f41e4da 100644 --- a/sys/netinet/in_pcb.c +++ b/sys/netinet/in_pcb.c @@ -321,6 +321,9 @@ in_pcbbind(struct inpcb *inp, struct sockaddr *nam, struct ucred *cred) * * On error, the values of *laddrp and *lportp are not changed. */ +VNET_DEFINE(int, inp_bindany) =3D 0; +SYSCTL_VNET_INT(_net_inet_ip, OID_AUTO, bindany, CTLFLAG_RW, + &VNET_NAME(inp_bindany), 0, "Force INP_BINDANY on all sockets"); int in_pcbbind_setup(struct inpcb *inp, struct sockaddr *nam, in_addr_t *laddr= p, u_short *lportp, struct ucred *cred) @@ -392,7 +395,8 @@ in_pcbbind_setup(struct inpcb *inp, struct sockaddr *nam, in_addr_t *laddrp, * If INP_BINDANY is set, then the socket may be bo= und * to any endpoint address, local or not. */ - if ((inp->inp_flags & INP_BINDANY) =3D=3D 0 && + if (VNET(inp_bindany) =3D=3D 0 && + (inp->inp_flags & INP_BINDANY) =3D=3D 0 && ifa_ifwithaddr_check((struct sockaddr *)sin) = =3D=3D 0) return (EADDRNOTAVAIL); } diff --git a/sys/netinet/in_pcb.h b/sys/netinet/in_pcb.h index 4ba19e6..3720121 100644 --- a/sys/netinet/in_pcb.h +++ b/sys/netinet/in_pcb.h @@ -467,6 +467,7 @@ VNET_DECLARE(int, ipport_randomcps); VNET_DECLARE(int, ipport_randomtime); VNET_DECLARE(int, ipport_stoprandom); VNET_DECLARE(int, ipport_tcpallocs); +VNET_DECLARE(int, inp_bindany); #define V_ipport_reservedhigh VNET(ipport_reservedhigh) #define V_ipport_reservedlow VNET(ipport_reservedlow) diff --git a/sys/netinet/raw_ip.c b/sys/netinet/raw_ip.c index c91d4a9..17a2e78 100644 --- a/sys/netinet/raw_ip.c +++ b/sys/netinet/raw_ip.c @@ -897,6 +897,7 @@ rip_bind(struct socket *so, struct sockaddr *nam, struct thread *td) if (TAILQ_EMPTY(&V_ifnet) || (addr->sin_family !=3D AF_INET && addr->sin_family !=3D AF_IMPL= INK) || (addr->sin_addr.s_addr && + VNET(inp_bindany) =3D=3D 0 && (inp->inp_flags & INP_BINDANY) =3D=3D 0 && ifa_ifwithaddr_check((struct sockaddr *)addr) =3D=3D 0)) return (EADDRNOTAVAIL); > >> Do you mean there is a way to control user input (ie 0 or 42, but >> nothing else)? > > No, I meant that if you'll use the custom sysctl value handler (via > SYSCTL_VNET_PROC, not vie SYSCTL_VNET_INT), then you can convert any > non-zero value to INP_BINDANY and zero to zero. =A0But given the need of > locking, I don't think that this won't be good to take this road: one > simple non-conditional logical instruction will be harmless even if it > is executed when it is not needed; but the block of > lock-logicalop-unlock will be worse. > -- > Eygene Ryabinkin =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0,,,^..^,,, > [ Life's unfair - but root password helps! =A0 =A0 =A0 =A0 =A0 | codelabs= .ru ] > [ 82FE 06BC D497 C0DE 49EC =A04FF0 16AF 9EAE 8152 ECFB | freebsd.org ] > From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 9 23:01:27 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 476121065672 for ; Sun, 9 Jan 2011 23:01:27 +0000 (UTC) (envelope-from joris.dedieu@gmail.com) Received: from mail-fx0-f54.google.com (mail-fx0-f54.google.com [209.85.161.54]) by mx1.freebsd.org (Postfix) with ESMTP id C23378FC15 for ; Sun, 9 Jan 2011 23:01:26 +0000 (UTC) Received: by fxm16 with SMTP id 16so18378378fxm.13 for ; Sun, 09 Jan 2011 15:01:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=yZjGRSnbVF9FvW+t9Cy12nIeXzL0AkLR9ue9XebEgy0=; b=WbbaLOP0ZY9UI1P+T4X6v3H/s+hU0KiSI7WOxqGehMGOzuLEXYYwHzelM492nfC96d o82SE+NIl0jvClIENqp0uy+nOjFr4XLYRgrVUAcnwvy4kUQwR6OfxJFdRZfNb01qY9v2 /2+W1CCVdvqL0geZ7lw8bdaQ1VNxK54GAclwk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=bGtw2yZZRp/EzRZ9HOremT8FeCQQS2pf9x+Vtw+x6d8xarwMYYnIGn73ZWsSnFJKeu vzkM0Fi66KFRBko9vE0j+bcQy6oEDv3XbFENo0vFeK2r2Yb7rv4jzkkG5SEeAslT2jAE Uks24bHpn1f0uKNPveSKJvBvEeghtxtIkAsmw= MIME-Version: 1.0 Received: by 10.223.96.195 with SMTP id i3mr2447397fan.77.1294614084603; Sun, 09 Jan 2011 15:01:24 -0800 (PST) Received: by 10.223.86.207 with HTTP; Sun, 9 Jan 2011 15:01:24 -0800 (PST) In-Reply-To: References: <4D274C5E.500@freebsd.org> Date: Mon, 10 Jan 2011 00:01:24 +0100 Message-ID: From: joris dedieu To: freebsd-hackers Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Fwd: binding non local ip. X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Jan 2011 23:01:27 -0000 ---------- Forwarded message ---------- From: joris dedieu Date: 2011/1/9 Subject: Re: binding non local ip. To: Julian Elischer 2011/1/7 Julian Elischer : > On 1/7/11 4:57 AM, joris dedieu wrote: >> >> Hi, >> I need a to bind non local ips =A0daemons that don't >> implement IP_BINDANY sockopt. > > I'm not sure you need it > you can use the ipfw 'fwd' command to make a locally bound > socket act and look as if it is bound to a non local address > > You need to tell us a little more about what you need to do > > for example, > Is the socket just listenning? or is it initiating? listenning I think. Typicaly prepare a spare server. eg: - Failover as with carp but with more complexes actions has shutting down the power of the main server, check data consistency, check if the problem is not just a reboot or a buggy service that =A0need to be restarted. - Switch an ip from a main server to a already configured proxy (during a d= os) - monitor that spare service is running. > >> There are several solutions as patching every single daemon >> or using carp (You may not want automatic failover), jailing >> the process and of course binding INADDR_ANY when possible ... >> >> As I'm too lazy for this, I wrote a little (maybe ugly as my >> kernel knowledges are really low) patch that add a sysctl >> entry in net.inet.ip that allow binding non local ips. It's >> maybe buggy and insecure but it seems to work. > > seems ok, but if the daemon is initiating, how does it know to bind to a = non > local address? It doesn't know. That's the goal. So when the address became local it's already ready. So you don't discover that it's misconfigured or broken, or that else your dummy colleague has imagined :) . You or a script ifconfig the alias and back to bed ! > also. if you have source, a single setsockopt() in each one is not much o= f a > job.. I already do this for haproxy and for apr. But (for haproxy) it seems to be too specific to be integrated upstreams. For other services (as tomcat) that don't know privileges dropping it's more problematic as IP_BINDANY needs in most case root privileges. I think that a system wide solution should be a good thing. Joris > > >> What do you think about it ? >> >> Thanks >> Joris >> >> --- a/sys/netinet/in_pcb.c >> +++ b/sys/netinet/in_pcb.c >> @@ -321,6 +321,9 @@ in_pcbbind(struct inpcb *inp, struct sockaddr >> *nam, struct ucred *cred) >> =A0 * >> =A0 * On error, the values of *laddrp and *lportp are not changed. >> =A0 */ >> +static int =A0 =A0 bindany =3D 0; /* 1 allows to bind a non local ip */ >> +SYSCTL_INT(_net_inet_ip, OID_AUTO, bindany, CTLFLAG_RW,&bindany, 0, >> + =A0 =A0"Allow to bind a non local ip"); >> =A0int >> =A0in_pcbbind_setup(struct inpcb *inp, struct sockaddr *nam, in_addr_t >> *laddrp, >> =A0 =A0 =A0u_short *lportp, struct ucred *cred) >> @@ -393,8 +396,12 @@ in_pcbbind_setup(struct inpcb *inp, struct >> sockaddr *nam, in_addr_t *laddrp, >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0* to any endpoint add= ress, local or not. >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0*/ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 if ((inp->inp_flags& =A0= INP_BINDANY) =3D=3D 0&& >> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 ifa_ifwithaddr_che= ck((struct sockaddr *)sin) >> =3D=3D 0) >> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 return (EA= DDRNOTAVAIL); >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 ifa_ifwithaddr_che= ck((struct sockaddr *)sin) >> =3D=3D 0) { >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 if(bindany= > =A00) >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 inp->inp_flags |=3D INP_BINDANY; >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 else >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 return (EADDRNOTAVAIL); >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 } >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 } >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 laddr =3D sin->sin_addr; >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 if (lport) { >> _______________________________________________ >> freebsd-hackers@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers >> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.or= g" >> > > From owner-freebsd-hackers@FreeBSD.ORG Mon Jan 10 09:27:02 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 662CC1065674; Mon, 10 Jan 2011 09:27:02 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from kabab.cs.huji.ac.il (kabab.cs.huji.ac.il [132.65.16.84]) by mx1.freebsd.org (Postfix) with ESMTP id 1E0EC8FC16; Mon, 10 Jan 2011 09:27:01 +0000 (UTC) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1PcE1k-00020L-DJ; Mon, 10 Jan 2011 11:27:00 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: Tom Judge In-reply-to: <4D29ED16.7030401@tomjudge.com> References: <4D295820.20807@tomjudge.com> <4D29ED16.7030401@tomjudge.com> Comments: In-reply-to Tom Judge message dated "Sun, 09 Jan 2011 11:15:02 -0600." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Mon, 10 Jan 2011 11:27:00 +0200 From: Daniel Braniss Message-ID: Cc: freebsd-hackers@freebsd.org, luigi@freebsd.org Subject: Re: sys/boot/boot0/boot0.S - r186598 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Jan 2011 09:27:02 -0000 > This is an OpenPGP/MIME signed message (RFC 2440 and 3156) > --------------enig0AE178BF2380C8CAA3249E0C > Content-Type: text/plain; charset=ISO-8859-1 > Content-Transfer-Encoding: quoted-printable > > On 09/01/2011 04:38, Daniel Braniss wrote: > >> There was a post on the embedded list that suggested this work around:= > > >> echo 'a 2' | fdisk -f /dev/stdin ad0 > >> boot0cfg -s 2 ad0 > >> > >> There are 2 issues with this: > >> 1) It can't be done without setting kern.geom.debugflags to 0x10. > >> 2) It resulted in most/all commands resulting in the error message > >> "Device not configured" including the second command and 'shutdown -r = > now=3D > >> '. > >> > >> Both of which leave this really work around fairly broken. > > the problem is that boot0cfg -s does NOT update the boot block, it fail= > s! > > the work around is: > > boot0cfg -s -t n dev > > then > > gpart set -a active -i n dev > > > > danny > > > Hi Danny, > > The bug does not seem to be in boot0cfg as: > > 1) It succeeds to write the new configuration to the boot block every > time i have tried. > 2) It does not touch the partition table at all only the mbr, so it was > never designed to change the active partition. arguable, since it used to work. > > If this is not a bug in boot0 then its a bug in the man pages for > boot0cfg as it does make reference to having to change the active slice > to make this work. the problem is not as simple as it looks, and I don't have all the answers, but after spendig much time on this, it seems that not all BIOSes behave in a 'standard way' :-) danny From owner-freebsd-hackers@FreeBSD.ORG Mon Jan 10 19:09:48 2011 Return-Path: Delivered-To: freebsd-hackers@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9CC33106566B for ; Mon, 10 Jan 2011 19:09:48 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 3BDB38FC16 for ; Mon, 10 Jan 2011 19:09:48 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id p0AJ65eN098678 for ; Mon, 10 Jan 2011 12:06:05 -0700 (MST) (envelope-from imp@bsdimp.com) Message-ID: <4D2B589B.2080702@bsdimp.com> Date: Mon, 10 Jan 2011 12:06:03 -0700 From: Warner Losh User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101029 Thunderbird/3.1.6 MIME-Version: 1.0 To: freebsd-hackers@FreeBSD.org References: <4D295820.20807@tomjudge.com> <4D29ED16.7030401@tomjudge.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: Re: sys/boot/boot0/boot0.S - r186598 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Jan 2011 19:09:48 -0000 On 01/10/2011 02:27, Daniel Braniss wrote: >> This is an OpenPGP/MIME signed message (RFC 2440 and 3156) >> --------------enig0AE178BF2380C8CAA3249E0C >> Content-Type: text/plain; charset=ISO-8859-1 >> Content-Transfer-Encoding: quoted-printable >> >> On 09/01/2011 04:38, Daniel Braniss wrote: >>>> There was a post on the embedded list that suggested this work around:= >>>> echo 'a 2' | fdisk -f /dev/stdin ad0 >>>> boot0cfg -s 2 ad0 >>>> >>>> There are 2 issues with this: >>>> 1) It can't be done without setting kern.geom.debugflags to 0x10. >>>> 2) It resulted in most/all commands resulting in the error message >>>> "Device not configured" including the second command and 'shutdown -r = >> now=3D >>>> '. >>>> >>>> Both of which leave this really work around fairly broken. >>> the problem is that boot0cfg -s does NOT update the boot block, it fail= >> s! >>> the work around is: >>> boot0cfg -s -t n dev >>> then >>> gpart set -a active -i n dev >>> >>> danny >>> >> Hi Danny, >> >> The bug does not seem to be in boot0cfg as: >> >> 1) It succeeds to write the new configuration to the boot block every >> time i have tried. >> 2) It does not touch the partition table at all only the mbr, so it was >> never designed to change the active partition. > arguable, since it used to work. > >> If this is not a bug in boot0 then its a bug in the man pages for >> boot0cfg as it does make reference to having to change the active slice >> to make this work. > the problem is not as simple as it looks, and I don't have all the answers, but after spendig much time on this, it seems that not all BIOSes behave > in a 'standard way' :-) It isn't a bug in boot0. The patch you pointed to was introduced to not wear out flash parts that boot a lot. boot0cfg likely is the wrong tool for this job, even if it used to work and kinda had the functionality you wanted. It's unlikely to be fixed, since there's no maintainer in the tree and it uses interfaces that are no longer supported. The right tool for the job is gpart. Sadly, the man page doesn't mention this at all. Fortunately, the source is easy to read. Someone should fix that disconnect :0. gpart set -a active -i 1 ada0 will do the trick. The reason that boot0 used to do the right thing is that it would always force writing the active partition on every boot. Now it only writes it if it is a change from the default. It might be argued that the proper behavior is update it only if it actually changed from last time (which means the first time it would write the flag automatically). I'm on the fence on this one, but am open to reasoned arguments. Warner > danny > > > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > > > From owner-freebsd-hackers@FreeBSD.ORG Mon Jan 10 21:45:24 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 787E91065672 for ; Mon, 10 Jan 2011 21:45:24 +0000 (UTC) (envelope-from Aaron.Caza@ca.weatherford.com) Received: from mail4.weatherford.com (mail4.weatherford.com [63.97.12.18]) by mx1.freebsd.org (Postfix) with ESMTP id 42B288FC0C for ; Mon, 10 Jan 2011 21:45:23 +0000 (UTC) X-IronPort-AV: E=Sophos;i="4.60,303,1291615200"; d="scan'208,217";a="414143514" Received: from usexbh02.wft.root.loc (HELO mail.weatherford.com) ([10.96.113.52]) by mail4.weatherford.com with ESMTP; 10 Jan 2011 15:16:34 -0600 Received: from owa.weatherford.com ([170.133.198.15]) by mail.weatherford.com with Microsoft SMTPSVC(6.0.3790.3959); Mon, 10 Jan 2011 15:16:34 -0600 Received: from 032-SN1MPN1-005.032d.mgd.msft.net ([169.254.5.218]) by 032-SN1MMR1-003.032d.mgd.msft.net ([170.133.198.15]) with mapi; Mon, 10 Jan 2011 15:16:34 -0600 From: "Caza, Aaron" To: "freebsd-hackers@freebsd.org" Thread-Topic: Hardclock() not so hard on i386 lately. Thread-Index: AcuxC6f6gNVFj1neRfS16HgvCRsyQQ== Date: Mon, 10 Jan 2011 21:16:33 +0000 Message-ID: Accept-Language: en-CA, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: MIME-Version: 1.0 X-OriginalArrivalTime: 10 Jan 2011 21:16:34.0678 (UTC) FILETIME=[A8E8D960:01CBB10B] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Hardclock() not so hard on i386 lately. X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Jan 2011 21:45:24 -0000 Greetings All, I've been experiencing a problem with the hardclock() call not exhibiting t= he same determinism in the FreeBSD 8.1 i386 Stable snapshots since November= . In the October snapshot and previous releases, instrumenting the hardclo= ck() to count ticks and using a kernel thread to print the output, I was se= eing 1024hz with +/- 1 tick jitter . Since November, however, I'm seeing a= lot more jitter - 1016hz-1024hz. To verify if the problem was with the ti= me-keeping or the hardclock(), I modified the hardclock() to raise & lower = a bit on the parallel port every tick and hooked it up to a frequency count= er. With the October release, I'm seeing 1023-1024hz as expected. With th= e FreeBSD 8.2 i386 Jan 2011 snapshot I'm seeing 1016-1024hz. Now, I know between Oct - Nov, the timecounter logic was modified to correc= tly allow for a 1-tick timecounter as prior to this the best it could do is= every other tick; however, I wouldn't think that modifying the timecounter= logic would have any bearing on the hard clock. A diff of kern_clock.c be= twix the two versions doesn't reveal anything useful. Being relatively new= to FreeBSD, I'm not certain where the next place I should be checking is. FYI: This is on an AMD Athlon II X2 235e Processor @ 2.7GHz running the SM= P kernel. Setting kern.smp.disabled=3D1 in /boot/loader.conf did not chang= e the behavior. Anyone got any useful pointers? Thanks in advance, Aaron This message may contain confidential and privileged information. If it has= been sent to you in error, please reply to advise the sender of the error = and then immediately delete it. If you are not the intended recipient, do n= ot read, copy, disclose or otherwise use this message. The sender disclaims= any liability for such unauthorized use. PLEASE NOTE that all incoming e-m= ails sent to Weatherford e-mail accounts will be archived and may be scanne= d by us and/or by external service providers to detect and prevent threats = to our systems, investigate illegal or inappropriate behavior, and/or elimi= nate unsolicited promotional e-mails (spam). This process could result in d= eletion of a legitimate e-mail before it is read by its intended recipient = at our organization. Moreover, based on the scanning results, the full text= of e-mails and attachments may be made available to Weatherford security a= nd other personnel for review and appropriate action. If you have any conce= rns about this process, please contact us at dataprivacy@weatherford.com. =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 CONFIDENTIAL & PRIVILEGED COMMUNICATION The information contained in this message is privileged, confidential, and = protected from disclosure. This message is intended for the individual or entity addressed herein.=20 If you are not the intended recipient, please do not read, copy, use or dis= close this communication to others.=20 Also please notify the sender by replying to this message, and then delete = it from your system.=20 The sender totally disclaims, and will not accept, any responsibility or li= ability for the unauthorized use,=20 or the consequences of any unauthorized use, of this communication or messa= ge. From owner-freebsd-hackers@FreeBSD.ORG Mon Jan 10 22:22:53 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 28CB0106564A; Mon, 10 Jan 2011 22:22:53 +0000 (UTC) (envelope-from tom@tomjudge.com) Received: from eu1sys200aog106.obsmtp.com (eu1sys200aog106.obsmtp.com [207.126.144.121]) by mx1.freebsd.org (Postfix) with SMTP id 14D7A8FC17; Mon, 10 Jan 2011 22:22:51 +0000 (UTC) Received: from source ([63.174.175.251]) by eu1sys200aob106.postini.com ([207.126.147.11]) with SMTP ID DSNKTSuGu6agfTQP6aCd38gN6e0hexWjfodn@postini.com; Mon, 10 Jan 2011 22:22:52 UTC Received: from [172.17.10.53] (unknown [172.17.10.53]) by bbbx3.usdmm.com (Postfix) with ESMTP id 88AB6FD054; Mon, 10 Jan 2011 22:02:58 +0000 (UTC) Message-ID: <4D2B820C.3050205@tomjudge.com> Date: Mon, 10 Jan 2011 16:02:52 -0600 From: Tom Judge User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.13) Gecko/20101208 Lightning/1.0b2 Thunderbird/3.1.7 MIME-Version: 1.0 To: Luigi Rizzo References: <4D295820.20807@tomjudge.com> <20110109183316.GA92631@onelab2.iet.unipi.it> <4D2A0514.7040305@tomjudge.com> <20110109224401.GA95358@onelab2.iet.unipi.it> In-Reply-To: <20110109224401.GA95358@onelab2.iet.unipi.it> X-Enigmail-Version: 1.1.1 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org, luigi@freebsd.org Subject: Re: sys/boot/boot0/boot0.S - r186598 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Jan 2011 22:22:53 -0000 On 01/09/2011 04:44 PM, Luigi Rizzo wrote: > On Sun, Jan 09, 2011 at 12:57:24PM -0600, Tom Judge wrote: >> On 09/01/2011 12:33, Luigi Rizzo wrote: >>> On Sun, Jan 09, 2011 at 12:39:28AM -0600, Tom Judge wrote: >>>> Hi, >>>> >>>> Today I ran into an issue where setting the default slice with boot0cfg >>>> -s is broken. >>> a few questions inline: >>> >> Output inline, full script log attached. >> >> If you need more info let me know. > > can you take a dump of the boot sector at various stages > indicated below: > Paths to the files inline. >> > > DUMP #1: ORIGINAL BOOT SECTOR http://www.tomjudge.com/tmp/boot0/file1 > > > > DUMP #2: AFTER THE BOOT SECTOR UPDATE http://www.tomjudge.com/tmp/boot0/file2 > > > > > DUMP #3: AFTER A REBOOT WITH NO KEYPRESS http://www.tomjudge.com/tmp/boot0/file3 > > > > DUMP #4: AFTER THE SUCCESSFUL BOOT IN SLICE 2 http://www.tomjudge.com/tmp/boot0/file4 > > At least from this we can tell how #4 differs from #2/#3 > Maybe we can update the update code so that it only writes an updated active flag if the active flag has changed? This would resolv the wear issue that caused this to change behavior. Tom -- TJU13-ARIN From owner-freebsd-hackers@FreeBSD.ORG Mon Jan 10 23:19:09 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 17A0B1065672; Mon, 10 Jan 2011 23:19:09 +0000 (UTC) (envelope-from luigi@onelab2.iet.unipi.it) Received: from onelab2.iet.unipi.it (onelab2.iet.unipi.it [131.114.59.238]) by mx1.freebsd.org (Postfix) with ESMTP id B585F8FC1A; Mon, 10 Jan 2011 23:19:07 +0000 (UTC) Received: by onelab2.iet.unipi.it (Postfix, from userid 275) id A9C2673098; Tue, 11 Jan 2011 00:33:30 +0100 (CET) Date: Tue, 11 Jan 2011 00:33:30 +0100 From: Luigi Rizzo To: Tom Judge Message-ID: <20110110233330.GA9190@onelab2.iet.unipi.it> References: <4D295820.20807@tomjudge.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D295820.20807@tomjudge.com> User-Agent: Mutt/1.4.2.3i Cc: freebsd-hackers@freebsd.org, luigi@freebsd.org Subject: Boot0cfg bug redux (Re: sys/boot/boot0/boot0.S - r186598) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Jan 2011 23:19:09 -0000 In order to understand the bug discussed in the recent thread (original message attached at the end), Tom Judge passed me the dump of the boot sector around the bug. The system giving trouble has the following configuration Fresh transcript: file1: ORIGINAL BOOT SECTOR # boot0cfg -v ad0 # flag start chs type end chs offset size 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 file2: boot sector after running 'boot0cfg -s 2 -v ad0' > cmp -x file1 file2 000001b5 00 01 _OPT, default option No big surprises here, the default selection changes from 0 to 1 HOWEVER, boot0cfg does not alter the 'active' flag in the partition table. This triggers, if i remember well, a 'feature' in the boot1/boot2, code which does not know/honor the selected partition and instead boots the first partition marked as 'active', and missing that, the first FreeBSD partition. As a consequence, if we reboot without pressing an F-key, the system boots from partition s1 even though the boot loader indicates F2. file3: boot sector after the above reboot > cmp -x file1 file3 000001b5 00 01 Next, reboot this time pressing F2. After the boot we start from s2, and the boot sector is now changed: file4: boot sector after pressing F2 > cmp -x file1 file4 000001b4 00 b1 _NXTDRV 000001b5 00 01 _OPT, default option 000001be 80 00 active flag, slice 1 000001ce 00 80 active flag, slice 2 As expected the 'active' flag is updated as a result of a boot from the partition selected. This is something that could be done by 'boot0cfg -s ...' to achieve the desired behaviour. The only "surprise" here is that _NXTDRV has changed. I am unsure if this was the result of an erroneous F5 keypress. Indeed 0xb1 is probably the correct initial value of the byte at 0x1b4, probably I/we forgot to initialize the field. So, to summarize, I guess that a possible fix (that does not involve using gpart, or even worse, modifying boot0.S, which probably does not have any spare space) is to modify boot0cfg so that it sets the 'active' flag for the partition corresponding to the default entry. What do people think ? cheers luigi On Sun, Jan 09, 2011 at 12:39:28AM -0600, Tom Judge wrote: > Hi, > > Today I ran into an issue where setting the default slice with boot0cfg > -s is broken. > > This is related to a section of this revision: > > + commit Warner's patch "orb $NOUPDATE,_FLAGS(%bp)" > to avoid writing to disk in case of a timeout/default choice; > > This issue is quite well documented in bin/134907 which has been open > since May 2009. > > Reproduced with a fresh nanobsd build: > > Boot 1 - Slice 1 active as set by nanobsd image builder: > > === > # boot0cfg -v ad0 > # flag start chs type end chs offset size > 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=2.0 drive=0x80 mask=0x3 ticks=182 bell=# (0x23) > options=packet,update,nosetdrv > volume serial ID 9090-9090 > default_selection=F1 (Slice 1) > === > > Update the active slice to 2: > === > # boot0cfg -s 2 -v ad0 > # flag start chs type end chs offset size > 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=2.0 drive=0x80 mask=0x3 ticks=182 bell=# (0x23) > options=packet,update,nosetdrv > volume serial ID 9090-9090 > default_selection=F2 (Slice 2) > === > > Reboot and let boot0 time out and boot default slice 2: > === > # boot0cfg -v ad0 > # flag start chs type end chs offset size > 1 0x80 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x00 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=2.0 drive=0x80 mask=0x3 ticks=182 bell=# (0x23) > options=packet,update,nosetdrv > volume serial ID 9090-9090 > default_selection=F2 (Slice 2) > === > The system actually booted into slice 1 here. > This was verified by dropping to the loader prompt and using show to grab: > loaddev=disk0s1a: > > Reboot and hit 2 at the boot0 prompt: > === > # boot0cfg -v ad0 > # flag start chs type end chs offset size > 1 0x00 0: 1: 1 0xa5 494: 15:63 63 498897 > 2 0x80 495: 1: 1 0xa5 989: 15:63 499023 498897 > 3 0x00 990: 0: 1 0xa5 992: 15:63 997920 3024 > > version=2.0 drive=0x80 mask=0x3 ticks=182 bell=# (0x23) > options=packet,update,nosetdrv > volume serial ID 9090-9090 > default_selection=F2 (Slice 2) > === > > This time we really boot into slice 2. > > The attached patch backs out the relevant part of r186598. > > There was a post on the embedded list that suggested this work around: > echo 'a 2' | fdisk -f /dev/stdin ad0 > boot0cfg -s 2 ad0 > > There are 2 issues with this: > 1) It can't be done without setting kern.geom.debugflags to 0x10. > 2) It resulted in most/all commands resulting in the error message > "Device not configured" including the second command and 'shutdown -r now'. > > Both of which leave this really work around fairly broken. > > > Tom > > Index: boot0.S > =================================================================== > --- boot0.S (revision 213760) > +++ boot0.S (working copy) > @@ -373,7 +373,6 @@ > * Timed out or default selection > */ > use_default: movb _OPT(%bp),%al # Load default > - orb $NOUPDATE,_FLAGS(%bp) # Disable updates > jmp check_selection # Join common code > > /* From owner-freebsd-hackers@FreeBSD.ORG Tue Jan 11 00:54:15 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A8A8D106566C for ; Tue, 11 Jan 2011 00:54:15 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from forward15.mail.yandex.net (forward15.mail.yandex.net [95.108.130.119]) by mx1.freebsd.org (Postfix) with ESMTP id 53BEF8FC13 for ; Tue, 11 Jan 2011 00:54:15 +0000 (UTC) Received: from smtp14.mail.yandex.net (smtp14.mail.yandex.net [95.108.131.192]) by forward15.mail.yandex.net (Yandex) with ESMTP id 39A4F44588AB; Tue, 11 Jan 2011 03:38:37 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1294706317; bh=lSuaBfU0EozT2Ns3RUcViajDIr4sPTh6S8CzT+z+Gi8=; h=Message-ID:Date:From:MIME-Version:To:CC:Subject:References: In-Reply-To:Content-Type; b=Lf+FV+pt9QN4M0ZuF59F6rOKR0oRtBycXNeR/a7PGW6Y+YJS7RLGPDbyfMqAaMJfb 7Bx3sO22SoRrXDKNTCNvKnTpQWTC2KlbVkFuk45rX7bPYNfHCz3xAVb7I3qrFVwN2t lOhRQZuwSOZU8rr/bbYeUIW3xP31s1DLv/TdkO/g= Received: from [178.141.6.99] (dynamic-178-141-6-99.kirov.comstar-r.ru [178.141.6.99]) by smtp14.mail.yandex.net (Yandex) with ESMTPSA id E220719B8067; Tue, 11 Jan 2011 03:38:36 +0300 (MSK) Message-ID: <4D2BA67F.8050801@yandex.ru> Date: Tue, 11 Jan 2011 03:38:23 +0300 From: "Andrey V. Elsukov" User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101030 Thunderbird/3.1.6 MIME-Version: 1.0 To: Luigi Rizzo References: <4D295820.20807@tomjudge.com> <20110110233330.GA9190@onelab2.iet.unipi.it> In-Reply-To: <20110110233330.GA9190@onelab2.iet.unipi.it> X-Enigmail-Version: 1.1.2 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigF2C576B910141C78195D450B" Cc: Tom Judge , freebsd-hackers@freebsd.org Subject: Re: Boot0cfg bug redux (Re: sys/boot/boot0/boot0.S - r186598) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Jan 2011 00:54:15 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigF2C576B910141C78195D450B Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: quoted-printable On 11.01.2011 02:33, Luigi Rizzo wrote: > As a consequence, if we reboot without pressing an F-key, the system > boots from partition s1 even though the boot loader indicates F2. > So, to summarize, I guess that a possible fix (that does not involve > using gpart, or even worse, modifying boot0.S, which probably does > not have any spare space) is to modify boot0cfg so that it sets the > 'active' flag for the partition corresponding to the default entry. >=20 > What do people think ? I don't remember which behavior was before, but it seems that users want to change "active" attribute when they use "boot0cfg -s". And i think it is not so hard to add several lines of code to pass "set" command to PART class. --=20 WBR, Andrey V. Elsukov --------------enigF2C576B910141C78195D450B Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (FreeBSD) iQEcBAEBAgAGBQJNK6aGAAoJEAHF6gQQyKF6q80H/1jNtnjWqYgGL7WclOinqXNf kZmQ8V0bequfZBsYUi5/6RPq8CL8nRO8Uqp10vt0EMjlmaL4GDnijwpbUZUjDZ0U 2OBOmVHFESbyr9AoIU0pgxvmv4XRYdKFSc5bn+1XbO4+1sblvQ65Uu7yxNgRgEuJ 17jOFLRLC+85Bxz7INbi5WTtedkqZIpD1bW6q0Bi7Y2Z9fDbezPkD2gUmXemsWvy F1sp3l1Xg2MfE662c8m/qewTSJ+uQHNkI96x1AnQYy/G2UzUUMGO44SSa884CWPX 9ma1o1lLZF7Qum0RSUtWnJduu3OhF+uihPDPAaho5hO/N/RDc/k/DIiUQ5izWEE= =A9km -----END PGP SIGNATURE----- --------------enigF2C576B910141C78195D450B-- From owner-freebsd-hackers@FreeBSD.ORG Tue Jan 11 00:58:07 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7B5F11065679 for ; Tue, 11 Jan 2011 00:58:07 +0000 (UTC) (envelope-from luigi@onelab2.iet.unipi.it) Received: from onelab2.iet.unipi.it (onelab2.iet.unipi.it [131.114.59.238]) by mx1.freebsd.org (Postfix) with ESMTP id 419058FC0C for ; Tue, 11 Jan 2011 00:58:06 +0000 (UTC) Received: by onelab2.iet.unipi.it (Postfix, from userid 275) id B2FF573098; Tue, 11 Jan 2011 02:12:29 +0100 (CET) Date: Tue, 11 Jan 2011 02:12:29 +0100 From: Luigi Rizzo To: "Andrey V. Elsukov" Message-ID: <20110111011229.GA10711@onelab2.iet.unipi.it> References: <4D295820.20807@tomjudge.com> <20110110233330.GA9190@onelab2.iet.unipi.it> <4D2BA67F.8050801@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D2BA67F.8050801@yandex.ru> User-Agent: Mutt/1.4.2.3i Cc: Tom Judge , freebsd-hackers@freebsd.org Subject: Re: Boot0cfg bug redux (Re: sys/boot/boot0/boot0.S - r186598) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Jan 2011 00:58:07 -0000 On Tue, Jan 11, 2011 at 03:38:23AM +0300, Andrey V. Elsukov wrote: > On 11.01.2011 02:33, Luigi Rizzo wrote: > > As a consequence, if we reboot without pressing an F-key, the system > > boots from partition s1 even though the boot loader indicates F2. > > > So, to summarize, I guess that a possible fix (that does not involve > > using gpart, or even worse, modifying boot0.S, which probably does > > not have any spare space) is to modify boot0cfg so that it sets the > > 'active' flag for the partition corresponding to the default entry. > > > > What do people think ? > > I don't remember which behavior was before, but it seems that users > want to change "active" attribute when they use "boot0cfg -s". more than "what was before" the issue is whether the 0x80 flag means ACTIVE (hence is should be set only for one partition) or it means BOOTABLE (so it is ok to have it set for multiple partitions, and bootloaders should ignore partitions with the flag clear, no matter what the selection is). boot0.S' behaviour is closer to ACTIVE than BOOTABLE. Same for fdisk, and the change i was proposing is in line with this interpretation. > And i think it is not so hard to add several lines of code to pass > "set" command to PART class. i don't know how this would help, because i believe the code at the origin of the bug is (or at least used to be) in boot2.c cheers luigi From owner-freebsd-hackers@FreeBSD.ORG Tue Jan 11 19:01:02 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AD3361065693 for ; Tue, 11 Jan 2011 19:01:02 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from out-0.mx.aerioconnect.net (outw.internet-mail-service.net [216.240.47.246]) by mx1.freebsd.org (Postfix) with ESMTP id 8D7038FC1B for ; Tue, 11 Jan 2011 19:01:02 +0000 (UTC) Received: from idiom.com (postfix@mx0.idiom.com [216.240.32.160]) by out-0.mx.aerioconnect.net (8.13.8/8.13.8) with ESMTP id p0BIldkm014294; Tue, 11 Jan 2011 10:47:39 -0800 X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e Received: from julian-mac.elischer.org (h-67-100-89-137.snfccasy.static.covad.net [67.100.89.137]) by idiom.com (Postfix) with ESMTP id 751972D6014; Tue, 11 Jan 2011 10:47:38 -0800 (PST) Message-ID: <4D2CA5E8.9070003@freebsd.org> Date: Tue, 11 Jan 2011 10:48:08 -0800 From: Julian Elischer User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10.4; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 To: joris dedieu References: <4D274C5E.500@freebsd.org> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.67 on 216.240.47.51 Cc: freebsd-hackers Subject: Re: Fwd: binding non local ip. X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Jan 2011 19:01:02 -0000 On 1/9/11 3:01 PM, joris dedieu wrote: > ---------- Forwarded message ---------- > From: joris dedieu > Date: 2011/1/9 > Subject: Re: binding non local ip. > To: Julian Elischer > > > 2011/1/7 Julian Elischer: >> On 1/7/11 4:57 AM, joris dedieu wrote: >>> Hi, >>> I need a to bind non local ips daemons that don't >>> implement IP_BINDANY sockopt. >> I'm not sure you need it >> you can use the ipfw 'fwd' command to make a locally bound >> socket act and look as if it is bound to a non local address >> >> You need to tell us a little more about what you need to do >> >> for example, >> Is the socket just listenning? or is it initiating? > listenning I think. > Typicaly prepare a spare server. > eg: > - Failover as with carp but with more complexes actions has shutting > down the power of the main server, check data consistency, check if > the problem is not just a reboot or a buggy service that need to be > restarted. A listenning server can be listenning on a local port and address. Use ipfw 'fwd' to force it to accept a non-local address socket. the local address of the listenning socket will be switched to that of the address on the session. e.g. ipfw add 100 fwd 127.0.0.1,80 tcp from any to 111.123.123.123 in recv em0 your local server listenning on 127.0.0.1:80 will end up with a socket with a local address of 111.123.123.123 even if that is not any address of yours. > - Switch an ip from a main server to a already configured proxy (during a dos) > - monitor that spare service is running. this is easy as shown above >>> There are several solutions as patching every single daemon >>> or using carp (You may not want automatic failover), jailing >>> the process and of course binding INADDR_ANY when possible ... >>> >>> As I'm too lazy for this, I wrote a little (maybe ugly as my >>> kernel knowledges are really low) patch that add a sysctl >>> entry in net.inet.ip that allow binding non local ips. It's >>> maybe buggy and insecure but it seems to work. >> seems ok, but if the daemon is initiating, how does it know to bind to a non >> local address? > It doesn't know. That's the goal. So when the address became local > it's already ready. So you don't discover that it's misconfigured or > broken, or that else your dummy colleague has imagined :) . You or a > script ifconfig the alias and back to bed ! >> also. if you have source, a single setsockopt() in each one is not much of a >> job.. > I already do this for haproxy and for apr. But (for haproxy) it seems > to be too specific to be integrated upstreams. For other services (as > tomcat) that don't know privileges dropping it's more problematic as > IP_BINDANY needs in most case root privileges. > > I think that a system wide solution should be a good thing. > Joris >> From owner-freebsd-hackers@FreeBSD.ORG Tue Jan 11 19:29:25 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9398B106570F for ; Tue, 11 Jan 2011 19:29:25 +0000 (UTC) (envelope-from lgj@usenix.org) Received: from lonestar.usenix.org (lonestar.usenix.org [131.106.3.102]) by mx1.freebsd.org (Postfix) with ESMTP id 7B2528FC1A for ; Tue, 11 Jan 2011 19:29:25 +0000 (UTC) Received: from negroni.usenix.org (negroni.usenix.org [131.106.3.145]) (authenticated bits=0) by lonestar.usenix.org (8.14.2/8.14.2) with ESMTP id p0BJST83026927 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO) for ; Tue, 11 Jan 2011 11:29:25 -0800 (PST) From: Lionel Garth Jones Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Date: Tue, 11 Jan 2011 11:29:24 -0800 Message-Id: <65A78C85-F6BB-4394-ADD8-F0D2C0BD520C@usenix.org> To: freebsd-hackers@freebsd.org Mime-Version: 1.0 (Apple Message framework v1082) X-Mailer: Apple Mail (2.1082) X-DCC-USENIX-Metrics: lonestar; whitelist X-Spam-Status: No, score=0.7 required=6.0 tests=ALL_TRUSTED, FH_DATE_PAST_20XX autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on lonestar X-Mailman-Approved-At: Tue, 11 Jan 2011 19:41:38 +0000 Subject: USENIX HotOS XIII Submission Deadline Approaching X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Jan 2011 19:29:25 -0000 I am writing to remind you that the deadline for submitting to HotOS XIII is only a week away. Please submit your work by Saturday, January 15, 2011, at 11:59 p.m. EST. http://www.usenix.org/hotos11/cfpc/ HotOS takes a broad view of systems, including operating systems, storage, networking, languages and language engineering, security, fault tolerance, and manageability. We are also interested in contributions influenced by other fields such as hardware design, machine learning, control theory, networking, economics, social organizations, and biological or other nontraditional computing systems. Full submission guidelines and a complete list of topics may be found at http://www.usenix.org/hotos11/cfpc/ We look forward to receiving your submissions! Matt Welsh, Google HotOS XIII Program Chair hotos11chair@usenix.org --------------------------------- Call for Papers 13th Workshop on Hot Topics in Operating Systems May 8-10, 2011 Napa Valley, CA=AC=86 http://www.usenix.org/hotos11/cfpc/ Submission Deadline: January 15, 2011, 11:59 p.m. EST --------------------------------- From owner-freebsd-hackers@FreeBSD.ORG Wed Jan 12 09:09:10 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1EA16106566B for ; Wed, 12 Jan 2011 09:09:10 +0000 (UTC) (envelope-from superbisquit@gmail.com) Received: from mail-qw0-f54.google.com (mail-qw0-f54.google.com [209.85.216.54]) by mx1.freebsd.org (Postfix) with ESMTP id CA4688FC08 for ; Wed, 12 Jan 2011 09:09:09 +0000 (UTC) Received: by qwj9 with SMTP id 9so338466qwj.13 for ; Wed, 12 Jan 2011 01:09:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=loC1jfVomRxdKbm+YeI89Pq0NPIp+aKz3e8zU18jw8I=; b=wRS7VWQjW6bxgQHfSbXSTS1ne2rNPCKSZaSGf8yw0d8Scx/7Ug8OuVVM4GwUAWrBcW QU/vC1qYdNldX72kkv44N2Det8yyWjjDYiXsKVbQHUthV8O96MqWTfzYKD/DwBsondF3 0mTTw0suyuAkYW3zgwIugr4j9p1M+6on8UBS8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=qv49KnYDXZptCcTLjT9g5IFkjAYynkhsPZ4AWYTysIG2Vp+PjnmXq3B8f0SHPFsAnK w1QTedIuwzQLXcaIxrtfdYwK+1ngsdAbLWfgmp7xrkFKUGoNnu2zgabVBTfkGEeak9jb vkkBFdsX5RjnGDCkw1jwE1kW073AQ1CiRAtVg= MIME-Version: 1.0 Received: by 10.229.183.66 with SMTP id cf2mr625607qcb.90.1294821570723; Wed, 12 Jan 2011 00:39:30 -0800 (PST) Received: by 10.220.187.7 with HTTP; Wed, 12 Jan 2011 00:39:30 -0800 (PST) Date: Wed, 12 Jan 2011 03:39:30 -0500 Message-ID: From: Super Bisquit To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Unable to compile drm.ko on powerpc X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Jan 2011 09:09:10 -0000 http://slexy.org/view/s2NSVy7aTU The build also fails looking for machine/specialreg.h. This file is only found on i386/amd64 processors. Drm.ko is needed by agp.ko. From owner-freebsd-hackers@FreeBSD.ORG Wed Jan 12 13:25:23 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D16B41065674 for ; Wed, 12 Jan 2011 13:25:23 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from kabab.cs.huji.ac.il (kabab.cs.huji.ac.il [132.65.16.84]) by mx1.freebsd.org (Postfix) with ESMTP id 8F1C38FC16 for ; Wed, 12 Jan 2011 13:25:22 +0000 (UTC) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1Pd0hV-000F76-DY for freebsd-hackers@freebsd.org; Wed, 12 Jan 2011 15:25:21 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: freebsd-hackers@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Wed, 12 Jan 2011 15:25:21 +0200 From: Daniel Braniss Message-ID: Subject: NFS: file too large X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Jan 2011 13:25:23 -0000 I'm getting 'File too large' when copying via NFS(v3, tcp/udp) a file that is larger than 1T. The server is ZFS which has no problem with large files. Is this fixable? Cheers, danny From owner-freebsd-hackers@FreeBSD.ORG Wed Jan 12 13:50:21 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5A06B1065695 for ; Wed, 12 Jan 2011 13:50:21 +0000 (UTC) (envelope-from onwahe@gmail.com) Received: from mail-qy0-f182.google.com (mail-qy0-f182.google.com [209.85.216.182]) by mx1.freebsd.org (Postfix) with ESMTP id 18F478FC0A for ; Wed, 12 Jan 2011 13:50:20 +0000 (UTC) Received: by qyk36 with SMTP id 36so584026qyk.13 for ; Wed, 12 Jan 2011 05:50:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=hAqVJDHFnSSlNYNJyrx+A27uEsLjZhc0gIGwHNFNAMM=; b=fqxNlh1DWgxHlkpew/1vd4z5Rqz7VkR15kvdULENw04Y5KS2BUTiXf/CHgI6m9Q4S2 UGOXDiG7AeTlkDflfAP6e81DfHGWarvgr6JToAEZJVN3dWKMxLdVnz/6h0507bBod+yE tNjVTxc71zz8/jVaphptfNdkvTEHk/Z+j1Fh8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=wd6dPX06bQb5F3v2ehq3ZjIM2v+gP8TVg47hpuoLkqcvfXmqi6BkghL2ajMxLWUJEl 0VFNF5CF7g3qcidPAI/O4vexLx5sR73HMO5VEkAFKx6ecx7tv6utk/EVknaqcXohHt0s UaRaWtxkxPFa5d+Q5xrPrccsr4mvTB96zpkoQ= MIME-Version: 1.0 Received: by 10.224.60.82 with SMTP id o18mr935433qah.189.1294838769311; Wed, 12 Jan 2011 05:26:09 -0800 (PST) Received: by 10.224.179.141 with HTTP; Wed, 12 Jan 2011 05:26:09 -0800 (PST) Date: Wed, 12 Jan 2011 14:26:09 +0100 Message-ID: From: Svatopluk Kraus To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Subject: A question about "WARNING: attempt to domain_add(xyz) after domainfinalize()" X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Jan 2011 13:50:21 -0000 Hi, I'd like to add a new network domain into kernel (and never remove it) from loadable module. In fact, I did it, but I got following warning from domain_add(): "WARNING: attempt to domain_add(xyz) after domainfinalize()". Now, I try to figure out what is behind the warning, which seems to become KASSERT (now, in notyet section part of code, which is 6 years old). I found a few iteration on domains list and each domain protosw table, which are not protected by any lock. OK, it is problem but when I only add a domain (it's added at the head of domains list) and never remove it then that could be safe. Moreover, it seems that without any limits, it is possible to add a new protocol into domain on reserved place labeled as PROTO_SPACER by pf_proto_register() function. Well, it's not a list so it's a different case (but a copy into spacer isn't atomic operation). I found two global variables (max_hdr,max_datalen) which are evaluated in each domain_init() from other variables (max_linkhdr,max_protohdr) and a global variable (max_keylen) which is evaluated from all known domains (dom_maxrtkey entry). The variables are used in other parts of kernel. Futher, I know about 'dom_ifattach' and 'dom_ifdetach' pointers to functions defined on each domain, which are responsible for 'if_afdata' entry on ifnet structure. Is there something more I didn't find in current kernel? Will be there something more in future kernels, what legitimize KASSERT in domain_add()? My network domain doesn't influence any mentioned global variables, doesn't define dom_ifattach() and dom_ifdetach() functions, and should be only added from loadable module and never removed. So, I think it's safe. But I'm a little bit nervous because of planned KASSERT in domain_add(). Well, I can implement an empty domain with some spacers for protocols, link it into kernel (thus shut down the warning), and make loadable module in which I only register protocols I want on already added domain, but why should I do it in that (for me good-for-nothing) way? Thanks for any response, Svata From owner-freebsd-hackers@FreeBSD.ORG Wed Jan 12 17:53:21 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7FEED106566B for ; Wed, 12 Jan 2011 17:53:21 +0000 (UTC) (envelope-from superbisquit@gmail.com) Received: from mail-qw0-f54.google.com (mail-qw0-f54.google.com [209.85.216.54]) by mx1.freebsd.org (Postfix) with ESMTP id 301FC8FC13 for ; Wed, 12 Jan 2011 17:53:20 +0000 (UTC) Received: by qwj9 with SMTP id 9so841796qwj.13 for ; Wed, 12 Jan 2011 09:53:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=/O4+AEMW9+ksoub97yV50KS8E+j46TXk3xMu3qXx1w8=; b=Hn2ftsqCQKM5yd2y3tGEqvKIgRFscOvo4qKwHllTsuROwVytYMRmORtTzGhtVMET4v Rw8AUHLRZXIXFYF/YTTMuUCILv+iQLaVQM6qzz+dyKo9fK5udZyNvIifeFLkY5gXM0qa BGVegwqldMTrsUXaIpGiRtexleBUSFXxC0k0k= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=mCLVHoO3ShqWI3mC8ARrj/nZXzwsi/qJmPBSwHVywllAkLy4Wnffc/ditQrVsYppa1 6e3n8YqjZ6kDylAWQIkNNwIMgtRVcHf9OnUMHlynkAnNS7EJ2+OOr4wp0/6BCCdhWjZA jV26E5uCBwy9izM1dvBbQu0KWjHD8+I38i2aU= MIME-Version: 1.0 Received: by 10.229.220.83 with SMTP id hx19mr1121839qcb.52.1294854800330; Wed, 12 Jan 2011 09:53:20 -0800 (PST) Received: by 10.220.187.7 with HTTP; Wed, 12 Jan 2011 09:53:20 -0800 (PST) Date: Wed, 12 Jan 2011 12:53:20 -0500 Message-ID: From: Super Bisquit To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: How do I change the default graphics card on a Powermac G4 Quicksilver? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Jan 2011 17:53:21 -0000 The last email I sent stated that the drm kernel module could not be built because specialreg.h is an i386 only function. I am also aware that the agp module needs drm to run. Why did I ask for help? The PowerMac G4 Quicksilver has an agp graphics slot. I also know that OpenFirmware is related to OpenBoot. If the default graphics slot can be switched with OpenBoot, then why not with Open Firmware. The item I do not have is the diagnostic tool. If the drm module cannot be built for the machine in question, then what is the proper forth command for choosing a PCI slot over the agp one without frying the logic board. In the event that my request seems to be spam: 1) Whoever has the same machine can install the PowerPC snapshot 9.0 from Nathan Whitehorn's site. The proper howto is at the FreeBSD forums. 2) Try building the module from the 9.0 sources. The card is a radeon 200. From owner-freebsd-hackers@FreeBSD.ORG Wed Jan 12 18:32:14 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D4937106566C for ; Wed, 12 Jan 2011 18:32:14 +0000 (UTC) (envelope-from nwhitehorn@freebsd.org) Received: from mail.icecube.wisc.edu (trout.icecube.wisc.edu [128.104.255.119]) by mx1.freebsd.org (Postfix) with ESMTP id A89B98FC08 for ; Wed, 12 Jan 2011 18:32:14 +0000 (UTC) Received: from localhost (localhost.localdomain [127.0.0.1]) by mail.icecube.wisc.edu (Postfix) with ESMTP id 311B15811E for ; Wed, 12 Jan 2011 11:59:56 -0600 (CST) X-Virus-Scanned: amavisd-new at icecube.wisc.edu Received: from mail.icecube.wisc.edu ([127.0.0.1]) by localhost (trout.icecube.wisc.edu [127.0.0.1]) (amavisd-new, port 10030) with ESMTP id EAkUVXTN7MDs for ; Wed, 12 Jan 2011 11:59:56 -0600 (CST) Received: from wanderer.tachypleus.net (i3-dhcp-172-16-223-197.icecube.wisc.edu [172.16.223.197]) by mail.icecube.wisc.edu (Postfix) with ESMTP id 0B14C5811A for ; Wed, 12 Jan 2011 11:59:56 -0600 (CST) Message-ID: <4D2DEC1B.3010208@freebsd.org> Date: Wed, 12 Jan 2011 11:59:55 -0600 From: Nathan Whitehorn User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.13) Gecko/20101227 Thunderbird/3.1.7 MIME-Version: 1.0 To: freebsd-hackers@freebsd.org References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: Unable to compile drm.ko on powerpc X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Jan 2011 18:32:14 -0000 On 01/12/11 02:39, Super Bisquit wrote: > http://slexy.org/view/s2NSVy7aTU > > The build also fails looking for machine/specialreg.h. This file is only > found on i386/amd64 processors. Drm.ko is needed by agp.ko. DRM is not required by AGP, rather the reverse, and DRM does not presently work on powerpc. The AGP kernel module also doesn't provide any useful features unless you are using DRM. You don't need either for graphics on powerpc machines. -Nathan From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 01:24:13 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BEFC01065674 for ; Thu, 13 Jan 2011 01:24:13 +0000 (UTC) (envelope-from superbisquit@gmail.com) Received: from mail-qy0-f182.google.com (mail-qy0-f182.google.com [209.85.216.182]) by mx1.freebsd.org (Postfix) with ESMTP id 5A9678FC16 for ; Thu, 13 Jan 2011 01:24:13 +0000 (UTC) Received: by qyk36 with SMTP id 36so1197348qyk.13 for ; Wed, 12 Jan 2011 17:24:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=llNHTnuLtKSnqiQ/nJ1O6jPpRxdmxJzCzGgg2wtu+cg=; b=L039RkWhva8vOyLDoA/Y+0OS/hB4nlqY0PRChv+P3nsPshiJsYwBFmueTbjM19q02T Je+AvNIUO0JC0Y4+46LafQlve5jWMiyUAgU3mnvUJB4BFdZfQtqjedZxLXNWHBcqUQph kVxL9pPzn22KJwdGLitR5kRQKzoNOo3FuvceE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=Wh+SHWoxtu91KKe6K4ujUrKQYpg6CAYOYodqBxo9VU3z6T44nCyKhKmBArwkd04wWd gXhA9L0GM4JiC6m6zqYKLbNrgsv9I7GVX5K6SQxQWBfkovZ2Ey3t4NE7idDcCd36sh78 SfQ49BgQAPuqlbixNz5BBksVyIQrgiXQ4oEcY= MIME-Version: 1.0 Received: by 10.229.183.66 with SMTP id cf2mr1464434qcb.90.1294881852400; Wed, 12 Jan 2011 17:24:12 -0800 (PST) Received: by 10.220.187.7 with HTTP; Wed, 12 Jan 2011 17:24:12 -0800 (PST) In-Reply-To: <4D2DEC1B.3010208@freebsd.org> References: <4D2DEC1B.3010208@freebsd.org> Date: Wed, 12 Jan 2011 20:24:12 -0500 Message-ID: From: Super Bisquit To: Nathan Whitehorn Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-hackers@freebsd.org Subject: Re: Unable to compile drm.ko on powerpc X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 01:24:13 -0000 My graphics port is agp and not pci. It's a Quicksilver 2002 with a 4x agp slot. Now, how do I make it work? That's the problem I've been recently asking about. Forgive me for bringing the next part here. The PowerPC snapshot 9 for the 32bit ppc needs updating. The ports tarball is behind. On 1/12/11, Nathan Whitehorn wrote: > On 01/12/11 02:39, Super Bisquit wrote: >> http://slexy.org/view/s2NSVy7aTU >> >> The build also fails looking for machine/specialreg.h. This file is only >> found on i386/amd64 processors. Drm.ko is needed by agp.ko. > > DRM is not required by AGP, rather the reverse, and DRM does not > presently work on powerpc. The AGP kernel module also doesn't provide > any useful features unless you are using DRM. You don't need either for > graphics on powerpc machines. > -Nathan > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 04:57:38 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0499D106566B for ; Thu, 13 Jan 2011 04:57:38 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from esa-annu.mail.uoguelph.ca (esa-annu.mail.uoguelph.ca [131.104.91.36]) by mx1.freebsd.org (Postfix) with ESMTP id BA8AB8FC08 for ; Thu, 13 Jan 2011 04:57:37 +0000 (UTC) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApwEAOsULk2DaFvO/2dsb2JhbACECKExrXuOH4Ehgzd0BIRohiiLMw X-IronPort-AV: E=Sophos;i="4.60,316,1291611600"; d="scan'208";a="105196779" Received: from erie.cs.uoguelph.ca (HELO zcs3.mail.uoguelph.ca) ([131.104.91.206]) by esa-annu-pri.mail.uoguelph.ca with ESMTP; 12 Jan 2011 23:57:36 -0500 Received: from zcs3.mail.uoguelph.ca (localhost.localdomain [127.0.0.1]) by zcs3.mail.uoguelph.ca (Postfix) with ESMTP id 0227BB53C2; Wed, 12 Jan 2011 20:20:49 -0500 (EST) Date: Wed, 12 Jan 2011 20:20:48 -0500 (EST) From: Rick Macklem To: Daniel Braniss Message-ID: <1344863848.140534.1294881648948.JavaMail.root@erie.cs.uoguelph.ca> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Originating-IP: [172.17.91.203] X-Mailer: Zimbra 6.0.10_GA_2692 (ZimbraWebClient - IE8 (Win)/6.0.10_GA_2692) Cc: freebsd-hackers@freebsd.org Subject: Re: NFS: file too large X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 04:57:38 -0000 > I'm getting 'File too large' when copying via NFS(v3, tcp/udp) a file > that is larger than 1T. The server is ZFS which has no problem with > large > files. > > Is this fixable? > As I understand it, there is no FreeBSD VFSop that returns the maximum file size supported. As such, the NFS servers just take a guess. You can either switch to the experimental NFS server, which guesses the largest size expressed in 64bits. OR You can edit sys/nfsserver/nfs_serv.c and change the assignment of a value to maxfsize = XXX; at around line #3671 to a larger value. I didn't check to see if there are additional restrictions in the clients. (They should believe what the server says it can support.) rick From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 05:42:07 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EA47C1065670 for ; Thu, 13 Jan 2011 05:42:06 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from out-0.mx.aerioconnect.net (out-0-30.mx.aerioconnect.net [216.240.47.90]) by mx1.freebsd.org (Postfix) with ESMTP id CC93C8FC08 for ; Thu, 13 Jan 2011 05:42:06 +0000 (UTC) Received: from idiom.com (postfix@mx0.idiom.com [216.240.32.160]) by out-0.mx.aerioconnect.net (8.13.8/8.13.8) with ESMTP id p0D5g5pW023165; Wed, 12 Jan 2011 21:42:05 -0800 X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e Received: from julian-mac.elischer.org (h-67-100-89-137.snfccasy.static.covad.net [67.100.89.137]) by idiom.com (Postfix) with ESMTP id BCDB62D6016; Wed, 12 Jan 2011 21:42:03 -0800 (PST) Message-ID: <4D2E90C9.2010600@freebsd.org> Date: Wed, 12 Jan 2011 21:42:33 -0800 From: Julian Elischer User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10.4; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 To: Svatopluk Kraus References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.67 on 216.240.47.51 Cc: freebsd-hackers@freebsd.org Subject: Re: A question about "WARNING: attempt to domain_add(xyz) after domainfinalize()" X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 05:42:07 -0000 On 1/12/11 5:26 AM, Svatopluk Kraus wrote: > Hi, > > I'd like to add a new network domain into kernel (and never remove it) > from loadable module. In fact, I did it, but I got following warning > from domain_add(): "WARNING: attempt to domain_add(xyz) after > domainfinalize()". Now, I try to figure out what is behind the > warning, which seems to become KASSERT (now, in notyet section part of > code, which is 6 years old). > just ignore that message, everyone else does :-) teh problem is that the idea of domainfinalize() is incompatible with having the ability to add domains from modules. Luckily domain finalize doesn't actually do anything that stops your new domain from working so it doesn't matter. you'll get the same message if you add netgraph.ko as an object. > I found a few iteration on domains list and each domain protosw table, > which are not protected by any lock. OK, it is problem but when I only > add a domain (it's added at the head of domains list) and never remove > it then that could be safe. Moreover, it seems that without any > limits, it is possible to add a new protocol into domain on reserved > place labeled as PROTO_SPACER by pf_proto_register() function. Well, > it's not a list so it's a different case (but a copy into spacer isn't > atomic operation). > > I found two global variables (max_hdr,max_datalen) which are evaluated > in each domain_init() from other variables (max_linkhdr,max_protohdr) > and a global variable (max_keylen) which is evaluated from all known > domains (dom_maxrtkey entry). The variables are used in other parts of > kernel. Futher, I know about 'dom_ifattach' and 'dom_ifdetach' > pointers to functions defined on each domain, which are responsible > for 'if_afdata' entry on ifnet structure. > > Is there something more I didn't find in current kernel? > Will be there something more in future kernels, what legitimize > KASSERT in domain_add()? > > My network domain doesn't influence any mentioned global variables, > doesn't define dom_ifattach() and dom_ifdetach() functions, and should > be only added from loadable module and never removed. So, I think it's > safe. But I'm a little bit nervous because of planned KASSERT in > domain_add(). > > Well, I can implement an empty domain with some spacers for protocols, > link it into kernel (thus shut down the warning), and make loadable > module in which I only register protocols I want on already added > domain, but why should I do it in that (for me good-for-nothing) way? > > Thanks for any response, Svata > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 15:08:21 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 72E72106567A for ; Thu, 13 Jan 2011 15:08:21 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from kabab.cs.huji.ac.il (kabab.cs.huji.ac.il [132.65.16.84]) by mx1.freebsd.org (Postfix) with ESMTP id 152A38FC1D for ; Thu, 13 Jan 2011 15:08:20 +0000 (UTC) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1PdOmg-0007DW-PH; Thu, 13 Jan 2011 17:08:18 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: Rick Macklem In-reply-to: <1344863848.140534.1294881648948.JavaMail.root@erie.cs.uoguelph.ca> References: <1344863848.140534.1294881648948.JavaMail.root@erie.cs.uoguelph.ca> Comments: In-reply-to Rick Macklem message dated "Wed, 12 Jan 2011 20:20:48 -0500." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 13 Jan 2011 17:08:18 +0200 From: Daniel Braniss Message-ID: Cc: freebsd-hackers@freebsd.org Subject: Re: NFS: file too large X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 15:08:21 -0000 > > I'm getting 'File too large' when copying via NFS(v3, tcp/udp) a file > > that is larger than 1T. The server is ZFS which has no problem with > > large > > files. > > > > Is this fixable? > > > As I understand it, there is no FreeBSD VFSop that returns the maximum > file size supported. As such, the NFS servers just take a guess. > > You can either switch to the experimental NFS server, which guesses the > largest size expressed in 64bits. > OR > You can edit sys/nfsserver/nfs_serv.c and change the assignment of a > value to > maxfsize = XXX; > at around line #3671 to a larger value. > > I didn't check to see if there are additional restrictions in the > clients. (They should believe what the server says it can support.) > > rick well, after some more experimentation, it sees to be a FreeBSD client issue. if the client is linux there is no problem. BTW, I 'think' I'm using the experimental server, but how can I be sure? I have the -e set for both nfs_server and mountd, I don't have option NFSD, but the nfsd.ko gets loaded. cheers, danny From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 16:17:02 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 90D121065672 for ; Thu, 13 Jan 2011 16:17:02 +0000 (UTC) (envelope-from nwhitehorn@freebsd.org) Received: from mail.icecube.wisc.edu (trout.icecube.wisc.edu [128.104.255.119]) by mx1.freebsd.org (Postfix) with ESMTP id 55A738FC1F for ; Thu, 13 Jan 2011 16:17:02 +0000 (UTC) Received: from localhost (localhost.localdomain [127.0.0.1]) by mail.icecube.wisc.edu (Postfix) with ESMTP id B14585811D; Thu, 13 Jan 2011 10:17:01 -0600 (CST) X-Virus-Scanned: amavisd-new at icecube.wisc.edu Received: from mail.icecube.wisc.edu ([127.0.0.1]) by localhost (trout.icecube.wisc.edu [127.0.0.1]) (amavisd-new, port 10030) with ESMTP id SwfS2IWdN6z5; Thu, 13 Jan 2011 10:17:01 -0600 (CST) Received: from comporellon.tachypleus.net (unknown [76.210.75.5]) by mail.icecube.wisc.edu (Postfix) with ESMTP id 4327D5811A; Thu, 13 Jan 2011 10:17:01 -0600 (CST) Message-ID: <4D2F257C.50005@freebsd.org> Date: Thu, 13 Jan 2011 10:17:00 -0600 From: Nathan Whitehorn User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.13) Gecko/20101214 Thunderbird/3.1.7 MIME-Version: 1.0 To: Super Bisquit References: <4D2DEC1B.3010208@freebsd.org> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: Unable to compile drm.ko on powerpc X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 16:17:02 -0000 AGP is derived from PCI, so AGP devices show up on the PCI bus. All the AGP kernel module does is provide hooks to manipulate some advanced features of the bus, mostly for the benefit of drm. -Nathan On 01/12/11 19:24, Super Bisquit wrote: > My graphics port is agp and not pci. It's a Quicksilver 2002 with a > 4x agp slot. > Now, how do I make it work? That's the problem I've been recently asking about. > Forgive me for bringing the next part here. > The PowerPC snapshot 9 for the 32bit ppc needs updating. The ports > tarball is behind. > > > On 1/12/11, Nathan Whitehorn wrote: >> On 01/12/11 02:39, Super Bisquit wrote: >>> http://slexy.org/view/s2NSVy7aTU >>> >>> The build also fails looking for machine/specialreg.h. This file is only >>> found on i386/amd64 processors. Drm.ko is needed by agp.ko. >> DRM is not required by AGP, rather the reverse, and DRM does not >> presently work on powerpc. The AGP kernel module also doesn't provide >> any useful features unless you are using DRM. You don't need either for >> graphics on powerpc machines. >> -Nathan >> _______________________________________________ >> freebsd-hackers@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers >> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" >> > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 17:46:43 2011 Return-Path: Delivered-To: hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D94461065670 for ; Thu, 13 Jan 2011 17:46:43 +0000 (UTC) (envelope-from rysto32@gmail.com) Received: from mail-ey0-f182.google.com (mail-ey0-f182.google.com [209.85.215.182]) by mx1.freebsd.org (Postfix) with ESMTP id 72B9E8FC16 for ; Thu, 13 Jan 2011 17:46:43 +0000 (UTC) Received: by eyf6 with SMTP id 6so985519eyf.13 for ; Thu, 13 Jan 2011 09:46:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=8CVSniCoKc0EagqUKN2JI3YFn7Ibt5vhW1yY1MOrenk=; b=cGXcPBU1bv1XE5mHzTXX6WzmDndczLk7ldRTytj3qltcTuNvAnGzymCsSgx2SIfgud mjsImwGk4G072ZHwBknE2TasTwFtFYBltDZAVewJUv7kkV/ZMm9NObJ0WrwVe9Ad1T3O yRMz2sVku2wu8Yy4q1wCdSb3oGYC/hUQY7os8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=U8GTqxUh5VQbeYbF0W5G2POJ1GCFKGmCfcosSo2+Thf2Mgk8Q2DMTkpeW3FPe/e/fx gkgvUOpsKI+ANoKzI7iy6s5Z+0crJONAri/BieQAf3J6BLoK//j7FwmWr7QzTf987NSf EsN3SRMUh0crsRTweXUXLnstpKEg61t03r8nc= MIME-Version: 1.0 Received: by 10.213.32.193 with SMTP id e1mr2516713ebd.74.1294939140195; Thu, 13 Jan 2011 09:19:00 -0800 (PST) Received: by 10.213.22.14 with HTTP; Thu, 13 Jan 2011 09:19:00 -0800 (PST) Date: Thu, 13 Jan 2011 12:19:00 -0500 Message-ID: From: Ryan Stone To: FreeBSD Hackers Content-Type: text/plain; charset=ISO-8859-1 Cc: Subject: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 17:46:43 -0000 I've been trying to get an application compiled with gcc 4.5.1 running on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. It turns out that the problem is that gcc is issuing SSE instructions(in my case, a movdqa) that assume that the stack will be aligned to a 16-byte boundary. It seems that Linux/i386 guarantees this, and I worry that gcc has extended this assumption to all i386 architectures. I'm assuming that FreeBSD doesn't make any such promises based on the fact that I'm getting crashes. There does seem to be a flag (-mstackrealign) that you can set to force gcc to align the stack to what it wants, but that pessimizes the generated code a bit. Some googling would seem to indicate that -mpreferred-stack-boundary won't always handle this problem correctly. Any ideas? My inclination, at least for our local source tree here at $WORK, would be to accommodate gcc and guarantee the stack alignment that it wants rather than pessimize our application. It seems we have an old local patch/hack in our FreeBSD 6.1 tree(apparently based on this: http://www.freebsd.org/cgi/getmsg.cgi?fetch=438552+0+/usr/local/www/db/text/2000/freebsd-current/20000507.freebsd-current). I believe that this patch is the reason why we haven't seen the problem when running on 6.1, but the patch doesn't seem to work anymore on 8.1. From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 19:06:25 2011 Return-Path: Delivered-To: hackers@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 2AEFB1065672; Thu, 13 Jan 2011 19:06:25 +0000 (UTC) Date: Thu, 13 Jan 2011 19:06:25 +0000 From: Alexander Best To: Ryan Stone Message-ID: <20110113190625.GA76352@freebsd.org> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Cc: FreeBSD Hackers Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 19:06:25 -0000 On Thu Jan 13 11, Ryan Stone wrote: > I've been trying to get an application compiled with gcc 4.5.1 running > on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. > It turns out that the problem is that gcc is issuing SSE > instructions(in my case, a movdqa) that assume that the stack will be > aligned to a 16-byte boundary. It seems that Linux/i386 guarantees > this, and I worry that gcc has extended this assumption to all i386 > architectures. I'm assuming that FreeBSD doesn't make any such > promises based on the fact that I'm getting crashes. > > There does seem to be a flag (-mstackrealign) that you can set to > force gcc to align the stack to what it wants, but that pessimizes the > generated code a bit. Some googling would seem to indicate that > -mpreferred-stack-boundary won't always handle this problem correctly. > > Any ideas? My inclination, at least for our local source tree here at > $WORK, would be to accommodate gcc and guarantee the stack alignment > that it wants rather than pessimize our application. It seems we have > an old local patch/hack in our FreeBSD 6.1 tree(apparently based on > this: http://www.freebsd.org/cgi/getmsg.cgi?fetch=438552+0+/usr/local/www/db/text/2000/freebsd-current/20000507.freebsd-current). > I believe that this patch is the reason why we haven't seen the > problem when running on 6.1, but the patch doesn't seem to work > anymore on 8.1. i'm experiencing a similar issue on amd64 with mplayer (svn snapshot) and gcc46: otaku% ./mplayer ~/filme/wiedhow.mkv MPlayer SVN-r32787-4.6.0 (C) 2000-2011 MPlayer Team 161 audio & 350 video codecs Playing /home/arundel/filme/wiedhow.mkv. zsh: illegal hardware instruction (core dumped) ./mplayer ~/filme/wiedhow.mkv otaku% echo $? 132 i'm not sure however, if both matters are related. gdb and 'bt' report: #0 0x0000000805327f03 in sscanf (str=0xa
, fmt=0x7fffffbffe60
) at /usr/subversion-src/lib/libc/stdio/sscanf.c:46 46 { [New Thread 80a407400 (LWP 105253/initial thread)] (gdb) bt #0 0x0000000805327f03 in sscanf (str=0xa
, fmt=0x7fffffbffe60
) at /usr/subversion-src/lib/libc/stdio/sscanf.c:46 #1 0x000000000062fa25 in vsscanf () #2 0x0000000805327f84 in sscanf (str=Variable "str" is not available. ) at /usr/subversion-src/lib/libc/stdio/sscanf.c:51 #3 0x000000000062fa25 in vsscanf () cheers. alex -- a13x From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 18:39:30 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 45E9C106564A for ; Thu, 13 Jan 2011 18:39:30 +0000 (UTC) (envelope-from lgj@usenix.org) Received: from lonestar.usenix.org (lonestar.usenix.org [131.106.3.102]) by mx1.freebsd.org (Postfix) with ESMTP id 2D9B68FC08 for ; Thu, 13 Jan 2011 18:39:30 +0000 (UTC) Received: from negroni.usenix.org (negroni.usenix.org [131.106.3.145]) (authenticated bits=0) by lonestar.usenix.org (8.14.2/8.14.2) with ESMTP id p0DIbUHq005011 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO) for ; Thu, 13 Jan 2011 10:39:29 -0800 (PST) From: Lionel Garth Jones Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Thu, 13 Jan 2011 10:39:29 -0800 Message-Id: <8F106AEB-554E-472A-B444-EED02B5E4FA8@usenix.org> To: freebsd-hackers@freebsd.org Mime-Version: 1.0 (Apple Message framework v1082) X-Mailer: Apple Mail (2.1082) X-DCC-USENIX-Metrics: lonestar; whitelist X-Spam-Status: No, score=0.7 required=6.0 tests=ALL_TRUSTED, FH_DATE_PAST_20XX autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on lonestar X-Mailman-Approved-At: Thu, 13 Jan 2011 19:06:55 +0000 Subject: HotPar '11 Submission Deadline: January 16, 2011 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 18:39:30 -0000 We are writing to remind you that the submission deadline for the 3rd USENIX Workshop on Hot Topics in Parallelism (HotPar '11) is quickly approaching. Please register your paper (submit your abstract) by Sunday, January 16, 2011, at 11:59 p.m. PST. http://www.usenix.org/hotpar11/cfpb/ HotPar '11 will bring together researchers and practitioners doing innovative work in the area of parallel computing. HotPar recognizes the broad impact of multicore computing and multithreaded processors, which are the pervasive computing platforms of the future. We seek relevant contributions in all fields, including application design, languages and compilers, systems, and architecture. We request submissions of position papers that propose new directions for research of products in these areas, advocate non-traditional approaches to the problems engendered by parallelism, or potentially generate controversy and discussion. More information and submission guidelines are available at http://www.usenix.org/hotpar11/cfpb/ We look forward to receiving your submissions! Sincerely, Michael McCool, Intel Mendel Rosenblum, Stanford University HotPar '11 Program Co-Chairs hotpar11chairs@usenix.org ------------------------------------------------------------------------ HotPar '11 Call for Papers 3rd USENIX Workshop on Hot Topics in Parallelism (HotPar '11) May 26-27, 2011, Berkeley, CA http://www.usenix.org/hotpar11/cfpb/ Paper registration (abstract submission) due: Sunday, January 16, 2011, 11:59 p.m. PST Paper submissions due: Tuesday, January 25, 2011, 11:59 p.m. PST ----------------------------------------------------------------------- From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 19:29:56 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5F280106566B for ; Thu, 13 Jan 2011 19:29:56 +0000 (UTC) (envelope-from se@FreeBSD.org) Received: from nm5.bullet.mail.sp2.yahoo.com (nm5.bullet.mail.sp2.yahoo.com [98.139.91.75]) by mx1.freebsd.org (Postfix) with SMTP id 3F9A28FC1D for ; Thu, 13 Jan 2011 19:29:56 +0000 (UTC) Received: from [98.139.91.63] by nm5.bullet.mail.sp2.yahoo.com with NNFMP; 13 Jan 2011 19:16:35 -0000 Received: from [98.136.185.47] by tm3.bullet.mail.sp2.yahoo.com with NNFMP; 13 Jan 2011 19:16:35 -0000 Received: from [127.0.0.1] by smtp108.mail.gq1.yahoo.com with NNFMP; 13 Jan 2011 19:16:35 -0000 X-Yahoo-Newman-Id: 16594.95375.bm@smtp108.mail.gq1.yahoo.com Received: from [192.168.119.19] (se@81.173.181.180 with plain) by smtp108.mail.gq1.yahoo.com with SMTP; 13 Jan 2011 11:16:34 -0800 PST X-Yahoo-SMTP: iDf2N9.swBDAhYEh7VHfpgq0lnq. X-YMail-OSG: HymDzi4VM1l8jWkxLd1sXdzavvPz6TlkqRHrK4sd9BQeNUw Ivg3Fy861E_Uan55in3Vu.donqMHjeyn5LN6qgouVj65ZEWgrFucQfZ1evWB zV8wes5ZrNCkirE9lz.Zyz3i1ZJSUxljvo7aQ3joeu5C020CJa2edh8gKN0j T0v9SVGdsx9Di.y6hs5GGOYYV_w0zsRRn_0FWE_zIDdzmvncQWyZkPk7xkio ggQ8SQKrQuSJkMVY_0JGhBJincZTEqA774lvj3UEBUk.IGEHjmdvbvAfFOxP 8J11YbpEZQCXETrSOQfUUjs5o_ueOeWeJnYsNRm.Nns_sI0tXqAonI67498R .Y1tVR5cdBvvqpHcX0Fy4mVjZ3A-- X-Yahoo-Newman-Property: ymail-3 Message-ID: <4D2F4F95.6020304@FreeBSD.org> Date: Thu, 13 Jan 2011 20:16:37 +0100 From: Stefan Esser User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.8.1.18) Gecko/20081105 Thunderbird/2.0.0.18 ThunderBrowse/3.2.2.1 Mnenhy/0.7.5.666 MIME-Version: 1.0 To: freebsd-hackers@freebsd.org References: <4D2E90C9.2010600@freebsd.org> In-Reply-To: <4D2E90C9.2010600@freebsd.org> X-Enigmail-Version: 1.1.1 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit Subject: Re: A question about "WARNING: attempt to domain_add(xyz) after domainfinalize()" X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 19:29:56 -0000 Am 13.01.2011 06:42, schrieb Julian Elischer: > On 1/12/11 5:26 AM, Svatopluk Kraus wrote: >> Hi, >> >> I'd like to add a new network domain into kernel (and never remove it) >> from loadable module. In fact, I did it, but I got following warning >> from domain_add(): "WARNING: attempt to domain_add(xyz) after >> domainfinalize()". Now, I try to figure out what is behind the >> warning, which seems to become KASSERT (now, in notyet section part of >> code, which is 6 years old). > > just ignore that message, everyone else does :-) Well, yes, but there are actual problems in the current code and it needs to be worked on. I checked the situation the last time the question arose about half a year ago, and there are races and real bugs (IIRC, you can only add one "domain" from a KLD, a second one will not be initialized). My spare time was (and to date is) very limited, but I still intend to prepare a fix (not sure whether the races can be completely avoided, but they are extremely hard to trigger since they only exist during module load). > teh problem is that the idea of domainfinalize() is incompatible with > having the ability to add domains from modules. > Luckily domain finalize doesn't actually do anything that stops your new > domain from working so it doesn't matter. Not exactly true: In fact, domainfinalize performs some init work for all domains and interfaces that have been compiled into the kernel. After domainfinalize has been called, this domain initialization (the initialization of pointers in the interface structure of all existing network devices) has to be performed by a call to the same code that domainfinalize calls in a loop for compiled in network interfaces. But there are checks in that code, which need to be checked and fixed. I had made annotations to the affected files, half a year ago, but do not have access to my development system right now and thus I cannot provide details, now. > you'll get the same message if you add netgraph.ko as an object. The netgraph domain is probably the only one that is often loaded from a KLD in generic systems. If another driver adds a domain and netgraph is also required, then I'd strongly suggest to compile netgraph into the kernel (and thus to have only one domain added from a KLD). Best regards, STefan From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 20:28:53 2011 Return-Path: Delivered-To: hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 666B110656AD for ; Thu, 13 Jan 2011 20:28:53 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id DB3728FC08 for ; Thu, 13 Jan 2011 20:28:52 +0000 (UTC) Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id p0DKSm0T065818 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 13 Jan 2011 22:28:48 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4) with ESMTP id p0DKSmDb081817; Thu, 13 Jan 2011 22:28:48 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4/Submit) id p0DKSmnL081816; Thu, 13 Jan 2011 22:28:48 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Thu, 13 Jan 2011 22:28:48 +0200 From: Kostik Belousov To: Ryan Stone Message-ID: <20110113202848.GI2518@deviant.kiev.zoral.com.ua> References: Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="/T+UM55GOh1Yge7W" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-3.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00, DNS_FROM_OPENWHOIS autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: FreeBSD Hackers Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 20:28:53 -0000 --/T+UM55GOh1Yge7W Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Jan 13, 2011 at 12:19:00PM -0500, Ryan Stone wrote: > I've been trying to get an application compiled with gcc 4.5.1 running > on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. > It turns out that the problem is that gcc is issuing SSE > instructions(in my case, a movdqa) that assume that the stack will be > aligned to a 16-byte boundary. It seems that Linux/i386 guarantees > this, and I worry that gcc has extended this assumption to all i386 > architectures. I'm assuming that FreeBSD doesn't make any such > promises based on the fact that I'm getting crashes. >=20 > There does seem to be a flag (-mstackrealign) that you can set to > force gcc to align the stack to what it wants, but that pessimizes the > generated code a bit. Some googling would seem to indicate that > -mpreferred-stack-boundary won't always handle this problem correctly. >=20 > Any ideas? My inclination, at least for our local source tree here at > $WORK, would be to accommodate gcc and guarantee the stack alignment > that it wants rather than pessimize our application. It seems we have > an old local patch/hack in our FreeBSD 6.1 tree(apparently based on > this: http://www.freebsd.org/cgi/getmsg.cgi?fetch=3D438552+0+/usr/local/w= ww/db/text/2000/freebsd-current/20000507.freebsd-current). > I believe that this patch is the reason why we haven't seen the > problem when running on 6.1, but the patch doesn't seem to work > anymore on 8.1. Look at lib/csu/i386-elf/crt1_s.S, we align stack on startup. My understanding is that the requirement is (%esp & 0xf) =3D=3D 0 just befo= re the call to the function. And we are off by 4 (this is my fault). Please give this a try. diff --git a/lib/csu/i386-elf/crt1_s.S b/lib/csu/i386-elf/crt1_s.S index d7ed0a2..17ac0e3 100644 --- a/lib/csu/i386-elf/crt1_s.S +++ b/lib/csu/i386-elf/crt1_s.S @@ -42,6 +42,7 @@ _start: .cfi_def_cfa_register %ebp andl $0xfffffff0,%esp # align stack leal 8(%ebp),%eax + subl $4,%esp pushl %eax # argv pushl 4(%ebp) # argc pushl %edx # rtld cleanup --/T+UM55GOh1Yge7W Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (FreeBSD) iEYEARECAAYFAk0vYH8ACgkQC3+MBN1Mb4jg2ACghtY+dXLJHNnfBuHpzJwkBZID Ve4AoNp18QlzNL9P/ZVNtakT0xmzAgLX =lm2n -----END PGP SIGNATURE----- --/T+UM55GOh1Yge7W-- From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 21:57:20 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 02CC0106564A for ; Thu, 13 Jan 2011 21:57:20 +0000 (UTC) (envelope-from joerg@britannica.bec.de) Received: from mo-p00-ob.rzone.de (mo-p00-ob.rzone.de [81.169.146.161]) by mx1.freebsd.org (Postfix) with ESMTP id 624508FC14 for ; Thu, 13 Jan 2011 21:57:19 +0000 (UTC) X-RZG-AUTH: :JiIXek6mfvEEUpFQdo7Fj1/zg48CFjWjQv0cW+St/nW/YPAwtil3kVlq3myX X-RZG-CLASS-ID: mo00 Received: from britannica.bec.de (dslb-088-074-063-088.pools.arcor-ip.net [88.74.63.88]) by post.strato.de (jimi mo49) (RZmta 24.9) with (DHE-RSA-AES128-SHA encrypted) ESMTP id Y05860n0DKCHm3 ; Thu, 13 Jan 2011 22:57:16 +0100 (MET) Received: by britannica.bec.de (sSMTP sendmail emulation); Thu, 13 Jan 2011 22:57:15 +0100 Date: Thu, 13 Jan 2011 22:57:15 +0100 From: Joerg Sonnenberger To: freebsd-hackers@freebsd.org, FreeBSD Hackers Message-ID: <20110113215713.GB5278@britannica.bec.de> Mail-Followup-To: freebsd-hackers@freebsd.org, FreeBSD Hackers References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) Cc: Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 21:57:20 -0000 On Thu, Jan 13, 2011 at 12:19:00PM -0500, Ryan Stone wrote: > I've been trying to get an application compiled with gcc 4.5.1 running > on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. > It turns out that the problem is that gcc is issuing SSE > instructions(in my case, a movdqa) that assume that the stack will be > aligned to a 16-byte boundary. It seems that Linux/i386 guarantees > this, and I worry that gcc has extended this assumption to all i386 > architectures. I'm assuming that FreeBSD doesn't make any such > promises based on the fact that I'm getting crashes. FreeBSD follows the original SYSV ABI. Linux at some point silently decided to redefine the ABI to fit their mindset. I think you want to use a combination of -mpreferred-stack-boundary=4 and -mincoming-stack-boundary=2. Joerg From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 22:00:58 2011 Return-Path: Delivered-To: hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3B0A1106564A for ; Thu, 13 Jan 2011 22:00:58 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id A8F3D8FC18 for ; Thu, 13 Jan 2011 22:00:56 +0000 (UTC) Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id p0DM0r4D072460 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 14 Jan 2011 00:00:53 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4) with ESMTP id p0DM0qnF083078 for ; Fri, 14 Jan 2011 00:00:52 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4/Submit) id p0DM0qxg083077 for hackers@freebsd.org; Fri, 14 Jan 2011 00:00:52 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Fri, 14 Jan 2011 00:00:52 +0200 From: Kostik Belousov To: FreeBSD Hackers Message-ID: <20110113220052.GL2518@deviant.kiev.zoral.com.ua> References: <20110113215713.GB5278@britannica.bec.de> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="VSJGZE3ajDCqFLUt" Content-Disposition: inline In-Reply-To: <20110113215713.GB5278@britannica.bec.de> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-3.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00, DNS_FROM_OPENWHOIS autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 22:00:58 -0000 --VSJGZE3ajDCqFLUt Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Jan 13, 2011 at 10:57:15PM +0100, Joerg Sonnenberger wrote: > On Thu, Jan 13, 2011 at 12:19:00PM -0500, Ryan Stone wrote: > > I've been trying to get an application compiled with gcc 4.5.1 running > > on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. > > It turns out that the problem is that gcc is issuing SSE > > instructions(in my case, a movdqa) that assume that the stack will be > > aligned to a 16-byte boundary. It seems that Linux/i386 guarantees > > this, and I worry that gcc has extended this assumption to all i386 > > architectures. I'm assuming that FreeBSD doesn't make any such > > promises based on the fact that I'm getting crashes. >=20 > FreeBSD follows the original SYSV ABI. Linux at some point silently > decided to redefine the ABI to fit their mindset. I think you want to > use a combination of -mpreferred-stack-boundary=3D4 and > -mincoming-stack-boundary=3D2. I think gcc [*] requires 16-byte alignment. Also, it follows the policy of not changing the stack alignment through the calls. What you see is a plain bug in FreeBSD, when a developer (me) tried to adopt to newer ABI but failed. * Might be not gcc in our tree, but definitely newer gcc releases. --VSJGZE3ajDCqFLUt Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (FreeBSD) iEYEARECAAYFAk0vdhQACgkQC3+MBN1Mb4j0SACgtUvjulBMeaNmpyWyg3Hv2UGP R7sAmwW4wOyAnlt9+EYIjXw71TR49W45 =W2jt -----END PGP SIGNATURE----- --VSJGZE3ajDCqFLUt-- From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 22:09:07 2011 Return-Path: Delivered-To: hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EE2941065679 for ; Thu, 13 Jan 2011 22:09:07 +0000 (UTC) (envelope-from joerg@britannica.bec.de) Received: from mo-p00-ob.rzone.de (mo-p00-ob.rzone.de [81.169.146.162]) by mx1.freebsd.org (Postfix) with ESMTP id 89BD18FC20 for ; Thu, 13 Jan 2011 22:09:07 +0000 (UTC) X-RZG-AUTH: :JiIXek6mfvEEUpFQdo7Fj1/zg48CFjWjQv0cW+St/nW/YPAwtil3kVlq3myX X-RZG-CLASS-ID: mo00 Received: from britannica.bec.de (dslb-088-074-063-088.pools.arcor-ip.net [88.74.63.88]) by post.strato.de (jimi mo49) (RZmta 24.9) with (DHE-RSA-AES128-SHA encrypted) ESMTP id Y05860n0DKCHm3 ; Thu, 13 Jan 2011 22:57:16 +0100 (MET) Received: by britannica.bec.de (sSMTP sendmail emulation); Thu, 13 Jan 2011 22:57:15 +0100 Date: Thu, 13 Jan 2011 22:57:15 +0100 From: Joerg Sonnenberger To: freebsd-hackers@freebsd.org, FreeBSD Hackers Message-ID: <20110113215713.GB5278@britannica.bec.de> Mail-Followup-To: freebsd-hackers@freebsd.org, FreeBSD Hackers References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) Cc: Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 22:09:08 -0000 On Thu, Jan 13, 2011 at 12:19:00PM -0500, Ryan Stone wrote: > I've been trying to get an application compiled with gcc 4.5.1 running > on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. > It turns out that the problem is that gcc is issuing SSE > instructions(in my case, a movdqa) that assume that the stack will be > aligned to a 16-byte boundary. It seems that Linux/i386 guarantees > this, and I worry that gcc has extended this assumption to all i386 > architectures. I'm assuming that FreeBSD doesn't make any such > promises based on the fact that I'm getting crashes. FreeBSD follows the original SYSV ABI. Linux at some point silently decided to redefine the ABI to fit their mindset. I think you want to use a combination of -mpreferred-stack-boundary=4 and -mincoming-stack-boundary=2. Joerg From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 22:53:56 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E1063106567A; Thu, 13 Jan 2011 22:53:56 +0000 (UTC) (envelope-from superbisquit@gmail.com) Received: from mail-qy0-f175.google.com (mail-qy0-f175.google.com [209.85.216.175]) by mx1.freebsd.org (Postfix) with ESMTP id 7CB828FC18; Thu, 13 Jan 2011 22:53:56 +0000 (UTC) Received: by qyk8 with SMTP id 8so5191401qyk.13 for ; Thu, 13 Jan 2011 14:53:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=ivBTf/TNrcU0F3tAirmfv/Mn6URfdWh7JwDldwbOK7U=; b=sU8QoYie5/u7d/Xo5R1xz0Syg91Fv01JBll/0fmnXL7RapWZXq5e9mmYINoh03yi7A gAMaD2fg/hcrbbtL6E7qU48ZHefdF51U1aRieF3IfKJZUPriiSVUmCWPCOOABNc59FwJ TptenCqDCjG+QLAakan2tQCm1BIBS96ValtYo= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=X/rjsL2c8YrJ8JVXJGqByyIZwVEBh4Kav9kOCLqgT8fdFwXt0iTooSHSbRTV2RG3lP XmOiT7uXchi0XPUhCPr7NAF7Ii9xKPdZeeaIOPAJ029J9BnsmqKAeVOxEzvZgU4J4XAy v42vqUrHORso8ma03ynboltSryJxauIFpNZwk= MIME-Version: 1.0 Received: by 10.229.220.83 with SMTP id hx19mr45445qcb.52.1294959235664; Thu, 13 Jan 2011 14:53:55 -0800 (PST) Received: by 10.220.187.7 with HTTP; Thu, 13 Jan 2011 14:53:55 -0800 (PST) In-Reply-To: <4D2F257C.50005@freebsd.org> References: <4D2DEC1B.3010208@freebsd.org> <4D2F257C.50005@freebsd.org> Date: Thu, 13 Jan 2011 17:53:55 -0500 Message-ID: From: Super Bisquit To: Nathan Whitehorn Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-hackers@freebsd.org Subject: Re: Unable to compile drm.ko on powerpc X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 22:53:57 -0000 I see this > Identifier "Card0" > Driver "ati" > VendorName "ATI Technologies Inc" > BoardName "Rage 128 PR/PRO AGP 4x TMDS" > BusID "PCI:0:16:0" > > From the October 2008 ppc mailing list. Am I going to need to configure X with AGP 4X in the board name section? The Quicksilver will have a reinstallation with 9.0 snapshot with ports grabbed by csup or portsnap. I'll post the results and crashes on the proper mailing list. On this mailing list, I'd still like to know the open firmware commands for switching default graphic slots. On Thu, Jan 13, 2011 at 11:17 AM, Nathan Whitehorn wrote: > AGP is derived from PCI, so AGP devices show up on the PCI bus. All the AGP > kernel module does is provide hooks to manipulate some advanced features of > the bus, mostly for the benefit of drm. > -Nathan > > > On 01/12/11 19:24, Super Bisquit wrote: > >> My graphics port is agp and not pci. It's a Quicksilver 2002 with a >> 4x agp slot. >> Now, how do I make it work? That's the problem I've been recently asking >> about. >> Forgive me for bringing the next part here. >> The PowerPC snapshot 9 for the 32bit ppc needs updating. The ports >> tarball is behind. >> >> >> On 1/12/11, Nathan Whitehorn wrote: >> >>> On 01/12/11 02:39, Super Bisquit wrote: >>> >>>> http://slexy.org/view/s2NSVy7aTU >>>> >>>> The build also fails looking for machine/specialreg.h. This file is only >>>> found on i386/amd64 processors. Drm.ko is needed by agp.ko. >>>> >>> DRM is not required by AGP, rather the reverse, and DRM does not >>> presently work on powerpc. The AGP kernel module also doesn't provide >>> any useful features unless you are using DRM. You don't need either for >>> graphics on powerpc machines. >>> -Nathan >>> _______________________________________________ >>> freebsd-hackers@freebsd.org mailing list >>> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers >>> To unsubscribe, send any mail to " >>> freebsd-hackers-unsubscribe@freebsd.org" >>> >>> _______________________________________________ >> freebsd-hackers@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers >> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org >> " >> > > From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 22:55:00 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5F0271065672 for ; Thu, 13 Jan 2011 22:55:00 +0000 (UTC) (envelope-from rysto32@gmail.com) Received: from mail-ew0-f54.google.com (mail-ew0-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id E8D3F8FC24 for ; Thu, 13 Jan 2011 22:54:59 +0000 (UTC) Received: by ewy24 with SMTP id 24so1171585ewy.13 for ; Thu, 13 Jan 2011 14:54:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=j7RXUhKvLSnqBsd45XNsT0+/CLlJ2pn8tVjBtKzlwnI=; b=qsiVZyh4m5Vt7EuIOQGOLGP0SfNSDVwQJmezcECIaLf8Qt9SEuqmYcG70lk662+hVm 1f/GhCxqk96DtkxrLjCyGSRjCvHKoGTMxk3QuQ3kbrjoDc1OWBAjzR3RpV85rBp7p4O6 WzXdlpUeRaGiZPlojlXd4x6RARtpRUz/cJdyc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=gh/8jYafsuSrEAm1J78WTiLU05ZzjARfuAqvdjXBApxq8mHlWsNJ2qzMdk93ttzPMD W9l39j2eDv9hv6vlBJRB12lsMo5ObakJWpTNbhaLqqp7EMqmJ/SzUzxEdKa9Qf/wD8HV nP7PWlfixolv3ILl/YURtdyWKyyHG16gADplI= MIME-Version: 1.0 Received: by 10.213.33.74 with SMTP id g10mr165850ebd.61.1294957892928; Thu, 13 Jan 2011 14:31:32 -0800 (PST) Received: by 10.213.22.14 with HTTP; Thu, 13 Jan 2011 14:31:32 -0800 (PST) In-Reply-To: <20110113202848.GI2518@deviant.kiev.zoral.com.ua> References: <20110113202848.GI2518@deviant.kiev.zoral.com.ua> Date: Thu, 13 Jan 2011 17:31:32 -0500 Message-ID: From: Ryan Stone To: Kostik Belousov Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-hackers@freebsd.org Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 22:55:00 -0000 On Thu, Jan 13, 2011 at 3:28 PM, Kostik Belousov wrote: > > Please give this a try. > Your patch resolved the issue for me. Thanks for the quick reply. From owner-freebsd-hackers@FreeBSD.ORG Thu Jan 13 23:38:35 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E7986106566C for ; Thu, 13 Jan 2011 23:38:35 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from esa-jnhn.mail.uoguelph.ca (esa-jnhn.mail.uoguelph.ca [131.104.91.44]) by mx1.freebsd.org (Postfix) with ESMTP id A88718FC15 for ; Thu, 13 Jan 2011 23:38:35 +0000 (UTC) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApwEAC8bL02DaFvO/2dsb2JhbACECKE4rnKNZoEhgzd0BIRohiiLMw X-IronPort-AV: E=Sophos;i="4.60,320,1291611600"; d="scan'208";a="107012597" Received: from erie.cs.uoguelph.ca (HELO zcs3.mail.uoguelph.ca) ([131.104.91.206]) by esa-jnhn-pri.mail.uoguelph.ca with ESMTP; 13 Jan 2011 18:38:34 -0500 Received: from zcs3.mail.uoguelph.ca (localhost.localdomain [127.0.0.1]) by zcs3.mail.uoguelph.ca (Postfix) with ESMTP id 0459AB3FA2; Thu, 13 Jan 2011 18:38:34 -0500 (EST) Date: Thu, 13 Jan 2011 18:38:34 -0500 (EST) From: Rick Macklem To: Daniel Braniss Message-ID: <1620435629.209827.1294961913954.JavaMail.root@erie.cs.uoguelph.ca> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Originating-IP: [172.17.91.201] X-Mailer: Zimbra 6.0.10_GA_2692 (ZimbraWebClient - IE8 (Win)/6.0.10_GA_2692) Cc: freebsd-hackers@freebsd.org Subject: Re: NFS: file too large X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Jan 2011 23:38:36 -0000 > > > I'm getting 'File too large' when copying via NFS(v3, tcp/udp) a > > > file > > > that is larger than 1T. The server is ZFS which has no problem > > > with > > > large > > > files. > > > > > > Is this fixable? > > > > > As I understand it, there is no FreeBSD VFSop that returns the > > maximum > > file size supported. As such, the NFS servers just take a guess. > > > > You can either switch to the experimental NFS server, which guesses > > the > > largest size expressed in 64bits. > > OR > > You can edit sys/nfsserver/nfs_serv.c and change the assignment of a > > value to > > maxfsize = XXX; > > at around line #3671 to a larger value. > > > > I didn't check to see if there are additional restrictions in the > > clients. (They should believe what the server says it can support.) > > > > rick > > well, after some more experimentation, it sees to be a FreeBSD client > issue. > if the client is linux there is no problem. > Try editting line #1226 of sys/nfsclient/nfs_vfsops.c, where it sets nm_maxfilesize = (u_int64_t)0x80000000 * DEV_BSIZE - 1; and make it something larger. I have no idea why the limit is set that way? (I'm guessing it was the limit for UFS.) Hopefully not some weird buffer cache restriction or similar, but you'll find out when you try increasing it.:-) I think I'll ask freebsd-fs@ about increasing this for NFSv3 and 4, since the server does provide a limit. (The client currently only reduces nm_maxfilesize from the above initial value using the server's limit.) Just "grep nm_maxfilesize *.c" in sys/nfsclient and you'll see it. > BTW, I 'think' I'm using the experimental server, but how can I be > sure? > I have the -e set for both nfs_server and mountd, I don't have option > NFSD, > but the nfsd.ko gets loaded. You can check by: # nfsstat -s # nfsstat -e -s and see which one reports non-zero RPC counts. If you happen to be running the regular server (probably not, given the above), you need to edit the server code as well as the client side. Good luck with it, rick From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 03:38:41 2011 Return-Path: Delivered-To: freebsd-hackers@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 08746106564A for ; Fri, 14 Jan 2011 03:38:41 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 9E0158FC25 for ; Fri, 14 Jan 2011 03:38:40 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id p0DNYMXc090288 for ; Thu, 13 Jan 2011 16:34:23 -0700 (MST) (envelope-from imp@bsdimp.com) Message-ID: <4D2F8BFE.9070607@bsdimp.com> Date: Thu, 13 Jan 2011 16:34:22 -0700 From: Warner Losh User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101029 Thunderbird/3.1.6 MIME-Version: 1.0 To: freebsd-hackers@FreeBSD.org References: <20110113202848.GI2518@deviant.kiev.zoral.com.ua> In-Reply-To: <20110113202848.GI2518@deviant.kiev.zoral.com.ua> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 03:38:41 -0000 On 01/13/2011 13:28, Kostik Belousov wrote: > On Thu, Jan 13, 2011 at 12:19:00PM -0500, Ryan Stone wrote: >> I've been trying to get an application compiled with gcc 4.5.1 running >> on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. >> It turns out that the problem is that gcc is issuing SSE >> instructions(in my case, a movdqa) that assume that the stack will be >> aligned to a 16-byte boundary. It seems that Linux/i386 guarantees >> this, and I worry that gcc has extended this assumption to all i386 >> architectures. I'm assuming that FreeBSD doesn't make any such >> promises based on the fact that I'm getting crashes. >> >> There does seem to be a flag (-mstackrealign) that you can set to >> force gcc to align the stack to what it wants, but that pessimizes the >> generated code a bit. Some googling would seem to indicate that >> -mpreferred-stack-boundary won't always handle this problem correctly. >> >> Any ideas? My inclination, at least for our local source tree here at >> $WORK, would be to accommodate gcc and guarantee the stack alignment >> that it wants rather than pessimize our application. It seems we have >> an old local patch/hack in our FreeBSD 6.1 tree(apparently based on >> this: http://www.freebsd.org/cgi/getmsg.cgi?fetch=438552+0+/usr/local/www/db/text/2000/freebsd-current/20000507.freebsd-current). >> I believe that this patch is the reason why we haven't seen the >> problem when running on 6.1, but the patch doesn't seem to work >> anymore on 8.1. > Look at lib/csu/i386-elf/crt1_s.S, we align stack on startup. > My understanding is that the requirement is (%esp& 0xf) == 0 just before > the call to the function. And we are off by 4 (this is my fault). > > Please give this a try. > > diff --git a/lib/csu/i386-elf/crt1_s.S b/lib/csu/i386-elf/crt1_s.S > index d7ed0a2..17ac0e3 100644 > --- a/lib/csu/i386-elf/crt1_s.S > +++ b/lib/csu/i386-elf/crt1_s.S > @@ -42,6 +42,7 @@ _start: > .cfi_def_cfa_register %ebp > andl $0xfffffff0,%esp # align stack > leal 8(%ebp),%eax > + subl $4,%esp > pushl %eax # argv > pushl 4(%ebp) # argc > pushl %edx # rtld cleanup I'm seeing weird core dumps for ssh and friends on i386 on stable/8 from a few days ago. Could that be related? Warner From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 04:55:50 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A6677106566B for ; Fri, 14 Jan 2011 04:55:50 +0000 (UTC) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by mx1.freebsd.org (Postfix) with ESMTP id 71DAE8FC08 for ; Fri, 14 Jan 2011 04:55:50 +0000 (UTC) Received: from apollo.backplane.com (localhost [127.0.0.1]) by apollo.backplane.com (8.14.4/8.14.1) with ESMTP id p0E4tNoH067766; Thu, 13 Jan 2011 20:55:23 -0800 (PST) Received: (from dillon@localhost) by apollo.backplane.com (8.14.4/8.13.4/Submit) id p0E4tMvG067765; Thu, 13 Jan 2011 20:55:22 -0800 (PST) Date: Thu, 13 Jan 2011 20:55:22 -0800 (PST) From: Matthew Dillon Message-Id: <201101140455.p0E4tMvG067765@apollo.backplane.com> To: Rick Macklem References: <1620435629.209827.1294961913954.JavaMail.root@erie.cs.uoguelph.ca> Cc: freebsd-hackers@freebsd.org Subject: Re: NFS: file too large X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 04:55:50 -0000 :Try editting line #1226 of sys/nfsclient/nfs_vfsops.c, where :it sets nm_maxfilesize = (u_int64_t)0x80000000 * DEV_BSIZE - 1; and make it :something larger. : :I have no idea why the limit is set that way? (I'm guessing it was the :limit for UFS.) Hopefully not some weird buffer cache restriction or :similar, but you'll find out when you try increasing it.:-) This is a throwback to when the buffer cache used 32 bit block numbers, hence 0x7FFFFFFF was the maximum 'safe' block number multiplied by the lowest supported block size (DEV_BSIZE), that could be handled by the buffer cache. That limit is completely irrelevant now and should probably be set to 0x7FFFFFFFFFFFFFFFLLU (since seek offsets are signed). -Matt Matthew Dillon From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 07:57:54 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EAB07106566C; Fri, 14 Jan 2011 07:57:54 +0000 (UTC) (envelope-from joerg@britannica.bec.de) Received: from mo-p00-ob.rzone.de (mo-p00-ob.rzone.de [81.169.146.162]) by mx1.freebsd.org (Postfix) with ESMTP id 5A1618FC1C; Fri, 14 Jan 2011 07:57:53 +0000 (UTC) X-RZG-AUTH: :JiIXek6mfvEEUpFQdo7Fj1/zg48CFjWjQv0cW+St/nW/YPAwtil3kVlq3myX X-RZG-CLASS-ID: mo00 Received: from britannica.bec.de (dslb-088-074-063-088.pools.arcor-ip.net [88.74.63.88]) by post.strato.de (jimi mo35) (RZmta 24.9) with (DHE-RSA-AES128-SHA encrypted) ESMTP id a0531dn0E5YeW2 ; Fri, 14 Jan 2011 08:57:51 +0100 (MET) Received: by britannica.bec.de (sSMTP sendmail emulation); Fri, 14 Jan 2011 08:57:51 +0100 Date: Fri, 14 Jan 2011 08:57:51 +0100 From: Joerg Sonnenberger To: freebsd-hackers@freebsd.org, FreeBSD Hackers Message-ID: <20110114075751.GA9961@britannica.bec.de> Mail-Followup-To: freebsd-hackers@freebsd.org, FreeBSD Hackers References: <20110113215713.GB5278@britannica.bec.de> <20110113220052.GL2518@deviant.kiev.zoral.com.ua> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110113220052.GL2518@deviant.kiev.zoral.com.ua> User-Agent: Mutt/1.5.20 (2009-06-14) Cc: Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 07:57:55 -0000 On Fri, Jan 14, 2011 at 12:00:52AM +0200, Kostik Belousov wrote: > On Thu, Jan 13, 2011 at 10:57:15PM +0100, Joerg Sonnenberger wrote: > > On Thu, Jan 13, 2011 at 12:19:00PM -0500, Ryan Stone wrote: > > > I've been trying to get an application compiled with gcc 4.5.1 running > > > on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. > > > It turns out that the problem is that gcc is issuing SSE > > > instructions(in my case, a movdqa) that assume that the stack will be > > > aligned to a 16-byte boundary. It seems that Linux/i386 guarantees > > > this, and I worry that gcc has extended this assumption to all i386 > > > architectures. I'm assuming that FreeBSD doesn't make any such > > > promises based on the fact that I'm getting crashes. > > > > FreeBSD follows the original SYSV ABI. Linux at some point silently > > decided to redefine the ABI to fit their mindset. I think you want to > > use a combination of -mpreferred-stack-boundary=4 and > > -mincoming-stack-boundary=2. > > I think gcc [*] requires 16-byte alignment. Also, it follows the > policy of not changing the stack alignment through the calls. Well, yes. GCC decided to force the Linux ABI change down our throat. It's not an issue if you decide to rebuild all your libraries every week, but it is a major PITA if you deal with old binary-only releases. Joerg From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 07:57:54 2011 Return-Path: Delivered-To: hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EAB07106566C; Fri, 14 Jan 2011 07:57:54 +0000 (UTC) (envelope-from joerg@britannica.bec.de) Received: from mo-p00-ob.rzone.de (mo-p00-ob.rzone.de [81.169.146.162]) by mx1.freebsd.org (Postfix) with ESMTP id 5A1618FC1C; Fri, 14 Jan 2011 07:57:53 +0000 (UTC) X-RZG-AUTH: :JiIXek6mfvEEUpFQdo7Fj1/zg48CFjWjQv0cW+St/nW/YPAwtil3kVlq3myX X-RZG-CLASS-ID: mo00 Received: from britannica.bec.de (dslb-088-074-063-088.pools.arcor-ip.net [88.74.63.88]) by post.strato.de (jimi mo35) (RZmta 24.9) with (DHE-RSA-AES128-SHA encrypted) ESMTP id a0531dn0E5YeW2 ; Fri, 14 Jan 2011 08:57:51 +0100 (MET) Received: by britannica.bec.de (sSMTP sendmail emulation); Fri, 14 Jan 2011 08:57:51 +0100 Date: Fri, 14 Jan 2011 08:57:51 +0100 From: Joerg Sonnenberger To: freebsd-hackers@freebsd.org, FreeBSD Hackers Message-ID: <20110114075751.GA9961@britannica.bec.de> Mail-Followup-To: freebsd-hackers@freebsd.org, FreeBSD Hackers References: <20110113215713.GB5278@britannica.bec.de> <20110113220052.GL2518@deviant.kiev.zoral.com.ua> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110113220052.GL2518@deviant.kiev.zoral.com.ua> User-Agent: Mutt/1.5.20 (2009-06-14) Cc: Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 07:57:55 -0000 On Fri, Jan 14, 2011 at 12:00:52AM +0200, Kostik Belousov wrote: > On Thu, Jan 13, 2011 at 10:57:15PM +0100, Joerg Sonnenberger wrote: > > On Thu, Jan 13, 2011 at 12:19:00PM -0500, Ryan Stone wrote: > > > I've been trying to get an application compiled with gcc 4.5.1 running > > > on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. > > > It turns out that the problem is that gcc is issuing SSE > > > instructions(in my case, a movdqa) that assume that the stack will be > > > aligned to a 16-byte boundary. It seems that Linux/i386 guarantees > > > this, and I worry that gcc has extended this assumption to all i386 > > > architectures. I'm assuming that FreeBSD doesn't make any such > > > promises based on the fact that I'm getting crashes. > > > > FreeBSD follows the original SYSV ABI. Linux at some point silently > > decided to redefine the ABI to fit their mindset. I think you want to > > use a combination of -mpreferred-stack-boundary=4 and > > -mincoming-stack-boundary=2. > > I think gcc [*] requires 16-byte alignment. Also, it follows the > policy of not changing the stack alignment through the calls. Well, yes. GCC decided to force the Linux ABI change down our throat. It's not an issue if you decide to rebuild all your libraries every week, but it is a major PITA if you deal with old binary-only releases. Joerg From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 09:01:55 2011 Return-Path: Delivered-To: freebsd-hackers@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8E5B4106566B for ; Fri, 14 Jan 2011 09:01:55 +0000 (UTC) (envelope-from peter.blok@bsd4all.org) Received: from relay10.prolocation.net (relay10.prolocation.net [IPv6:2a00:d00:ff:133:94:228:133:100]) by mx1.freebsd.org (Postfix) with ESMTP id C46F48FC24 for ; Fri, 14 Jan 2011 09:01:54 +0000 (UTC) Received: from cust-95-128-94-66.breedbanddelft.nl ([95.128.94.66] helo=mail.bsd4all.org) by relay10.prolocation.net with esmtp (Exim 4.69) (envelope-from ) id 1PdfXe-0005uX-2o; Fri, 14 Jan 2011 10:01:54 +0100 Received: from mailgw (mailgw [192.168.10.12]) by mail.bsd4all.org (Postfix) with ESMTP id 493381152E; Fri, 14 Jan 2011 10:01:48 +0100 (CET) X-Virus-Scanned: amavisd-new at bsd4all.org Received: from mail.bsd4all.org ([192.168.10.1]) by mailgw (fwgw.homebrew.bsd4all.org [192.168.10.12]) (amavisd-new, port 10024) with ESMTP id RUChvQgXCzZG; Fri, 14 Jan 2011 10:01:36 +0100 (CET) Received: from bsd4all.org (adexlinge10 [192.168.10.16]) by mail.bsd4all.org (Postfix) with ESMTP id 42275114B0; Fri, 14 Jan 2011 10:01:36 +0100 (CET) Received: from 128.222.37.58 ([128.222.37.58]) by adexlinge10.LINGE10.local ([192.168.10.16]) with Microsoft Exchange Server HTTP-DAV ; Fri, 14 Jan 2011 08:58:35 +0000 User-Agent: Microsoft-Entourage/12.26.0.100708 Date: Fri, 14 Jan 2011 09:52:34 +0100 From: Peter Blok To: Warner Losh , Message-ID: Thread-Topic: What does the FreeBSD/i386 ABI say about stack alignment? Thread-Index: AcuzyGKkPQk+EXqxs0KcmFccelbB7A== In-Reply-To: <4D2F8BFE.9070607@bsdimp.com> Mime-version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 09:01:55 -0000 Hi, I=B9m probably missing something but if you require a stack variable to be aligned why not use a type attribute like __attribute__ ((aligned (8))) Peter On 1/14/11 00:34 AM, "Warner Losh" wrote: > On 01/13/2011 13:28, Kostik Belousov wrote: >> > On Thu, Jan 13, 2011 at 12:19:00PM -0500, Ryan Stone wrote: >>> >> I've been trying to get an application compiled with gcc 4.5.1 runni= ng >>> >> on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. >>> >> It turns out that the problem is that gcc is issuing SSE >>> >> instructions(in my case, a movdqa) that assume that the stack will b= e >>> >> aligned to a 16-byte boundary. It seems that Linux/i386 guarantees >>> >> this, and I worry that gcc has extended this assumption to all i386 >>> >> architectures. I'm assuming that FreeBSD doesn't make any such >>> >> promises based on the fact that I'm getting crashes. >>> >> >>> >> There does seem to be a flag (-mstackrealign) that you can set to >>> >> force gcc to align the stack to what it wants, but that pessimizes t= he >>> >> generated code a bit. Some googling would seem to indicate that >>> >> -mpreferred-stack-boundary won't always handle this problem correctl= y. >>> >> >>> >> Any ideas? My inclination, at least for our local source tree here = at >>> >> $WORK, would be to accommodate gcc and guarantee the stack alignment >>> >> that it wants rather than pessimize our application. It seems we ha= ve >>> >> an old local patch/hack in our FreeBSD 6.1 tree(apparently based on >>> >> this:=20 >>> http://www.freebsd.org/cgi/getmsg.cgi?fetch=3D438552+0+/usr/local/www/db/= text/ >>> 2000/freebsd-current/20000507.freebsd-current). >>> >> I believe that this patch is the reason why we haven't seen the >>> >> problem when running on 6.1, but the patch doesn't seem to work >>> >> anymore on 8.1. >> > Look at lib/csu/i386-elf/crt1_s.S, we align stack on startup. >> > My understanding is that the requirement is (%esp& 0xf) =3D=3D 0 just bef= ore >> > the call to the function. And we are off by 4 (this is my fault). >> > >> > Please give this a try. >> > >> > diff --git a/lib/csu/i386-elf/crt1_s.S b/lib/csu/i386-elf/crt1_s.S >> > index d7ed0a2..17ac0e3 100644 >> > --- a/lib/csu/i386-elf/crt1_s.S >> > +++ b/lib/csu/i386-elf/crt1_s.S >> > @@ -42,6 +42,7 @@ _start: >> > .cfi_def_cfa_register %ebp >> > andl $0xfffffff0,%esp # align stack >> > leal 8(%ebp),%eax >> > + subl $4,%esp >> > pushl %eax # argv >> > pushl 4(%ebp) # argc >> > pushl %edx # rtld cleanup >=20 > I'm seeing weird core dumps for ssh and friends on i386 on stable/8 from > a few days ago. Could that be related? >=20 > Warner >=20 > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org= " From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 09:03:07 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 698851065670 for ; Fri, 14 Jan 2011 09:03:07 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id F2B6D8FC1F for ; Fri, 14 Jan 2011 09:03:06 +0000 (UTC) Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id p0E8Shie041873 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 14 Jan 2011 10:28:43 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4) with ESMTP id p0E8Sedj086562; Fri, 14 Jan 2011 10:28:40 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4/Submit) id p0E8SeSj086561; Fri, 14 Jan 2011 10:28:40 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Fri, 14 Jan 2011 10:28:40 +0200 From: Kostik Belousov To: Warner Losh Message-ID: <20110114082840.GM2518@deviant.kiev.zoral.com.ua> References: <20110113202848.GI2518@deviant.kiev.zoral.com.ua> <4D2F8BFE.9070607@bsdimp.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="2DT8m24oj8Onh3Jp" Content-Disposition: inline In-Reply-To: <4D2F8BFE.9070607@bsdimp.com> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-3.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00, DNS_FROM_OPENWHOIS autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: freebsd-hackers@freebsd.org Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 09:03:07 -0000 --2DT8m24oj8Onh3Jp Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Jan 13, 2011 at 04:34:22PM -0700, Warner Losh wrote: > On 01/13/2011 13:28, Kostik Belousov wrote: > >On Thu, Jan 13, 2011 at 12:19:00PM -0500, Ryan Stone wrote: > >>I've been trying to get an application compiled with gcc 4.5.1 running > >>on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. > >>It turns out that the problem is that gcc is issuing SSE > >>instructions(in my case, a movdqa) that assume that the stack will be > >>aligned to a 16-byte boundary. It seems that Linux/i386 guarantees > >>this, and I worry that gcc has extended this assumption to all i386 > >>architectures. I'm assuming that FreeBSD doesn't make any such > >>promises based on the fact that I'm getting crashes. > >> > >>There does seem to be a flag (-mstackrealign) that you can set to > >>force gcc to align the stack to what it wants, but that pessimizes the > >>generated code a bit. Some googling would seem to indicate that > >>-mpreferred-stack-boundary won't always handle this problem correctly. > >> > >>Any ideas? My inclination, at least for our local source tree here at > >>$WORK, would be to accommodate gcc and guarantee the stack alignment > >>that it wants rather than pessimize our application. It seems we have > >>an old local patch/hack in our FreeBSD 6.1 tree(apparently based on > >>this:=20 > >>http://www.freebsd.org/cgi/getmsg.cgi?fetch=3D438552+0+/usr/local/www/d= b/text/2000/freebsd-current/20000507.freebsd-current). > >> I believe that this patch is the reason why we haven't seen the > >>problem when running on 6.1, but the patch doesn't seem to work > >>anymore on 8.1. > >Look at lib/csu/i386-elf/crt1_s.S, we align stack on startup. > >My understanding is that the requirement is (%esp& 0xf) =3D=3D 0 just b= efore > >the call to the function. And we are off by 4 (this is my fault). > > > >Please give this a try. > > > >diff --git a/lib/csu/i386-elf/crt1_s.S b/lib/csu/i386-elf/crt1_s.S > >index d7ed0a2..17ac0e3 100644 > >--- a/lib/csu/i386-elf/crt1_s.S > >+++ b/lib/csu/i386-elf/crt1_s.S > >@@ -42,6 +42,7 @@ _start: > > .cfi_def_cfa_register %ebp > > andl $0xfffffff0,%esp # align stack > > leal 8(%ebp),%eax > >+ subl $4,%esp > > pushl %eax # argv > > pushl 4(%ebp) # argc > > pushl %edx # rtld cleanup >=20 > I'm seeing weird core dumps for ssh and friends on i386 on stable/8 from= =20 > a few days ago. Could that be related? Few days ago ? It was in the tree for probably one year. I very much doubt it, but cannot say anything until you show the backtrace. Our in-tree gcc masks this by typically doing stack realignment on the entry into the main(). --2DT8m24oj8Onh3Jp Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (FreeBSD) iEYEARECAAYFAk0wCTgACgkQC3+MBN1Mb4hINQCdGcmAJ6uHU1M6NHM6CNWbzVdK 9qIAoJd6sIfWp6vqc2MeaxS4be8KmVYH =EAQ3 -----END PGP SIGNATURE----- --2DT8m24oj8Onh3Jp-- From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 09:26:31 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8311D10656C5 for ; Fri, 14 Jan 2011 09:26:31 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from kabab.cs.huji.ac.il (kabab.cs.huji.ac.il [132.65.16.84]) by mx1.freebsd.org (Postfix) with ESMTP id 3BB108FC14 for ; Fri, 14 Jan 2011 09:26:31 +0000 (UTC) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1PdfvR-000LQE-PM; Fri, 14 Jan 2011 11:26:29 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: Matthew Dillon In-reply-to: <201101140455.p0E4tMvG067765@apollo.backplane.com> References: <1620435629.209827.1294961913954.JavaMail.root@erie.cs.uoguelph.ca> <201101140455.p0E4tMvG067765@apollo.backplane.com> Comments: In-reply-to Matthew Dillon message dated "Thu, 13 Jan 2011 20:55:22 -0800." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 14 Jan 2011 11:26:29 +0200 From: Daniel Braniss Message-ID: Cc: freebsd-hackers@freebsd.org, Rick Macklem Subject: Re: NFS: file too large X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 09:26:31 -0000 > :Try editting line #1226 of sys/nfsclient/nfs_vfsops.c, where > :it sets nm_maxfilesize = (u_int64_t)0x80000000 * DEV_BSIZE - 1; and make it > :something larger. > : > :I have no idea why the limit is set that way? (I'm guessing it was the > :limit for UFS.) Hopefully not some weird buffer cache restriction or > :similar, but you'll find out when you try increasing it.:-) > > This is a throwback to when the buffer cache used 32 bit block numbers, > hence 0x7FFFFFFF was the maximum 'safe' block number multiplied by > the lowest supported block size (DEV_BSIZE), that could be handled by > the buffer cache. > > That limit is completely irrelevant now and should probably be set to > 0x7FFFFFFFFFFFFFFFLLU (since seek offsets are signed). I just did that and it fixes the problem. BTW, why not make away with the test altogether? Cheers and thanks, danny From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 10:37:13 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 14FDB1065698 for ; Fri, 14 Jan 2011 10:37:13 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from kabab.cs.huji.ac.il (kabab.cs.huji.ac.il [132.65.16.84]) by mx1.freebsd.org (Postfix) with ESMTP id C6D738FC20 for ; Fri, 14 Jan 2011 10:37:12 +0000 (UTC) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1Pdh1r-000MPA-G3 for freebsd-hackers@freebsd.org; Fri, 14 Jan 2011 12:37:11 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: freebsd-hackers@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 14 Jan 2011 12:37:11 +0200 From: Daniel Braniss Message-ID: Subject: more gpart/glabel problems X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 10:37:13 -0000 the provider in this case is mfid0 mfi0: mfid0: on mfi0 mfid0: 953344MB (1952448512 sectors) RAID volume 'r0' is optimal so I first use gpart: gpart create -s GPT mfid0 gpart bootcode -b /boot/pmbr mfid0 gpart add -s2G -t freebsd-ufs mfid0 so far, so good: gpart show => 34 1952448445 mfid0 GPT (931G) 34 128 1 freebsd-boot (64K) 162 4194304 2 freebsd-ufs (2.0G) 4194466 1948254013 - free - (929G) now: glabel lable r0 mfid0 and on the console: GEOM: mfid0: the secondary GPT table is corrupt or invalid. GEOM: mfid0: using the primary only -- recovery suggested. GEOM: mfid0: the secondary GPT table is corrupt or invalid. GEOM: mfid0: using the primary only -- recovery suggested. GEOM: label/r0: corrupt or invalid GPT detected. GEOM: label/r0: GPT rejected -- may not be recoverable. BTW, going the MBR way, it works as expected. so what am I doing wrong? thanks, danny From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 10:43:43 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DDD57106566C for ; Fri, 14 Jan 2011 10:43:43 +0000 (UTC) (envelope-from aryeh.friedman@gmail.com) Received: from mail-gw0-f54.google.com (mail-gw0-f54.google.com [74.125.83.54]) by mx1.freebsd.org (Postfix) with ESMTP id 9D8E98FC13 for ; Fri, 14 Jan 2011 10:43:43 +0000 (UTC) Received: by gwj21 with SMTP id 21so1093552gwj.13 for ; Fri, 14 Jan 2011 02:43:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=a9cXi2skiHNVzUjJpXtCojJSg86B9+GdDA6bZhf/MCI=; b=kNRUKjQV1p9IANwLZQWkb4H/8nhDSdE05QconswnN4F/vosp6Ll0u07C6xMc6kc+Jp YTB+Zdc31KDRqIjh9u+rRBA1068HZWIx6JvI3bg3K9lxWtUfm9HRtkoPlTLlZtDIHE5g iXxvXkgym7NWl4dDlCSQfWXCHSxjNhYxuRs2I= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=lUsxOrIJxM/fqOIIfasRswKbyQqEAkIXm2oMT+reiem6S1JlU3fPN9r3DKjxrLVNOy crO920McU7bj9YTWUwS6qypKJzNWbOSM7saHxJ13lFMuSQAL1cBqqJ7FjJYjvjhmka1d hvLF56NOEn89bp0kKTDBax9Ca7/VhCc7Pobz0= MIME-Version: 1.0 Received: by 10.236.108.41 with SMTP id p29mr1157248yhg.54.1295000395218; Fri, 14 Jan 2011 02:19:55 -0800 (PST) Received: by 10.236.110.10 with HTTP; Fri, 14 Jan 2011 02:19:55 -0800 (PST) Date: Fri, 14 Jan 2011 05:19:55 -0500 Message-ID: From: Aryeh Friedman To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Subject: best way to run -RELEASE and -CURRENT on the same machine X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 10:43:43 -0000 My normal work doesn't require -CURRENT but the stuff I need to do Android development only works on -CURRENT the problem I only have one machine and want to make it so I can run 8.2-RC1 for most everyday things but can switch to -CURRENT when I do Android work.... Obviously I would like to make it so my ports are also build for both machines everytime I run portmaster (or the equiv)... dual boot or jail or what?.... note that -CURRENT currently is unusable due to active refactoring of the interrupt handling and my NIC (ale(4)) causing a panic when it goes from down to up From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 10:51:56 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9297B106566B for ; Fri, 14 Jan 2011 10:51:56 +0000 (UTC) (envelope-from stb@lassitu.de) Received: from gilb.zs64.net (gilb.zs64.net [IPv6:2001:470:1f0b:105e::1ea]) by mx1.freebsd.org (Postfix) with ESMTP id 59A758FC18 for ; Fri, 14 Jan 2011 10:51:56 +0000 (UTC) Received: by gilb.zs64.net (Postfix, from stb@lassitu.de) id 8A251D0C5B; Fri, 14 Jan 2011 11:51:54 +0100 (CET) Mime-Version: 1.0 (Apple Message framework v1082) Content-Type: text/plain; charset=us-ascii From: Stefan Bethke In-Reply-To: Date: Fri, 14 Jan 2011 11:51:49 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: References: To: Daniel Braniss X-Mailer: Apple Mail (2.1082) Cc: freebsd-hackers@freebsd.org Subject: Re: more gpart/glabel problems X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 10:51:56 -0000 Am 14.01.2011 um 11:37 schrieb Daniel Braniss: > now: > glabel lable r0 mfid0 > so what am I doing wrong? glabel uses the last sector of the device to store the label. GPT keeps = it's backup table there. Additionally, GEOM then tastes the glabel device, and the size of the = glabel device (label/r0) does not agree with the GPT table, since it's = one sector smaller than the device that you created the GPT table on. Are you trying to label the entire array, or individual partitions? If you want to label the entire device, do that first, and then create = the GPT table on the label device. If you want to label individual = partitions, then use the gpart label options, or newfs options. Stefan --=20 Stefan Bethke Fon +49 151 14070811 From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 10:51:58 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EA717106564A for ; Fri, 14 Jan 2011 10:51:58 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from forward20.mail.yandex.net (forward20.mail.yandex.net [95.108.253.145]) by mx1.freebsd.org (Postfix) with ESMTP id 9BDEC8FC17 for ; Fri, 14 Jan 2011 10:51:58 +0000 (UTC) Received: from smtp19.mail.yandex.net (smtp19.mail.yandex.net [95.108.252.19]) by forward20.mail.yandex.net (Yandex) with ESMTP id E06B95D10F4E; Fri, 14 Jan 2011 13:51:56 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1295002316; bh=npXDluuA/1v8pQsXpRsAfsnlZus6ODtr+pSNNHoT6YY=; h=Message-ID:Date:From:MIME-Version:To:CC:Subject:References: In-Reply-To:Content-Type:Content-Transfer-Encoding; b=i9jwuX3Kv10Lk0B65+x2Gm9MFBrnZ11ufOUk33edtPzejXb/2oOcLnGpNhu9Nu9Z+ snJG+KA46yhTz61gXEVEnHFEtE5CcVAOtDe2uik2ufAMMsqDoxWNJZlxSuSxhxKYU/ M/NpAE4L/Up+6uU8flJXzSqbG9lSqNix+ZO1GEhU= Received: from [127.0.0.1] (ns.kirov.so-cdu.ru [77.72.136.145]) by smtp19.mail.yandex.net (Yandex) with ESMTPSA id A5C7728700A9; Fri, 14 Jan 2011 13:51:56 +0300 (MSK) Message-ID: <4D302ACC.7010606@yandex.ru> Date: Fri, 14 Jan 2011 13:51:56 +0300 From: "Andrey V. Elsukov" User-Agent: Mozilla Thunderbird 1.5 (FreeBSD/20051231) MIME-Version: 1.0 To: Daniel Braniss References: In-Reply-To: X-Enigmail-Version: 1.1.1 Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: more gpart/glabel problems X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 10:51:59 -0000 On 14.01.2011 13:37, Daniel Braniss wrote: > and on the console: > GEOM: mfid0: the secondary GPT table is corrupt or invalid. > GEOM: mfid0: using the primary only -- recovery suggested. > GEOM: mfid0: the secondary GPT table is corrupt or invalid. > GEOM: mfid0: using the primary only -- recovery suggested. > GEOM: label/r0: corrupt or invalid GPT detected. > GEOM: label/r0: GPT rejected -- may not be recoverable. > > BTW, going the MBR way, it works as expected. > > so what am I doing wrong? GLABEL saves his metadata in the last sector of the given provider where secondary GPT is located. You can label mfid0 with glabel and after that create GPT on top of label/r0. This should work. -- WBR, Andrey V. Elsukov From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 11:33:49 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 927C1106566B for ; Fri, 14 Jan 2011 11:33:49 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from kabab.cs.huji.ac.il (kabab.cs.huji.ac.il [132.65.16.84]) by mx1.freebsd.org (Postfix) with ESMTP id 4C4EE8FC08 for ; Fri, 14 Jan 2011 11:33:49 +0000 (UTC) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1Pdhud-000MyD-MM; Fri, 14 Jan 2011 13:33:47 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: "Andrey V. Elsukov" In-reply-to: <4D302ACC.7010606@yandex.ru> References: <4D302ACC.7010606@yandex.ru> Comments: In-reply-to "Andrey V. Elsukov" message dated "Fri, 14 Jan 2011 13:51:56 +0300." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 14 Jan 2011 13:33:47 +0200 From: Daniel Braniss Message-ID: Cc: freebsd-hackers@freebsd.org Subject: Re: more gpart/glabel problems X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 11:33:49 -0000 > On 14.01.2011 13:37, Daniel Braniss wrote: > > and on the console: > > GEOM: mfid0: the secondary GPT table is corrupt or invalid. > > GEOM: mfid0: using the primary only -- recovery suggested. > > GEOM: mfid0: the secondary GPT table is corrupt or invalid. > > GEOM: mfid0: using the primary only -- recovery suggested. > > GEOM: label/r0: corrupt or invalid GPT detected. > > GEOM: label/r0: GPT rejected -- may not be recoverable. > > > > BTW, going the MBR way, it works as expected. > > > > so what am I doing wrong? > > GLABEL saves his metadata in the last sector of the given provider > where secondary GPT is located. You can label mfid0 with glabel and > after that create GPT on top of label/r0. This should work. I guess 'should' is the right word, because it doesn't :-) # glabel label r0 mfid0 # gpart create -s GPT label/r0 label/r0 created but on console: GEOM: mfid0: the secondary GPT header is not in the last LBA next: # gpart add -b 34 -s128 -t freebsd-boot $d on console: more of the same, and # gpart show => 34 1952448444 label/r0 GPT (931G) 34 128 1 freebsd-boot (64K) 162 1952448316 - free - (931G) => 34 1952448444 mfid0 GPT (931G) [CORRUPT] 34 128 1 freebsd-boot (64K) 162 1952448316 - free - (931G) danny From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 11:47:30 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8CCAD106564A for ; Fri, 14 Jan 2011 11:47:30 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from forward2.mail.yandex.net (forward2.mail.yandex.net [77.88.46.7]) by mx1.freebsd.org (Postfix) with ESMTP id 245978FC19 for ; Fri, 14 Jan 2011 11:47:29 +0000 (UTC) Received: from smtp1.mail.yandex.net (smtp1.mail.yandex.net [77.88.46.101]) by forward2.mail.yandex.net (Yandex) with ESMTP id 4F9A138A8C80; Fri, 14 Jan 2011 14:47:28 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1295005648; bh=/F/WejxhpPOjX0GXfe0M42qkQrYSAU0a4UW5Axx2NY8=; h=Message-ID:Date:From:MIME-Version:To:CC:Subject:References: In-Reply-To:Content-Type; b=XMq1p04MwMTtfXa1/KwHJjCTbrlWBdmUmD3iOh8BPiyhB3LEQr/BYMl4pjAxJlYzR tqpeQ5lPOEAoCQGqe+izk2PfU3/4mntZuz8CaHDOg6zZoi9HfN3oc7wTwVpLBfF7wy w9/PVtwaeEbWcP6MnPv4LvRCXvACTUtusrvJ1iUs= Received: from [127.0.0.1] (ns.kirov.so-cdu.ru [77.72.136.145]) by smtp1.mail.yandex.net (Yandex) with ESMTPSA id 165D5290095; Fri, 14 Jan 2011 14:47:28 +0300 (MSK) Message-ID: <4D3037CC.1030901@yandex.ru> Date: Fri, 14 Jan 2011 14:47:24 +0300 From: "Andrey V. Elsukov" User-Agent: Mozilla Thunderbird 1.5 (FreeBSD/20051231) MIME-Version: 1.0 To: Daniel Braniss References: <4D302ACC.7010606@yandex.ru> In-Reply-To: X-Enigmail-Version: 1.1.1 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig796DC9FCBCDF02E77B675B44" Cc: freebsd-hackers@freebsd.org Subject: Re: more gpart/glabel problems X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 11:47:30 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig796DC9FCBCDF02E77B675B44 Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: quoted-printable On 14.01.2011 14:33, Daniel Braniss wrote: >> On 14.01.2011 13:37, Daniel Braniss wrote: >>> and on the console: >>> GEOM: mfid0: the secondary GPT table is corrupt or invalid. >>> GEOM: mfid0: using the primary only -- recovery suggested. >>> GEOM: mfid0: the secondary GPT table is corrupt or invalid. >>> GEOM: mfid0: using the primary only -- recovery suggested. >>> GEOM: label/r0: corrupt or invalid GPT detected. >>> GEOM: label/r0: GPT rejected -- may not be recoverable. >>> >>> BTW, going the MBR way, it works as expected. >>> >>> so what am I doing wrong? >> >> GLABEL saves his metadata in the last sector of the given provider >> where secondary GPT is located. You can label mfid0 with glabel and >> after that create GPT on top of label/r0. This should work. >=20 > I guess 'should' is the right word, because it doesn't :-) > # glabel label r0 mfid0 > # gpart create -s GPT label/r0 > label/r0 created > but on console: > GEOM: mfid0: the secondary GPT header is not in the last LBA > next: > # gpart add -b 34 -s128 -t freebsd-boot $d > on console: more of the same, and > # gpart show > =3D> 34 1952448444 label/r0 GPT (931G) > 34 128 1 freebsd-boot (64K) > 162 1952448316 - free - (931G) > =09 > =3D> 34 1952448444 mfid0 GPT (931G) [CORRUPT] > 34 128 1 freebsd-boot (64K) > 162 1952448316 - free - (931G) > danny It works as expected. Both providers label/r0 and mfid0 have primary GPT,= but label/r0 is one sector smaller than mfid0 and GPT's metadata is valid= only for label/r0. mfid0 marked as CORRUPT and you can not modify it. Please read RECOVERING section of gpart(8) manual page. --=20 WBR, Andrey V. Elsukov --------------enig796DC9FCBCDF02E77B675B44 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (MingW32) iQEcBAEBAgAGBQJNMDfPAAoJEAHF6gQQyKF63x0H/idIZRg6n5By3bjUEDp1Shdg dTeIhgc+8DJJ86dDHTocqKnYFCXVNcgqwF4o6Lth8i7ke4tqqqgYCUETRwyDqzX5 R6jCnib6/7I5q3ls15m/BfNVYO2XW6Tr4/5PcUmLylyhWQaaL/9Wm+KeS49m4IJ2 FYfhb0tLLt2pC+z+U0nAfgttlgYpuOzWnWMWDR1Y8VDwYYFPXHFb+EoZLaeEt0Wd pWy7PGbfN6/ZLPfuP6pZlGx6yxE/CWOCzqlpaDp7HuNagzDAJzOb3X0QAEMzry3f jhmKoZ3mO5Fsx5kXtIWPeiTZfPwZ1oDUpjIR0vwEXe6KMec4Dfzj3HrFEUDFeF0= =C7xZ -----END PGP SIGNATURE----- --------------enig796DC9FCBCDF02E77B675B44-- From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 12:09:40 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DE476106566B for ; Fri, 14 Jan 2011 12:09:40 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from kabab.cs.huji.ac.il (kabab.cs.huji.ac.il [132.65.16.84]) by mx1.freebsd.org (Postfix) with ESMTP id 9620C8FC0A for ; Fri, 14 Jan 2011 12:09:40 +0000 (UTC) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1PdiTK-000Ncn-FG; Fri, 14 Jan 2011 14:09:38 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: "Andrey V. Elsukov" In-reply-to: <4D3037CC.1030901@yandex.ru> References: <4D302ACC.7010606@yandex.ru> <4D3037CC.1030901@yandex.ru> Comments: In-reply-to "Andrey V. Elsukov" message dated "Fri, 14 Jan 2011 14:47:24 +0300." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 14 Jan 2011 14:09:38 +0200 From: Daniel Braniss Message-ID: Cc: freebsd-hackers@freebsd.org, Stefan Bethke Subject: Re: more gpart/glabel problems X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 12:09:40 -0000 > This is an OpenPGP/MIME signed message (RFC 2440 and 3156) > --------------enig796DC9FCBCDF02E77B675B44 > Content-Type: text/plain; charset=KOI8-R > Content-Transfer-Encoding: quoted-printable > > On 14.01.2011 14:33, Daniel Braniss wrote: > >> On 14.01.2011 13:37, Daniel Braniss wrote: > >>> and on the console: > >>> GEOM: mfid0: the secondary GPT table is corrupt or invalid. > >>> GEOM: mfid0: using the primary only -- recovery suggested. > >>> GEOM: mfid0: the secondary GPT table is corrupt or invalid. > >>> GEOM: mfid0: using the primary only -- recovery suggested. > >>> GEOM: label/r0: corrupt or invalid GPT detected. > >>> GEOM: label/r0: GPT rejected -- may not be recoverable. > >>> > >>> BTW, going the MBR way, it works as expected. > >>> > >>> so what am I doing wrong? > >> > >> GLABEL saves his metadata in the last sector of the given provider > >> where secondary GPT is located. You can label mfid0 with glabel and > >> after that create GPT on top of label/r0. This should work. > >=20 > > I guess 'should' is the right word, because it doesn't :-) > > # glabel label r0 mfid0 > > # gpart create -s GPT label/r0 > > label/r0 created > > but on console: > > GEOM: mfid0: the secondary GPT header is not in the last LBA > > next: > > # gpart add -b 34 -s128 -t freebsd-boot $d > > on console: more of the same, and > > # gpart show > > =3D> 34 1952448444 label/r0 GPT (931G) > > 34 128 1 freebsd-boot (64K) > > 162 1952448316 - free - (931G) > > =09 > > =3D> 34 1952448444 mfid0 GPT (931G) [CORRUPT] > > 34 128 1 freebsd-boot (64K) > > 162 1952448316 - free - (931G) > > danny > > It works as expected. Both providers label/r0 and mfid0 have primary GPT,= > > but label/r0 is one sector smaller than mfid0 and GPT's metadata is valid= > > only for label/r0. mfid0 marked as CORRUPT and you can not modify it. > Please read RECOVERING section of gpart(8) manual page. he, he, did that before, it just removes the label/s anyways, I believe that I'm now on a better track, ie: # gpart create -s GPT mfid0 mfid0 created # gpart add -b 34 -s128 -t freebsd-boot -l r0/boot mfid0 mfid0p1 added # gpart add -s2G -t freebsd-ufs -l r0/root mfid0 and now, in /dev/gpt: r0/boot r0/root thanks Stephan and Andrey, danny From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 12:11:52 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7AD21106564A for ; Fri, 14 Jan 2011 12:11:52 +0000 (UTC) (envelope-from rysto32@gmail.com) Received: from mail-ey0-f182.google.com (mail-ey0-f182.google.com [209.85.215.182]) by mx1.freebsd.org (Postfix) with ESMTP id 0DD328FC0A for ; Fri, 14 Jan 2011 12:11:51 +0000 (UTC) Received: by eyf6 with SMTP id 6so1343633eyf.13 for ; Fri, 14 Jan 2011 04:11:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=IS7KjaKvbKqkmjf3TolEIduVpKRI9Au+IdiplPzqV3w=; b=Xd06+3fRRpnyJk2OSjNCQzg1dknr1a5R0wn1H+2zf/qLSOJ/oT3joDIoMSungoH5d1 L01Y8NKwy1dS8r9fUSSiDTdww2SXid4smeikLFCP8aobIMqsrXWaXdsLlX//Gqxw3MQ5 t+9RW8qdDLwu7CCGd1EfKvOfFPL8Q2mq8mCLE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=VPOnxVc69cdyCVirNBqUkHQ059bY6muabU8T8cc5AtTQRk2pJrFMPRpMBKNPdcbZLI h02ZL9IZfuXLkbOn+3O3B2+WOb10v4GJShpJ7L0pgHEWskEgJBVNmrSpk1qr4gosIQqA fWcS8TgP+Xa5FIWQHDTGOeBkEcNOn0agZx+Fc= MIME-Version: 1.0 Received: by 10.213.32.193 with SMTP id e1mr668217ebd.74.1295007110821; Fri, 14 Jan 2011 04:11:50 -0800 (PST) Received: by 10.213.22.14 with HTTP; Fri, 14 Jan 2011 04:11:50 -0800 (PST) In-Reply-To: References: <4D2F8BFE.9070607@bsdimp.com> Date: Fri, 14 Jan 2011 07:11:50 -0500 Message-ID: From: Ryan Stone To: Peter Blok Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 12:11:52 -0000 On Fri, Jan 14, 2011 at 3:52 AM, Peter Blok wrote: > Hi, > > I=B9m probably missing something but if you require a stack variable to b= e > aligned why not use a type attribute like __attribute__ ((aligned (8))) > > Peter In my case I had no stack variable that required alignment. gcc issued some movdqa instructions in order to initialize a memory region on the stack to all-zeros. From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 12:40:02 2011 Return-Path: Delivered-To: freebsd-hackers@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3DBE1106566C; Fri, 14 Jan 2011 12:40:02 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from gw01.mail.saunalahti.fi (gw01.mail.saunalahti.fi [195.197.172.115]) by mx1.freebsd.org (Postfix) with ESMTP id ED0578FC1B; Fri, 14 Jan 2011 12:40:01 +0000 (UTC) Received: from jh (a91-153-115-208.elisa-laajakaista.fi [91.153.115.208]) by gw01.mail.saunalahti.fi (Postfix) with SMTP id E54C8151427; Fri, 14 Jan 2011 14:24:54 +0200 (EET) Date: Fri, 14 Jan 2011 14:24:54 +0200 From: Jaakko Heinonen To: freebsd-hackers@FreeBSD.org, rodrigc@FreeBSD.org Message-ID: <20110114122454.GA4805@jh> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) Cc: Subject: [patch] nmount ro, rw and negated option handling X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 12:40:02 -0000 Hi, Currently nmount(2) allows a mount point to have "ro", "rw", and "noro" string options concurrently active. This can cause erratic behavior demonstrated by this example: 1. Have mountd(8) running. 2. # mdconfig -a -t vnode -f ufsimg 3. # mount -o ro,rw /dev/md0 /mnt After these steps the mount point has string options "ro", "rw" and "noro" active but the MNT_RDONLY flag is not set. Eventually this will lead to "ffs_sync: rofs mod" (or similar) panic because the ffs code marks the file system read-only due to the "ro" string option. (MNT_RDONLY flag is used in most places for read-only check.) I wrote a patch to do following changes: - vfs_equalopts() now recognizes "ro" and "rw" as equal options - vfs_mergeopts() uses vfs_sanitizeopts() to merge options. This ensures that if the same option shows up several times (negated or not), only the last one is taken in account. There is still a problem when for example option "foo" and "nofoo" are merged: the "nofoo" option will become an active option. This is not a regression however and currently I don't know an easy way to solve this because the list of valid options is not available in vfs_mergeopts(). - vfs_donmount() always converts "norw"/"rdonly" to "ro" and "noro" to "rw". Thus the mount point will always have either "rw" or "ro" option. I haven't seen any in-tree file system to test for "noro" but at least ZFS tests for "rw". That's why I chose "rw" instead or "noro". The patch is available here: http://people.freebsd.org/~jh/patches/nmount-ro-rw.diff Reviews and testing would be appreciated. Here are some references to bug reports which the patch attempts to resolve: http://lists.freebsd.org/pipermail/freebsd-current/2009-September/thread.html#11385 http://lists.freebsd.org/pipermail/freebsd-questions/2009-August/204124.html http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/133614 http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/150206 -- Jaakko From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 13:01:44 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 30A85106566B for ; Fri, 14 Jan 2011 13:01:44 +0000 (UTC) (envelope-from peter.blok@bsd4all.org) Received: from relay20.prolocation.net (relay20.prolocation.net [IPv6:2a00:d00:ff:133:94:228:133:110]) by mx1.freebsd.org (Postfix) with ESMTP id 8EA908FC1B for ; Fri, 14 Jan 2011 13:01:43 +0000 (UTC) Received: from cust-95-128-94-66.breedbanddelft.nl ([95.128.94.66] helo=mail.bsd4all.org) by relay20.prolocation.net with esmtp (Exim 4.69) (envelope-from ) id 1PdjHi-0001ox-4F; Fri, 14 Jan 2011 14:01:42 +0100 Received: from mailgw (mailgw [192.168.10.12]) by mail.bsd4all.org (Postfix) with ESMTP id 807AA11571; Fri, 14 Jan 2011 14:01:39 +0100 (CET) X-Virus-Scanned: amavisd-new at bsd4all.org Received: from mail.bsd4all.org ([192.168.10.1]) by mailgw (fwgw.homebrew.bsd4all.org [192.168.10.12]) (amavisd-new, port 10024) with ESMTP id 8siTp1iE2hu6; Fri, 14 Jan 2011 14:01:27 +0100 (CET) Received: from bsd4all.org (adexlinge10 [192.168.10.16]) by mail.bsd4all.org (Postfix) with ESMTP id CDB3E114EB; Fri, 14 Jan 2011 14:01:27 +0100 (CET) Received: from 128.222.37.58 ([128.222.37.58]) by adexlinge10.LINGE10.local ([192.168.10.16]) with Microsoft Exchange Server HTTP-DAV ; Fri, 14 Jan 2011 12:58:32 +0000 User-Agent: Microsoft-Entourage/12.26.0.100708 Date: Fri, 14 Jan 2011 13:52:29 +0100 From: Peter Blok To: Ryan Stone Message-ID: Thread-Topic: What does the FreeBSD/i386 ABI say about stack alignment? Thread-Index: Acuz5EMUecEd65HQTvKkId6y6WxJegABaOnM In-Reply-To: Mime-version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-hackers@freebsd.org Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 13:01:44 -0000 Hi Ryan, Well I think gcc should not generate movdqa if it cannot guarantee the area it is working on is aligned. If the stack is not aligned, it should generat= e =AD probably less efficient =AD code that works. What is this area, if it is not a local variable allocated somewhere? Is it some sort of stack probing? Is alloca used? Are variable length arrays used= ? Peter On 1/14/11 13:11 PM, "Ryan Stone" wrote: > On Fri, Jan 14, 2011 at 3:52 AM, Peter Blok wrot= e: >> > Hi, >> > >> > I=B9m probably missing something but if you require a stack variable to = be >> > aligned why not use a type attribute like __attribute__ ((aligned (8))= ) >> > >> > Peter >=20 > In my case I had no stack variable that required alignment. gcc > issued some movdqa instructions in order to initialize a memory region > on the stack to all-zeros. >=20 From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 13:12:23 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 039EE106564A for ; Fri, 14 Jan 2011 13:12:23 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (m209-73.dsl.rawbw.com [198.144.209.73]) by mx1.freebsd.org (Postfix) with ESMTP id 94C208FC16 for ; Fri, 14 Jan 2011 13:12:22 +0000 (UTC) Received: from albert.catwhisker.org (localhost [127.0.0.1]) by albert.catwhisker.org (8.14.4/8.14.4) with ESMTP id p0EChHd8040717; Fri, 14 Jan 2011 04:43:17 -0800 (PST) (envelope-from david@albert.catwhisker.org) Received: (from david@localhost) by albert.catwhisker.org (8.14.4/8.14.4/Submit) id p0EChHKf040716; Fri, 14 Jan 2011 04:43:17 -0800 (PST) (envelope-from david) Date: Fri, 14 Jan 2011 04:43:17 -0800 From: David Wolfskill To: Aryeh Friedman Message-ID: <20110114124317.GN1817@albert.catwhisker.org> Mail-Followup-To: David Wolfskill , Aryeh Friedman , freebsd-hackers@freebsd.org References: Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="E4UgsyMmvHjpIg3x" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i Cc: freebsd-hackers@freebsd.org Subject: Re: best way to run -RELEASE and -CURRENT on the same machine X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 13:12:23 -0000 --E4UgsyMmvHjpIg3x Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I won't claim that the approach I use is "best" for anyone (even me), but it generally works adequately for my purposes. I use a dual- (actually, quad-)boot approach, and set up the file systems in such a way that /usr/local is a symlink from each bootable environment to the same place. On my home "build machine," I maintain private FreeBSD repo mirrors; I mirror those onto my laptop. I use the above-sketched approach on both the build machine & my laptop, and (at present) track stable/8 & head on those machines on a daily basis. I update the ports (on each machine) while running stable/8. Naturally, if the goal were to be to test port-building or the function & stability of a port under head, this appraoch will not be suitable. To make this a bit more complete, I periodically (at present, each Sunday) install the latest built snapshot of stable/8 on my "production" machines here at home. Note that I am actually using "development" branches for this; that may or may not make sense for a given situation. (I had managed to get started on the multi-boot appraoch before jails existed -- it's a minor variation of an approach I used to use on IBM mainframes back in the 80s. It's plausible that some form of virtualization or the use of jails would do the job for me, but I'm fairly comfortable using what I'm familiar with.) Peace, david --=20 David H. Wolfskill david@catwhisker.org Depriving a girl or boy of an opportunity for education is evil. See http://www.catwhisker.org/~david/publickey.gpg for my public key. --E4UgsyMmvHjpIg3x Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (FreeBSD) iEYEARECAAYFAk0wROQACgkQmprOCmdXAD2q5gCfWIoUsE2JMAQ58Yb3aXnMJRl3 /iIAnikSusQn2TgKO8VHfcmca3zycBK2 =grGi -----END PGP SIGNATURE----- --E4UgsyMmvHjpIg3x-- From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 13:53:13 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D7612106566C for ; Fri, 14 Jan 2011 13:53:13 +0000 (UTC) (envelope-from rysto32@gmail.com) Received: from mail-ey0-f182.google.com (mail-ey0-f182.google.com [209.85.215.182]) by mx1.freebsd.org (Postfix) with ESMTP id 6A9BD8FC0A for ; Fri, 14 Jan 2011 13:53:12 +0000 (UTC) Received: by eyf6 with SMTP id 6so1372810eyf.13 for ; Fri, 14 Jan 2011 05:53:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=pKE9OopzGIzZ0C6aaS2JKozE/pfMWmp9xrLlogLKPns=; b=qZxYcQMK0Xttiib7mfihUjHRQFa/3nhFnUHRcRTVU17XmwiOe86b38froT/ZX/Dvl3 fOC+wyHsd0Tb+YNVY8UVSSHd+lQ9ed7EjJ5io22FjW/HgVm3bosUIDTzKtJ9v06pKzxz rQvehHbk/VFVWosvzDNV86JY10arz095qRTXU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=oVA0fx3wm10yLSpCmezrHPdHa5NaueJk2X7kiNb+s6YUsZgCbO8NeZK9wQOxnWgflA oHjRtM/0Lqi0kkgkuUXUe4uB+AJF3xyybTUEBhyN/x7wTegCWp2YK8w/XhhxZdT5r2K2 /D2VJ82/J/kwCtx5Q0C0isR857kVPOwpA5d/8= MIME-Version: 1.0 Received: by 10.213.4.198 with SMTP id 6mr1576764ebs.74.1295013191137; Fri, 14 Jan 2011 05:53:11 -0800 (PST) Received: by 10.213.22.14 with HTTP; Fri, 14 Jan 2011 05:53:11 -0800 (PST) In-Reply-To: References: Date: Fri, 14 Jan 2011 08:53:11 -0500 Message-ID: From: Ryan Stone To: Peter Blok Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 13:53:13 -0000 On Fri, Jan 14, 2011 at 7:52 AM, Peter Blok wrote: > Hi Ryan, > > Well I think gcc should not generate movdqa if it cannot guarantee the ar= ea > it is working on is aligned. If the stack is not aligned, it should gener= ate > =96 probably less efficient =96 code that works. Well that's the trouble, in Linux at least it *can* guarantee that the area is aligned. And it seems that according to kib, FreeBSD also intended to guarantee that alignment, but due to a bug always produced an unaligned stack(which explains why the hack I tried to fix the alignment didn't work -- the bug happened after we got to userland). > What is this area, if it is not a local variable allocated somewhere? Is = it > some sort of stack probing? Is alloca used? Are variable length arrays us= ed? To be honest I'm really not sure. It was dying somewhere in the constructor of a C++ class. Unfortunately due to a lot of inlining and gdb being a total piece of garbage, I wasn't able to suss out exactly what C++ code the instruction corresponded to, and once I understood the problem with movdqa I stopped digging in the C++ code. From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 16:52:21 2011 Return-Path: Delivered-To: freebsd-hackers@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 09FA610656A3 for ; Fri, 14 Jan 2011 16:52:21 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 9C8718FC0C for ; Fri, 14 Jan 2011 16:52:20 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id p0EGgtt1000178; Fri, 14 Jan 2011 09:42:55 -0700 (MST) (envelope-from imp@bsdimp.com) Message-ID: <4D307D0F.7000008@bsdimp.com> Date: Fri, 14 Jan 2011 09:42:55 -0700 From: Warner Losh User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101029 Thunderbird/3.1.6 MIME-Version: 1.0 To: Kostik Belousov References: <20110113202848.GI2518@deviant.kiev.zoral.com.ua> <4D2F8BFE.9070607@bsdimp.com> <20110114082840.GM2518@deviant.kiev.zoral.com.ua> In-Reply-To: <20110114082840.GM2518@deviant.kiev.zoral.com.ua> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@FreeBSD.org Subject: Re: What does the FreeBSD/i386 ABI say about stack alignment? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 16:52:21 -0000 On 01/14/2011 01:28, Kostik Belousov wrote: > On Thu, Jan 13, 2011 at 04:34:22PM -0700, Warner Losh wrote: >> On 01/13/2011 13:28, Kostik Belousov wrote: >>> On Thu, Jan 13, 2011 at 12:19:00PM -0500, Ryan Stone wrote: >>>> I've been trying to get an application compiled with gcc 4.5.1 running >>>> on FreeBSD 8.1, but it's been crashing during startup with a SIGBUS. >>>> It turns out that the problem is that gcc is issuing SSE >>>> instructions(in my case, a movdqa) that assume that the stack will be >>>> aligned to a 16-byte boundary. It seems that Linux/i386 guarantees >>>> this, and I worry that gcc has extended this assumption to all i386 >>>> architectures. I'm assuming that FreeBSD doesn't make any such >>>> promises based on the fact that I'm getting crashes. >>>> >>>> There does seem to be a flag (-mstackrealign) that you can set to >>>> force gcc to align the stack to what it wants, but that pessimizes the >>>> generated code a bit. Some googling would seem to indicate that >>>> -mpreferred-stack-boundary won't always handle this problem correctly. >>>> >>>> Any ideas? My inclination, at least for our local source tree here at >>>> $WORK, would be to accommodate gcc and guarantee the stack alignment >>>> that it wants rather than pessimize our application. It seems we have >>>> an old local patch/hack in our FreeBSD 6.1 tree(apparently based on >>>> this: >>>> http://www.freebsd.org/cgi/getmsg.cgi?fetch=438552+0+/usr/local/www/db/text/2000/freebsd-current/20000507.freebsd-current). >>>> I believe that this patch is the reason why we haven't seen the >>>> problem when running on 6.1, but the patch doesn't seem to work >>>> anymore on 8.1. >>> Look at lib/csu/i386-elf/crt1_s.S, we align stack on startup. >>> My understanding is that the requirement is (%esp& 0xf) == 0 just before >>> the call to the function. And we are off by 4 (this is my fault). >>> >>> Please give this a try. >>> >>> diff --git a/lib/csu/i386-elf/crt1_s.S b/lib/csu/i386-elf/crt1_s.S >>> index d7ed0a2..17ac0e3 100644 >>> --- a/lib/csu/i386-elf/crt1_s.S >>> +++ b/lib/csu/i386-elf/crt1_s.S >>> @@ -42,6 +42,7 @@ _start: >>> .cfi_def_cfa_register %ebp >>> andl $0xfffffff0,%esp # align stack >>> leal 8(%ebp),%eax >>> + subl $4,%esp >>> pushl %eax # argv >>> pushl 4(%ebp) # argc >>> pushl %edx # rtld cleanup >> I'm seeing weird core dumps for ssh and friends on i386 on stable/8 from >> a few days ago. Could that be related? > Few days ago ? It was in the tree for probably one year. > I very much doubt it, but cannot say anything until you show the backtrace. > > Our in-tree gcc masks this by typically doing stack realignment on the > entry into the main(). I tend to think you are right... The backtrace doesn't have an aligned instruction to worry about. I'll rebuild to make sure it is all sane... Warner From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 17:08:54 2011 Return-Path: Delivered-To: freebsd-hackers@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8BFBE1065675 for ; Fri, 14 Jan 2011 17:08:54 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 4C3148FC28 for ; Fri, 14 Jan 2011 17:08:54 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id p0EGwEYJ000361 for ; Fri, 14 Jan 2011 09:58:14 -0700 (MST) (envelope-from imp@bsdimp.com) Message-ID: <4D3080A6.6010704@bsdimp.com> Date: Fri, 14 Jan 2011 09:58:14 -0700 From: Warner Losh User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101029 Thunderbird/3.1.6 MIME-Version: 1.0 To: freebsd-hackers@FreeBSD.org References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: Re: best way to run -RELEASE and -CURRENT on the same machine X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 17:08:54 -0000 On 01/14/2011 03:19, Aryeh Friedman wrote: > My normal work doesn't require -CURRENT but the stuff I need to do > Android development only works on -CURRENT the problem I only have one > machine and want to make it so I can run 8.2-RC1 for most everyday > things but can switch to -CURRENT when I do Android work.... Obviously > I would like to make it so my ports are also build for both machines > everytime I run portmaster (or the equiv)... dual boot or jail or > what?.... note that -CURRENT currently is unusable due to active > refactoring of the interrupt handling and my NIC (ale(4)) causing a > panic when it goes from down to up I'd be tempted to run a -current jail inside of an 8.x base system. That's not supported, but would likely work. An even better idea might be to run a -current system inside a VirtualBox container. This would allow you to run it at full speed, but insulate your primary system if there's bad things going on with -current this week. I do a lot of FreeBSD development inside of VirtualBox. It is quite nice that way. Warner From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 17:22:47 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F11F4106566C for ; Fri, 14 Jan 2011 17:22:47 +0000 (UTC) (envelope-from aryeh.friedman@gmail.com) Received: from mail-yw0-f54.google.com (mail-yw0-f54.google.com [209.85.213.54]) by mx1.freebsd.org (Postfix) with ESMTP id B14E98FC12 for ; Fri, 14 Jan 2011 17:22:47 +0000 (UTC) Received: by ywp6 with SMTP id 6so991004ywp.13 for ; Fri, 14 Jan 2011 09:22:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=HDpjwrDppAYzEF+tfk6aMbnliQZ7/gCj0ev2nbXX8v0=; b=lPj+5J2ndIzX/1ittmzW9AZrkCJ9e0ZFW4p34LlsrzGd6I4cYYI6nTo7WZt/L0ER2+ rNsPbtdmX+L3Ogw5J4j3LuahRkZgP/ti9+8Jp9CQZDBp9K/GLlA+MBkwEcbK2jNHGkDR FrZejdWsx/PnOZ+Uochj3dbJpoj//10HSdTcI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=ZSTNG+MHCHi0fAaPSYfXlAoeaDGEFqyI+Liy7ThaNYNQlzvX8eUMqbapA66WaM+Pfy CDSkaiLvO7hFHQP1o4lkiTS+0/UYqh3rQbzP2Y/QWKFBikTp+G2HGcp7oh/0UE8LxuWW AM4TEZLjoTWzEM/mh6pOp3oc3t5Tog+tMdGAk= MIME-Version: 1.0 Received: by 10.236.109.146 with SMTP id s18mr2160878yhg.28.1295025766946; Fri, 14 Jan 2011 09:22:46 -0800 (PST) Received: by 10.236.110.10 with HTTP; Fri, 14 Jan 2011 09:22:46 -0800 (PST) Date: Fri, 14 Jan 2011 12:22:46 -0500 Message-ID: From: Aryeh Friedman To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Subject: dual booting two versions of FB X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 17:22:48 -0000 What is the "correct" procedure for loading two versions of FB onto the same disk and making both of them bootable? From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 17:29:12 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3A700106564A for ; Fri, 14 Jan 2011 17:29:12 +0000 (UTC) (envelope-from aryeh.friedman@gmail.com) Received: from mail-gy0-f182.google.com (mail-gy0-f182.google.com [209.85.160.182]) by mx1.freebsd.org (Postfix) with ESMTP id E99898FC12 for ; Fri, 14 Jan 2011 17:29:11 +0000 (UTC) Received: by gyf3 with SMTP id 3so1239086gyf.13 for ; Fri, 14 Jan 2011 09:29:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=Dg5XkEf0ccRQ88c0UkJqMBPWv2OaJAzwT3gSq7iER4o=; b=amTuSiZ/+r49bzB8kgGOkV+sAHly11iAkC2CyIwCKSGl2ntZ0Fc1HuzuR+KXd28TLQ Q5mNPRCSlstCbL9xaGzIMh31N+vG3u3VLqQ7q7gwWLsUmVCVMbsZIlJmEqkR9ftA92WJ +S2OdkpsQytP7bK6UoK4agnaV7aaxbaFqEP0E= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=fjJc7IxSMcb4JlmgYz2ffj/j8AS9+jtnYZHPRPG/6FHoRAlna73tV216CcpO1dtC+T xgAI+EqS1EHR6cswAMGajo8EfNgR4dvsGgz5XRWZIwGeNPBpg5iJNCuF/kSVmbO05sB/ MRG8AIeLFv23A/CBIJSRkvpRkiL9pCZ27M5YA= MIME-Version: 1.0 Received: by 10.236.103.19 with SMTP id e19mr2214166yhg.15.1295026150448; Fri, 14 Jan 2011 09:29:10 -0800 (PST) Received: by 10.236.110.10 with HTTP; Fri, 14 Jan 2011 09:29:10 -0800 (PST) In-Reply-To: References: <20110114172559.GO1817@albert.catwhisker.org> Date: Fri, 14 Jan 2011 12:29:10 -0500 Message-ID: From: Aryeh Friedman To: David Wolfskill , freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Cc: Subject: Re: dual booting two versions of FB X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 17:29:12 -0000 On 1/14/11, Aryeh Friedman wrote: > I know I spent all morning attempting to actual get it to work and > can't... I can't seem to make the second partion bootable > > On 1/14/11, David Wolfskill wrote: >> On Fri, Jan 14, 2011 at 12:22:46PM -0500, Aryeh Friedman wrote: >>> What is the "correct" procedure for loading two versions of FB onto >>> the same disk and making both of them bootable? >> >> I already responded to your earlier query on the same topic. >> >> There's more than one "correct" way to do it. >> >> Peace, >> david >> -- >> David H. Wolfskill david@catwhisker.org >> Depriving a girl or boy of an opportunity for education is evil. >> >> See http://www.catwhisker.org/~david/publickey.gpg for my public key. >> > From owner-freebsd-hackers@FreeBSD.ORG Fri Jan 14 19:34:40 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 74A561065670 for ; Fri, 14 Jan 2011 19:34:40 +0000 (UTC) (envelope-from aryeh.friedman@gmail.com) Received: from mail-ew0-f54.google.com (mail-ew0-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id 070A38FC13 for ; Fri, 14 Jan 2011 19:34:39 +0000 (UTC) Received: by ewy24 with SMTP id 24so1630612ewy.13 for ; Fri, 14 Jan 2011 11:34:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=2gVVERQYXTqfj1b1CRb1utclP+etHCCiGFKPVD7ptXk=; b=DwKJU8V8OpjL1tvC9dAyi3d7mhk1Zq6DOh6nfR97bMNTXuG0bLEliWd3FFAw0jyiu2 cLVZo86LIMyAMvg7rj23d+vDza1qlnJ12dkZ2e6pv7T1ytKEQlYsd/KL7Kd2H0LrLrR7 hB8LA3kDRJlRMIJoIsCs8fHhNVsoOzx17nIr0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=vXNj9NeJAT6sZdPSpLmn6D0cksrjccjIeTQYjW+mKPPP8q3wc8Hiv2zMt9l+nvUM53 SFLJZ0ith5XFoJ6AOv5f0gi2feAYFTy/Dpr6rsxtgyyD7b2ud3KZAXtgUcs2Acx4KJlI bwtxNEcIqY/ZPHZOhOPQW80Pbh36T50F+Vn1w= MIME-Version: 1.0 Received: by 10.216.154.136 with SMTP id h8mr886674wek.84.1295033678777; Fri, 14 Jan 2011 11:34:38 -0800 (PST) Received: by 10.216.52.66 with HTTP; Fri, 14 Jan 2011 11:34:38 -0800 (PST) In-Reply-To: References: <20110114172559.GO1817@albert.catwhisker.org> Date: Fri, 14 Jan 2011 14:34:38 -0500 Message-ID: From: Aryeh Friedman To: David Wolfskill , freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Cc: Subject: Re: dual booting two versions of FB X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Jan 2011 19:34:40 -0000 On 1/14/11, Aryeh Friedman wrote: > On 1/14/11, Aryeh Friedman wrote: >> I know I spent all morning attempting to actual get it to work and >> can't... I can't seem to make the second partion bootable >> >> On 1/14/11, David Wolfskill wrote: >>> On Fri, Jan 14, 2011 at 12:22:46PM -0500, Aryeh Friedman wrote: >>>> What is the "correct" procedure for loading two versions of FB onto >>>> the same disk and making both of them bootable? >>> >>> I already responded to your earlier query on the same topic. >>> >>> There's more than one "correct" way to do it. >>> >>> Peace, >>> david >>> -- >>> David H. Wolfskill david@catwhisker.org >>> Depriving a girl or boy of an opportunity for education is evil. >>> >>> See http://www.catwhisker.org/~david/publickey.gpg for my public key. >>> >> > Finally got disklabel to do th etrick... From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 00:09:24 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E3AF61065742 for ; Sat, 15 Jan 2011 00:09:24 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from esa-annu.mail.uoguelph.ca (esa-annu.mail.uoguelph.ca [131.104.91.36]) by mx1.freebsd.org (Postfix) with ESMTP id A0E1E8FC16 for ; Sat, 15 Jan 2011 00:09:24 +0000 (UTC) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApwEAP1zME2DaFvO/2dsb2JhbACECqFHrHaOMYEkgzd0BIRrhiuLNA X-IronPort-AV: E=Sophos;i="4.60,325,1291611600"; d="scan'208";a="105467904" Received: from erie.cs.uoguelph.ca (HELO zcs3.mail.uoguelph.ca) ([131.104.91.206]) by esa-annu-pri.mail.uoguelph.ca with ESMTP; 14 Jan 2011 19:09:23 -0500 Received: from zcs3.mail.uoguelph.ca (localhost.localdomain [127.0.0.1]) by zcs3.mail.uoguelph.ca (Postfix) with ESMTP id B92B2B3F90; Fri, 14 Jan 2011 19:09:23 -0500 (EST) Date: Fri, 14 Jan 2011 19:09:23 -0500 (EST) From: Rick Macklem To: Daniel Braniss Message-ID: <334773590.270506.1295050163687.JavaMail.root@erie.cs.uoguelph.ca> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Originating-IP: [172.17.91.202] X-Mailer: Zimbra 6.0.10_GA_2692 (ZimbraWebClient - IE8 (Win)/6.0.10_GA_2692) Cc: freebsd-hackers@freebsd.org Subject: Re: NFS: file too large X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 00:09:25 -0000 > > BTW, why not make away with the test altogether? > Well, since a server specifies the maximum file size it can handle, it seems good form to check for that in the client. (Although I'd agree that a server shouldn't crash if a read/write that goes beyond that limit.) Also, as Matt notes, off_t is signed. As such, it looks to me like the check could mess up if uio_offset it right near 0x7fffffffffffffff, so that uio->ui_offset + uio->uio_resid ends up negative. I think the check a little above that for uio_offset < 0 should also check uio_offset + uio_resid < 0 to avoid this. rick From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 00:16:06 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C9512106566B for ; Sat, 15 Jan 2011 00:16:06 +0000 (UTC) (envelope-from lgj@usenix.org) Received: from lonestar.usenix.org (lonestar.usenix.org [131.106.3.102]) by mx1.freebsd.org (Postfix) with ESMTP id 94E168FC08 for ; Sat, 15 Jan 2011 00:16:06 +0000 (UTC) Received: from negroni.usenix.org (negroni.usenix.org [131.106.3.145]) (authenticated bits=0) by lonestar.usenix.org (8.14.2/8.14.2) with ESMTP id p0F0E8Z4009571 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO) for ; Fri, 14 Jan 2011 16:16:06 -0800 (PST) From: Lionel Garth Jones Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Date: Fri, 14 Jan 2011 16:16:06 -0800 Message-Id: <3A0ECC62-38D8-49E5-BC80-28D65F5D08C0@usenix.org> To: freebsd-hackers@freebsd.org Mime-Version: 1.0 (Apple Message framework v1082) X-Mailer: Apple Mail (2.1082) X-DCC-Usenix-Metrics: lonestar; whitelist X-Spam-Status: No, score=0.7 required=6.0 tests=ALL_TRUSTED, FH_DATE_PAST_20XX autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on lonestar X-Mailman-Approved-At: Sat, 15 Jan 2011 00:18:18 +0000 Subject: USENIX WebApps '11 Submission Deadline Approaching X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 00:16:06 -0000 I am writing to remind you that the submission deadline for the 2nd = USENIX Conference on Web Application Development (WebApps '11) is approaching. Please submit your work by January 21, 2011, at 11:59 p.m. PST. http://www.usenix.org/webapps11/cfpb/ Like the inaugural WebApps '10, WebApps '11 seeks to attract cutting-edge research that advances the state of the art, not only on novel Web applications but also on infrastructure, tools, and techniques that support the development, analysis/testing, operation, or deployment of those applications. Possible topics include but are not limited to: * Storage for Web-scale applications * Techniques for testing and debugging * Novel strategies for fault tolerance or high availability in Web apps * The Web as an emerging platform in new application areas * HCI techniques related specifically to Web apps * Measurement, modeling, workload generation, and other tools to aid = experimental research on Web apps * New and unusual app features or implementation techniques * Media delivery applications and infrastructure * Client-side libraries, toolkits, plug-ins * Server-side frameworks * Languages and language engineering advances relevant to Web app development * Deployment substrates and technologies (cloud computing, infrastructure as a service, testing as a service, etc.) More information and submission guidelines are available at http://www.usenix.org/webapps11/cfpb/ WebApps '11 will take place June 15-16, 2011, in Portland, OR, and is part of USENIX Federated Conferences Week. I look forward to receiving your submissions! Sincerely, Armando Fox, University of California, Berkeley WebApps '11 Program Chair webapps11chair@usenix.org ------------------------------------------------------------------------ Call for Papers: 2nd USENIX Conference on Web Application Development (WebApps '11) June 15-16, 2011 Portland, OR Part of USENIX Federated Conferences Week, June 12-17, 2011 http://www.usenix.org/webapps11/cfpb/ Paper submission deadline: January 21, 2011, 11:59 p.m. PST ------------------------------------------------------------------------ From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 01:45:53 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3C060106566B for ; Sat, 15 Jan 2011 01:45:53 +0000 (UTC) (envelope-from sec@42.org) Received: from ice.42.org (v6.42.org [IPv6:2001:608:9::1]) by mx1.freebsd.org (Postfix) with ESMTP id EA9C88FC0A for ; Sat, 15 Jan 2011 01:45:52 +0000 (UTC) Received: by ice.42.org (Postfix, from userid 1000) id 26D4C28459; Sat, 15 Jan 2011 02:45:52 +0100 (CET) Date: Sat, 15 Jan 2011 02:45:52 +0100 From: Stefan `Sec` Zehl To: freebsd-hackers@freebsd.org Message-ID: <20110115014551.GA24844@ice.42.org> X-Current-Backlog: 3891 messages Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.3i I-love-doing-this: really X-Modeline: vim:set ts=8 sw=4 smarttab tw=72 si noic notitle: Accept-Languages: de, en X-URL: http://sec.42.org/ Subject: tcp_output.c:560 - is this code correct? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 01:45:53 -0000 Hi, I just found a bug in FreeBSD amd64 -- (see the PR#kern/154006) a missing "(long)" cast in tcp_output.c. I have a question about this code (around line 560) where adv is calculated: | if (recwin > 0 && !(tp->t_flags & TF_NEEDSYN) && | !TCPS_HAVERCVDFIN(tp->t_state)) { | /* | * "adv" is the amount we can increase the window, | * taking into account that we are limited by | * TCP_MAXWIN << tp->rcv_scale. | */ | long adv = min(recwin, (long)TCP_MAXWIN << tp->rcv_scale) - | (tp->rcv_adv - tp->rcv_nxt); | [...] adv is getting negative in my case (receiver window size == 0) because recwin == (tp->rcv_adv - tp->rcv_nxt), but recwin is bigger than (TCP_MAXWIN << tp->rcv_scale) >From the comment above it seems that adv shouldn't be negative ever. So I wonder if that code was meant to be: long adv = min(recwin - (tp->rcv_adv - tp->rcv_nxt) , (long)TCP_MAXWIN << tp->rcv_scale); instead? At least as far as I understand the code, that would make more sense. Thanks, Sec -- The problem with troubleshooting is that trouble shoots back. From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 10:11:30 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 18F2F10656C7 for ; Sat, 15 Jan 2011 10:11:30 +0000 (UTC) (envelope-from perryh@pluto.rain.com) Received: from agora.rdrop.com (agora.rdrop.com [IPv6:2607:f678:1010::34]) by mx1.freebsd.org (Postfix) with ESMTP id D781E8FC0A for ; Sat, 15 Jan 2011 10:11:29 +0000 (UTC) Received: from agora.rdrop.com (66@localhost [127.0.0.1]) by agora.rdrop.com (8.13.1/8.12.7) with ESMTP id p0FABRXA077113 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Sat, 15 Jan 2011 02:11:27 -0800 (PST) (envelope-from perryh@pluto.rain.com) Received: (from uucp@localhost) by agora.rdrop.com (8.13.1/8.12.9/Submit) with UUCP id p0FABRk3077112; Sat, 15 Jan 2011 02:11:27 -0800 (PST) Received: from fbsd61 by pluto.rain.com (4.1/SMI-4.1-pluto-M2060407) id AA22676; Sat, 15 Jan 11 02:06:01 PST Date: Sat, 15 Jan 2011 02:05:20 -0800 From: perryh@pluto.rain.com To: imp@bsdimp.com Message-Id: <4d317160.aZbMJeQ5WXPEWSgc%perryh@pluto.rain.com> References: <4D3080A6.6010704@bsdimp.com> In-Reply-To: <4D3080A6.6010704@bsdimp.com> User-Agent: nail 11.25 7/29/05 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: best way to run -RELEASE and -CURRENT on the same machine X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 10:11:30 -0000 Warner Losh wrote: > I'd be tempted to run a -current jail inside of an 8.x base > system. That's not supported, but would likely work. Only if the OP doesn't need a -CURRENT kernel :) From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 11:10:20 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AE270106566B for ; Sat, 15 Jan 2011 11:10:20 +0000 (UTC) (envelope-from aryeh.friedman@gmail.com) Received: from mail-wy0-f182.google.com (mail-wy0-f182.google.com [74.125.82.182]) by mx1.freebsd.org (Postfix) with ESMTP id 45D6A8FC13 for ; Sat, 15 Jan 2011 11:10:19 +0000 (UTC) Received: by wyf19 with SMTP id 19so3740072wyf.13 for ; Sat, 15 Jan 2011 03:10:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=UdxC8LzyterQRMWfnI2IXIn/0lmth5Pn2J+jJPS/PwA=; b=KRGI6UXyPb048JZw3rlKf0fyd0NyFujbStPIOnJtALPy8ije/XSPo6dEeYfHoi1BE9 9V2OpraekDc6ZBvFLxw5AVP+gxDvSNEWLTHb1vF/DLl8s3E2qalh8rIXyvxDY1ZlM4BV b4oSOgJhUBVMNUS7t2steLBdZVIC7gfuKgs7U= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=g/0+BuzpykM0NwwEIHWeMnucdM7V3sRcwAb0vRtCNrh/YpDYXgNGdp8XbxFRua839n v3wVPT5LxqVxK39lvnHz6HmyEilPbNn13lyZgF3uI7KB3RCrRQQrbzx2nrno288GXlvR EHSEiuSTCDKOKm5CUjgJfCKQdDl9MiYlrgGN4= MIME-Version: 1.0 Received: by 10.216.160.84 with SMTP id t62mr1432023wek.69.1295089819125; Sat, 15 Jan 2011 03:10:19 -0800 (PST) Received: by 10.216.52.66 with HTTP; Sat, 15 Jan 2011 03:10:19 -0800 (PST) Date: Sat, 15 Jan 2011 06:10:19 -0500 Message-ID: From: Aryeh Friedman To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Subject: changing label text in boot0 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 11:10:20 -0000 I have 2 different versions of FB running on the same drive (-STABLE and -CURRENT) and want to know a) is it possible and b) how to change the boot0 "F?" labels so that "F1" (slice 1) is "FreeBSD-STABLE" and "F2" (slice 2) is "FreeBSD-CURRENT" From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 11:54:13 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8F6801065670 for ; Sat, 15 Jan 2011 11:54:13 +0000 (UTC) (envelope-from doconnor@gsoft.com.au) Received: from cain.gsoft.com.au (cain.gsoft.com.au [203.31.81.10]) by mx1.freebsd.org (Postfix) with ESMTP id E67118FC0C for ; Sat, 15 Jan 2011 11:54:12 +0000 (UTC) Received: from [10.166.30.183] ([120.154.253.252]) (authenticated bits=0) by cain.gsoft.com.au (8.14.4/8.14.3) with ESMTP id p0FBS1jN083471 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Sat, 15 Jan 2011 21:58:09 +1030 (CST) (envelope-from doconnor@gsoft.com.au) Mime-Version: 1.0 (Apple Message framework v1082) Content-Type: text/plain; charset=us-ascii From: "Daniel O'Connor" In-Reply-To: Date: Sat, 15 Jan 2011 22:28:01 +1100 Content-Transfer-Encoding: quoted-printable Message-Id: <49BD68D7-91DE-40FC-B7DC-035B43E7335E@gsoft.com.au> References: To: Aryeh Friedman X-Mailer: Apple Mail (2.1082) X-Spam-Score: -0.272 () BAYES_00,RDNS_NONE X-Scanned-By: MIMEDefang 2.67 on 203.31.81.10 Cc: freebsd-hackers@freebsd.org Subject: Re: changing label text in boot0 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 11:54:13 -0000 On 15/01/2011, at 22:10, Aryeh Friedman wrote: > I have 2 different versions of FB running on the same drive (-STABLE > and -CURRENT) and want to know a) is it possible and b) how to change > the boot0 "F?" labels so that "F1" (slice 1) is "FreeBSD-STABLE" and > "F2" (slice 2) is "FreeBSD-CURRENT" It isn't possible. The text is printed based on the partition ID (which is the same for = both) and there is no room in there for any extra logic. =09 -- Daniel O'Connor software and network engineer for Genesis Software - http://www.gsoft.com.au "The nice thing about standards is that there are so many of them to choose from." -- Andrew Tanenbaum GPG Fingerprint - 5596 B766 97C0 0E94 4347 295E E593 DC20 7B3F CE8C From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 12:50:14 2011 Return-Path: Delivered-To: hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CCE04106566C; Sat, 15 Jan 2011 12:50:14 +0000 (UTC) (envelope-from danger@FreeBSD.org) Received: from services.syscare.sk (services.syscare.sk [188.40.39.36]) by mx1.freebsd.org (Postfix) with ESMTP id 53E038FC08; Sat, 15 Jan 2011 12:48:24 +0000 (UTC) Received: from services.syscare.sk (services [188.40.39.36]) by services.syscare.sk (Postfix) with ESMTP id 5571771A5D; Sat, 15 Jan 2011 13:48:23 +0100 (CET) X-Virus-Scanned: amavisd-new at rulez.sk Received: from services.syscare.sk ([188.40.39.36]) by services.syscare.sk (services.rulez.sk [188.40.39.36]) (amavisd-new, port 10024) with ESMTP id wH+IGgsXR73d; Sat, 15 Jan 2011 13:48:21 +0100 (CET) Received: from danger-mbp.local (adsl-dyn11.78-98-106.t-com.sk [78.98.106.11]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: danger@rulez.sk) by services.syscare.sk (Postfix) with ESMTPSA id 8E44771A3F; Sat, 15 Jan 2011 13:48:19 +0100 (CET) Message-ID: <4D319792.7040107@FreeBSD.org> Date: Sat, 15 Jan 2011 13:48:18 +0100 From: Daniel Gerzo Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.14pre) Gecko/20110113 Lanikai/3.1.8pre MIME-Version: 1.0 To: hackers@freebsd.org, current@freebsd.org Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: Fwd: HEADSUP: Call for FreeBSD Status Reports - 4Q/2010 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 12:50:14 -0000 Hello all, the submission date for status report entries is due today and so far I have received only 12 of them. I am of course open to accept more submissions, but please try to submit them as soon as possible (at least let me know you are planning to). It would be great to inform our community about the progress made during the previous quarter as well as about the upcoming projects! Thanks! -------- Original Message -------- Subject: HEADSUP: Call for FreeBSD Status Reports - 4Q/2010 Date: Mon, 27 Dec 2010 13:26:41 +0100 From: Daniel Gerzo Organization: The FreeBSD Project To: current@freebsd.org, hackers@freebsd.org Dear all, I would like to remind you that the next round of status reports covering the last quarter of 2010 is due on January 15th, 2011. This initiative is very welcome in our community. Therefore, I would like to ask you to submit your status reports soon, so that we can compile the report on time. Do not hesitate and write us a few lines - a short description about what you are working on, what are your plans and goals, so we can inform our community about your great work! Check out the reports from the past to get some inspiration of what your submission should look like. If you know about a project that should be included in the status report, please let us know as well, so we can poke the responsible people to provide us with something useful. Updates to submissions from the last report are welcome too. Note that the submissions are accepted from anyone involved within the FreeBSD community, you do not have to be a FreeBSD committer. Submissions about anything related to FreeBSD are very welcome! Please email us the filled-in XML template which can be found at http://www.freebsd.org/news/status/report-sample.xml to monthly@FreeBSD.org, or alternatively use our web based form located at http://www.freebsd.org/cgi/monthly.cgi. For more information, please visit http://www.freebsd.org/news/status/. We are looking forward to see your submissions! -- S pozdravom / Best regards Daniel Gerzo, FreeBSD committer From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 14:50:41 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CD6A91065674 for ; Sat, 15 Jan 2011 14:50:41 +0000 (UTC) (envelope-from e.schuele@computer.org) Received: from smtpauth01.prod.mesa1.secureserver.net (smtpauth01.prod.mesa1.secureserver.net [64.202.165.181]) by mx1.freebsd.org (Postfix) with SMTP id 85EB08FC08 for ; Sat, 15 Jan 2011 14:50:41 +0000 (UTC) Received: (qmail 13233 invoked from network); 15 Jan 2011 14:24:00 -0000 Received: from unknown (71.164.218.188) by smtpauth01.prod.mesa1.secureserver.net (64.202.165.181) with ESMTP; 15 Jan 2011 14:24:00 -0000 Message-ID: <4D31ADF7.50701@computer.org> Date: Sat, 15 Jan 2011 08:23:51 -0600 From: Eric Schuele User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.9.1.16) Gecko/20110107 Lightning/1.0b1 Thunderbird/3.0.11 MIME-Version: 1.0 To: freebsd-hackers@freebsd.org References: In-Reply-To: X-Enigmail-Version: 1.0.1 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig6B3D1FEA6BA25761CC193DD9" Subject: Re: changing label text in boot0 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 14:50:41 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig6B3D1FEA6BA25761CC193DD9 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 01/15/2011 05:10, Aryeh Friedman wrote: > I have 2 different versions of FB running on the same drive (-STABLE > and -CURRENT) and want to know a) is it possible and b) how to change > the boot0 "F?" labels so that "F1" (slice 1) is "FreeBSD-STABLE" and > "F2" (slice 2) is "FreeBSD-CURRENT" GRUB might solve your needs. sysutils/grub -- Regards, Eric --------------enig6B3D1FEA6BA25761CC193DD9 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (FreeBSD) iEYEARECAAYFAk0xrfcACgkQngSDRM3IXUqgCACdEeA82gRjTC9R8606GO6yDZRr FKgAn3o25tq0Mn1nQ/abt8KAMe4H8DHg =5qTD -----END PGP SIGNATURE----- --------------enig6B3D1FEA6BA25761CC193DD9-- From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 20:38:04 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 43B52106566C for ; Sat, 15 Jan 2011 20:38:04 +0000 (UTC) (envelope-from redcrash@gmail.com) Received: from mail-iy0-f182.google.com (mail-iy0-f182.google.com [209.85.210.182]) by mx1.freebsd.org (Postfix) with ESMTP id 099978FC0C for ; Sat, 15 Jan 2011 20:38:03 +0000 (UTC) Received: by iyb26 with SMTP id 26so3618247iyb.13 for ; Sat, 15 Jan 2011 12:38:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=mHLzjr5UzW2e1DMiSfr/kYmj2Lpwps3AfWMVLyLOiXM=; b=JH6YolXONu7jGE4StarZFbBskscVAiSmXlUedo9L2U9ZcsL5hloZVhSOr/KV270Kd9 n2lcfZlPMlWUy0RI6FxTUrOjJR9Khw6VZRzFnTV3Raxbbv6oiJX9capVVwbud+cHQNB2 Iv9Oe67zGCPVzdYwZZaCqmtIp1kQk25i7zYmQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=UHaDbW0PsOddES0xFlgoJjQmpjCS7rMDe02OQgiWbqqjaKdLiX0fk5KBiL+3GY+jm9 JjuyBGvEojw+g3anBv8MJajt/YNKEVr5DvaqLyZFaUjRSdw1MLHkxtY0A/81ZjWcaQzz nX0mN0hpKXxyd6ciXaK7CS47wzf4KHdG1/FGA= MIME-Version: 1.0 Received: by 10.231.206.1 with SMTP id fs1mr2220238ibb.193.1295122162611; Sat, 15 Jan 2011 12:09:22 -0800 (PST) Received: by 10.231.32.194 with HTTP; Sat, 15 Jan 2011 12:09:22 -0800 (PST) Date: Sat, 15 Jan 2011 21:09:22 +0100 Message-ID: From: Harald Servat To: freebsd-hackers@freebsd.org Content-Type: multipart/mixed; boundary=90e6ba53b5287174c70499e82090 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Question about sysctl-ing coretemp module values X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 20:38:04 -0000 --90e6ba53b5287174c70499e82090 Content-Type: text/plain; charset=ISO-8859-1 Hello, First of all, forgive if this is not the appropiate list to ask this. Could you point me the correct list if so? I'm writing a small program to capture the temperature reported by the coretemp kernel module. I'm doing this by using the sysctl API. However, I'm facing a problem when reading that value (dev.cpu.0.temperature, for example). man 3 sysctl has an example (labeled as "To retrieve the standard search path for the system utilities:") which seems great to me to know the length of the OID it wants to read before running the "real" sysctl. I wrote a similar example (attached) based on that, but it does not work appropiately. The 1st call tells me that len = 4 (whereas the value for dev.cpu.0.temperature is "37.0C" which should be 5 if \0 is not counted). Can anyone shed some light on what I'm doing wrong? Thank you very much! -- _________________________________________________________________ Fry: You can see how I lived before I met you. Bender: You lived before you met me?! Fry: Yeah, lots of people did. Bender: Really?! --90e6ba53b5287174c70499e82090-- From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 21:12:21 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 07F6B106564A for ; Sat, 15 Jan 2011 21:12:21 +0000 (UTC) (envelope-from mdf356@gmail.com) Received: from mail-iy0-f182.google.com (mail-iy0-f182.google.com [209.85.210.182]) by mx1.freebsd.org (Postfix) with ESMTP id C25BE8FC16 for ; Sat, 15 Jan 2011 21:12:20 +0000 (UTC) Received: by iyb26 with SMTP id 26so3632935iyb.13 for ; Sat, 15 Jan 2011 13:12:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=Ew9GJhUDgJ503DaEshirZ0Ap/bsr0W5qm4MOwhIfTZA=; b=LDoibZZ7JjzR0Gyvw530OpsZCHy6ztf0IBCoJi4YdroplAXElyAP0JGo1Mlj6CKRWE TL2K1HmtsPcFTEAE2QLUfR2gI0HGeTcaSiCLeqsVV3FIKQBeXlxDduC5/7WYNLER8O7A 3ZrDma7dFy2LQ/A5BSitaAtS99FAa7Y5tp5R8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=KIBVHFlCNOjM1r8T9u2FoP/RNC8Xt6BB0BFDrWxj/UY1Ge5rEfrbW2o9hdwhkue8h7 FnnzETFrImgCx4up3/6R5T/UiSX3ZKqxCZCmPq9YHnYXetgn2AvObe8nrJztKuDyx9oO TF1k0Xo28j6+VpaWUdqm+74CdPCg0iCdRo9Ro= MIME-Version: 1.0 Received: by 10.231.171.197 with SMTP id i5mr2297016ibz.54.1295124610549; Sat, 15 Jan 2011 12:50:10 -0800 (PST) Received: by 10.231.160.147 with HTTP; Sat, 15 Jan 2011 12:50:10 -0800 (PST) In-Reply-To: References: Date: Sat, 15 Jan 2011 12:50:10 -0800 Message-ID: From: Matthew Fleming To: Harald Servat Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org Subject: Re: Question about sysctl-ing coretemp module values X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 21:12:21 -0000 On Sat, Jan 15, 2011 at 12:09 PM, Harald Servat wrote: > Hello, > > =A0First of all, forgive if this is not the appropiate list to ask this. > Could you point me the correct list if so? > > =A0I'm writing a small program to capture the temperature reported by the > coretemp kernel module. I'm doing this by using the sysctl API. However, = I'm > facing a problem when reading that value (dev.cpu.0.temperature, for > example). > > =A0man 3 sysctl has an example (labeled as "To retrieve the standard sear= ch > path for the system utilities:") which seems great to me to know the leng= th > of the OID it wants to read before running the "real" sysctl. I wrote a > similar example (attached) based on that, but it does not work appropiate= ly. > The 1st call tells me that len =3D 4 (whereas the value for > dev.cpu.0.temperature is "37.0C" which should be 5 if \0 is not counted). > > =A0Can anyone shed some light on what I'm doing wrong? The list ate your attachment but I think I know what you're misinterpreting= . The coretemp sysctl is, if I'm reading the code correctly, returning the temperature as an int (hence len=3D4) in 10ths of a degree K. Then sysctl(8) is printing this as %.1fC, which is where the 37.0C comes from. So the sysctl returns an int with some value and then printf does the conversion. The coretemp sysctl uses the unconventional "IK" format, meaning that it's a signed int that should be interpreted as Kelvin. Cheers, matthew From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 21:53:59 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B2EA3106564A for ; Sat, 15 Jan 2011 21:53:59 +0000 (UTC) (envelope-from oliver.pntr@gmail.com) Received: from mail-ww0-f50.google.com (mail-ww0-f50.google.com [74.125.82.50]) by mx1.freebsd.org (Postfix) with ESMTP id 477798FC0C for ; Sat, 15 Jan 2011 21:53:59 +0000 (UTC) Received: by wwf26 with SMTP id 26so4104343wwf.31 for ; Sat, 15 Jan 2011 13:53:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=pQzR6KLX3H0jAoE1T5XZObxlYyk2a4ceDloFyo8wjv8=; b=PuVFiapt4kotY/Zb+vVsWe4Om5ZbTC66QKmCTf7/auJJh8u9j8c0OpFkq1rnYNVob7 tEQzX4cPntWwrta9PQg/Ep3fwIubPEz3FEtS7vXg0k6rYKdsVSQ3sc2vAVkw67pkya2T 9Sy6gza5aptYwKMiJlIX6aIuOwgAVcJTTplIs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=EWpklBFLfD4Nhi2HYLKnGrGBBetBIIBukfK+uoeWTW/9fPO0DlzkIwp2JxwR7k7+Xb MMF3WB7excu5rw2PSE2FYYgp2VLg2PxJo4BeU1cofZVNIdOAf8DZxAQsXIoZ3abKHc5R 6igvdIRPZtMtSjENSo1B2SUdT/7tV3ZkBjQW4= MIME-Version: 1.0 Received: by 10.227.141.77 with SMTP id l13mr353102wbu.159.1295126538821; Sat, 15 Jan 2011 13:22:18 -0800 (PST) Received: by 10.227.59.3 with HTTP; Sat, 15 Jan 2011 13:22:18 -0800 (PST) In-Reply-To: References: Date: Sat, 15 Jan 2011 22:22:18 +0100 Message-ID: From: Oliver Pinter To: Harald Servat Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-hackers@freebsd.org Subject: Re: Question about sysctl-ing coretemp module values X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 21:53:59 -0000 http://oliverp.teteny.bme.hu/git/?p=base/AiBoost-sensord.git;a=blob;f=aiboost-sensord.c;h=349b612066eb0514a2d5c3035908e7418ca71500;hb=HEAD On 1/15/11, Harald Servat wrote: > Hello, > > First of all, forgive if this is not the appropiate list to ask this. > Could you point me the correct list if so? > > I'm writing a small program to capture the temperature reported by the > coretemp kernel module. I'm doing this by using the sysctl API. However, I'm > facing a problem when reading that value (dev.cpu.0.temperature, for > example). > > man 3 sysctl has an example (labeled as "To retrieve the standard search > path for the system utilities:") which seems great to me to know the length > of the OID it wants to read before running the "real" sysctl. I wrote a > similar example (attached) based on that, but it does not work appropiately. > The 1st call tells me that len = 4 (whereas the value for > dev.cpu.0.temperature is "37.0C" which should be 5 if \0 is not counted). > > Can anyone shed some light on what I'm doing wrong? > > Thank you very much! > -- > _________________________________________________________________ > Fry: You can see how I lived before I met you. > Bender: You lived before you met me?! > Fry: Yeah, lots of people did. > Bender: Really?! > From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 15 21:56:52 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CFB0910657C2 for ; Sat, 15 Jan 2011 21:56:52 +0000 (UTC) (envelope-from aryeh.friedman@gmail.com) Received: from mail-wy0-f182.google.com (mail-wy0-f182.google.com [74.125.82.182]) by mx1.freebsd.org (Postfix) with ESMTP id 65B018FC2A for ; Sat, 15 Jan 2011 21:56:52 +0000 (UTC) Received: by wyf19 with SMTP id 19so4059739wyf.13 for ; Sat, 15 Jan 2011 13:56:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=YLQdpG2EQL3uW+eTyl/RkkNCR4C0BzLXU//TwG3Ze24=; b=cbk/69az7h5XhYcFUwlJQYcHaZ+oQwgu7FW2WjumZVd0HN03KUJo/IKKjzi6f6NNrp 03djZFB2tzhVbN5d/BPVfbwaiAmyQGj/RrXYIBs2OMRYnlxVCQMXLvl6d8EwWJ1qpwv4 V2E3NxNbUxNySfWdavtJJkfnHEt1sx40F0vjs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=bqIpCjEiYVx7eLUpirtEfHSqilqNJ7PregrEb71MRk68+enU45lwpb+fckh2s1IxvH xHB1q7q1kuQmOes1GQTcit1urCxUw4twW07OPjLNfIEbmi0YV3pziB15M/sPfBMe6QMf ThEYUKVbOY3Abl8Hf4HPqwuXxg5WQTCyNLhbM= MIME-Version: 1.0 Received: by 10.216.160.84 with SMTP id t62mr1811280wek.69.1295128530921; Sat, 15 Jan 2011 13:55:30 -0800 (PST) Received: by 10.216.52.66 with HTTP; Sat, 15 Jan 2011 13:55:30 -0800 (PST) Date: Sat, 15 Jan 2011 16:55:30 -0500 Message-ID: From: Aryeh Friedman To: Mark Felder , freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Cc: Subject: Android development (was Re: best way to run -RELEASE and -CURRENT on the same machine) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jan 2011 21:56:52 -0000 I am brand new to the whole android development thing... All I know is the phone some how makes it self look like a Linux machine to the outside world (how and such I have no clue)... when I connected it to USB I got: ugen5.2: at usbus5 umass0: on usbus5 umass0: SCSI over Bulk-Only; quirks = 0x0000 umass0:0:0:-1: Attached to scbus0 (probe0:umass-sim0:0:0:0): TEST UNIT READY. CDB: 0 0 0 0 0 0 (probe0:umass-sim0:0:0:0): CAM status: SCSI Status Error (probe0:umass-sim0:0:0:0): SCSI status: Check Condition (probe0:umass-sim0:0:0:0): SCSI sense: UNIT ATTENTION asc:29,0 (Power on, reset, or bus device reset occurred) (probe0:umass-sim0:0:0:0): TEST UNIT READY. CDB: 0 0 0 0 0 0 (probe0:umass-sim0:0:0:0): CAM status: SCSI Status Error (probe0:umass-sim0:0:0:0): SCSI status: Check Condition (probe0:umass-sim0:0:0:0): SCSI sense: NOT READY asc:3a,0 (Medium not present) da0 at umass-sim0 bus 0 scbus0 target 0 lun 0 da0: Removable Direct Access SCSI-2 device da0: 40.000MB/s transfers da0: Attempt to query device size failed: NOT READY, Medium not present My mother board has a built in NIC so I think no WiFi there but I go through a NetGear 54g router so if you can tell me the default IP or anything else that would be helpful (the phone is completely set to factory defaults has no SIM card or service) On Sat, Jan 15, 2011 at 4:48 PM, Mark Felder wrote: > I saw you mention android development -- is adb over usb working on -CURRENT > or something? I've been forced to use adb over wifi since I can't get access > to my android phones over USB :( > > > Regards, > > > Mark >