From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 03:19:22 2008 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 734D41065672; Sun, 7 Dec 2008 03:19:22 +0000 (UTC) (envelope-from ken@mthelicon.com) Received: from hercules.mthelicon.com (hercules.mthelicon.com [IPv6:2001:49f0:2023::2]) by mx1.freebsd.org (Postfix) with ESMTP id 3FC9D8FC0C; Sun, 7 Dec 2008 03:19:22 +0000 (UTC) (envelope-from ken@mthelicon.com) Received: from feathers.peganest.com (78-33-110-3.static-adsl.entanet.co.uk [78.33.110.3] (may be forged)) (authenticated bits=0) by hercules.mthelicon.com (8.14.3/8.14.2) with ESMTP id mB73JJQA022337 (version=TLSv1/SSLv3 cipher=DHE-DSS-AES256-SHA bits=256 verify=NO); Sun, 7 Dec 2008 03:19:21 GMT (envelope-from ken@mthelicon.com) From: Pegasus Mc Cleaft Organization: Feathers To: hackers@freebsd.org, current@freebsd.org Date: Sun, 7 Dec 2008 03:19:18 +0000 User-Agent: KMail/1.10.1 (FreeBSD/8.0-CURRENT; KDE/4.1.1; amd64; ; ) MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200812070319.18461.ken@mthelicon.com> Cc: Subject: Problems with zfsboot loader if raidz present on any drive 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, 07 Dec 2008 03:19:22 -0000 Hello Hackers, Recently and friend and I have been trying to get the new gptzfsboot working on our machines and ran into a interesting problem. Initially I was building the world without the environment variable LOADER_ZFS_SUPPORT=YES in the /etc/make.conf and this, of course, didnt work very well. Every time the machine booted, it would throw 2 lines after the pin-wheel and then reboot. I couldent read what the lines were it went so fast. My friend had a bit more luck and got his machine working OK with a single drive and later a mirror drive added. I added the environment variable and rebuilt everything and installed. This time, I could see the bios drives and a further 2 lines of ZFS something and a reboot... No matter what I tried, I couldent get the machine to boot up to a point where I could try and fix the problem, so I started pulling devices out and found the following: If there is a raidz pool on any drive (not necessarily the one that you are trying to boot from) the loader dies and reboots the machine. My friend, as an experiment created 3 gpt partitions (in addition to the single partition that he had been previously booted from) on his single drive and made a raidz pool for testing. His machine showed the same condition as mine, however he was able to capture the message before the machine rebooted: ZFS: can only boot from disk or mirror vdevs ZFS: inconsistent nvlist contents / ~Peg From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 09:22:19 2008 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 2D18A1065676; Sun, 7 Dec 2008 09:22:19 +0000 (UTC) (envelope-from dfr@rabson.org) Received: from itchy.rabson.org (unknown [IPv6:2002:50b1:e8f2:1::143]) by mx1.freebsd.org (Postfix) with ESMTP id DC2628FC19; Sun, 7 Dec 2008 09:22:18 +0000 (UTC) (envelope-from dfr@rabson.org) Received: from [IPv6:2001:470:909f:1:21b:63ff:feb8:5abc] (unknown [IPv6:2001:470:909f:1:21b:63ff:feb8:5abc]) by itchy.rabson.org (Postfix) with ESMTP id CD2273F9F; Sun, 7 Dec 2008 09:22:16 +0000 (GMT) Message-Id: <66BF33BA-EC11-446F-9DE7-15395F293FE2@rabson.org> From: Doug Rabson To: Pegasus Mc Cleaft In-Reply-To: <200812070319.18461.ken@mthelicon.com> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v929.2) Date: Sun, 7 Dec 2008 09:22:16 +0000 References: <200812070319.18461.ken@mthelicon.com> X-Mailer: Apple Mail (2.929.2) Cc: hackers@freebsd.org, current@freebsd.org Subject: Re: Problems with zfsboot loader if raidz present on any drive 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, 07 Dec 2008 09:22:19 -0000 On 7 Dec 2008, at 03:19, Pegasus Mc Cleaft wrote: > Hello Hackers, > > Recently and friend and I have been trying to get the new > gptzfsboot working > on our machines and ran into a interesting problem. > > Initially I was building the world without the environment variable > LOADER_ZFS_SUPPORT=YES in the /etc/make.conf and this, of course, > didnt work > very well. Every time the machine booted, it would throw 2 lines > after the > pin-wheel and then reboot. I couldent read what the lines were it > went so > fast. > > My friend had a bit more luck and got his machine working OK with a > single > drive and later a mirror drive added. > > I added the environment variable and rebuilt everything and > installed. This > time, I could see the bios drives and a further 2 lines of ZFS > something and a > reboot... > > No matter what I tried, I couldent get the machine to boot up to a > point > where I could try and fix the problem, so I started pulling devices > out and > found the following: If there is a raidz pool on any drive (not > necessarily > the one that you are trying to boot from) the loader dies and > reboots the > machine. My friend, as an experiment created 3 gpt partitions (in > addition to > the single partition that he had been previously booted from) on his > single > drive and made a raidz pool for testing. His machine showed the same > condition > as mine, however he was able to capture the message before the machine > rebooted: > > > ZFS: can only boot from disk or mirror vdevs > > ZFS: inconsistent nvlist contents The zfsboot code in current doesn't support raidz or raidz2. I have been working on adding that support but its not ready yet. The code works in my test harness but crashes instantly when I put it in the boot code :(. I should have time to finish debugging it soon. From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 11:13:34 2008 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 559731065672 for ; Sun, 7 Dec 2008 11:13:34 +0000 (UTC) (envelope-from joao.barros@gmail.com) Received: from fg-out-1718.google.com (fg-out-1718.google.com [72.14.220.158]) by mx1.freebsd.org (Postfix) with ESMTP id CF4368FC12 for ; Sun, 7 Dec 2008 11:13:33 +0000 (UTC) (envelope-from joao.barros@gmail.com) Received: by fg-out-1718.google.com with SMTP id l26so870743fgb.35 for ; Sun, 07 Dec 2008 03:13:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=mO5gMikeLQLmWpNdI5Pz307UoIoRAOCrblBtgRG9Bpc=; b=AjQvar2tYKhyCGdFCQkAGx284Si/8deWAeJvTC1g2DzkN5UFw5kU7QBch0Y97M2GRx 4VksCWFFVAK7yO2BzXQBTnn3RQo3ShClqZ6v3umvblRUz9rd+oY7VEGmmWtIUMZ947pO VRdKhNC0S27yQZGME+NDXE2hZHOV+jnd8KyUw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=qo3+rUghik9Q2jt9G2RosjHZPpgGqtfsz7tiR5bVqJy430STidRCyiVs68ty4l0dly lvkhv7vqo3nJRMfE6pWhwfx32VTDi37cb+KF8p3rolMDTysGF49I/uPSrjjZBdoUsHQO S1Bu9tnhUhVrV9eOxGG2v/7906FGlhLWPHGK0= Received: by 10.180.253.12 with SMTP id a12mr776136bki.147.1228646913361; Sun, 07 Dec 2008 02:48:33 -0800 (PST) Received: by 10.180.236.13 with HTTP; Sun, 7 Dec 2008 02:48:33 -0800 (PST) Message-ID: <70e8236f0812070248p3341c24aob024995be08b962a@mail.gmail.com> Date: Sun, 7 Dec 2008 10:48:33 +0000 From: "Joao Barros" To: "Doug Rabson" In-Reply-To: <66BF33BA-EC11-446F-9DE7-15395F293FE2@rabson.org> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <200812070319.18461.ken@mthelicon.com> <66BF33BA-EC11-446F-9DE7-15395F293FE2@rabson.org> Cc: hackers@freebsd.org, Pegasus Mc Cleaft , current@freebsd.org Subject: Re: Problems with zfsboot loader if raidz present on any drive 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, 07 Dec 2008 11:13:34 -0000 On Sun, Dec 7, 2008 at 9:22 AM, Doug Rabson wrote: > > On 7 Dec 2008, at 03:19, Pegasus Mc Cleaft wrote: > >> Hello Hackers, >> >> Recently and friend and I have been trying to get the new >> gptzfsboot working >> on our machines and ran into a interesting problem. >> >> Initially I was building the world without the environment variable >> LOADER_ZFS_SUPPORT=YES in the /etc/make.conf and this, of course, didnt >> work >> very well. Every time the machine booted, it would throw 2 lines after the >> pin-wheel and then reboot. I couldent read what the lines were it went so >> fast. >> >> My friend had a bit more luck and got his machine working OK with a >> single >> drive and later a mirror drive added. >> >> I added the environment variable and rebuilt everything and >> installed. This >> time, I could see the bios drives and a further 2 lines of ZFS something >> and a >> reboot... >> >> No matter what I tried, I couldent get the machine to boot up to a >> point >> where I could try and fix the problem, so I started pulling devices out >> and >> found the following: If there is a raidz pool on any drive (not >> necessarily >> the one that you are trying to boot from) the loader dies and reboots the >> machine. My friend, as an experiment created 3 gpt partitions (in addition >> to >> the single partition that he had been previously booted from) on his >> single >> drive and made a raidz pool for testing. His machine showed the same >> condition >> as mine, however he was able to capture the message before the machine >> rebooted: >> >> >> ZFS: can only boot from disk or mirror vdevs >> >> ZFS: inconsistent nvlist contents > > The zfsboot code in current doesn't support raidz or raidz2. I have been > working on adding that support but its not ready yet. The code works in my > test harness but crashes instantly when I put it in the boot code :(. I > should have time to finish debugging it soon. > After installing my system yesterday on a single disk with gptzfsboot, I connected my old raidz and I only got cyclic reboots. I knew instantly it had something to do with the raidz. Disconnecting 2 out of the 4 disks of the raidz would allow the system to boot as the raidz would not present itself as ONLINE. As a temporary workaround for this problem I disabled those 2 disks on the BIOS, the system boots fine and the kernel is able to find them later. Doug, when you feel comfortable to share any patches, I'm willing to test :-) -- Joao Barros From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 12:17:24 2008 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 6461A1065670; Sun, 7 Dec 2008 12:17:24 +0000 (UTC) (envelope-from ken@mthelicon.com) Received: from hercules.mthelicon.com (hercules.mthelicon.com [IPv6:2001:49f0:2023::2]) by mx1.freebsd.org (Postfix) with ESMTP id 2D0A08FC14; Sun, 7 Dec 2008 12:17:24 +0000 (UTC) (envelope-from ken@mthelicon.com) Received: from feathers.peganest.com (78-33-110-3.static-adsl.entanet.co.uk [78.33.110.3] (may be forged)) (authenticated bits=0) by hercules.mthelicon.com (8.14.3/8.14.2) with ESMTP id mB7CHLVo024422 (version=TLSv1/SSLv3 cipher=DHE-DSS-AES256-SHA bits=256 verify=NO); Sun, 7 Dec 2008 12:17:23 GMT (envelope-from ken@mthelicon.com) From: Pegasus Mc Cleaft Organization: Feathers To: Doug Rabson Date: Sun, 7 Dec 2008 12:17:20 +0000 User-Agent: KMail/1.10.1 (FreeBSD/8.0-CURRENT; KDE/4.1.1; amd64; ; ) References: <200812070319.18461.ken@mthelicon.com> <66BF33BA-EC11-446F-9DE7-15395F293FE2@rabson.org> In-Reply-To: <66BF33BA-EC11-446F-9DE7-15395F293FE2@rabson.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200812071217.20500.ken@mthelicon.com> Cc: hackers@freebsd.org, current@freebsd.org Subject: Re: Problems with zfsboot loader if raidz present on any drive 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, 07 Dec 2008 12:17:24 -0000 On Sunday 07 December 2008 09:22:16 Doug Rabson wrote: > On 7 Dec 2008, at 03:19, Pegasus Mc Cleaft wrote: > > Hello Hackers, > > > > Recently and friend and I have been trying to get the new > > gptzfsboot working > > on our machines and ran into a interesting problem. > > > > Initially I was building the world without the environment variable > > LOADER_ZFS_SUPPORT=YES in the /etc/make.conf and this, of course, > > didnt work > > very well. Every time the machine booted, it would throw 2 lines > > after the > > pin-wheel and then reboot. I couldent read what the lines were it > > went so > > fast. > > > > My friend had a bit more luck and got his machine working OK with a > > single > > drive and later a mirror drive added. > > > > I added the environment variable and rebuilt everything and > > installed. This > > time, I could see the bios drives and a further 2 lines of ZFS > > something and a > > reboot... > > > > No matter what I tried, I couldent get the machine to boot up to a > > point > > where I could try and fix the problem, so I started pulling devices > > out and > > found the following: If there is a raidz pool on any drive (not > > necessarily > > the one that you are trying to boot from) the loader dies and > > reboots the > > machine. My friend, as an experiment created 3 gpt partitions (in > > addition to > > the single partition that he had been previously booted from) on his > > single > > drive and made a raidz pool for testing. His machine showed the same > > condition > > as mine, however he was able to capture the message before the machine > > rebooted: > > > > > > ZFS: can only boot from disk or mirror vdevs > > > > ZFS: inconsistent nvlist contents > > The zfsboot code in current doesn't support raidz or raidz2. I have > been working on adding that support but its not ready yet. The code > works in my test harness but crashes instantly when I put it in the > boot code :(. I should have time to finish debugging it soon. Hi Doug, In my haste to put a message to the group, I didnt do a very good job of explaining or give what platform I was working with. I set up a single disk pool with the gptzfsboot code on it as a boot drive. My idea was to have a single disk boot (and after it boots and I can kill the UFS drive I am currently booting from) convert it to a mirror. But I have 6 other drives in the machine that I have as a raidz for my /usr/home, et al. If the 6 raidz drives are present at boot time, the machine starts to cyclic reboot just after the pin-wheel. The machine I am working on is running FBSD8.0-Current as of midnight 7/12/2008 and the platform is AMD64. If I can help test in any way I would be more than happy to try, or provide any information necessary.. ~Peg From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 08:40:58 2008 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 701E71065673; Sun, 7 Dec 2008 08:40:58 +0000 (UTC) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Received: from wojtek.tensor.gdynia.pl (wojtek.tensor.gdynia.pl [IPv6:2001:4070:101:2::1]) by mx1.freebsd.org (Postfix) with ESMTP id D5D298FC13; Sun, 7 Dec 2008 08:40:55 +0000 (UTC) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Received: from wojtek.tensor.gdynia.pl (localhost [IPv6:::1]) by wojtek.tensor.gdynia.pl (8.14.3/8.14.3) with ESMTP id mB78emBU005437; Sun, 7 Dec 2008 09:40:48 +0100 (CET) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Received: from localhost (wojtek@localhost) by wojtek.tensor.gdynia.pl (8.14.3/8.14.3/Submit) with ESMTP id mB78ek8M005434; Sun, 7 Dec 2008 09:40:47 +0100 (CET) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Date: Sun, 7 Dec 2008 09:40:46 +0100 (CET) From: Wojciech Puchar To: onsapoengo Ons In-Reply-To: <4be2da2e0812062344y26eddcc9sf589531d10c71a1c@mail.gmail.com> Message-ID: <20081207093713.O5433@wojtek.tensor.gdynia.pl> References: <4be2da2e0812062344y26eddcc9sf589531d10c71a1c@mail.gmail.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Mailman-Approved-At: Sun, 07 Dec 2008 12:39:52 +0000 Cc: freebsd-hackers@freebsd.org, freebsd-questions@freebsd.org Subject: Re: Why FreeBSD not popular on hardware vendors 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, 07 Dec 2008 08:40:58 -0000 > manufacturers of hardware. More recently there were times when anybody from because managers/bosses concentrate on majority, not minority of users. > manufacturers did not notice Linux. However now it is possible to find a few > given out "put normal OS - their list is at us on a site and then we will i recommend you to find "normal shop" to buy hardware, that allow you to fully test computer before buying. if you think there are larger (even hundreds means larger) start selling "FreeBSD compatible computers" in your area! You could make money on that, many people will easily spend 100$ more for computer that is already tested 100% FreeBSD compatible. All you have to do is to test/check lots of different parts of hardware if it actually work with FreeBSD fine, and make computers from that parts. From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 15:56:48 2008 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 9FD601065676 for ; Sun, 7 Dec 2008 15:56:48 +0000 (UTC) (envelope-from yonyossef.lists@gmail.com) Received: from yw-out-2324.google.com (yw-out-2324.google.com [74.125.46.28]) by mx1.freebsd.org (Postfix) with ESMTP id 5DA8C8FC1A for ; Sun, 7 Dec 2008 15:56:48 +0000 (UTC) (envelope-from yonyossef.lists@gmail.com) Received: by yw-out-2324.google.com with SMTP id 9so315613ywe.13 for ; Sun, 07 Dec 2008 07:56:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type:content-transfer-encoding :content-disposition; bh=RFBgf0UXguEWv4yWNwxMWm3MXxashumnOtECyg1Yed0=; b=dpDmjgohIxAsJWGFNQbPV4RgzRxPaMe30rmAtzQPr7pf1EHLszVa6PZHxkUd5mgn3M QLNaPVrWAdv4M9ntx9//0sIYGwiMb+vinBRhuppk16aj+oQo4SY3BktNOKtdUTVG0raW pXkvJUS4bx8Ea+LIjcbaWaZMPgy84wbQpXnTg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type :content-transfer-encoding:content-disposition; b=icl1gOn3y2+CPznYkitmH1GOCilVIwX1p5TlG4mHGumUAeGPouwcRH2lfFk9uKbjOv WovMs8n/i/TL/sPUSZ1B3nmEXryfeCqzY5GlMHOsaG088/K8NzydfFGCPg+r9XcaD5I3 LEuv6mUfZurkUjKZOo/LeZk0LoVgSUPglrhNE= Received: by 10.151.110.14 with SMTP id n14mr1856470ybm.160.1228665407685; Sun, 07 Dec 2008 07:56:47 -0800 (PST) Received: by 10.150.154.21 with HTTP; Sun, 7 Dec 2008 07:56:47 -0800 (PST) Message-ID: <20def4870812070756n649f442fwc6e1d3da195a0669@mail.gmail.com> Date: Sun, 7 Dec 2008 17:56:47 +0200 From: "Yony Yossef" To: freebsd-questions@freebsd.org, freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Cc: Subject: Timer driven tasks in FreeBSD 7 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, 07 Dec 2008 15:56:48 -0000 Hi All, What mechanism should I use for making my netwrok driver call a function every half a second, for instnace? I am already using task queues but I haven't found a way to make it work with a timer. Thanks Yony From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 16:03:38 2008 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 3B62C106564A; Sun, 7 Dec 2008 16:03:38 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from igloo.linux.gr (igloo.linux.gr [62.1.205.36]) by mx1.freebsd.org (Postfix) with ESMTP id A5F808FC17; Sun, 7 Dec 2008 16:03:37 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from kobe.laptop (adsl153-194.kln.forthnet.gr [62.1.244.194]) (authenticated bits=128) by igloo.linux.gr (8.14.3/8.14.3/Debian-5) with ESMTP id mB7G3Roa014721 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Sun, 7 Dec 2008 18:03:32 +0200 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.3/8.14.3) with ESMTP id mB7G3Qxr052044; Sun, 7 Dec 2008 18:03:26 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) Received: (from keramida@localhost) by kobe.laptop (8.14.3/8.14.3/Submit) id mB7G3Ppr052043; Sun, 7 Dec 2008 18:03:25 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) From: Giorgos Keramidas To: "Yony Yossef" References: <20def4870812070756n649f442fwc6e1d3da195a0669@mail.gmail.com> Date: Sun, 07 Dec 2008 18:03:24 +0200 In-Reply-To: <20def4870812070756n649f442fwc6e1d3da195a0669@mail.gmail.com> (Yony Yossef's message of "Sun, 7 Dec 2008 17:56:47 +0200") Message-ID: <877i6ct1kj.fsf@kobe.laptop> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-MailScanner-ID: mB7G3Roa014721 X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-4.003, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL 0.40, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@ceid.upatras.gr X-Spam-Status: No Cc: freebsd-hackers@freebsd.org, freebsd-questions@freebsd.org Subject: Re: Timer driven tasks in FreeBSD 7 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, 07 Dec 2008 16:03:38 -0000 On Sun, 7 Dec 2008 17:56:47 +0200, "Yony Yossef" wrote: > Hi All, > > What mechanism should I use for making my netwrok driver call a > function every half a second, for instnace? > > I am already using task queues but I haven't found a way to make it > work with a timer. callout_xxx() functions should do the trick. See the timeout(9) manpage for more details. From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 19:20:55 2008 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 812CC1065670 for ; Sun, 7 Dec 2008 19:20:55 +0000 (UTC) (envelope-from marius@nuenneri.ch) Received: from yx-out-2324.google.com (yx-out-2324.google.com [74.125.44.28]) by mx1.freebsd.org (Postfix) with ESMTP id 3E2028FC1B for ; Sun, 7 Dec 2008 19:20:55 +0000 (UTC) (envelope-from marius@nuenneri.ch) Received: by yx-out-2324.google.com with SMTP id 8so332743yxb.13 for ; Sun, 07 Dec 2008 11:20:54 -0800 (PST) Received: by 10.90.104.20 with SMTP id b20mr918082agc.50.1228676430435; Sun, 07 Dec 2008 11:00:30 -0800 (PST) Received: by 10.90.73.15 with HTTP; Sun, 7 Dec 2008 11:00:30 -0800 (PST) Message-ID: Date: Sun, 7 Dec 2008 20:00:30 +0100 From: "=?ISO-8859-1?Q?Marius_N=FCnnerich?=" To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Subject: Why safe using msleep with timeout=0 but not tsleep? 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, 07 Dec 2008 19:20:55 -0000 See subject. Interesting commit: http://svn.freebsd.org/viewvc/base?view=revision&revision=77059 - Marius From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 19:55:16 2008 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 46DA91065672 for ; Sun, 7 Dec 2008 19:55:16 +0000 (UTC) (envelope-from kientzle@freebsd.org) Received: from kientzle.com (kientzle.com [66.166.149.50]) by mx1.freebsd.org (Postfix) with ESMTP id 08FF38FC12 for ; Sun, 7 Dec 2008 19:55:15 +0000 (UTC) (envelope-from kientzle@freebsd.org) Received: from [10.123.2.178] (p53.kientzle.com [66.166.149.53]) by kientzle.com (8.12.9/8.12.9) with ESMTP id mB7Jsvtv044473; Sun, 7 Dec 2008 11:54:57 -0800 (PST) (envelope-from kientzle@freebsd.org) Message-ID: <493C2A0C.1080103@freebsd.org> Date: Sun, 07 Dec 2008 11:54:52 -0800 From: Tim Kientzle User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.12) Gecko/20060422 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Ed Schouten References: <20081206155908.GG18652@hoeg.nl> In-Reply-To: <20081206155908.GG18652@hoeg.nl> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Cc: FreeBSD Hackers Subject: Re: Syscons with xterm emulation: one step closer to UTF-8 support? 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, 07 Dec 2008 19:55:16 -0000 Ed Schouten wrote: > > A couple of weeks ago I started working on a library (libteken) that > implements a subset of features (escape sequences) of xterm, our trusty > X11 terminal application. Ed, VT100 emulation in syscons is a great idea. The first time ;-) I implemented VT100 emulation I didn't know about all of the VT100 and VT220 torture tests floating around. If you haven't already, I strongly suggest you track down some of them. The various VT100 "movies" are useful tests and kind of fun to watch. Tim From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 17:59:51 2008 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 AE1791065673 for ; Sun, 7 Dec 2008 17:59:51 +0000 (UTC) (envelope-from nox@saturn.kn-bremen.de) Received: from gwyn.kn-bremen.de (gwyn.kn-bremen.de [212.63.36.242]) by mx1.freebsd.org (Postfix) with ESMTP id 34C658FC14 for ; Sun, 7 Dec 2008 17:59:51 +0000 (UTC) (envelope-from nox@saturn.kn-bremen.de) Received: by gwyn.kn-bremen.de (Postfix, from userid 10) id 09DA3191A2A; Sun, 7 Dec 2008 18:59:49 +0100 (CET) Received: from saturn.kn-bremen.de (noident@localhost [127.0.0.1]) by saturn.kn-bremen.de (8.14.2/8.13.8) with ESMTP id mB7HtuNO061435; Sun, 7 Dec 2008 18:55:56 +0100 (CET) (envelope-from nox@saturn.kn-bremen.de) Received: (from nox@localhost) by saturn.kn-bremen.de (8.14.2/8.13.6/Submit) id mB7HtufT061434; Sun, 7 Dec 2008 18:55:56 +0100 (CET) (envelope-from nox) From: Juergen Lock Date: Sun, 7 Dec 2008 18:55:56 +0100 To: Nate Eldredge Message-ID: <20081207175556.GA61107@saturn.kn-bremen.de> References: <5f67a8c40812021718i4cc225fem5b02a448702ec606@mail.gmail.com> <7d6fde3d0812040327w7c92826i64c6073a453d65ef@mail.gmail.com> <5f67a8c40812040952u1364563awcfd493695e7fea7c@mail.gmail.com> <200812042046.mB4KkC0k016853@saturn.kn-bremen.de> <20081204212311.GA17962@saturn.kn-bremen.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2007-11-01) X-Mailman-Approved-At: Sun, 07 Dec 2008 20:32:06 +0000 Cc: yanefbsd@gmail.com, freebsd-hackers@freebsd.org Subject: Re: AMD64 qemu completely broken? 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, 07 Dec 2008 17:59:51 -0000 On Thu, Dec 04, 2008 at 02:43:47PM -0800, Nate Eldredge wrote: > On Thu, 4 Dec 2008, Juergen Lock wrote: > >> I forgot to say the qemu-devel port (as well as the later snapshots I >> posted about on -emulation) also support -curses, which shows the emulated >> vga text(!)console on qemu's tty. This works quite well with FreeBSD guests >> (even the isos) if you extend your xterm/whatever by one line (the default >> vga textconsole is 80x25 instead of 80x24.) > > As long as we're sharing tips about qemu: > > I've recently been working with qemu on amd64 and have set up a Debian etch > i386 guest which is working well. I am using the qemu-devel and > kqemu-kmod-devel ports. I am not using -kernel-kqemu at the moment; I > thought I would get things working before trying to speed up. > > Using qemu I've finally achieved my goal of being able to use flash on > FreeBSD/amd64 (in some sense :-O). > Actually at least on RELENG_7 and later the original www/linux-flashplugin9 + www/nspluginwrapper don't work too bad at least for video sites these days (on 6 and 7.0 you need a patch and there it probably doesn't quite work on SMP because another patch concerning SMP can't be merged.) See e.g. this thread on -emulation for more: http://lists.freebsd.org/pipermail/freebsd-emulation/2008-October/005433.html (also later on that thread iirc were reports of hangs with ff3 and linux base fc4, so either use f7 or f8, or stick with ff2 for now, like if you're on 6 + linprocfs patch where only fc4 works. And you want to run that nspluginwrapper -i command under 5. as the user that will run the browser, not as root. Oh and that flash9 advisory is no longer an issue, it has been updated since.) I even got flash10 running, which probably can enter ports some time after the slush: http://lists.freebsd.org/pipermail/freebsd-emulation/2008-October/005438.html > savevm and loadvm don't work due to a security patch. Since my guest > system is trusted I reverted the patch. I filed a PR as ports/129417 . > Yup, fixed since. (I'm only saying this for the benefit of other readers. :) Merged a fix from debian sid kvm. > I found that '-net user' is horribly broken on amd64 (qemu segfaults). It > uses some ancient [*] BSD TCP/IP code (via slirp) which assumes that > pointers are 32 bits and doesn't hesitate to shove them into random 32-bit > corners of externally defined structures if it's convenient. Looks like a > pain to clean up. Yup slirp is ancient code and doesnt really work on 64 bit hosts. (as also mentioned in the qemu ports' pkg-message...) > '-net tap' works fine, but requires root privileges and > is more work to set up. > Actually it doesn't require root privs to run, only to setup. (Ok you _might_ need sudo to ifconfig the tap device and/or bridge in the qemu-ifup script... But qemu itself can certainly run as user.) > [*] Out of curiosity, I looked at some Unix Archive stuff and found the > identical code in BSD's Net2, circa 1991. It is identified in a comment as > a "quick hack" and adorned with several /* XXX */. Naturally the code and > the comments survive intact, 17 years later. :-( > This might be somewhat more understandable if you know that the original slirp code was written many moons ago and only later resurrected for emulation purposes. (It was originally invented for dialup users that logged into shellservers' gettys via serial modem lines so they could also use the box' inet connection locally before things like ppp were available...) Cheers, Juergen From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 21:16:03 2008 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 DEEC5106564A; Sun, 7 Dec 2008 21:16:03 +0000 (UTC) (envelope-from ed@hoeg.nl) Received: from palm.hoeg.nl (mx0.hoeg.nl [IPv6:2001:7b8:613:100::211]) by mx1.freebsd.org (Postfix) with ESMTP id 7CEA38FC0C; Sun, 7 Dec 2008 21:16:03 +0000 (UTC) (envelope-from ed@hoeg.nl) Received: by palm.hoeg.nl (Postfix, from userid 1000) id 5FC3B1CE1F; Sun, 7 Dec 2008 22:16:02 +0100 (CET) Date: Sun, 7 Dec 2008 22:16:02 +0100 From: Ed Schouten To: Tim Kientzle Message-ID: <20081207211602.GJ18652@hoeg.nl> References: <20081206155908.GG18652@hoeg.nl> <493C2A0C.1080103@freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="GvznHscUikHnwW2p" Content-Disposition: inline In-Reply-To: <493C2A0C.1080103@freebsd.org> User-Agent: Mutt/1.5.18 (2008-05-17) Cc: FreeBSD Hackers Subject: Re: Syscons with xterm emulation: one step closer to UTF-8 support? 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, 07 Dec 2008 21:16:04 -0000 --GvznHscUikHnwW2p Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable * Tim Kientzle wrote: > VT100 emulation in syscons is a great idea. > > The first time ;-) I implemented VT100 emulation I didn't > know about all of the VT100 and VT220 torture tests > floating around. If you haven't already, I strongly > suggest you track down some of them. The various > VT100 "movies" are useful tests and kind of fun to watch. Yes. That's a very good idea. So far I've mainly done testing with vttest, maintained by Thomas Dickey: http://invisible-island.net/vttest/vttest.html But I'll see if I can find others. They are very good to monitor regressions. --=20 Ed Schouten WWW: http://80386.nl/ --GvznHscUikHnwW2p Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iEYEARECAAYFAkk8PRIACgkQ52SDGA2eCwVJOACcD8LaJgJZF05A+FxOZWpdI1ez UxQAnidmAiCVMCYWRjWkHMDhe8WSxAKM =HKAo -----END PGP SIGNATURE----- --GvznHscUikHnwW2p-- From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 21:45:56 2008 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 30CFE1065673 for ; Sun, 7 Dec 2008 21:45:56 +0000 (UTC) (envelope-from patfbsd@davenulle.org) Received: from smtp.lamaiziere.net (net.lamaiziere.net [91.121.44.19]) by mx1.freebsd.org (Postfix) with ESMTP id EAEE18FC13 for ; Sun, 7 Dec 2008 21:45:55 +0000 (UTC) (envelope-from patfbsd@davenulle.org) Received: from baby-jane.lamaiziere.net (246.10.87-79.rev.gaoland.net [79.87.10.246]) by smtp.lamaiziere.net (Postfix) with ESMTPA id 9519F63366E for ; Sun, 7 Dec 2008 22:45:54 +0100 (CET) Received: from baby-jane (localhost [127.0.0.1]) by baby-jane.lamaiziere.net (Postfix) with ESMTP id 2DDCF6728C0 for ; Sun, 7 Dec 2008 22:45:53 +0100 (CET) Date: Sun, 7 Dec 2008 22:45:51 +0100 From: Patrick =?ISO-8859-15?Q?Lamaizi=E8re?= To: freebsd-hackers@freebsd.org Message-ID: <20081207224551.13ca3590@baby-jane> Organization: /dave/nulle X-Mailer: Claws Mail 3.3.1 (GTK+ 2.12.9; i386-apple-darwin9.3.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: crypto(9) choose another driver if we cannot open a session on it 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, 07 Dec 2008 21:45:56 -0000 Hello, I wrote a small patch to allow the crypto framework to choose another cryptographic driver if we cannot open a session on the driver. The current version selects the driver that handles all the requested algorithms and with the less count of active sessions. But this is not enough, by example the glxsb(4) driver does not accept AES session with key's length != 128 bits. It rejects also HMAC algorithms if there is no AES encryption to do in the session (HMAC is done by software to make it works with ipsec). The other way to deal with this problem would be to implement in the glxsb driver software implementations for AES 192 et AES 256. (OpenBSD did it recently). But I think this is a hack and it's better to revert to another driver. diff of sys/opencrypto/crypto.c between 8-CURRENT http://user.lamaiziere.net/patrick/opencrypto-071208/crypto.c-diff sys/opencrypto/crypto.c http://user.lamaiziere.net/patrick/opencrypto-071208/crypto.c That should not break anything. It would be nice to test it on a box with a Geode LX CPU and a crypto device like a VPN1411 card. I don't have the hardware but I've checked that we revert to the cryptosoft driver when using ipsec and glxsb with AES key's length != 128 bits. Thanks, regards. From owner-freebsd-hackers@FreeBSD.ORG Sun Dec 7 22:56:14 2008 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 AB696106564A for ; Sun, 7 Dec 2008 22:56:14 +0000 (UTC) (envelope-from neldredge@math.ucsd.edu) Received: from euclid.ucsd.edu (euclid.ucsd.edu [132.239.145.52]) by mx1.freebsd.org (Postfix) with ESMTP id 8070F8FC18 for ; Sun, 7 Dec 2008 22:56:14 +0000 (UTC) (envelope-from neldredge@math.ucsd.edu) Received: from zeno.ucsd.edu (zeno.ucsd.edu [132.239.145.22]) by euclid.ucsd.edu (8.11.7p3+Sun/8.11.7) with ESMTP id mB7MuA625782; Sun, 7 Dec 2008 14:56:11 -0800 (PST) Received: from localhost (neldredg@localhost) by zeno.ucsd.edu (8.11.7p3+Sun/8.11.7) with ESMTP id mB7MuAr10286; Sun, 7 Dec 2008 14:56:10 -0800 (PST) X-Authentication-Warning: zeno.ucsd.edu: neldredg owned process doing -bs Date: Sun, 7 Dec 2008 14:56:10 -0800 (PST) From: Nate Eldredge X-X-Sender: neldredg@zeno.ucsd.edu To: Juergen Lock In-Reply-To: <20081207175556.GA61107@saturn.kn-bremen.de> Message-ID: References: <5f67a8c40812021718i4cc225fem5b02a448702ec606@mail.gmail.com> <7d6fde3d0812040327w7c92826i64c6073a453d65ef@mail.gmail.com> <5f67a8c40812040952u1364563awcfd493695e7fea7c@mail.gmail.com> <200812042046.mB4KkC0k016853@saturn.kn-bremen.de> <20081204212311.GA17962@saturn.kn-bremen.de> <20081207175556.GA61107@saturn.kn-bremen.de> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: Nate Eldredge , yanefbsd@gmail.com, freebsd-hackers@freebsd.org Subject: Re: AMD64 qemu completely broken? 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, 07 Dec 2008 22:56:14 -0000 On Sun, 7 Dec 2008, Juergen Lock wrote: > On Thu, Dec 04, 2008 at 02:43:47PM -0800, Nate Eldredge wrote: >> On Thu, 4 Dec 2008, Juergen Lock wrote: >> >>> I forgot to say the qemu-devel port (as well as the later snapshots I >>> posted about on -emulation) also support -curses, which shows the emulated >>> vga text(!)console on qemu's tty. This works quite well with FreeBSD guests >>> (even the isos) if you extend your xterm/whatever by one line (the default >>> vga textconsole is 80x25 instead of 80x24.) >> >> As long as we're sharing tips about qemu: >> >> I've recently been working with qemu on amd64 and have set up a Debian etch >> i386 guest which is working well. I am using the qemu-devel and >> kqemu-kmod-devel ports. I am not using -kernel-kqemu at the moment; I >> thought I would get things working before trying to speed up. >> >> Using qemu I've finally achieved my goal of being able to use flash on >> FreeBSD/amd64 (in some sense :-O). >> > Actually at least on RELENG_7 and later the original www/linux-flashplugin9 > + www/nspluginwrapper don't work too bad at least for video sites these > days (on 6 and 7.0 you need a patch and there it probably doesn't quite > work on SMP because another patch concerning SMP can't be merged.) See > e.g. this thread on -emulation for more: > http://lists.freebsd.org/pipermail/freebsd-emulation/2008-October/005433.html Thanks for the pointer. I will probably wait until 7.1 is out and ports are defrosted, so I can go straight to flash10 and not to have to do everything twice, but this information should be very helpful. >> '-net tap' works fine, but requires root privileges and >> is more work to set up. >> > Actually it doesn't require root privs to run, only to setup. > (Ok you _might_ need sudo to ifconfig the tap device and/or bridge > in the qemu-ifup script... But qemu itself can certainly run as user.) Okay. I was being lazy and letting qemu do some of that work for me. >> [*] Out of curiosity, I looked at some Unix Archive stuff and found the >> identical code in BSD's Net2, circa 1991. It is identified in a comment as >> a "quick hack" and adorned with several /* XXX */. Naturally the code and >> the comments survive intact, 17 years later. :-( >> > This might be somewhat more understandable if you know that the original > slirp code was written many moons ago and only later resurrected for > emulation purposes. (It was originally invented for dialup users that > logged into shellservers' gettys via serial modem lines so they could > also use the box' inet connection locally before things like ppp were > available...) Yep, I think I remember trying to use some slip implementation over a serial modem once. It's just unfortunate that qemu chose that code for their TCP/IP implementation rather than something else more modern. Not that I'm volunteering to update it :) -- Nate Eldredge neldredge@math.ucsd.edu From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 8 10:18:54 2008 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 AEC711065673 for ; Mon, 8 Dec 2008 10:18:54 +0000 (UTC) (envelope-from auryn@zirakzigil.org) Received: from mail.giulioferro.it (mail.giulioferro.it [85.18.102.52]) by mx1.freebsd.org (Postfix) with ESMTP id 67DAA8FC17; Mon, 8 Dec 2008 10:18:54 +0000 (UTC) (envelope-from auryn@zirakzigil.org) Received: from localhost (localhost [127.0.0.1]) by mail.giulioferro.it (Postfix) with ESMTP id 72F1B33C18; Mon, 8 Dec 2008 11:03:00 +0100 (CET) X-Virus-Scanned: amavisd-new at giulioferro.it Received: from mail.giulioferro.it ([127.0.0.1]) by localhost (aurynwork1sv1.giulioferro.it [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id gE5NlRKMHLIQ; Mon, 8 Dec 2008 11:02:57 +0100 (CET) Received: from [192.168.229.16] (localhost [127.0.0.1]) (Authenticated sender: gferro@giulioferro.it) by mail.giulioferro.it (Postfix) with ESMTP id A277F33C17; Mon, 8 Dec 2008 11:02:57 +0100 (CET) Message-ID: <493CF049.8070004@zirakzigil.org> Date: Mon, 08 Dec 2008 11:00:41 +0100 From: Giulio Ferro User-Agent: Thunderbird 2.0.0.18 (X11/20081125) MIME-Version: 1.0 To: vkashyap@freebsd.org, freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: Problems with twa 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, 08 Dec 2008 10:18:55 -0000 I've installed a 3ware 9500 sata controller with 4 1TB disks in raid 5. Apart from the usual wrong geometry warning the starting configuration is ok: I create a single partition with the default labels plus a /usr/home label with takes most of the disk space (about 2.7TB). When I reboot the system the /usr/home partition size drops unexplainably to about 640GB. In order to try to understand what happens I've installed freebsd anew, this time creating 2 partitions: the first one 50GB, the second about 2.7TB (the remaining space). Everything seems to work correctly. I reboot the system and lo! the second partitions shrinks to about 640GB and the partitioner (using sysinstall) tells me that there are 2048GB free! This happens both with freebsd 7 and 8 current amd64. Thanks for any help. From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 8 10:37:06 2008 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 E1E4C1065676 for ; Mon, 8 Dec 2008 10:37:06 +0000 (UTC) (envelope-from freebsd-hackers@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id 676A38FC1B for ; Mon, 8 Dec 2008 10:37:05 +0000 (UTC) (envelope-from freebsd-hackers@m.gmane.org) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1L9dU7-0001uF-Oo for freebsd-hackers@freebsd.org; Mon, 08 Dec 2008 10:37:03 +0000 Received: from lara.cc.fer.hr ([161.53.72.113]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 08 Dec 2008 10:37:03 +0000 Received: from ivoras by lara.cc.fer.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 08 Dec 2008 10:37:03 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-hackers@freebsd.org From: Ivan Voras Date: Mon, 08 Dec 2008 11:36:55 +0100 Lines: 61 Message-ID: References: <493CF049.8070004@zirakzigil.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig74292645D45E2B768062CBEF" X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: lara.cc.fer.hr User-Agent: Thunderbird 2.0.0.18 (X11/20081125) In-Reply-To: <493CF049.8070004@zirakzigil.org> X-Enigmail-Version: 0.95.0 Sender: news Subject: Re: Problems with twa 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, 08 Dec 2008 10:37:07 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig74292645D45E2B768062CBEF Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Giulio Ferro wrote: > I've installed a 3ware 9500 sata controller with 4 1TB disks > in raid 5. > Apart from the usual wrong geometry warning the starting configuration > is ok: I create a single partition with the default labels plus a /usr/= home > label with takes most of the disk space (about 2.7TB). >=20 > When I reboot the system the /usr/home partition size drops unexplainab= ly > to about 640GB. >=20 > In order to try to understand what happens I've installed freebsd anew,= > this > time creating 2 partitions: the first one 50GB, the second about 2.7TB = (the > remaining space). Everything seems to work correctly. > I reboot the system and lo! the second partitions shrinks to about 640G= B > and > the partitioner (using sysinstall) tells me that there are 2048GB free!= >=20 > This happens both with freebsd 7 and 8 current amd64. >=20 > Thanks for any help. It's probably because you cannot create bsdlabels or fdisk partitions larger than 2 TB. The sizes you're seeing are probably because of overflows in calculations. It's not that the OS doesn't support larger drives, the problem is the partition formats. You might succeed by creating two large partitions, one ending just before the 2 TB limit and one stretching the rest of the space, but a more robust way would be to either create two smaller volumes (if the controller supports creating them on the array) or you'll need to install FreeBSD on a separate, smaller array and partition the large array with GPT (or use ZFS). --------------enig74292645D45E2B768062CBEF 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.6 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFJPPjIldnAQVacBcgRAsk4AJ9ksMLD9Lv3EGUvOnq7M6oShfCRcACdELzK qjV5bCDbIYvDA2Ichhs3Wck= =J7g8 -----END PGP SIGNATURE----- --------------enig74292645D45E2B768062CBEF-- From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 8 15:06:07 2008 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 9095C1065670; Mon, 8 Dec 2008 15:06:07 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 8334D8FC1B; Mon, 8 Dec 2008 15:06:06 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id RAA12757; Mon, 08 Dec 2008 17:06:04 +0200 (EET) (envelope-from avg@icyb.net.ua) Message-ID: <493D37DB.6030902@icyb.net.ua> Date: Mon, 08 Dec 2008 17:06:03 +0200 From: Andriy Gapon User-Agent: Thunderbird 2.0.0.18 (X11/20081124) MIME-Version: 1.0 To: freebsd-usb@freebsd.org, FreeBSD Hackers References: <4912E462.4090608@icyb.net.ua> <491586B9.2020303@vwsoft.com> <4919851B.7050800@icyb.net.ua> <492FF127.807@icyb.net.ua> <20081128134802.GA75900@onelab2.iet.unipi.it> In-Reply-To: <20081128134802.GA75900@onelab2.iet.unipi.it> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Subject: Re: usb keyboard dying at loader prompt 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, 08 Dec 2008 15:06:07 -0000 [forwarded to the lists] on 28/11/2008 15:48 Luigi Rizzo said the following: > just as a test, can you check if /boot/loader from 6.2 (or sometime > before jan.2008 - e.g. you could take one from a 6.3 CD) which you > can also find at > > http://info.iet.unipi.it/~luigi/doc/20081128-freebsd-6.3-boot-loader > > gives the same behaviour ? > > I was seeing bugs related to the loader with pxeboot and > the behaviour that you mention below sounds related. > > It also sounds related to a problem that i a started having > recently with an usb keyboard after i upgraded to 7.x .... > in fact i am going to try this old loader myself! > > let me know how the old loader works and if it fixes the > problem i will relate the two issues and bring them up > on the lists for discussion Luigi, thank you very much for this! With your loader the things are much much better. The keyboard doesn't die anymore at the loader prompt! All in all, it seems that this is right direction. -- Andriy Gapon From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 8 19:41:52 2008 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 59985106564A for ; Mon, 8 Dec 2008 19:41:52 +0000 (UTC) (envelope-from freebsd-hackers@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id 0E54F8FC14 for ; Mon, 8 Dec 2008 19:41:51 +0000 (UTC) (envelope-from freebsd-hackers@m.gmane.org) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1L9lzI-0005Af-5B for freebsd-hackers@freebsd.org; Mon, 08 Dec 2008 19:41:48 +0000 Received: from 93-138-120-23.adsl.net.t-com.hr ([93.138.120.23]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 08 Dec 2008 19:41:48 +0000 Received: from ivoras by 93-138-120-23.adsl.net.t-com.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 08 Dec 2008 19:41:48 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-hackers@freebsd.org From: Ivan Voras Date: Mon, 08 Dec 2008 20:41:32 +0100 Lines: 42 Message-ID: Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigAC288EFC3F818D23A20E01B6" X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 93-138-120-23.adsl.net.t-com.hr User-Agent: Thunderbird 2.0.0.18 (Windows/20081105) X-Enigmail-Version: 0.95.7 Sender: news Subject: MAXFILES in subr_param.c 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, 08 Dec 2008 19:41:52 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigAC288EFC3F818D23A20E01B6 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi, I'm looking at kern/subr_param.c: 72 #ifndef MAXFILES 73 #define MAXFILES (maxproc * 2) 74 #endif Shouldn't this be at least maxproc*3, for stdin,out,err for every proc? Also, it looks like MAXFILES is used only once, and in a bit funny way: 238 maxfiles =3D MAXFILES; 239 TUNABLE_INT_FETCH("kern.maxfiles", &maxfiles); 240 maxprocperuid =3D (maxproc * 9) / 10; 241 maxfilesperproc =3D (maxfiles * 9) / 10; Historical reasons? --------------enigAC288EFC3F818D23A20E01B6 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.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAkk9eHIACgkQldnAQVacBciUbgCfX6chQ/3yf8+TeRRYLqgHzxqz +BYAoLanLIAbmknErIpZHECZD5eAddfV =Oauk -----END PGP SIGNATURE----- --------------enigAC288EFC3F818D23A20E01B6-- From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 8 20:21:58 2008 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 3F8AF1065673 for ; Mon, 8 Dec 2008 20:21:58 +0000 (UTC) (envelope-from philip@paeps.cx) Received: from gateway.nixsys.be (gateway.nixsys.be [IPv6:2001:6f8:32f::42]) by mx1.freebsd.org (Postfix) with ESMTP id DF8528FC13 for ; Mon, 8 Dec 2008 20:21:57 +0000 (UTC) (envelope-from philip@paeps.cx) Received: from detritus.paeps.cx (detritus.paeps.cx [IPv6:2001:6f8:1408::4]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client CN "detritus.paeps.cx", Issuer "CAcert Class 3 Root" (verified OK)) by gateway.nixsys.be (Postfix) with ESMTPS id 2B8E04056; Mon, 8 Dec 2008 21:21:57 +0100 (CET) Received: by detritus.paeps.cx (Postfix, from userid 1001) id 92DB920BC; Mon, 8 Dec 2008 21:21:55 +0100 (CET) Date: Mon, 8 Dec 2008 21:21:55 +0100 From: Philip Paeps To: Patrick =?utf-8?Q?Lamaizi=C3=A8re?= Message-ID: <20081208202155.GA7403@detritus.paeps.cx> Mail-Followup-To: Patrick =?utf-8?Q?Lamaizi=C3=A8re?= , freebsd-hackers@freebsd.org References: <20081207224551.13ca3590@baby-jane> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20081207224551.13ca3590@baby-jane> X-PGP-Fingerprint: 356B AE02 4763 F739 2FA2 E438 2649 E628 C5D3 4D05 X-Date: Today is Boomtime, the 50th day of The Aftermath in the YOLD 3174 X-Phase-of-Moon: The Moon is Waxing Gibbous (80% of Full) X-Message-Flag: Get a proper mailclient! Organization: Happily Disorganized User-Agent: Mutt/1.5.18 (2008-05-17) Cc: freebsd-hackers@freebsd.org Subject: Re: crypto(9) choose another driver if we cannot open a session on it 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, 08 Dec 2008 20:21:58 -0000 On 2008-12-07 22:45:51 (+0100), Patrick Lamaizière wrote: > I wrote a small patch to allow the crypto framework to choose another > cryptographic driver if we cannot open a session on the driver. Very cool. :-) I've been hacking on this too, mainly to get rid of the code duplication that currently exists. > That should not break anything. It would be nice to test it on a box with a > Geode LX CPU and a crypto device like a VPN1411 card. I don't have the > hardware but I've checked that we revert to the cryptosoft driver when using > ipsec and glxsb with AES key's length != 128 bits. I'll test that tonight. I think I've got a hifn card hiding somewhere near a soekris. Thanks! - Philip -- Philip Paeps Please don't Cc me, I am philip@freebsd.org subscribed to the list. "Maybe you should loosen her clothing or something." -- Gaspode the wonder dog (Terry Pratchett, Moving Pictures) From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 8 20:52:19 2008 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 034D4106564A for ; Mon, 8 Dec 2008 20:52:19 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id 76BC88FC16 for ; Mon, 8 Dec 2008 20:52:18 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from localhost.corp.yahoo.com (john@localhost [IPv6:::1]) (authenticated bits=0) by server.baldwin.cx (8.14.3/8.14.3) with ESMTP id mB8KqBnH003949; Mon, 8 Dec 2008 15:52:11 -0500 (EST) (envelope-from jhb@freebsd.org) From: John Baldwin To: freebsd-hackers@freebsd.org Date: Mon, 8 Dec 2008 15:17:39 -0500 User-Agent: KMail/1.9.7 References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200812081517.39375.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (server.baldwin.cx [IPv6:::1]); Mon, 08 Dec 2008 15:52:12 -0500 (EST) X-Virus-Scanned: ClamAV version 0.94.2, clamav-milter version 0.94.2 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-2.6 required=4.2 tests=AWL,BAYES_00,NO_RELAYS autolearn=ham version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on server.baldwin.cx Cc: Marius =?iso-8859-1?q?N=FCnnerich?= Subject: Re: Why safe using msleep with timeout=0 but not tsleep? 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, 08 Dec 2008 20:52:19 -0000 On Sunday 07 December 2008 02:00:30 pm Marius N=FCnnerich wrote: > See subject. > Interesting commit: > http://svn.freebsd.org/viewvc/base?view=3Drevision&revision=3D77059 Lost wakeups. If you have code like so that doesn't use any locks: int flag; void foo(void) { flag =3D 1; wakeup(&flag); } void bar(void) { if (flag =3D=3D 0) tsleep(&foo, ..., 0); } Then one CPU may run the 'foo' routine to completion after another CPU has= =20 seen 'flag =3D=3D 0' but before it has put the thread to sleep in tsleep().= Even=20 on UP systems with preemption you can still get this race if you get=20 preempted by an interrupt (which runs foo()) in between the 'flag =3D=3D 0'= test=20 and calling tsleep(). Using an interlock avoid this: struct mtx lock; int flag; void foo(void) { mtx_lock(&lock); flag =3D 1; mtx_unlock(&lock); wakeup(&flag); } void bar(void) { mtx_lock(&lock); if (flag =3D=3D 0) mtx_sleep(&foo, &lock, ..., 0); mtx_unlock(&lock); } In this case 'lock' closes the SMP/preemption races. =2D-=20 John Baldwin From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 8 22:51:14 2008 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 69823106564A; Mon, 8 Dec 2008 22:51:14 +0000 (UTC) (envelope-from sobomax@FreeBSD.org) Received: from sippysoft.com (gk1.360sip.com [72.236.70.240]) by mx1.freebsd.org (Postfix) with ESMTP id 311048FC08; Mon, 8 Dec 2008 22:51:13 +0000 (UTC) (envelope-from sobomax@FreeBSD.org) Received: from [192.168.1.38] (S0106001372fd1e07.vs.shawcable.net [70.71.171.106]) (authenticated bits=0) by sippysoft.com (8.13.8/8.13.8) with ESMTP id mB8Mf6OB093006 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 8 Dec 2008 14:41:06 -0800 (PST) (envelope-from sobomax@FreeBSD.org) Message-ID: <493DA269.2070805@FreeBSD.org> Date: Mon, 08 Dec 2008 14:40:41 -0800 From: Maxim Sobolev Organization: Sippy Software, Inc. User-Agent: Thunderbird 2.0.0.18 (Windows/20081105) MIME-Version: 1.0 To: hackers@FreeBSD.org, Luigi Rizzo , "current@freebsd.org" Content-Type: text/plain; charset=ISO-8859-2; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: Enhancing cdboot [patch for review] 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, 08 Dec 2008 22:51:14 -0000 Hi, Below please find patch that enhances cdboot with two compile-time options: 1. CDBOOT_SILENT. When this option is set, the cdboot doesn't produce any messages except "Loading, please wait..." and it also passes RBX_MUTE flag to the next stage to silence it as well. This is intended for custom installations where end-user is not required to see any messages or interfere with the boot process. 2. CDBOOT_PROMPT. When this option is enabled the cdboot behaves like windows xp or vista cd loader, that is it reads MBR from the first hard drive in the system and if the MBR is bootable (i.e. drive has some other operating system installed on it) then it presents user with "Press any key to boot from CD" prompt and waits 20 seconds. If key is not pressed then the control is passed to the MBR, otherwise CD is booted. This is intended for installation CD to allow unattended mode and also helps when installation CD is unintentionally left in the drive of the machine that is set to boot off CD. Any comments/suggestions are appreciated. If there are no objections I would like to commit the change. The long-term goal is to make CDBOOT_PROMPT default mode for installation CD. http://sobomax.sippysoft.com/~sobomax/cdboot.diff -Maxim From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 8 22:51:14 2008 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 EA6081065676; Mon, 8 Dec 2008 22:51:14 +0000 (UTC) (envelope-from sobomax@sippysoft.com) Received: from sippysoft.com (gk1.360sip.com [72.236.70.240]) by mx1.freebsd.org (Postfix) with ESMTP id B2A178FC0C; Mon, 8 Dec 2008 22:51:14 +0000 (UTC) (envelope-from sobomax@sippysoft.com) Received: from [192.168.1.38] (S0106001372fd1e07.vs.shawcable.net [70.71.171.106]) (authenticated bits=0) by sippysoft.com (8.13.8/8.13.8) with ESMTP id mB8MenNc092961 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 8 Dec 2008 14:40:50 -0800 (PST) (envelope-from sobomax@sippysoft.com) Message-ID: <493DA258.7010001@sippysoft.com> Date: Mon, 08 Dec 2008 14:40:24 -0800 From: Maxim Sobolev Organization: Sippy Software User-Agent: Thunderbird 2.0.0.18 (Windows/20081105) MIME-Version: 1.0 To: hackers@FreeBSD.org, Luigi Rizzo , "current@freebsd.org" Content-Type: text/plain; charset=KOI8-U; format=flowed Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Mon, 08 Dec 2008 23:06:16 +0000 Cc: Subject: Enhancing cdboot [patch for review] 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, 08 Dec 2008 22:51:15 -0000 Hi, Below please find patch that enhances cdboot with two compile-time options: 1. CDBOOT_SILENT. When this option is set, the cdboot doesn't produce any messages except "Loading, please wait..." and it also passes RBX_MUTE flag to the next stage to silence it as well. This is intended for custom installations where end-user is not required to see any messages or interfere with the boot process. 2. CDBOOT_PROMPT. When this option is enabled the cdboot behaves like windows xp or vista cd loader, that is it reads MBR from the first hard drive in the system and if the MBR is bootable (i.e. drive has some other operating system installed on it) then it presents user with "Press any key to boot from CD" prompt and waits 20 seconds. If key is not pressed then the control is passed to the MBR, otherwise CD is booted. This is intended for installation CD to allow unattended mode and also helps when installation CD is unintentionally left in the drive of the machine that is set to boot off CD. Any comments/suggestions are appreciated. If there are no objections I would like to commit the change. The long-term goal is to make CDBOOT_PROMPT default mode for installation CD. http://sobomax.sippysoft.com/~sobomax/cdboot.diff -Maxim From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 8 23:45:57 2008 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 E3AD5106567D for ; Mon, 8 Dec 2008 23:45:57 +0000 (UTC) (envelope-from marius@nuenneri.ch) Received: from rn-out-0910.google.com (rn-out-0910.google.com [64.233.170.185]) by mx1.freebsd.org (Postfix) with ESMTP id A39008FC1B for ; Mon, 8 Dec 2008 23:45:57 +0000 (UTC) (envelope-from marius@nuenneri.ch) Received: by rn-out-0910.google.com with SMTP id j71so1541783rne.12 for ; Mon, 08 Dec 2008 15:45:56 -0800 (PST) Received: by 10.90.28.12 with SMTP id b12mr1496671agb.115.1228779956189; Mon, 08 Dec 2008 15:45:56 -0800 (PST) Received: by 10.90.73.15 with HTTP; Mon, 8 Dec 2008 15:45:56 -0800 (PST) Message-ID: Date: Tue, 9 Dec 2008 00:45:56 +0100 From: "=?ISO-8859-1?Q?Marius_N=FCnnerich?=" To: "John Baldwin" In-Reply-To: <200812081517.39375.jhb@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <200812081517.39375.jhb@freebsd.org> Cc: freebsd-hackers@freebsd.org Subject: Re: Why safe using msleep with timeout=0 but not tsleep? 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, 08 Dec 2008 23:45:58 -0000 On Mon, Dec 8, 2008 at 9:17 PM, John Baldwin wrote: > On Sunday 07 December 2008 02:00:30 pm Marius N=FCnnerich wrote: >> See subject. >> Interesting commit: >> http://svn.freebsd.org/viewvc/base?view=3Drevision&revision=3D77059 > > Lost wakeups. If you have code like so that doesn't use any locks: > > int flag; > > void > foo(void) > { > > flag =3D 1; > wakeup(&flag); > } > > void > bar(void) > { > > if (flag =3D=3D 0) > tsleep(&foo, ..., 0); > } > > Then one CPU may run the 'foo' routine to completion after another CPU ha= s > seen 'flag =3D=3D 0' but before it has put the thread to sleep in tsleep(= ). Even > on UP systems with preemption you can still get this race if you get > preempted by an interrupt (which runs foo()) in between the 'flag =3D=3D = 0' test > and calling tsleep(). Using an interlock avoid this: > > struct mtx lock; > int flag; > > void > foo(void) > { > > mtx_lock(&lock); > flag =3D 1; > mtx_unlock(&lock); > wakeup(&flag); > } > > void > bar(void) > { > > mtx_lock(&lock); > if (flag =3D=3D 0) > mtx_sleep(&foo, &lock, ..., 0); > mtx_unlock(&lock); > } > > In this case 'lock' closes the SMP/preemption races. > > -- > John Baldwin > Thank you for the explanation, John! From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 8 23:46:20 2008 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 577811065709; Mon, 8 Dec 2008 23:46:20 +0000 (UTC) (envelope-from luigi@onelab2.iet.unipi.it) Received: from onelab2.iet.unipi.it (onelab2.iet.unipi.it [131.114.9.129]) by mx1.freebsd.org (Postfix) with ESMTP id 16EBE8FC24; Mon, 8 Dec 2008 23:46:19 +0000 (UTC) (envelope-from luigi@onelab2.iet.unipi.it) Received: by onelab2.iet.unipi.it (Postfix, from userid 275) id 4E3CB7309E; Tue, 9 Dec 2008 00:51:19 +0100 (CET) Date: Tue, 9 Dec 2008 00:51:19 +0100 From: Luigi Rizzo To: Maxim Sobolev Message-ID: <20081208235119.GA46608@onelab2.iet.unipi.it> References: <493DA269.2070805@FreeBSD.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <493DA269.2070805@FreeBSD.org> User-Agent: Mutt/1.4.2.3i Cc: Luigi Rizzo , hackers@freebsd.org, "current@freebsd.org" Subject: Re: Enhancing cdboot [patch for review] 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, 08 Dec 2008 23:46:20 -0000 On Mon, Dec 08, 2008 at 02:40:41PM -0800, Maxim Sobolev wrote: > Hi, > > Below please find patch that enhances cdboot with two compile-time options: ... > Any comments/suggestions are appreciated. If there are no objections I > would like to commit the change. The long-term goal is to make > CDBOOT_PROMPT default mode for installation CD. > > http://sobomax.sippysoft.com/~sobomax/cdboot.diff Looks good. Some comments: 1. since there is plenty of space in the cdboot sector, why don't you make the two option always compiled in, controlling which one to activate through flags in the bootsector itself, to be set patching the binary sector itself using a mechanism similar to boot0cfg. Of course you cannot alter a cdrom after you burn it, but it makes it easier to build CDs with one or the other defaults, patching cdboot or the iso image itself before creating/burning it. 2. in fact, the 'silent' option could be disabled at runtime by pressing some key (e.g. adding a short wait loop before proceeding; if this is meant for custom, unattended CDs the extra delay should not matter much); 3. one nitpick -- in one of the first chunks you replace $start with $LOAD, but if i am not mistaken operation depends on $LOAD = $start, so why don't you always use the same ? Also in terms of relocation size, wouldn't it be the case of hardwiring the size of the cd boot sector: - mov $((end_init - start)/2),%cx + mov 1024,%cx 4. another nitpick -- the value you pass in %si to the MBR does not seem to point to anything useful. As discussed about boot0.S and the followup in the mailing lists, there seems to be no standard but at least some MBR expect %si to point to a partition entry, so you should probably initialize one in a way similar way to that used by boot0.S cheers luigi From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 00:29:32 2008 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 59EA6106564A; Tue, 9 Dec 2008 00:29:32 +0000 (UTC) (envelope-from sobomax@FreeBSD.org) Received: from sippysoft.com (gk1.360sip.com [72.236.70.240]) by mx1.freebsd.org (Postfix) with ESMTP id 17DD78FC16; Tue, 9 Dec 2008 00:29:31 +0000 (UTC) (envelope-from sobomax@FreeBSD.org) Received: from [192.168.1.38] (S0106001372fd1e07.vs.shawcable.net [70.71.171.106]) (authenticated bits=0) by sippysoft.com (8.13.8/8.13.8) with ESMTP id mB90TTqG098401 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 8 Dec 2008 16:29:30 -0800 (PST) (envelope-from sobomax@FreeBSD.org) Message-ID: <493DBBD0.5080705@FreeBSD.org> Date: Mon, 08 Dec 2008 16:29:04 -0800 From: Maxim Sobolev Organization: Sippy Software, Inc. User-Agent: Thunderbird 2.0.0.18 (Windows/20081105) MIME-Version: 1.0 To: Luigi Rizzo References: <493DA269.2070805@FreeBSD.org> <20081208235119.GA46608@onelab2.iet.unipi.it> In-Reply-To: <20081208235119.GA46608@onelab2.iet.unipi.it> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Luigi Rizzo , hackers@FreeBSD.org, "current@freebsd.org" Subject: Re: Enhancing cdboot [patch for review] 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, 09 Dec 2008 00:29:32 -0000 Luigi Rizzo wrote: > On Mon, Dec 08, 2008 at 02:40:41PM -0800, Maxim Sobolev wrote: >> Hi, >> >> Below please find patch that enhances cdboot with two compile-time options: > ... >> Any comments/suggestions are appreciated. If there are no objections I >> would like to commit the change. The long-term goal is to make >> CDBOOT_PROMPT default mode for installation CD. >> >> http://sobomax.sippysoft.com/~sobomax/cdboot.diff > > Looks good. Some comments: Thank you for the review and comments. Please see my answers below. > 1. since there is plenty of space in the cdboot sector, why don't you > make the two option always compiled in, controlling which one to > activate through flags in the bootsector itself, to be set > patching the binary sector itself using a mechanism similar to > boot0cfg. > Of course you cannot alter a cdrom after you burn it, > but it makes it easier to build CDs with one or the other defaults, > patching cdboot or the iso image itself before creating/burning it. > > 2. in fact, the 'silent' option could be disabled at runtime by > pressing some key (e.g. adding a short wait loop before proceeding; > if this is meant for custom, unattended CDs the extra delay should not > matter much); Good idea, I will see if I can put that in. In fact this behavior should have to be optional as well, since one of the uses for the "silent" option here is to provide tamper-resistant boot process on custom hardware. > 3. one nitpick -- in one of the first chunks you replace $start > with $LOAD, but if i am not mistaken operation depends on $LOAD = $start, > so why don't you always use the same ? No, they are not the same. $LOAD is address where BIOS loads boot sector, which is 0x7c00 by default (you can configure it when building CD-ROM, which is why it's an option). On the other hand, $start is address where code is compiled to be located, which is 0x0600. > Also in terms of relocation size, wouldn't it be the case of > hardwiring the size of the cd boot sector: > > - mov $((end_init - start)/2),%cx > + mov 1024,%cx Well, I don't see the reason to hardwire this. CDROM boot code can be of different size (within certain limits of course, to be selected when building ISO), it's not limited to fixed number of sectors like boot[012]. > 4. another nitpick -- the value you pass in %si to the MBR does not > seem to point to anything useful. As discussed about boot0.S and > the followup in the mailing lists, there seems to be no standard > but at least some MBR expect %si to point to a partition entry, > so you should probably initialize one in a way similar way to that > used by boot0.S Hmm, maybe I misunderstood it then. What do you mean by "point to partition entry exactly"? Right now it points to the beginning on MBR. -Maxim From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 01:29:41 2008 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 2A4CF1065672; Tue, 9 Dec 2008 01:29:41 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from igloo.linux.gr (igloo.linux.gr [62.1.205.36]) by mx1.freebsd.org (Postfix) with ESMTP id 9890C8FC0C; Tue, 9 Dec 2008 01:29:40 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from kobe.laptop (adsl200-163.kln.forthnet.gr [79.103.13.163]) (authenticated bits=128) by igloo.linux.gr (8.14.3/8.14.3/Debian-5) with ESMTP id mB91TVeb001263 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Tue, 9 Dec 2008 03:29:36 +0200 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.3/8.14.3) with ESMTP id mB91TVmd066821; Tue, 9 Dec 2008 03:29:31 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) Received: (from keramida@localhost) by kobe.laptop (8.14.3/8.14.3/Submit) id mB91TS4q066732; Tue, 9 Dec 2008 03:29:28 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) From: Giorgos Keramidas To: Maxim Sobolev References: <493DA269.2070805@FreeBSD.org> <20081208235119.GA46608@onelab2.iet.unipi.it> <493DBBD0.5080705@FreeBSD.org> Date: Tue, 09 Dec 2008 03:29:28 +0200 In-Reply-To: <493DBBD0.5080705@FreeBSD.org> (Maxim Sobolev's message of "Mon, 08 Dec 2008 16:29:04 -0800") Message-ID: <87oczmjfuv.fsf@kobe.laptop> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-MailScanner-ID: mB91TVeb001263 X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-3.957, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL 0.44, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@ceid.upatras.gr X-Spam-Status: No Cc: Luigi Rizzo , hackers@freebsd.org, Luigi Rizzo , "current@freebsd.org" Subject: Re: Enhancing cdboot [patch for review] 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, 09 Dec 2008 01:29:41 -0000 On Mon, 08 Dec 2008 16:29:04 -0800, Maxim Sobolev wrote: > Luigi Rizzo wrote: >> On Mon, Dec 08, 2008 at 02:40:41PM -0800, Maxim Sobolev wrote: >>> Hi, >>> Below please find patch that enhances cdboot with two compile-time options: >> ... >>> Any comments/suggestions are appreciated. If there are no objections I >>> would like to commit the change. The long-term goal is to make >>> CDBOOT_PROMPT default mode for installation CD. >>> >>> http://sobomax.sippysoft.com/~sobomax/cdboot.diff >> >> Looks good. Some comments: > > Thank you for the review and comments. Please see my answers below. > >> 1. since there is plenty of space in the cdboot sector, why don't you >> make the two option always compiled in, controlling which one to >> activate through flags in the bootsector itself, to be set >> patching the binary sector itself using a mechanism similar to >> boot0cfg. >> Of course you cannot alter a cdrom after you burn it, >> but it makes it easier to build CDs with one or the other defaults, >> patching cdboot or the iso image itself before creating/burning it. >> >> 2. in fact, the 'silent' option could be disabled at runtime by >> pressing some key (e.g. adding a short wait loop before proceeding; >> if this is meant for custom, unattended CDs the extra delay should not >> matter much); > > Good idea, I will see if I can put that in. In fact this behavior should > have to be optional as well, since one of the uses for the "silent" > option here is to provide tamper-resistant boot process on custom > hardware. Nice pair of features :-) If there are no pressing space constraints maybe we can build both options in by default, but still make them opt-out when necessary? With a bit of makefile glue we can make it possible to compile with an `src.conf' that includes: WITH_CDBOOT_SILENT=1 WITHOUT_CDBOOT_PROMPT=1 This way the defaults can include support for both options, but we can conditionally compile *out* the bits that are not needed for some custom installation. Something like this can define one or both of these options in CFLAGS, depending on what `src.conf' contains: # When CDBOOT_SILENT is set, the cdboot doesn't produce any messages except # "Loading, please wait..." and it also passes RBX_MUTE flag to the next # stage to silence it as well. This is intended for custom installations # where end-user is not required to see any messages or interfere with the # boot process. .if ${MK_CDBOOT_SILENT} != "no" CFLAGS+= -DCDBOOT_SILENT .endif # When CDBOOT_PROMPT is enabled the cdboot behaves like windows xp or vista # cd loader, that is it reads MBR from the first hard drive in the system # and if the MBR is bootable (i.e. drive has some other operating system # installed on it) then it presents user with "Press any key to boot from # CD" prompt and waits for 20 seconds. If key is not pressed then the # control is passed to the MBR, otherwise CD is booted. This is intended for # installation CD to allow unattended mode and also helps when installation # CD has been unintentionally left in the drive of the machine that is set # to boot off CD. .if ${MK_CDBOOT_PROMPT} != "no" CFLAGS+= -DCDBOOT_PROMPT .endif The defaults for ${MK_CDBOOT_XXX} will have to be explicitly set in `src/share/mk/bsd.own.mk', near line 281: 281 # 282 # MK_* options which default to "yes". 283 # 284 .for var in \ ... But that shouldn't be a problem, AFAICT :-) From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 03:39:57 2008 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 B1CE91065670; Tue, 9 Dec 2008 03:39:57 +0000 (UTC) (envelope-from luigi@onelab2.iet.unipi.it) Received: from onelab2.iet.unipi.it (onelab2.iet.unipi.it [131.114.9.129]) by mx1.freebsd.org (Postfix) with ESMTP id 707AF8FC13; Tue, 9 Dec 2008 03:39:57 +0000 (UTC) (envelope-from luigi@onelab2.iet.unipi.it) Received: by onelab2.iet.unipi.it (Postfix, from userid 275) id 4AA3E73098; Tue, 9 Dec 2008 04:44:56 +0100 (CET) Date: Tue, 9 Dec 2008 04:44:56 +0100 From: Luigi Rizzo To: Maxim Sobolev Message-ID: <20081209034456.GA54569@onelab2.iet.unipi.it> References: <493DA269.2070805@FreeBSD.org> <20081208235119.GA46608@onelab2.iet.unipi.it> <493DBBD0.5080705@FreeBSD.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <493DBBD0.5080705@FreeBSD.org> User-Agent: Mutt/1.4.2.3i Cc: Luigi Rizzo , hackers@freebsd.org, "current@freebsd.org" Subject: Re: Enhancing cdboot [patch for review] 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, 09 Dec 2008 03:39:57 -0000 On Mon, Dec 08, 2008 at 04:29:04PM -0800, Maxim Sobolev wrote: > Luigi Rizzo wrote: ... > >4. another nitpick -- the value you pass in %si to the MBR does not > > seem to point to anything useful. As discussed about boot0.S and > > the followup in the mailing lists, there seems to be no standard > > but at least some MBR expect %si to point to a partition entry, > > so you should probably initialize one in a way similar way to that > > used by boot0.S > > Hmm, maybe I misunderstood it then. What do you mean by "point to > partition entry exactly"? Right now it points to the beginning on MBR. ok, so here is what I know. Even though there is no standard, at least ldlinux.sys and perhaps other bootloaders expect %si to point to a 16-byte record containing the partition descriptor (same structure as one of the 4 records at 0x1be in the MBR) for the partition they were loaded from. ldlinux.sys uses this info to "relocate": it knows the location of the other sectors of ldlinux.sys relative to the beginning of the partition, and uses the start-of-partition from the record at %si to compute these locations in terms of absolute disk positions. Note that in principle a MBR does not need this info -- even if it is a multi-sector boot code such as boot0ext, it may well assume to be located at offset 0. On the other hand if the code on the MBR uses %si, then you should set the entry so that at least the starting CHS and LBA info point to the first sector on disk, i.e. CHS=0,0,1 and LBA=0. In practical terms -- make %si point to a 16-byte area of memory containing all 0's except for the byte representing the sector number for the start of the partition. See the code in a recent sys/boot/i386/boot0/boot0.S which gives some details on this. cheers luigi From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 04:49:10 2008 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 71CB3106564A; Tue, 9 Dec 2008 04:49:10 +0000 (UTC) (envelope-from sobomax@FreeBSD.org) Received: from sippysoft.com (gk1.360sip.com [72.236.70.240]) by mx1.freebsd.org (Postfix) with ESMTP id 1C1DD8FC12; Tue, 9 Dec 2008 04:49:09 +0000 (UTC) (envelope-from sobomax@FreeBSD.org) Received: from [192.168.1.38] (S0106001372fd1e07.vs.shawcable.net [70.71.171.106]) (authenticated bits=0) by sippysoft.com (8.13.8/8.13.8) with ESMTP id mB94n6KT010797 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 8 Dec 2008 20:49:08 -0800 (PST) (envelope-from sobomax@FreeBSD.org) Message-ID: <493DF8A3.6070905@FreeBSD.org> Date: Mon, 08 Dec 2008 20:48:35 -0800 From: Maxim Sobolev Organization: Sippy Software, Inc. User-Agent: Thunderbird 2.0.0.18 (Windows/20081105) MIME-Version: 1.0 To: Luigi Rizzo References: <493DA269.2070805@FreeBSD.org> <20081208235119.GA46608@onelab2.iet.unipi.it> <493DBBD0.5080705@FreeBSD.org> <20081209034456.GA54569@onelab2.iet.unipi.it> In-Reply-To: <20081209034456.GA54569@onelab2.iet.unipi.it> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Luigi Rizzo , hackers@FreeBSD.org, "current@freebsd.org" Subject: Re: Enhancing cdboot [patch for review] 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, 09 Dec 2008 04:49:10 -0000 Luigi Rizzo wrote: > On Mon, Dec 08, 2008 at 04:29:04PM -0800, Maxim Sobolev wrote: >> Luigi Rizzo wrote: > ... >>> 4. another nitpick -- the value you pass in %si to the MBR does not >>> seem to point to anything useful. As discussed about boot0.S and >>> the followup in the mailing lists, there seems to be no standard >>> but at least some MBR expect %si to point to a partition entry, >>> so you should probably initialize one in a way similar way to that >>> used by boot0.S >> Hmm, maybe I misunderstood it then. What do you mean by "point to >> partition entry exactly"? Right now it points to the beginning on MBR. > > ok, so here is what I know. > > Even though there is no standard, at least ldlinux.sys and perhaps > other bootloaders expect %si to point to a 16-byte record containing > the partition descriptor (same structure as one of the 4 records > at 0x1be in the MBR) for the partition they were loaded from. > > ldlinux.sys uses this info to "relocate": it knows the location of the > other sectors of ldlinux.sys relative to the beginning of the partition, > and uses the start-of-partition from the record at %si to compute > these locations in terms of absolute disk positions. > > Note that in principle a MBR does not need this info -- even if it > is a multi-sector boot code such as boot0ext, it may well assume to > be located at offset 0. > > On the other hand if the code on the MBR uses %si, then you should > set the entry so that at least the starting CHS and LBA info point > to the first sector on disk, i.e. CHS=0,0,1 and LBA=0. > > In practical terms -- make %si point to a 16-byte area of memory > containing all 0's except for the byte representing the sector > number for the start of the partition. > See the code in a recent sys/boot/i386/boot0/boot0.S which gives > some details on this. I see, thank you for the explanation. It looks like it only makes sense for multi-stage boot loaders, when the stage has been loaded from some location within the disk and it needs some clue to determine where it has came from. In this case we simply emulate BIOS loading MBR, and from what I've read here MBR code should make no assumptions with regard to %si, so that I would just set it to zero. Do you think it could create any issues? -Maxim From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 11:18:55 2008 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 1DE5A1065675 for ; Tue, 9 Dec 2008 11:18:55 +0000 (UTC) (envelope-from freebsd-hackers@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id CA90B8FC17 for ; Tue, 9 Dec 2008 11:18:54 +0000 (UTC) (envelope-from freebsd-hackers@m.gmane.org) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1LA0c6-0001xN-Ev for freebsd-hackers@freebsd.org; Tue, 09 Dec 2008 11:18:50 +0000 Received: from 195.208.174.178 ([195.208.174.178]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 09 Dec 2008 11:18:50 +0000 Received: from vadim_nuclight by 195.208.174.178 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 09 Dec 2008 11:18:50 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-hackers@freebsd.org From: Vadim Goncharov Date: Tue, 9 Dec 2008 11:18:42 +0000 (UTC) Organization: Nuclear Lightning @ Tomsk, TPU AVTF Hostel Lines: 14 Message-ID: References: <200811240152.13032.ken@mthelicon.com> <20081124122718.GB28709@rink.nu> X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 195.208.174.178 X-Comment-To: Rink Springer User-Agent: slrn/0.9.8.1 (FreeBSD) Sender: news Subject: Re: who on FreeBSD 8.0 - AMD64 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: vadim_nuclight@mail.ru List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Dec 2008 11:18:55 -0000 Hi Rink Springer! On Mon, 24 Nov 2008 13:27:18 +0100; Rink Springer wrote about 'Re: who on FreeBSD 8.0 - AMD64': >> By the way, are there pseudo-terminal names renamed in -CURRENT ? Why? > Yes, this is the result of the new giant-free TTY layer that was > imported a few months ago. What was the reason to rename? Isn't that a POLA violation for both users/older software? -- WBR, Vadim Goncharov. ICQ#166852181 mailto:vadim_nuclight@mail.ru [Moderator of RU.ANTI-ECOLOGY][FreeBSD][http://antigreen.org][LJ:/nuclight] From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 15:02:51 2008 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 5E4E41065673 for ; Tue, 9 Dec 2008 15:02:51 +0000 (UTC) (envelope-from bsd.quest@googlemail.com) Received: from yw-out-2324.google.com (yw-out-2324.google.com [74.125.46.29]) by mx1.freebsd.org (Postfix) with ESMTP id 10DEC8FC19 for ; Tue, 9 Dec 2008 15:02:50 +0000 (UTC) (envelope-from bsd.quest@googlemail.com) Received: by yw-out-2324.google.com with SMTP id 9so677986ywe.13 for ; Tue, 09 Dec 2008 07:02:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:date:from:to:subject :message-id:reply-to:mail-followup-to:mime-version:content-type :content-disposition:user-agent; bh=XzjE+U4Phmy5ZVx/N2IKDTOR6ezBLgXB8cAr22pd7eE=; b=J9MpS4TR9qQiZdicKClCMDoWaHBT+v5MvytI3cOPqZI/O2JiuaojUEeE5ETSnhJGqs UsnHdODCWrucdytjY59vjG5moc/3bIV+WFeFuHfWJsBztQ2tXhOcVbDBiGfQiXovTvna nsn1CjGHUmfnIs8dNHFSis6jQxToeL6I4S4JY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=date:from:to:subject:message-id:reply-to:mail-followup-to :mime-version:content-type:content-disposition:user-agent; b=oW1xzCBlKuehh6XwDqa0G72mfqo0ATMIQxQwEmfNddgAhuTW6+4qzKP/RhVWcIcAL9 weEBKgZlt4zNoZ/6ha/IY5K3V2TGjqa2IsMm/wBGNJY7az6E/qrVVYiVsjRqkS0QVW2G rxY4qeVZIQft2e+CTjJ3koKCG3dEMnJDo8aAY= Received: by 10.86.59.18 with SMTP id h18mr67478fga.42.1228834969637; Tue, 09 Dec 2008 07:02:49 -0800 (PST) Received: from localhost (BAJ113e.baj.pppool.de [77.137.17.62]) by mx.google.com with ESMTPS id l12sm163760fgb.45.2008.12.09.07.02.47 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 09 Dec 2008 07:02:48 -0800 (PST) Date: Tue, 9 Dec 2008 16:02:21 +0100 From: Alexej Sokolov To: freebsd-hackers@freebsd.org Message-ID: <20081209150221.GC2875@debian.samsung.router> Mail-Followup-To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) Subject: vm_map (9) + MAP_PREFAULT and MAP_PREFAULT_PARTIAL X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Alexej Sokolov List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Dec 2008 15:02:51 -0000 Hello, could anyone explain what exactly do the cow-flags MAP_PREFAULT_PARTIAL, MAP_PREFAULT. I couldn't understand it from man pages and from source code. It's mean that the pages will be wired ? Thanks, -- Alexej Sokolov From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 16:46:33 2008 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 9BC931065675 for ; Tue, 9 Dec 2008 16:46:33 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.249]) by mx1.freebsd.org (Postfix) with ESMTP id 4D6638FC19 for ; Tue, 9 Dec 2008 16:46:33 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: by an-out-0708.google.com with SMTP id b6so22124ana.13 for ; Tue, 09 Dec 2008 08:46:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=IBjk28Z0E/BJrfZjN5k+QSCdwDC/Kru/UIxPDWRDMUI=; b=TNO9nOqocJsjhw8v+lBJCada+J4w7la0sAoTc7YRqKtfeUc6prq0YAQdWV0/eYX/vn kVsT5/9Uql5id4cdVr3pNjD0V0tExxv2JmtduMRi+udse64q9jq4cSO2Jx3yUR8+qrdZ PSjM48eYD0pqO4WQFa/05at3AZ4UT6T93EAEI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=hczBpxOI/+YkhIqTOptbqym5SGB1XwSY+urrqwJNZc+ROpeYPtsvDkv+vrtfiERLqR 9bdu3nSkH8a3ROFwGqQVbQQl07ZlZgeBZrPFbmYlwcvvAztsXha1ZGLg7ESyxi5pYgAG nsKHH/6YBB9Hvw/1Cuk3TE6GfJz3fKvwrzTPw= Received: by 10.114.124.12 with SMTP id w12mr203466wac.210.1228841192096; Tue, 09 Dec 2008 08:46:32 -0800 (PST) Received: by 10.90.114.14 with HTTP; Tue, 9 Dec 2008 08:46:31 -0800 (PST) Message-ID: Date: Tue, 9 Dec 2008 19:46:31 +0300 From: pluknet To: vadim_nuclight@mail.ru In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <200811240152.13032.ken@mthelicon.com> <20081124122718.GB28709@rink.nu> Cc: freebsd-hackers@freebsd.org Subject: Re: who on FreeBSD 8.0 - AMD64 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, 09 Dec 2008 16:46:33 -0000 2008/12/9 Vadim Goncharov : > Hi Rink Springer! > > On Mon, 24 Nov 2008 13:27:18 +0100; Rink Springer wrote about 'Re: who on FreeBSD 8.0 - AMD64': > >>> By the way, are there pseudo-terminal names renamed in -CURRENT ? Why? >> Yes, this is the result of the new giant-free TTY layer that was >> imported a few months ago. > > What was the reason to rename? Isn't that a POLA violation for both > users/older software? > You should read pty(4). -- wbr, pluknet From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 18:13:31 2008 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 2939A1065670 for ; Tue, 9 Dec 2008 18:13:31 +0000 (UTC) (envelope-from bounces@nabble.com) Received: from kuber.nabble.com (kuber.nabble.com [216.139.236.158]) by mx1.freebsd.org (Postfix) with ESMTP id F3CF18FC08 for ; Tue, 9 Dec 2008 18:13:30 +0000 (UTC) (envelope-from bounces@nabble.com) Received: from isper.nabble.com ([192.168.236.156]) by kuber.nabble.com with esmtp (Exim 4.63) (envelope-from ) id 1LA75L-0001LY-Va for freebsd-hackers@freebsd.org; Tue, 09 Dec 2008 10:13:28 -0800 Message-ID: <20920300.post@talk.nabble.com> Date: Tue, 9 Dec 2008 10:13:27 -0800 (PST) From: ancelgray To: freebsd-hackers@freebsd.org In-Reply-To: <20786956.post@talk.nabble.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Nabble-From: ancelgray@yahoo.com References: <20080121170155.GC51116@hamlet.SetFilePointer.com> <20713056.post@talk.nabble.com> <20786956.post@talk.nabble.com> Subject: Re: Hardware support for AMD Geode CS5536 audio? 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, 09 Dec 2008 18:13:31 -0000 Lionel, Well, I installed mpg123 on my PC Engines ALIX 1C and it worked fine playing mp3 files without changing my snd_amd5536.ko driver. However, I have gone ahead and made a version of snd_amd5536.ko that has larger default buffers. Hopefully, this will work on your machine. Go here: http://modelofreality.org/snd_amd5536.html and download snd_amd5536.ko underneath where it says "Here's a version with larger (2k) default buffers for test:" Don't forget to turn off the vchan interface with "sysctl dev.pcm.0.play.vchans=0" You must do this after each driver reload. Let me know how it goes. Andrew -- View this message in context: http://www.nabble.com/Hardware-support-for-AMD-Geode-CS5536-audio--tp15002428p20920300.html Sent from the freebsd-hackers mailing list archive at Nabble.com. From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 19:01:10 2008 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 E38A3106568C for ; Tue, 9 Dec 2008 19:01:10 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (adsl-63-193-123-122.dsl.snfc21.pacbell.net [63.193.123.122]) by mx1.freebsd.org (Postfix) with ESMTP id 715138FC2C for ; Tue, 9 Dec 2008 19:01:10 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (localhost [127.0.0.1]) by albert.catwhisker.org (8.14.3/8.14.3) with ESMTP id mB9J1AWg090301 for ; Tue, 9 Dec 2008 11:01:10 -0800 (PST) (envelope-from david@albert.catwhisker.org) Received: (from david@localhost) by albert.catwhisker.org (8.14.3/8.14.3/Submit) id mB9J1A05090300 for hackers@freebsd.org; Tue, 9 Dec 2008 11:01:10 -0800 (PST) (envelope-from david) Date: Tue, 9 Dec 2008 11:01:10 -0800 From: David Wolfskill To: hackers@freebsd.org Message-ID: <20081209190110.GW60731@albert.catwhisker.org> References: <20081203001538.GC96383@bunrab.catwhisker.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="dQ+ozEaLk2y6HH72" Content-Disposition: inline In-Reply-To: <20081203001538.GC96383@bunrab.catwhisker.org> User-Agent: Mutt/1.4.2.3i Cc: Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 09 Dec 2008 19:01:11 -0000 --dQ+ozEaLk2y6HH72 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Dec 02, 2008 at 04:15:38PM -0800, David Wolfskill wrote: > I seem to have a fairly- (though not deterministly so) reproducible > mode of failure with an NFS-mounted directory hierarchy: An attempt to > traverse a "sufficiently large" hierarchy (e.g., via "tar zcpf" or "rm > -fr") will fail to "visit" some subdirectories, typically apparently > acting as if the subdirectories in question do not actually exist > (despite the names having been returned in the output of a previous > readdir()). > ...=20 I was able to reproduce the external symptoms of the failure running CURRENT as of yesterday, using "rm -fr" of a copy of a recent /usr/ports hierachy on an NFS-mounted file system as a test case. However, I believe the mechanism may be a bit different -- while still being other than what I would expect. One aspect in which the externally-observable symptoms were different (under CURRENT, vs. RELENG_7) is that under CURRENT, once the error condition occurred, the NFS client machine was in a state where it merely kept repeating nfs server pid848@fbsd-build:/volume: not responding until I logged in as root & rebooted it. Here's a cut/paste of the kdump from the ktrace of the amd(8) process under CURRENT, showing where the master amd(8) process (pid 848) forks a child (4126) to try the unmount: 848 amd 1228846258.722953 CALL gettimeofday(0x8078e48,0) 848 amd 1228846258.722964 RET gettimeofday 0 848 amd 1228846258.722982 CALL sigprocmask(SIG_BLOCK,0xbfbfeaec,0x= bfbfeadc) 848 amd 1228846258.722993 RET sigprocmask 0 848 amd 1228846258.723003 CALL fork 848 amd 1228846258.730250 RET fork 4126/0x101e 848 amd 1228846258.730405 CALL sigprocmask(SIG_SETMASK,0xbfbfeadc,= 0) 4126 amd 1228846258.730252 RET fork 0 4126 amd 1228846258.730456 CALL getpid 4126 amd 1228846258.730467 RET getpid 4126/0x101e 4126 amd 1228846258.730493 CALL unmount(0x2825f340,0) 848 amd 1228846258.730422 RET sigprocmask 0 848 amd 1228846258.730595 CALL gettimeofday(0x8078e48,0) 848 amd 1228846258.730608 RET gettimeofday 0 =2E.. 848 amd 1228846258.914814 CALL sigprocmask(SIG_SETMASK,0xbfbfeba0,= 0) 848 amd 1228846258.914826 RET sigprocmask 0 848 amd 1228846258.914838 CALL select(0x400,0xbfbfec40,0,0,0xbfbfe= cd8) 4126 amd 1228846259.090428 RET unmount 0 4126 amd 1228846259.090492 CALL sigprocmask(SIG_BLOCK,0x2809b080,0x= bfbfea0c) 4126 amd 1228846259.090505 RET sigprocmask 0 4126 amd 1228846259.090518 CALL sigprocmask(SIG_SETMASK,0x2809b090,= 0) 4126 amd 1228846259.090530 RET sigprocmask 0 4126 amd 1228846259.090545 CALL sigprocmask(SIG_BLOCK,0x2809b080,0x= bfbfe9dc) 4126 amd 1228846259.090556 RET sigprocmask 0 4126 amd 1228846259.090576 CALL sigprocmask(SIG_SETMASK,0x2809b090,= 0) 4126 amd 1228846259.090587 RET sigprocmask 0 4126 amd 1228846259.090605 CALL exit(0) 848 amd 1228846259.091248 RET select -1 errno 4 Interrupted syste= m call 848 amd 1228846259.091277 PSIG SIGCHLD caught handler=3D0x805e090 = mask=3D0x0 code=3D0x0 848 amd 1228846259.091298 CALL wait4(0xffffffff,0xbfbfe83c,WNOHANG= ,0) 848 amd 1228846259.091329 RET wait4 4126/0x101e 848 amd 1228846259.091342 CALL wait4(0xffffffff,0xbfbfe83c,WNOHANG= ,0) 848 amd 1228846259.091352 RET wait4 -1 errno 10 No child processes 848 amd 1228846259.091365 CALL sigprocmask(SIG_SETMASK,0x80795bc,0) 848 amd 1228846259.091377 RET sigprocmask 0 848 amd 1228846259.091390 CALL sigprocmask(SIG_BLOCK,0x80792c4,0) 848 amd 1228846259.091401 RET sigprocmask 0 848 amd 1228846259.091411 CALL gettimeofday(0x8078e48,0) 848 amd 1228846259.091422 RET gettimeofday 0 Note that while the child didn't get EBUSY (as it does under RELENG_7) -- indeed, the unmount call appears to have returned 0 -- the master amd(8) process looks to be seeing "errno 4 Interrupted system call." And here's a relevent part of the kdump from the "rm -fr" -- I had kdump spit out Epoch timestamps with each in order to make correlation easier: 4121 rm 1228846258.736266 CALL unlink(0x2821c148) 4121 rm 1228846258.736281 NAMI "distinfo" 4121 rm 1228846258.738329 RET unlink 0 4121 rm 1228846258.738379 CALL unlink(0x2821c1b8) 4121 rm 1228846258.738401 NAMI "pkg-descr" 4121 rm 1228846258.739963 RET unlink 0 4121 rm 1228846258.739982 CALL open(0x28178b6b,O_RDONLY,0) 4121 rm 1228846258.740002 NAMI ".." 4121 rm 1228846258.740541 RET open 4 4121 rm 1228846258.740558 CALL fstat(0x4,0xbfbfe96c) 4121 rm 1228846258.740579 STRU struct stat {dev=3D67174155, ino=3D= 22674937, mode=3Ddrwxr-xr-x , nlink=3D114, uid=3D9874, gid=3D929, rdev=3D0,= atime=3D1228846258.184514000, stime =3D1228846258.779501000, ctime=3D1228846258.779501000, birthtime=3D-1, size= =3D12288, blksize=3D4096, blocks=3D24, flags=3D0x0 } 4121 rm 1228846258.740593 RET fstat 0 4121 rm 1228846258.740608 CALL fchdir(0x4) 4121 rm 1228846258.740626 RET fchdir 0 4121 rm 1228846258.740641 CALL close(0x4) 4121 rm 1228846258.740976 RET close 0 4121 rm 1228846258.740991 CALL rmdir(0x2821c538) 4121 rm 1228846258.741007 NAMI "dnscheck" 4121 rm 1228846258.741764 RET rmdir 0 4121 rm 1228846258.741783 CALL stat(0x2821d028,0xbfbfe900) 4121 rm 1228846258.741799 NAMI "dnsdoctor" 4121 rm 1228846258.742050 STRU struct stat {dev=3D67174155, ino=3D= 2519891, mode=3Ddrwxr-xr-x , nlink=3D3, uid=3D9874, gid=3D929, rdev=3D0, at= ime=3D1228844788, stime=3D1227555712,=20 ctime=3D1228845836.981842000, birthtime=3D-1, size=3D4096, blksize=3D4096, = blocks=3D8, flags=3D0x0 } 4121 rm 1228846258.742066 RET stat 0 4121 rm 1228846258.742080 CALL open(0x2821d028,O_NONBLOCK,= 0x28200000) 4121 rm 1228846258.742097 NAMI "dnsdoctor" 4121 rm 1228846258.742419 RET open 4 4121 rm 1228846258.742435 CALL fstat(0x4,0xbfbfe6a0) 4121 rm 1228846258.742452 STRU struct stat {dev=3D67174155, ino=3D= 2519891, mode=3Ddrwxr-xr-x , nlink=3D3, uid=3D9874, gid=3D929, rdev=3D0, at= ime=3D1228844788, stime=3D1227555712,=20 ctime=3D1228845836.981842000, birthtime=3D-1, size=3D4096, blksize=3D4096, = blocks=3D8, flags=3D0x0 } 4121 rm 1228846258.742465 RET fstat 0 4121 rm 1228846258.742480 CALL fcntl(0x4,F_SETFD,FD_CLOEXEC) 4121 rm 1228846258.742495 RET fcntl 0 4121 rm 1228846258.742516 CALL fstatfs(0x4,0xbfbfe700) 4121 rm 1228846258.742792 RET fstatfs -1 errno 2 No such file or = directory 4121 rm 1228846258.742809 CALL close(0x4) 4121 rm 1228846258.743187 RET close 0 4121 rm 1228846258.743203 CALL stat(0x2821d098,0xbfbfe900) 4121 rm 1228846258.743219 NAMI "dnsflood" 4121 rm 1228846258.743544 STRU struct stat {dev=3D67174155, ino=3D= 2519892, mode=3Ddrwxr-xr-x , nlink=3D3, uid=3D9874, gid=3D929, rdev=3D0, at= ime=3D1228844788, stime=3D1227555712, ctime=3D1228845836.978868000, birthti= me=3D-1, size=3D4096, blksize=3D4096, blocks=3D8, flags=3D0x0 } 4121 rm 1228846258.743559 RET stat 0 4121 rm 1228846258.743574 CALL open(0x2821d098,O_NONBLOCK,= 0x28200000) 4121 rm 1228846258.743590 NAMI "dnsflood" 4121 rm 1228846258.743792 RET open 4 4121 rm 1228846258.743809 CALL fstat(0x4,0xbfbfe6a0) 4121 rm 1228846258.743826 STRU struct stat {dev=3D67174155, ino=3D= 2519892, mode=3Ddrwxr-xr-x , nlink=3D3, uid=3D9874, gid=3D929, rdev=3D0, at= ime=3D1228844788, stime=3D1227555712, ctime=3D1228845836.978868000, birthti= me=3D-1, size=3D4096, blksize=3D4096, blocks=3D8, flags=3D0x0 } 4121 rm 1228846258.743840 RET fstat 0 4121 rm 1228846258.743854 CALL fcntl(0x4,F_SETFD,FD_CLOEXEC) 4121 rm 1228846258.743867 RET fcntl 0 4121 rm 1228846258.743882 CALL fstatfs(0x4,0xbfbfe700) 4121 rm 1228846258.744008 RET fstatfs -1 errno 2 No such file or = directory 4121 rm 1228846258.744022 CALL close(0x4) 4121 rm 1228846258.744411 RET close 0 [I included a moderate amount of successful processing near the beginning of that excerpt, so folks could see the pattern.] In contrast, here are the similar kdump excerpts from RELENG_7: 702 amd 1228774660.297858 CALL gettimeofday(0x807ad48,0) 702 amd 1228774660.297864 RET gettimeofday 0 702 amd 1228774660.297872 CALL sigprocmask(SIG_BLOCK,0xbfbfeaec,0x= bfbfeadc) 702 amd 1228774660.297878 RET sigprocmask 0 702 amd 1228774660.297883 CALL fork 702 amd 1228774660.302658 RET fork 16840/0x41c8 16840 amd 1228774660.302660 RET fork 0 702 amd 1228774660.302689 CALL sigprocmask(SIG_SETMASK,0xbfbfeadc,= 0) 16840 amd 1228774660.302707 CALL getpid 16840 amd 1228774660.302725 RET getpid 16840/0x41c8 702 amd 1228774660.302715 RET sigprocmask 0 702 amd 1228774660.302746 CALL gettimeofday(0x807ad48,0) 16840 amd 1228774660.302753 CALL unmount(0x2837d310,0) 702 amd 1228774660.302753 RET gettimeofday 0 =2E.. 702 amd 1228774660.417933 CALL select(0x400,0xbfbfec40,0,0,0xbfbfe= cd8) 16840 amd 1228774660.434632 RET unmount -1 errno 16 Device busy 16840 amd 1228774660.434684 CALL sigprocmask(SIG_BLOCK,0x28097c00,0x= bfbfea0c) 16840 amd 1228774660.434691 RET sigprocmask 0 16840 amd 1228774660.434699 CALL sigprocmask(SIG_SETMASK,0x28097c10,= 0) 16840 amd 1228774660.434705 RET sigprocmask 0 16840 amd 1228774660.434713 CALL sigprocmask(SIG_BLOCK,0x28097c00,0x= bfbfe9dc) 16840 amd 1228774660.434718 RET sigprocmask 0 16840 amd 1228774660.434729 CALL sigprocmask(SIG_SETMASK,0x28097c10,= 0) 16840 amd 1228774660.434734 RET sigprocmask 0 16840 amd 1228774660.434745 CALL exit(0x10) 702 amd 1228774660.435214 RET select -1 errno 4 Interrupted syste= m call 702 amd 1228774660.435227 PSIG SIGCHLD caught handler=3D0x805de20 = mask=3D0x0 code=3D0x0 702 amd 1228774660.435237 CALL wait4(0xffffffff,0xbfbfe83c,WNOHANG= ,0) 702 amd 1228774660.435255 RET wait4 16840/0x41c8 702 amd 1228774660.435296 CALL wait4(0xffffffff,0xbfbfe83c,WNOHANG= ,0) 702 amd 1228774660.435302 RET wait4 -1 errno 10 No child processes 702 amd 1228774660.435307 CALL sigprocmask(SIG_SETMASK,0x807ba7c,0) 702 amd 1228774660.435312 RET sigprocmask 0 702 amd 1228774660.435317 CALL sigprocmask(SIG_BLOCK,0x807b784,0) 702 amd 1228774660.435323 RET sigprocmask 0 and: 16835 rm 1228774660.305162 CALL open(0x2816280b,O_RDONLY,0) 16835 rm 1228774660.305173 NAMI ".." 16835 rm 1228774660.305626 RET open 4 16835 rm 1228774660.305634 CALL fstat(0x4,0xbfbfe93c) 16835 rm 1228774660.305644 STRU struct stat {dev=3D50396945, ino=3D= 29713037, mode=3Ddrwxr-xr-x , nlink=3D91, uid=3D9874, gid=3D929, rdev=3D0, = atime=3D1228774657.877477000, stime=3D 1228774660.314260000, ctime=3D1228774660.314260000, birthtime=3D0, size=3D2= 0480, blksize=3D4096, blocks=3D40, flags=3D0x0 } 16835 rm 1228774660.305651 RET fstat 0 16835 rm 1228774660.305658 CALL fchdir(0x4) 16835 rm 1228774660.305667 RET fchdir 0 16835 rm 1228774660.305674 CALL close(0x4) 16835 rm 1228774660.305824 RET close 0 16835 rm 1228774660.305831 CALL rmdir(0x2821afe8) 16835 rm 1228774660.305838 NAMI "p-interp" 16835 rm 1228774660.306498 RET rmdir 0 16835 rm 1228774660.306513 CALL stat(0x28218b48,0xbfbfe8cc) 16835 rm 1228774660.306519 NAMI "pcemu" 16835 rm 1228774660.306756 STRU struct stat {dev=3D50396945, ino=3D= 8465981, mode=3Ddrwxr-xr-x , nlink=3D5, uid=3D9874, gid=3D929, rdev=3D0, at= ime=3D1228772282, stime=3D1227555736,=20 ctime=3D1228773351.399184000, birthtime=3D0, size=3D4096, blksize=3D4096, b= locks=3D8, flags=3D0x0 } 16835 rm 1228774660.306764 RET stat 0 16835 rm 1228774660.306770 CALL open(0x28218b48,O_NONBLOCK,= 0x1) 16835 rm 1228774660.306776 NAMI "pcemu" 16835 rm 1228774660.307003 RET open 4 16835 rm 1228774660.307010 CALL fstat(0x4,0xbfbfe8cc) 16835 rm 1228774660.307018 STRU struct stat {dev=3D50396945, ino=3D= 8465981, mode=3Ddrwxr-xr-x , nlink=3D5, uid=3D9874, gid=3D929, rdev=3D0, at= ime=3D1228772282, stime=3D1227555736,=20 ctime=3D1228773351.399184000, birthtime=3D0, size=3D4096, blksize=3D4096, b= locks=3D8, flags=3D0x0 } 16835 rm 1228774660.307025 RET fstat 0 16835 rm 1228774660.307031 CALL fcntl(0x4,F_SETFD,FD_CLOEXEC) 16835 rm 1228774660.307039 RET fcntl 0 16835 rm 1228774660.307049 CALL fstatfs(0x4,0xbfbfe6f4) 16835 rm 1228774660.307294 RET fstatfs -1 errno 2 No such file or = directory 16835 rm 1228774660.307302 CALL close(0x4) 16835 rm 1228774660.307549 RET close 0 16835 rm 1228774660.307557 CALL stat(0x28218b98,0xbfbfe8cc) 16835 rm 1228774660.307563 NAMI "pearpc" 16835 rm 1228774660.307759 STRU struct stat {dev=3D50396945, ino=3D= 27094159, mode=3Ddrwxr-xr-x , nlink=3D4, uid=3D9874, gid=3D929, rdev=3D0, a= time=3D1228772282, stime=3D1227555736, ctime=3D1228773351.390236000, birtht= ime=3D0, size=3D4096, blksize=3D4096, blocks=3D8, flags=3D0x0 } 16835 rm 1228774660.307767 RET stat 0 16835 rm 1228774660.307772 CALL open(0x28218b98,O_NONBLOCK,= 0x1) 16835 rm 1228774660.307779 NAMI "pearpc" 16835 rm 1228774660.308000 RET open 4 16835 rm 1228774660.308007 CALL fstat(0x4,0xbfbfe8cc) 16835 rm 1228774660.308015 STRU struct stat {dev=3D50396945, ino=3D= 27094159, mode=3Ddrwxr-xr-x , nlink=3D4, uid=3D9874, gid=3D929, rdev=3D0, a= time=3D1228772282, stime=3D1227555736, ctime=3D1228773351.390236000, birtht= ime=3D0, size=3D4096, blksize=3D4096, blocks=3D8, flags=3D0x0 } 16835 rm 1228774660.308021 RET fstat 0 16835 rm 1228774660.308026 CALL fcntl(0x4,F_SETFD,FD_CLOEXEC) 16835 rm 1228774660.308032 RET fcntl 0 16835 rm 1228774660.308038 CALL fstatfs(0x4,0xbfbfe6f4) 16835 rm 1228774660.308101 RET fstatfs -1 errno 2 No such file or = directory 16835 rm 1228774660.308108 CALL close(0x4) 16835 rm 1228774660.308350 RET close 0 So either way, the user-level program attempting the directory hierarchy traversal can be coded to be very careful, yet still receive a rude surprise -- the system saying that a file that the program had already opened (and still has opened) does not exist. How rude! :-{ I'll be very happy to test suggested patches, whether intended to fix the problem or merely facilitate diagnosis. That said, it shouldn't be difficult to reproduce this -- I did it with a copy of /usr/ports; a colleague has reported doing so with a copy of /usr/src (though I haven't witnessed that). 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. --dQ+ozEaLk2y6HH72 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (FreeBSD) iEYEARECAAYFAkk+wHUACgkQmprOCmdXAD25wwCeOVCAPA1VsOGdt1mlGyqRb9QZ MoEAnRZW06V29ACC3EW1JO1ojpYPiCvq =pw7g -----END PGP SIGNATURE----- --dQ+ozEaLk2y6HH72-- From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 20:04:37 2008 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 D3A091065673 for ; Tue, 9 Dec 2008 20:04:37 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.terabit.net.ua (mail.terabit.net.ua [195.137.202.147]) by mx1.freebsd.org (Postfix) with ESMTP id 778648FC17 for ; Tue, 9 Dec 2008 20:04:37 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from skuns.zoral.com.ua ([91.193.166.194] helo=mail.zoral.com.ua) by mail.terabit.net.ua with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63 (FreeBSD)) (envelope-from ) id 1LA8ot-000LTF-1e; Tue, 09 Dec 2008 22:04:35 +0200 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 mB9K4VHI066588 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 9 Dec 2008 22:04:32 +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.3/8.14.3) with ESMTP id mB9K4VMZ095828; Tue, 9 Dec 2008 22:04:31 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.3/8.14.3/Submit) id mB9K4Vbt095827; Tue, 9 Dec 2008 22:04:31 +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: Tue, 9 Dec 2008 22:04:31 +0200 From: Kostik Belousov To: David Wolfskill Message-ID: <20081209200431.GL2038@deviant.kiev.zoral.com.ua> References: <20081203001538.GC96383@bunrab.catwhisker.org> <20081209190110.GW60731@albert.catwhisker.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="IJmQ7d57n2fskpx3" Content-Disposition: inline In-Reply-To: <20081209190110.GW60731@albert.catwhisker.org> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: ClamAV version 0.93.3, clamav-milter version 0.93.3 on skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua X-Virus-Scanned: mail.terabit.net.ua 1LA8ot-000LTF-1e a20a96039016188949f94c2f483f48f4 X-Terabit: YES Cc: hackers@freebsd.org Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 09 Dec 2008 20:04:37 -0000 --IJmQ7d57n2fskpx3 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Dec 09, 2008 at 11:01:10AM -0800, David Wolfskill wrote: > On Tue, Dec 02, 2008 at 04:15:38PM -0800, David Wolfskill wrote: > > I seem to have a fairly- (though not deterministly so) reproducible > > mode of failure with an NFS-mounted directory hierarchy: An attempt to > > traverse a "sufficiently large" hierarchy (e.g., via "tar zcpf" or "rm > > -fr") will fail to "visit" some subdirectories, typically apparently > > acting as if the subdirectories in question do not actually exist > > (despite the names having been returned in the output of a previous > > readdir()). > > ...=20 >=20 Did you saw me previous answer ? Supposed patch for your problem was committed to head as r185557, and MFCed to 7 in r185796, and to 7.1 in r185801. Please test with latest sources. --IJmQ7d57n2fskpx3 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iEYEARECAAYFAkk+z08ACgkQC3+MBN1Mb4iJnwCfUsj9bCMpOWQoNpyX6ufLXKTv 3kkAoL5KuijF0jfqd0ZY55JCQ9Vyi5/J =+Sco -----END PGP SIGNATURE----- --IJmQ7d57n2fskpx3-- From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 22:24:52 2008 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 97D451065675 for ; Tue, 9 Dec 2008 22:24:52 +0000 (UTC) (envelope-from marius@alchemy.franken.de) Received: from alchemy.franken.de (alchemy.franken.de [194.94.249.214]) by mx1.freebsd.org (Postfix) with ESMTP id D14058FC1A for ; Tue, 9 Dec 2008 22:24:51 +0000 (UTC) (envelope-from marius@alchemy.franken.de) Received: from alchemy.franken.de (localhost [127.0.0.1]) by alchemy.franken.de (8.14.3/8.14.3/ALCHEMY.FRANKEN.DE) with ESMTP id mB9MBvk9021988; Tue, 9 Dec 2008 23:11:58 +0100 (CET) (envelope-from marius@alchemy.franken.de) Received: (from marius@localhost) by alchemy.franken.de (8.14.3/8.14.3/Submit) id mB9MBvB7021987; Tue, 9 Dec 2008 23:11:57 +0100 (CET) (envelope-from marius) Date: Tue, 9 Dec 2008 23:11:57 +0100 From: Marius Strobl To: Ed Schouten Message-ID: <20081209221157.GA21934@alchemy.franken.de> References: <20081206155908.GG18652@hoeg.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20081206155908.GG18652@hoeg.nl> User-Agent: Mutt/1.4.2.3i Cc: FreeBSD Hackers Subject: Re: Syscons with xterm emulation: one step closer to UTF-8 support? 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, 09 Dec 2008 22:24:52 -0000 On Sat, Dec 06, 2008 at 04:59:08PM +0100, Ed Schouten wrote: > > My question is if there are people out there who could help me > implementing UTF-8 font rendering. I wouldn't have a clue where to > start (yet). > When implementing UTF-8 font rendering/creating UTF-8 fonts please take into account 12x22 fonts as framebuffers used on sparc64 have to be considered fixed mode and fonts smaller than the Sun default look really bad with these resolutions. Marius From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 22:48:37 2008 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 BDDD91065673 for ; Tue, 9 Dec 2008 22:48:37 +0000 (UTC) (envelope-from prvs=julian=2224d921f@elischer.org) Received: from smtp-outbound.ironport.com (smtp-outbound.ironport.com [63.251.108.112]) by mx1.freebsd.org (Postfix) with ESMTP id A76008FC17 for ; Tue, 9 Dec 2008 22:48:37 +0000 (UTC) (envelope-from prvs=julian=2224d921f@elischer.org) Received: from unknown (HELO julian-mac.elischer.org) ([10.251.60.75]) by smtp-outbound.ironport.com with ESMTP; 09 Dec 2008 14:20:04 -0800 Message-ID: <493EEF15.4050600@elischer.org> Date: Tue, 09 Dec 2008 14:20:05 -0800 From: Julian Elischer User-Agent: Thunderbird 2.0.0.18 (Macintosh/20081105) MIME-Version: 1.0 To: Kostik Belousov References: <20081203001538.GC96383@bunrab.catwhisker.org> <20081209190110.GW60731@albert.catwhisker.org> <20081209200431.GL2038@deviant.kiev.zoral.com.ua> In-Reply-To: <20081209200431.GL2038@deviant.kiev.zoral.com.ua> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: hackers@freebsd.org, David Wolfskill Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 09 Dec 2008 22:48:37 -0000 Kostik Belousov wrote: > On Tue, Dec 09, 2008 at 11:01:10AM -0800, David Wolfskill wrote: >> On Tue, Dec 02, 2008 at 04:15:38PM -0800, David Wolfskill wrote: >>> I seem to have a fairly- (though not deterministly so) reproducible >>> mode of failure with an NFS-mounted directory hierarchy: An attempt to >>> traverse a "sufficiently large" hierarchy (e.g., via "tar zcpf" or "rm >>> -fr") will fail to "visit" some subdirectories, typically apparently >>> acting as if the subdirectories in question do not actually exist >>> (despite the names having been returned in the output of a previous >>> readdir()). >>> ... > > Did you saw me previous answer ? Supposed patch for your problem was > committed to head as r185557, and MFCed to 7 in r185796, and to > 7.1 in r185801. > > Please test with latest sources. did you notice that he tested with latest -current and releng 7? From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 9 22:55:22 2008 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 50C8E1065675 for ; Tue, 9 Dec 2008 22:55:22 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (adsl-63-193-123-122.dsl.snfc21.pacbell.net [63.193.123.122]) by mx1.freebsd.org (Postfix) with ESMTP id 210FD8FC17 for ; Tue, 9 Dec 2008 22:55:21 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (localhost [127.0.0.1]) by albert.catwhisker.org (8.14.3/8.14.3) with ESMTP id mB9MtKcP091360; Tue, 9 Dec 2008 14:55:20 -0800 (PST) (envelope-from david@albert.catwhisker.org) Received: (from david@localhost) by albert.catwhisker.org (8.14.3/8.14.3/Submit) id mB9MtKhi091359; Tue, 9 Dec 2008 14:55:20 -0800 (PST) (envelope-from david) Date: Tue, 9 Dec 2008 14:55:20 -0800 From: David Wolfskill To: Julian Elischer Message-ID: <20081209225520.GB60731@albert.catwhisker.org> References: <20081203001538.GC96383@bunrab.catwhisker.org> <20081209190110.GW60731@albert.catwhisker.org> <20081209200431.GL2038@deviant.kiev.zoral.com.ua> <493EEF15.4050600@elischer.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="gLcqQrOcczDba7nC" Content-Disposition: inline In-Reply-To: <493EEF15.4050600@elischer.org> User-Agent: Mutt/1.4.2.3i Cc: Kostik Belousov , hackers@freebsd.org Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 09 Dec 2008 22:55:22 -0000 --gLcqQrOcczDba7nC Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Dec 09, 2008 at 02:20:05PM -0800, Julian Elischer wrote: > Kostik Belousov wrote: > >... > >Did you saw me previous answer ? Supposed patch for your problem was > >committed to head as r185557, and MFCed to 7 in r185796, and to > >7.1 in r185801. > > > >Please test with latest sources. >=20 > did you notice that he tested with latest -current and releng 7? CURRENT was as of yesterday, as was RELENG_7; while kib@'s commit hit HEAD on 02 Dec, but didn't hit RELENG_7 until after I grabbed the sources for RELENG_7 yesterday. I have some local infrastructure hassles to deal with so I can update the sources in question, but I will test RELENG_7 with the commit & report back. 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. --gLcqQrOcczDba7nC Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (FreeBSD) iEYEARECAAYFAkk+91gACgkQmprOCmdXAD2VjACghsMaEB10FVghRWSuczBz50wb tdAAnR5BZ8XTo79jMm6+MRlRUc0MYBVP =RTm7 -----END PGP SIGNATURE----- --gLcqQrOcczDba7nC-- From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 00:33:46 2008 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 5F97D1065675; Wed, 10 Dec 2008 00:33:46 +0000 (UTC) (envelope-from paul@fletchermoorland.co.uk) Received: from hydra.fletchermoorland.co.uk (93-152-14-233.daisydsl.managedbroadband.co.uk [93.152.14.233]) by mx1.freebsd.org (Postfix) with ESMTP id AC8EC8FC0C; Wed, 10 Dec 2008 00:33:45 +0000 (UTC) (envelope-from paul@fletchermoorland.co.uk) Received: from apollo (78-32-77-91.static-adsl.entanet.co.uk [78.32.77.91] (may be forged)) by hydra.fletchermoorland.co.uk (8.14.2/8.14.2) with ESMTP id mB9NsOCU026758; Tue, 9 Dec 2008 23:54:24 GMT (envelope-from paul@fletchermoorland.co.uk) From: "Paul Wootton" To: "'Doug Rabson'" , "'Joao Barros'" References: <200812070319.18461.ken@mthelicon.com><66BF33BA-EC11-446F-9DE7-15395F293FE2@rabson.org> <200812071217.20500.ken@mthelicon.com> Date: Tue, 9 Dec 2008 23:54:23 -0000 Message-ID: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_NextPart_000_097A_01C95A59.76D7E7A0" X-Mailer: Microsoft Office Outlook 11 Thread-Index: AclYZdeqvU848MR2S165xKklLA3etgB84p/Q X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5579 In-Reply-To: <200812071217.20500.ken@mthelicon.com> Cc: hackers@freebsd.org, current@freebsd.org, 'Pegasus Mc Cleaft' Subject: RE: Problems with zfsboot loader if raidz present on any drive 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, 10 Dec 2008 00:33:46 -0000 This is a multi-part message in MIME format. ------=_NextPart_000_097A_01C95A59.76D7E7A0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit >-----Original Message----- >From: owner-freebsd-hackers@freebsd.org >[mailto:owner-freebsd-hackers@freebsd.org] On Behalf Of Pegasus Mc >Cleaft >Sent: 07 December 2008 12:17 > To: Doug Rabson > Cc: hackers@freebsd.org; current@freebsd.org > Subject: Re: Problems with zfsboot loader if raidz present on any >drive > > On Sunday 07 December 2008 09:22:16 Doug Rabson wrote: > On 7 Dec 2008, at 03:19, Pegasus Mc Cleaft wrote: > > > Hello Hackers, > > > > > > Recently and friend and I have been trying to get the new > > > gptzfsboot working on our machines and ran into a interesting > > > problem. > > > > > > Initially I was building the world without the environment > > > variable LOADER_ZFS_SUPPORT=YES in the /etc/make.conf and this, of > > > course, didnt work very well. Every time the machine booted, it > > > would throw 2 lines after the pin-wheel and then reboot. I > > > couldent read what the lines were it went so fast. > > > > > > My friend had a bit more luck and got his machine working OK with > > > a single drive and later a mirror drive added. > > > > > > I added the environment variable and rebuilt everything and > > > installed. This time, I could see the bios drives and a further 2 > > > lines of ZFS something and a reboot... > > > > > > No matter what I tried, I couldent get the machine to boot up to > > > a point where I could try and fix the problem, so I started > > > pulling devices out and found the following: If there is a raidz > > > pool on any drive (not necessarily the one that you are trying to > > > boot from) the loader dies and reboots the machine. My friend, as > > > an experiment created 3 gpt partitions (in addition to the single > > > partition that he had been previously booted from) on his single > > > drive and made a raidz pool for testing. His machine showed the > > > same condition as mine, however he was able to capture the message > > > before the machine > > > rebooted: > > > > > > > > > ZFS: can only boot from disk or mirror vdevs > > > > > > ZFS: inconsistent nvlist contents > > > > The zfsboot code in current doesn't support raidz or raidz2. I have > > been working on adding that support but its not ready yet. The code > > works in my test harness but crashes instantly when I put it in the > > boot code :(. I should have time to finish debugging it soon. > > Hi Doug, > > In my haste to put a message to the group, I didnt do a very good job > of explaining or give what platform I was working with. > > I set up a single disk pool with the gptzfsboot code on it as a boot drive. > My idea was to have a single disk boot (and after it boots and I can > kill the UFS drive I am currently booting from) convert it to a > mirror. But I have 6 other drives in the machine that I have as a raidz for my /usr/home, et al. > > If the 6 raidz drives are present at boot time, the machine starts to > cyclic reboot just after the pin-wheel. > > The machine I am working on is running FBSD8.0-Current as of midnight > 7/12/2008 and the platform is AMD64. > > If I can help test in any way I would be more than happy to try, or > provide any information necessary.. > > ~Peg Hi Doug, I was working with Peg on this over the weekend. I think I have a patch for this - see http://www.freebsd.org/cgi/query-pr.cgi?pr=129539 The problem was that we were not checking the return code from vdev_init_from_nvlist() on line 726 in /usr/src/sys/boot/zfs/zfsimpl.c Joao, Do you want to try the attached patch? It seems to have fixed the problem, at least on mine and Peg's machine. Cheers Paul ------=_NextPart_000_097A_01C95A59.76D7E7A0 Content-Type: application/octet-stream; name="zfsimpl.c.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="zfsimpl.c.patch" *** zfsimpl.c Wed Nov 19 16:59:19 2008=0A= --- zfsimpl.c.fix Tue Dec 9 22:48:36 2008=0A= ***************=0A= *** 721,731 ****=0A= if (nvlist_find(nvlist,=0A= ZPOOL_CONFIG_VDEV_TREE,=0A= DATA_TYPE_NVLIST, 0, &vdevs)) {=0A= return (EIO);=0A= }=0A= ! vdev_init_from_nvlist(vdevs, &top_vdev);=0A= =0A= /*=0A= * Add the toplevel vdev to the pool if its not already there.=0A= */=0A= STAILQ_FOREACH(pool_vdev, &spa->spa_vdevs, v_childlink)=0A= --- 721,733 ----=0A= if (nvlist_find(nvlist,=0A= ZPOOL_CONFIG_VDEV_TREE,=0A= DATA_TYPE_NVLIST, 0, &vdevs)) {=0A= return (EIO);=0A= }=0A= ! int initRetVal =3D vdev_init_from_nvlist(vdevs, &top_vdev);=0A= ! if(initRetVal)=0A= ! return initRetVal;=0A= =0A= /*=0A= * Add the toplevel vdev to the pool if its not already there.=0A= */=0A= STAILQ_FOREACH(pool_vdev, &spa->spa_vdevs, v_childlink)=0A= ------=_NextPart_000_097A_01C95A59.76D7E7A0-- From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 06:25:51 2008 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 DF6FE1065670 for ; Wed, 10 Dec 2008 06:25:50 +0000 (UTC) (envelope-from stutiredboy@gmail.com) Received: from yw-out-2324.google.com (yw-out-2324.google.com [74.125.46.28]) by mx1.freebsd.org (Postfix) with ESMTP id 963228FC13 for ; Wed, 10 Dec 2008 06:25:50 +0000 (UTC) (envelope-from stutiredboy@gmail.com) Received: by yw-out-2324.google.com with SMTP id 9so171386ywe.13 for ; Tue, 09 Dec 2008 22:25:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type; bh=leIjh6QnJzyv4LteXRylfeJAAG+Yvywdufk4doE+Gj4=; b=eni4pdKvK5J8VpoYwFy27jL915gP2V4nbevoi8wOkcpiZe6G582L+yp11Arxz5HdZW dQl5pryY+aavk99EvgRQhjcY07RnKleF1KUIgCCH5aqPLS/610Hh2nPzPsHDUi0heds/ a7tr938RUg6+Vgu3EAmBtrwzp5VXETltaysfQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type; b=aPw5LOJQvXRuWs2xQ8uWTy5vA7eXpmUTAy9P325D6gV/MdRn0cguDVBvUa0Wk8ygiF 5h2drgoNXEx+aNHJooyHaqpXbLj/ywA4t8CfZYbqAk/2ggozJ5BFGX2jkAgN9/kFt6yI 954X4QVh2JQeJrQAgzIWWX2Ov95DMuOYU0Dw8= Received: by 10.150.52.2 with SMTP id z2mr1481673ybz.72.1228888642611; Tue, 09 Dec 2008 21:57:22 -0800 (PST) Received: by 10.150.98.17 with HTTP; Tue, 9 Dec 2008 21:57:22 -0800 (PST) Message-ID: Date: Wed, 10 Dec 2008 13:57:22 +0800 From: "=?GB2312?B?s8LQocn6?=" To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: [help]strange problem about gethostbyname/getaddrinfo 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, 10 Dec 2008 06:25:51 -0000 hi,all,we have a project which must resolv some domains in the server process our system in FreeBSD 6.2 or 6.3, the server process may open 7000+ sockets,not fork we have set the maxopensockets as 65536,as follows: kern.ipc.numopensockets: 4737 kern.ipc.maxsockets: 65536 socket: 356, 65538, 4737, 6747, 64793968 and the follow is our limit info: cputime unlimited filesize unlimited datasize 2621440 kbytes stacksize 65536 kbytes coredumpsize unlimited memoryuse unlimited vmemoryuse unlimited descriptors 655000 memorylocked unlimited maxproc 5547 sbsize unlimited I am sure we have set the /etc/reslov.conf correctly, I can resolve any legal domain use dig or gethostbyname or getaddrinfo in my another test program The problem is we found when the server porcess open 1000+ or higher sockets(but we can query any legal domain in the system normally), the gethostbyname or getaddrinfo might fetch nothing(sometimes the query is ok), the gethostbyname's return error is: errno=2,strerror=Host name lookup failure and the getaddrinfo's return error is: "hostname nor servname provided, or not known", /* EAI_NONAME */ we have tried to use the tcpdump to analyse the query packets, unluckily , we catch nothing, seem like that the program does not query anything(or get none dns server,even 127.0.0.1) , neither using gethostbyname nor getaddrinfo,and we also try set the query type as tcp and udp, the same disappointment result. The stranger thing is we have tried to run another demo process which have open 4000+ sockets, all work well..so the problem might not related to open too much sockets..and we found that, even we set the /etc/resolve.conf nothing, normally the gethostbyname/getaddrinfo will check 127.0.0.1, and we can get the query packets The server process's query is under a single process not multi threads Can anyone help me analyse the error/problem, which may raise this situation or any useful info, thanks very much ! From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 07:07:43 2008 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 72024106564A for ; Wed, 10 Dec 2008 07:07:43 +0000 (UTC) (envelope-from crquan@gmail.com) Received: from mail-bw0-f14.google.com (mail-bw0-f14.google.com [209.85.218.14]) by mx1.freebsd.org (Postfix) with ESMTP id E0B908FC2D for ; Wed, 10 Dec 2008 07:07:42 +0000 (UTC) (envelope-from crquan@gmail.com) Received: by bwz7 with SMTP id 7so341368bwz.19 for ; Tue, 09 Dec 2008 23:07:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=co62z3fF7Xaf9SA6zJsjJ+m7l3BLqidrF4MTna92zg4=; b=tiwOo+MJS9td5dLcmshUi5SiIGs89tjUy2xKgjfvlitqAkPo+fubc1lnmjt7h/vAvt Sx7erCpqsqOLMAAa2sz5s+nl4DC7lXhcTKJ7TVF8Rn34k9WvkWHhU2Yh6m2KziPts/xq asRECj3zjeKJpT5Ll88IzPUEmptOBa16/E8rM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=i61td516sSqx+Fo2d7O3kPuvac5vaQJr2kN8hNzQz6BtHQsxPmPHS+hvYIjMOTaZTB 8LExGUEt6SCZSZKoUFLlIAO4ukDmrfybwwKJ4ySrnGsL6MHHGQ83cgeXbM56y8uWQinh YoTZS3avKgCyDlAphUT04P5L+esB2PPO8Y5lk= Received: by 10.103.131.18 with SMTP id i18mr392485mun.74.1228890987819; Tue, 09 Dec 2008 22:36:27 -0800 (PST) Received: by 10.103.191.7 with HTTP; Tue, 9 Dec 2008 22:36:27 -0800 (PST) Message-ID: <91b13c310812092236j7063f177yafd83948a891ea76@mail.gmail.com> Date: Wed, 10 Dec 2008 14:36:27 +0800 From: "Cheng Renquan" To: "=?UTF-8?B?6ZmI5bCP55Sf?=" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: base64 Content-Disposition: inline References: Cc: freebsd-hackers@freebsd.org Subject: Re: [help]strange problem about gethostbyname/getaddrinfo 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, 10 Dec 2008 07:07:43 -0000 T24gV2VkLCBEZWMgMTAsIDIwMDggYXQgMTo1NyBQTSwg6ZmI5bCP55SfIDxzdHV0aXJlZGJveUBn bWFpbC5jb20+IHdyb3RlOgo+IGhpLGFsbCx3ZSBoYXZlIGEgcHJvamVjdCB3aGljaCBtdXN0IHJl c29sdiBzb21lIGRvbWFpbnMgaW4gdGhlIHNlcnZlcgo+IHByb2Nlc3MKPiBvdXIgc3lzdGVtIGlu IEZyZWVCU0QgNi4yIG9yIDYuMywgdGhlIHNlcnZlciBwcm9jZXNzIG1heSBvcGVuIDcwMDArCj4g c29ja2V0cyxub3QgZm9yawo+IHdlIGhhdmUgc2V0IHRoZSBtYXhvcGVuc29ja2V0cyBhcyA2NTUz NixhcyBmb2xsb3dzOgoKVXNlIHN0cmFjZSB0byB0cmFjZSBpdCwKCi0tIApDaGVuZyBSZW5xdWFu LCBTaGVuemhlbiwgQ2hpbmEKTWFyaWUgdm9uIEVibmVyLUVzY2hlbmJhY2ggIC0gIkV2ZW4gYSBz dG9wcGVkIGNsb2NrIGlzIHJpZ2h0IHR3aWNlIGEgZGF5LiIK From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 08:09:19 2008 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 DC804106564A for ; Wed, 10 Dec 2008 08:09:19 +0000 (UTC) (envelope-from rdivacky@lev.vlakno.cz) Received: from vlakno.cz (77-93-215-190.static.masterinter.net [77.93.215.190]) by mx1.freebsd.org (Postfix) with ESMTP id 92CD38FC12 for ; Wed, 10 Dec 2008 08:09:18 +0000 (UTC) (envelope-from rdivacky@lev.vlakno.cz) Received: from localhost (localhost [127.0.0.1]) by vlakno.cz (Postfix) with ESMTP id D049B9CB1C5; Wed, 10 Dec 2008 09:04:34 +0100 (CET) X-Virus-Scanned: amavisd-new at vlakno.cz Received: from vlakno.cz ([127.0.0.1]) by localhost (lev.vlakno.cz [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 9dup-VmZn39m; Wed, 10 Dec 2008 09:04:32 +0100 (CET) Received: from lev.vlakno.cz (localhost [127.0.0.1]) by vlakno.cz (Postfix) with ESMTP id 4D8249CB208; Wed, 10 Dec 2008 09:04:32 +0100 (CET) Received: (from rdivacky@localhost) by lev.vlakno.cz (8.14.2/8.14.2/Submit) id mBA84WbN030029; Wed, 10 Dec 2008 09:04:32 +0100 (CET) (envelope-from rdivacky) Date: Wed, 10 Dec 2008 09:04:31 +0100 From: Roman Divacky To: Cheng Renquan Message-ID: <20081210080431.GA29866@freebsd.org> References: <91b13c310812092236j7063f177yafd83948a891ea76@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <91b13c310812092236j7063f177yafd83948a891ea76@mail.gmail.com> User-Agent: Mutt/1.4.2.3i Cc: ????????? , freebsd-hackers@freebsd.org Subject: Re: [help]strange problem about gethostbyname/getaddrinfo 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, 10 Dec 2008 08:09:19 -0000 On Wed, Dec 10, 2008 at 02:36:27PM +0800, Cheng Renquan wrote: > On Wed, Dec 10, 2008 at 1:57 PM, ????????? wrote: > > hi,all,we have a project which must resolv some domains in the server > > process > > our system in FreeBSD 6.2 or 6.3, the server process may open 7000+ > > sockets,not fork > > we have set the maxopensockets as 65536,as follows: > > Use strace to trace it, I personally found strace on fbsd to lie to me everytime. I'd avoid that and use ktrace/kdump instead... From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 08:29:01 2008 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 B4BAB106567E; Wed, 10 Dec 2008 08:29:01 +0000 (UTC) (envelope-from dfr@rabson.org) Received: from itchy.rabson.org (unknown [IPv6:2002:50b1:e8f2:1::143]) by mx1.freebsd.org (Postfix) with ESMTP id 2D6538FC1A; Wed, 10 Dec 2008 08:29:01 +0000 (UTC) (envelope-from dfr@rabson.org) Received: from [IPv6:2001:470:909f:1:21b:63ff:feb8:5abc] (unknown [IPv6:2001:470:909f:1:21b:63ff:feb8:5abc]) by itchy.rabson.org (Postfix) with ESMTP id 712753FAA; Wed, 10 Dec 2008 08:28:59 +0000 (GMT) Message-Id: From: Doug Rabson To: "Paul Wootton" In-Reply-To: Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v929.2) Date: Wed, 10 Dec 2008 08:28:59 +0000 References: <200812070319.18461.ken@mthelicon.com><66BF33BA-EC11-446F-9DE7-15395F293FE2@rabson.org> <200812071217.20500.ken@mthelicon.com> X-Mailer: Apple Mail (2.929.2) Cc: 'Joao Barros' , hackers@freebsd.org, current@freebsd.org, 'Pegasus Mc Cleaft' Subject: Re: Problems with zfsboot loader if raidz present on any drive 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, 10 Dec 2008 08:29:01 -0000 On 9 Dec 2008, at 23:54, Paul Wootton wrote: >> -----Original Message----- >> From: owner-freebsd-hackers@freebsd.org >> [mailto:owner-freebsd-hackers@freebsd.org] On Behalf Of Pegasus Mc >> Cleaft >> Sent: 07 December 2008 12:17 >> To: Doug Rabson >> Cc: hackers@freebsd.org; current@freebsd.org >> Subject: Re: Problems with zfsboot loader if raidz present on any >> drive >> >> On Sunday 07 December 2008 09:22:16 Doug Rabson wrote: >> On 7 Dec 2008, at 03:19, Pegasus Mc Cleaft wrote: >>>> Hello Hackers, >>>> >>>> Recently and friend and I have been trying to get the new >>>> gptzfsboot working on our machines and ran into a interesting >>>> problem. >>>> >>>> Initially I was building the world without the environment >>>> variable LOADER_ZFS_SUPPORT=YES in the /etc/make.conf and this, of >>>> course, didnt work very well. Every time the machine booted, it >>>> would throw 2 lines after the pin-wheel and then reboot. I >>>> couldent read what the lines were it went so fast. >>>> >>>> My friend had a bit more luck and got his machine working OK with >>>> a single drive and later a mirror drive added. >>>> >>>> I added the environment variable and rebuilt everything and >>>> installed. This time, I could see the bios drives and a further 2 >>>> lines of ZFS something and a reboot... >>>> >>>> No matter what I tried, I couldent get the machine to boot up to >>>> a point where I could try and fix the problem, so I started >>>> pulling devices out and found the following: If there is a raidz >>>> pool on any drive (not necessarily the one that you are trying to >>>> boot from) the loader dies and reboots the machine. My friend, as >>>> an experiment created 3 gpt partitions (in addition to the single >>>> partition that he had been previously booted from) on his single >>>> drive and made a raidz pool for testing. His machine showed the >>>> same condition as mine, however he was able to capture the message >>>> before the machine >>>> rebooted: >>>> >>>> >>>> ZFS: can only boot from disk or mirror vdevs >>>> >>>> ZFS: inconsistent nvlist contents >>> >>> The zfsboot code in current doesn't support raidz or raidz2. I have >>> been working on adding that support but its not ready yet. The code >>> works in my test harness but crashes instantly when I put it in the >>> boot code :(. I should have time to finish debugging it soon. >> >> Hi Doug, >> >> In my haste to put a message to the group, I didnt do a very good > job >> of explaining or give what platform I was working with. >> >> I set up a single disk pool with the gptzfsboot code on it as a boot > drive. >> My idea was to have a single disk boot (and after it boots and I can >> kill the UFS drive I am currently booting from) convert it to a >> mirror. But I have 6 other drives in the machine that I have as a >> raidz > for my /usr/home, et al. >> >> If the 6 raidz drives are present at boot time, the machine starts > to >> cyclic reboot just after the pin-wheel. >> >> The machine I am working on is running FBSD8.0-Current as of > midnight >> 7/12/2008 and the platform is AMD64. >> >> If I can help test in any way I would be more than happy to try, or >> provide any information necessary.. >> >> ~Peg > > Hi Doug, > I was working with Peg on this over the weekend. > I think I have a patch for this - see > http://www.freebsd.org/cgi/query-pr.cgi?pr=129539 > The problem was that we were not checking the return code from > vdev_init_from_nvlist() on line 726 in /usr/src/sys/boot/zfs/zfsimpl.c > > > Joao, > Do you want to try the attached patch? It seems to have fixed the > problem, > at least on mine and Peg's machine. This looks like the right fix. I will commit something similar to this today. From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 11:21:26 2008 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 7AADF106564A; Wed, 10 Dec 2008 11:21:26 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (tim.des.no [194.63.250.121]) by mx1.freebsd.org (Postfix) with ESMTP id 400EA8FC17; Wed, 10 Dec 2008 11:21:26 +0000 (UTC) (envelope-from des@des.no) Received: from ds4.des.no (des.no [84.49.246.2]) by smtp.des.no (Postfix) with ESMTP id 2B3516D44C; Wed, 10 Dec 2008 11:21:25 +0000 (UTC) Received: by ds4.des.no (Postfix, from userid 1001) id 0A1CF844DD; Wed, 10 Dec 2008 12:21:25 +0100 (CET) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Ivan Voras References: Date: Wed, 10 Dec 2008 12:21:24 +0100 In-Reply-To: (Ivan Voras's message of "Mon, 08 Dec 2008 20:41:32 +0100") Message-ID: <863agws2bv.fsf@ds4.des.no> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org Subject: Re: MAXFILES in subr_param.c 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, 10 Dec 2008 11:21:26 -0000 Ivan Voras writes: > I'm looking at kern/subr_param.c: > > 72 #ifndef MAXFILES > 73 #define MAXFILES (maxproc * 2) > 74 #endif > > Shouldn't this be at least maxproc*3, for stdin,out,err for every proc? Even maxproc * 3 won't be enough, unless none of your processes actually do anything. It's just an arbitrary value, based on the assumption that you will never have maxproc concurrent processes anyway. > Also, it looks like MAXFILES is used only once, and in a bit funny way: > > 238 maxfiles =3D MAXFILES; > 239 TUNABLE_INT_FETCH("kern.maxfiles", &maxfiles); > 240 maxprocperuid =3D (maxproc * 9) / 10; > 241 maxfilesperproc =3D (maxfiles * 9) / 10; What's funny about it? > Historical reasons? To a certain degree, yes; MAXFILES used to be a static limit which you could only change in your kernel config. It is now a loader tunable (though you can still change the default in your kernel config), so the MAXFILES macro was replaced with a maxfiles variable wherever it is used, and the former is now only used to initialize the latter. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 13:30:40 2008 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 CBF541065672 for ; Wed, 10 Dec 2008 13:30:40 +0000 (UTC) (envelope-from freebsd-hackers@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id 53AE88FC1E for ; Wed, 10 Dec 2008 13:30:40 +0000 (UTC) (envelope-from freebsd-hackers@m.gmane.org) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1LAP97-0005lw-Lt for freebsd-hackers@freebsd.org; Wed, 10 Dec 2008 13:30:33 +0000 Received: from lara.cc.fer.hr ([161.53.72.113]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 10 Dec 2008 13:30:33 +0000 Received: from ivoras by lara.cc.fer.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 10 Dec 2008 13:30:33 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-hackers@freebsd.org From: Ivan Voras Date: Wed, 10 Dec 2008 14:30:24 +0100 Lines: 65 Message-ID: References: <863agws2bv.fsf@ds4.des.no> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig6EC81F27CD3BD473BFC4B047" X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: lara.cc.fer.hr User-Agent: Thunderbird 2.0.0.18 (X11/20081125) In-Reply-To: <863agws2bv.fsf@ds4.des.no> X-Enigmail-Version: 0.95.0 Sender: news Subject: Re: MAXFILES in subr_param.c 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, 10 Dec 2008 13:30:40 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig6EC81F27CD3BD473BFC4B047 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Dag-Erling Sm=C3=B8rgrav wrote: > Ivan Voras writes: >> I'm looking at kern/subr_param.c: >> >> 72 #ifndef MAXFILES >> 73 #define MAXFILES (maxproc * 2) >> 74 #endif >> >> Shouldn't this be at least maxproc*3, for stdin,out,err for every proc= ? >=20 > Even maxproc * 3 won't be enough, unless none of your processes actuall= y > do anything.=20 > It's just an arbitrary value, based on the assumption that > you will never have maxproc concurrent processes anyway. Ok. >=20 >> Also, it looks like MAXFILES is used only once, and in a bit funny way= : >> >> 238 maxfiles =3D MAXFILES; >> 239 TUNABLE_INT_FETCH("kern.maxfiles", &maxfiles); >> 240 maxprocperuid =3D (maxproc * 9) / 10; >> 241 maxfilesperproc =3D (maxfiles * 9) / 10; >=20 > What's funny about it? MAXFILES is a macro used only once, where it resolves to (maxproc*2). It's not technically incorrect, but it looks like it adds noise. >> Historical reasons? >=20 > To a certain degree, yes; MAXFILES used to be a static limit which you > could only change in your kernel config. It is now a loader tunable > (though you can still change the default in your kernel config), so the= > MAXFILES macro was replaced with a maxfiles variable wherever it is > used, and the former is now only used to initialize the latter. Ok. --------------enig6EC81F27CD3BD473BFC4B047 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.6 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFJP8RyldnAQVacBcgRAiifAKCSk5SrKVscHd7LyeT5D4P++Vpj3gCgtaob 5Zzgh2vQiBDT+DONfM7eKck= =BZWx -----END PGP SIGNATURE----- --------------enig6EC81F27CD3BD473BFC4B047-- From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 02:36:26 2008 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 691BA1065673 for ; Wed, 10 Dec 2008 02:36:26 +0000 (UTC) (envelope-from issapoet@gmail.com) Received: from mail-qy0-f31.google.com (mail-qy0-f31.google.com [209.85.221.31]) by mx1.freebsd.org (Postfix) with ESMTP id 1DFE58FC1B for ; Wed, 10 Dec 2008 02:36:25 +0000 (UTC) (envelope-from issapoet@gmail.com) Received: by qyk12 with SMTP id 12so136944qyk.19 for ; Tue, 09 Dec 2008 18:36:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type; bh=jp4CFJmGlVhWIsQP7N4O/7xN3rN4JrPf7e+5mbA2NX8=; b=GUPoW5JU4l/R2tRkpQmpYlfBwU4w/jmKP0OIbQLj42YgEspSVjwMZNTJDGatabmrdY dXCiq7BRcXp2R7Yo2LuOtz1dNwSoKS5JgA4IcBhQc+yhkfWrAhIGeKEZeBJcletKFlUO lXwcj1iECEhgXxd28oFVfRSe/vI+dECDCpIH0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type; b=OUkFTwOQLxstgggJkTtV6Cb43UxaI03kCqU2/T13X4kOyIkvIOx+BAKyK5tejQNEJ2 A9g6vDWw45pVqe6W945QMmXO/6sWHhXXTZXJiSIoHRAdC4nDRXb1LaApwFPhLvgMxi9c qgmfDUgVSlJ18u7w8sQSd/hR8+QHj/wAsjA4k= Received: by 10.215.14.12 with SMTP id r12mr1342150qai.189.1228875468936; Tue, 09 Dec 2008 18:17:48 -0800 (PST) Received: by 10.215.101.20 with HTTP; Tue, 9 Dec 2008 18:17:48 -0800 (PST) Message-ID: Date: Wed, 10 Dec 2008 04:17:48 +0200 From: "=?KOI8-R?B?4MzJ0SDzzc/Mycs=?=" To: freebsd-hackers@freebsd.org MIME-Version: 1.0 X-Mailman-Approved-At: Wed, 10 Dec 2008 14:14:23 +0000 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: FreeBSD 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, 10 Dec 2008 02:36:26 -0000 Hello dear command of developers of FreeBSD. I wish to take part in the project on developing out of FreeBSD and to subscribe for dispatch. Excuse me for my English. From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 15:00:18 2008 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 93EC4106567C; Wed, 10 Dec 2008 15:00:18 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from igloo.linux.gr (igloo.linux.gr [62.1.205.36]) by mx1.freebsd.org (Postfix) with ESMTP id 10FD08FC14; Wed, 10 Dec 2008 15:00:17 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from kobe.laptop (adsl22-219.kln.forthnet.gr [77.49.149.219]) (authenticated bits=128) by igloo.linux.gr (8.14.3/8.14.3/Debian-5) with ESMTP id mBAF04Ar013826 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 10 Dec 2008 17:00:09 +0200 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.3/8.14.3) with ESMTP id mBAF04We085518; Wed, 10 Dec 2008 17:00:04 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) Received: (from keramida@localhost) by kobe.laptop (8.14.3/8.14.3/Submit) id mBAF04b2085517; Wed, 10 Dec 2008 17:00:04 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) From: Giorgos Keramidas To: Ivan Voras References: Date: Wed, 10 Dec 2008 17:00:04 +0200 In-Reply-To: (Ivan Voras's message of "Mon, 08 Dec 2008 20:41:32 +0100") Message-ID: <87fxkwdqiz.fsf@kobe.laptop> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-MailScanner-ID: mBAF04Ar013826 X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-3.858, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL 0.54, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@ceid.upatras.gr X-Spam-Status: No Cc: freebsd-hackers@freebsd.org Subject: Re: MAXFILES in subr_param.c 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, 10 Dec 2008 15:00:18 -0000 On Mon, 08 Dec 2008 20:41:32 +0100, Ivan Voras wrote: > Hi, > > I'm looking at kern/subr_param.c: > > 72 #ifndef MAXFILES > 73 #define MAXFILES (maxproc * 2) > 74 #endif > > Shouldn't this be at least maxproc*3, for stdin,out,err for every proc? > > Also, it looks like MAXFILES is used only once, and in a bit funny way: > > 238 maxfiles = MAXFILES; > 239 TUNABLE_INT_FETCH("kern.maxfiles", &maxfiles); > 240 maxprocperuid = (maxproc * 9) / 10; > 241 maxfilesperproc = (maxfiles * 9) / 10; This is an attempt to limit a rogue process from grabbing the full maxfiles or maxproc value by opening too many files. There will still be (maxfiles / 10) file descriptors available and (maxproc / 10) process table entries, so that you can for example try to log into the system as root and try to fix things. You can still cause all sorts of trouble by *forking* and then going off into a file descriptor allocation spree, but as I said this is an _attempt_ at keeping things in a relatively sane state in the _default_ state. You can still use the loader to set the actual values of the `kern.maxprocperuid' and `kern.maxfilesperproc' tunables to something that is more robust for your particular application. The defaults are just a `best effort' guess to keep things working in the most common case. Nothing funny about them :) From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 15:02:41 2008 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 AC688106564A; Wed, 10 Dec 2008 15:02:41 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from igloo.linux.gr (igloo.linux.gr [62.1.205.36]) by mx1.freebsd.org (Postfix) with ESMTP id 288E18FC08; Wed, 10 Dec 2008 15:02:40 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from kobe.laptop (adsl22-219.kln.forthnet.gr [77.49.149.219]) (authenticated bits=128) by igloo.linux.gr (8.14.3/8.14.3/Debian-5) with ESMTP id mBAF2Usq015035 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 10 Dec 2008 17:02:35 +0200 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.3/8.14.3) with ESMTP id mBAF2U2Y085546; Wed, 10 Dec 2008 17:02:30 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) Received: (from keramida@localhost) by kobe.laptop (8.14.3/8.14.3/Submit) id mBAF2UwR085545; Wed, 10 Dec 2008 17:02:30 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) From: Giorgos Keramidas To: Ivan Voras References: <863agws2bv.fsf@ds4.des.no> Date: Wed, 10 Dec 2008 17:02:30 +0200 In-Reply-To: (Ivan Voras's message of "Wed, 10 Dec 2008 14:30:24 +0100") Message-ID: <87bpvkdqex.fsf@kobe.laptop> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-MailScanner-ID: mBAF2Usq015035 X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-3.858, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL 0.54, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@ceid.upatras.gr X-Spam-Status: No Cc: freebsd-hackers@freebsd.org Subject: Re: MAXFILES in subr_param.c 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, 10 Dec 2008 15:02:41 -0000 On Wed, 10 Dec 2008 14:30:24 +0100, Ivan Voras wrote: >>> Also, it looks like MAXFILES is used only once, and in a bit funny way: >>> >>> 238 maxfiles = MAXFILES; >>> 239 TUNABLE_INT_FETCH("kern.maxfiles", &maxfiles); >>> 240 maxprocperuid = (maxproc * 9) / 10; >>> 241 maxfilesperproc = (maxfiles * 9) / 10; >> >> What's funny about it? > > MAXFILES is a macro used only once, where it resolves to (maxproc*2). > It's not technically incorrect, but it looks like it adds noise. It doesn't add noise :-) It's arguably a code quality and `documentation' feature. It provides a human-readable, useful name to the "magic" value (maxproc * 2). If we decide to bump the default to (maxproc * 10) sometime later, we won't have to grovel through the entire src/sys/tree and look for maxproc instances that need updating. From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 15:05:10 2008 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 A161F106564A; Wed, 10 Dec 2008 15:05:10 +0000 (UTC) (envelope-from prvs=12308e1c5a=killing@multiplay.co.uk) Received: from mail1.multiplay.co.uk (core6.multiplay.co.uk [85.236.96.23]) by mx1.freebsd.org (Postfix) with ESMTP id EDEB18FC13; Wed, 10 Dec 2008 15:05:09 +0000 (UTC) (envelope-from prvs=12308e1c5a=killing@multiplay.co.uk) DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=multiplay.co.uk; s=Multiplay; t=1228920552; x=1229525352; q=dns/txt; h=Received: Message-ID:From:To:Subject:Date:MIME-Version:Content-Type: Content-Transfer-Encoding; bh=rGttyBfSniE0d99ULXmMihcsuSpGy/XY6A O+1IR2LXw=; b=n/xebX+AKYvikTYaBWzq00hRpdZkSLHr/FfVtZTpTk6M347DR3 CUKC29SpHCLMCylL/m6l8pK6NzYjuSMQqoNRJCYv1XyBje9pD5gPypyzcnaTM3HA FloNj5F9W3HBeY5bmY6YNjDS8k4jNMfC/1XDI+i9KB1x07Wy7rpyp4Hps= X-Spam-Checker-Version: SpamAssassin 3.1.8 (2007-02-13) on mail1.multiplay.co.uk X-Spam-Level: X-Spam-Status: No, score=-14.7 required=6.0 tests=BAYES_00, FORGED_MUA_OUTLOOK, USER_IN_WHITELIST,USER_IN_WHITELIST_TO autolearn=ham version=3.1.8 Received: from r2d2 by mail1.multiplay.co.uk (MDaemon PRO v9.6.6) with ESMTP id md50006696587.msg; Wed, 10 Dec 2008 14:49:11 +0000 X-Authenticated-Sender: Killing@multiplay.co.uk X-MDRemoteIP: 213.123.247.160 X-Return-Path: prvs=12308e1c5a=killing@multiplay.co.uk X-Envelope-From: killing@multiplay.co.uk Message-ID: <38D2AA3D46354E8EA3EE2A1056A1BE4A@multiplay.co.uk> From: "Steven Hartland" To: , Date: Wed, 10 Dec 2008 14:49:11 -0000 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.5512 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5579 X-Spam-Processed: mail1.multiplay.co.uk, Wed, 10 Dec 2008 14:49:11 +0000 X-MDAV-Processed: mail1.multiplay.co.uk, Wed, 10 Dec 2008 14:49:12 +0000 Cc: Subject: 7.0 unusual performance issue - vmdaemon hang? 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, 10 Dec 2008 15:05:10 -0000 Just had one of hour webservers flag as down here and on investigation the machine seems to be struggling due to a hung vmdaemon process. top is reporting vmdaemon as using a constant 55.57% CPU yet CPU time is not increasing:- last pid: 36492; load averages: 0.04, 0.05, .11 up 89+19:53:21 14:36:08 223 processes: 9 running, 201 sleeping, 13 waiting CPU states: 0.0% user, 0.0% nice, 0.0% system, 0.0% interrupt, 100% idle Mem: 644M Active, 2780M Inact, 480M Wired, 249M Cache, 214M Buf, 3759M Free Swap: 4096M Total, 537M Used, 3559M Free, 13% Inuse PID USERNAME THR PRI NICE SIZE RES STATE C TIME WCPU COMMAND 11 root 1 171 ki31 0K 16K CPU7 7 2116.4 100.00% idle: cpu7 12 root 1 171 ki31 0K 16K CPU6 6 2059.5 100.00% idle: cpu6 13 root 1 171 ki31 0K 16K CPU5 5 2029.3 100.00% idle: cpu5 14 root 1 171 ki31 0K 16K CPU4 4 1977.8 100.00% idle: cpu4 15 root 1 171 ki31 0K 16K CPU3 3 1912.0 100.00% idle: cpu3 16 root 1 171 ki31 0K 16K CPU2 2 1835.2 100.00% idle: cpu2 17 root 1 171 ki31 0K 16K CPU1 1 1763.1 100.00% idle: cpu1 18 root 1 171 ki31 0K 16K RUN 0 1727.6 100.00% idle: cpu0 37 root 1 20 - 0K 16K psleep 5 0:56 55.57% vmdaemon 60198 www 1 4 0 98M 13516K sbwait 2 35:21 1.46% httpd 60264 www 1 4 0 133M 9248K sbwait 0 21:21 0.39% httpd 30 root 1 -68 - 0K 16K - 7 18.3H 0.00% em1 taskq 29 root 1 -68 - 0K 16K - 6 330:21 0.00% em0 taskq 41 root 1 20 - 0K 16K syncer 1 212:42 0.00% syncer 21 root 1 -44 - 0K 16K WAIT 0 201:02 0.00% swi1: net 19 root 1 -32 - 0K 16K WAIT 0 120:15 0.00% swi4: clock 22 root 1 44 - 0K 16K - 5 73:00 0.00% yarrow I've tried to ktrace the process and it produced nothing, also tried gdb and it failed to attach. Is there anything else I can try before we reboot the machine to help determine what the problem is? Regards Steve ================================================ This e.mail is private and confidential between Multiplay (UK) Ltd. and the person or entity to whom it is addressed. In the event of misdirection, the recipient is prohibited from using, copying, printing or otherwise disseminating it or any information contained in it. In the event of misdirection, illegible or incomplete transmission please telephone +44 845 868 1337 or return the E.mail to postmaster@multiplay.co.uk. From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 15:05:26 2008 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 0333110656FC for ; Wed, 10 Dec 2008 15:05:26 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.terabit.net.ua (mail.terabit.net.ua [195.137.202.147]) by mx1.freebsd.org (Postfix) with ESMTP id 8C1528FC08 for ; Wed, 10 Dec 2008 15:05:25 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from skuns.zoral.com.ua ([91.193.166.194] helo=mail.zoral.com.ua) by mail.terabit.net.ua with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63 (FreeBSD)) (envelope-from ) id 1LAQcq-000G2B-SA; Wed, 10 Dec 2008 17:05:21 +0200 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 mBAF5GV9038932 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 10 Dec 2008 17:05:16 +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.3/8.14.3) with ESMTP id mBAF5GSi006745; Wed, 10 Dec 2008 17:05:16 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.3/8.14.3/Submit) id mBAF5GPj006744; Wed, 10 Dec 2008 17:05:16 +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: Wed, 10 Dec 2008 17:05:16 +0200 From: Kostik Belousov To: Julian Elischer Message-ID: <20081210150516.GN2038@deviant.kiev.zoral.com.ua> References: <20081203001538.GC96383@bunrab.catwhisker.org> <20081209190110.GW60731@albert.catwhisker.org> <20081209200431.GL2038@deviant.kiev.zoral.com.ua> <493EEF15.4050600@elischer.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="dRZtNaFcRiL7vj6v" Content-Disposition: inline In-Reply-To: <493EEF15.4050600@elischer.org> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: ClamAV version 0.93.3, clamav-milter version 0.93.3 on skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua X-Virus-Scanned: mail.terabit.net.ua 1LAQcq-000G2B-SA 6cfd4696766118cf7ed3381502150e63 X-Terabit: YES Cc: hackers@freebsd.org, David Wolfskill Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 10 Dec 2008 15:05:26 -0000 --dRZtNaFcRiL7vj6v Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Dec 09, 2008 at 02:20:05PM -0800, Julian Elischer wrote: > Kostik Belousov wrote: > >On Tue, Dec 09, 2008 at 11:01:10AM -0800, David Wolfskill wrote: > >>On Tue, Dec 02, 2008 at 04:15:38PM -0800, David Wolfskill wrote: > >>>I seem to have a fairly- (though not deterministly so) reproducible > >>>mode of failure with an NFS-mounted directory hierarchy: An attempt to > >>>traverse a "sufficiently large" hierarchy (e.g., via "tar zcpf" or "rm > >>>-fr") will fail to "visit" some subdirectories, typically apparently > >>>acting as if the subdirectories in question do not actually exist > >>>(despite the names having been returned in the output of a previous > >>>readdir()). > >>>...=20 > > > >Did you saw me previous answer ? Supposed patch for your problem was > >committed to head as r185557, and MFCed to 7 in r185796, and to > >7.1 in r185801. > > > >Please test with latest sources. >=20 >=20 > did you notice that he tested with latest -current and releng 7? Yes, and failure mode on the HEAD looks like a different issue. --dRZtNaFcRiL7vj6v Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iEYEARECAAYFAkk/2qwACgkQC3+MBN1Mb4hRJACgkdgm5Y+rmded67QImbO+3L1t s0sAoJB2gCEL1aWdc5qYRp2W6OiB+cKq =DMUy -----END PGP SIGNATURE----- --dRZtNaFcRiL7vj6v-- From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 15:21:07 2008 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 9BEBF106564A for ; Wed, 10 Dec 2008 15:21:07 +0000 (UTC) (envelope-from ivoras@gmail.com) Received: from mail-bw0-f14.google.com (mail-bw0-f14.google.com [209.85.218.14]) by mx1.freebsd.org (Postfix) with ESMTP id D412D8FC08 for ; Wed, 10 Dec 2008 15:21:06 +0000 (UTC) (envelope-from ivoras@gmail.com) Received: by bwz7 with SMTP id 7so804347bwz.19 for ; Wed, 10 Dec 2008 07:21:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:sender :to:subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references :x-google-sender-auth; bh=o9sm7E3yj6a1Z5mzZhJi9mIWa5v2KauZN4fOv8/uWcw=; b=SyW/TMszuM5d1MotFMSZ6+BhygvVvPj8wbBuW54lKrUmNoZZiGZMuKQKLh05I3U8kz fe7M4mMLRYujALRh9zi1/eAMsHdTp4wKV2iZfKseYsiTVrbm+V7qPqYtF8YHwJZtPiOk muznO64z8ShkED/wedmjc9OlNTMyGVEQJ9jAU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references:x-google-sender-auth; b=ThY0UwVU0RNVuGzMd2OB0FFoBafJV56tRC6nm6jY1CIoyEcrWiff5n/UNfpduMJvZV YAuAWqQmGxMcu6d7WZoYqE/1QyHxt74J0JZgng8N+XZ3imGJnUhN0sVBkaofVZAaEIfX 1Al0A5bGNSoipRIAlzB1dce02ATgfO+AF7WPg= Received: by 10.181.141.7 with SMTP id t7mr495079bkn.10.1228922441693; Wed, 10 Dec 2008 07:20:41 -0800 (PST) Received: by 10.180.238.15 with HTTP; Wed, 10 Dec 2008 07:20:41 -0800 (PST) Message-ID: <9bbcef730812100720h5b3aab6ek46c4f36c67a37d58@mail.gmail.com> Date: Wed, 10 Dec 2008 16:20:41 +0100 From: "Ivan Voras" Sender: ivoras@gmail.com To: "Giorgos Keramidas" In-Reply-To: <87bpvkdqex.fsf@kobe.laptop> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <863agws2bv.fsf@ds4.des.no> <87bpvkdqex.fsf@kobe.laptop> X-Google-Sender-Auth: 33b7f3b14be52eaf Cc: freebsd-hackers@freebsd.org Subject: Re: MAXFILES in subr_param.c 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, 10 Dec 2008 15:21:07 -0000 2008/12/10 Giorgos Keramidas : > On Wed, 10 Dec 2008 14:30:24 +0100, Ivan Voras wrote: >>>> Also, it looks like MAXFILES is used only once, and in a bit funny way: >>>> >>>> 238 maxfiles = MAXFILES; >>>> 239 TUNABLE_INT_FETCH("kern.maxfiles", &maxfiles); >>>> 240 maxprocperuid = (maxproc * 9) / 10; >>>> 241 maxfilesperproc = (maxfiles * 9) / 10; >>> >>> What's funny about it? >> >> MAXFILES is a macro used only once, where it resolves to (maxproc*2). >> It's not technically incorrect, but it looks like it adds noise. > > It doesn't add noise :-) > > It's arguably a code quality and `documentation' feature. It provides a > human-readable, useful name to the "magic" value (maxproc * 2). If we > decide to bump the default to (maxproc * 10) sometime later, we won't > have to grovel through the entire src/sys/tree and look for maxproc > instances that need updating. The macro is defined and used exactly once, in this file. Other files probably use maxfiles. The problem is - since it's in an #ifdef block - is it defined anywhere else? A quick grep yields only this: conf/NOTES:options MAXFILES=999 conf/options:MAXFILES opt_param.h I don't know how config interacts with the source - does it shadow the subr_param.c value? This isn't a very important question as the system demonstratively works in any case, I see it more as a style curiosity. From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 15:28:55 2008 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 A9FFF1065676; Wed, 10 Dec 2008 15:28:55 +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 6821A8FC19; Wed, 10 Dec 2008 15:28:55 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1LAQze-0005kh-92; Wed, 10 Dec 2008 17:28:54 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: stable@FreeBSD.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Wed, 10 Dec 2008 17:28:54 +0200 From: Danny Braniss Message-ID: Cc: hackers@FreeBSD.org Subject: zfs panics 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, 10 Dec 2008 15:28:55 -0000 hi, from a solaris or linux client, doing a ls(1) of a nfs exported zfs file, for example: ls /net/zfs-server/h/.zfs/snapshot, panics the server. The server is running latest 7.1-prerelease. when client is freebsd, it mostly works, but in a few cases the server just goes into comma. btw, the server is running vanilla zfs, no tunning, and the server is 64bit with 8gb of memory and quad core (dell-pe2950) Fatal trap 12: page fault while in kernel mode cpuid = 0; apic id = 00 fault virtual address = 0x168 fault code = supervisor write data, page not present instruction pointer = 0x8:0xffffffff804a9175 stack pointer = 0x10:0xffffffffb71fc550 frame pointer = 0x10:0xffffffffb71fc560 code segment = base 0x0, limit 0xfffff, type 0x1b = DPL 0, pres 1, long 1, def32 0, gran 1 processor eflags = interrupt enabled, resume, IOPL = 0 current process = 802 (nfsd) [thread pid 802 tid 100185 ] Stopped at _mtx_lock_flags+0x15: lock cmpxchgq %rsi,0x50(%rdi) db> tr Tracing pid 802 tid 100185 td 0xffffff0004d576e0 _mtx_lock_flags() at _mtx_lock_flags+0x15 vput() at vput+0x45 nfsrv_readdirplus() at nfsrv_readdirplus+0x83e nfssvc() at nfssvc+0x400 syscall() at syscall+0x1bb Xfast_syscall() at Xfast_syscall+0xab --- syscall (155, FreeBSD ELF64, nfssvc), rip = 0x8006885cc, rsp = 0x7fffffffea2 From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 15:44:46 2008 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 A424C1065672 for ; Wed, 10 Dec 2008 15:44:46 +0000 (UTC) (envelope-from rea-fbsd@codelabs.ru) Received: from 0.mx.codelabs.ru (0.mx.codelabs.ru [144.206.177.45]) by mx1.freebsd.org (Postfix) with ESMTP id 52F5B8FC08 for ; Wed, 10 Dec 2008 15:44:46 +0000 (UTC) (envelope-from rea-fbsd@codelabs.ru) DomainKey-Signature: a=rsa-sha1; q=dns; c=simple; s=one; d=codelabs.ru; h=Received:Date:From:To:Cc:Subject:Message-ID:Reply-To:References:MIME-Version:Content-Type:Content-Disposition:In-Reply-To:Sender; b=j4tKLwhUFoso+xaoq+KZmSTOd0IC0qAaNJ3owxVS0BkoauEi+e4ovhOThjwTTBD8xY5PmGlTe5zqCCvBkRECgcoABOKIcju1TzsYeevdt8GxZ+wJKlYQW7Rh6WU95sk3ZB0V6wU9nLxaUg5r/clWXef0pC4z2cQ2pDyfn1Xurak=; Received: from shadow.codelabs.ru (shadow.codelabs.ru [144.206.177.8]) by 0.mx.codelabs.ru with esmtpsa (TLSv1:AES256-SHA:256) id 1LAREz-00085O-1r; Wed, 10 Dec 2008 18:44:45 +0300 Date: Wed, 10 Dec 2008 18:44:43 +0300 From: Eygene Ryabinkin To: =?koi8-r?B?4MzJ0SDzzc/Mycs=?= Message-ID: References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="TiqCXmo5T1hvSQQg" Content-Disposition: inline In-Reply-To: Sender: rea-fbsd@codelabs.ru Cc: freebsd-hackers@freebsd.org Subject: Re: FreeBSD X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: rea-fbsd@codelabs.ru List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Dec 2008 15:44:46 -0000 --TiqCXmo5T1hvSQQg Content-Type: text/plain; charset=koi8-r Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Wed, Dec 10, 2008 at 04:17:48AM +0200, =E0=CC=C9=D1 =F3=CD=CF=CC=C9=CB wrot= e: > Hello dear command of developers of FreeBSD. I wish to take part in the > project on developing out of FreeBSD and to subscribe for dispatch. http://lists.freebsd.org/pipermail/freebsd-hackers/2008-November/026566.html and especially http://www.freebsd.org/projects/index.html http://wiki.freebsd.org/ will be good too. --=20 Eygene _ ___ _.--. # \`.|\..----...-'` `-._.-'_.-'` # Remember that it is hard / ' ` , __.--' # to read the on-line manual =20 )/' _/ \ `-_, / # while single-stepping the kernel. `-'" `"\_ ,_.-;_.-\_ ', fsc/as # _.-'_./ {_.' ; / # -- FreeBSD Developers handbook=20 {_.-``-' {_/ # --TiqCXmo5T1hvSQQg Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (FreeBSD) iEYEARECAAYFAkk/4+sACgkQthUKNsbL7Yg9hwCeKV6Ey4EgLWnAe0ZsnBBQVT4P 7DwAni+EIBFLcDUmoqsDW0TFv1uywZTn =Gr+R -----END PGP SIGNATURE----- --TiqCXmo5T1hvSQQg-- From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 16:18:20 2008 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 58541106564A; Wed, 10 Dec 2008 16:18:20 +0000 (UTC) (envelope-from jh@saunalahti.fi) Received: from emh03.mail.saunalahti.fi (emh03.mail.saunalahti.fi [62.142.5.109]) by mx1.freebsd.org (Postfix) with ESMTP id 157A88FC16; Wed, 10 Dec 2008 16:18:20 +0000 (UTC) (envelope-from jh@saunalahti.fi) Received: from saunalahti-vams (vs3-10.mail.saunalahti.fi [62.142.5.94]) by emh03-2.mail.saunalahti.fi (Postfix) with SMTP id A5F68EBD63; Wed, 10 Dec 2008 18:01:03 +0200 (EET) Received: from emh07.mail.saunalahti.fi ([62.142.5.117]) by vs3-10.mail.saunalahti.fi ([62.142.5.94]) with SMTP (gateway) id A03FAAA0F94; Wed, 10 Dec 2008 18:01:03 +0200 Received: from a91-153-125-115.elisa-laajakaista.fi (a91-153-125-115.elisa-laajakaista.fi [91.153.125.115]) by emh07.mail.saunalahti.fi (Postfix) with SMTP id 20F781C63AC; Wed, 10 Dec 2008 18:00:59 +0200 (EET) Date: Wed, 10 Dec 2008 18:00:59 +0200 From: Jaakko Heinonen To: Danny Braniss Message-ID: <20081210160059.GA3495@a91-153-125-115.elisa-laajakaista.fi> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.18 (2008-05-17) X-Antivirus: VAMS Cc: stable@FreeBSD.org, hackers@FreeBSD.org Subject: Re: zfs panics 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, 10 Dec 2008 16:18:20 -0000 Hi, On 2008-12-10, Danny Braniss wrote: > from a solaris or linux client, doing a ls(1) of a nfs exported zfs file, > for example: ls /net/zfs-server/h/.zfs/snapshot, > panics the server. The server is running latest 7.1-prerelease. This has been reported as PR kern/125149. I have described the problem in this message: http://lists.freebsd.org/pipermail/freebsd-fs/2008-October/005217.html See the PR for RELENG_7 patches. (http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/125149) -- Jaakko From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 16:21:24 2008 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 372701065672; Wed, 10 Dec 2008 16:21:24 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (tim.des.no [194.63.250.121]) by mx1.freebsd.org (Postfix) with ESMTP id E81778FC08; Wed, 10 Dec 2008 16:21:23 +0000 (UTC) (envelope-from des@des.no) Received: from ds4.des.no (des.no [84.49.246.2]) by smtp.des.no (Postfix) with ESMTP id F18FE6D44C; Wed, 10 Dec 2008 16:21:22 +0000 (UTC) Received: by ds4.des.no (Postfix, from userid 1001) id D7853844DD; Wed, 10 Dec 2008 17:21:22 +0100 (CET) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: "Ivan Voras" References: <863agws2bv.fsf@ds4.des.no> <87bpvkdqex.fsf@kobe.laptop> <9bbcef730812100720h5b3aab6ek46c4f36c67a37d58@mail.gmail.com> Date: Wed, 10 Dec 2008 17:21:22 +0100 In-Reply-To: <9bbcef730812100720h5b3aab6ek46c4f36c67a37d58@mail.gmail.com> (Ivan Voras's message of "Wed, 10 Dec 2008 16:20:41 +0100") Message-ID: <86iqpsknlp.fsf@ds4.des.no> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: Giorgos Keramidas , freebsd-hackers@freebsd.org Subject: Re: MAXFILES in subr_param.c 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, 10 Dec 2008 16:21:24 -0000 "Ivan Voras" writes: > The macro is defined and used exactly once, in this file. Other files > probably use maxfiles. maxfiles is the real value; it's a loader tunable, and more importantly, it can be modified at run time through the kern.maxfiles sysctl variable. MAXFILES is simply the default value to which maxfiles is initialized. > The problem is - since it's in an #ifdef block > - is it defined anywhere else? A quick grep yields only this: > > conf/NOTES:options MAXFILES=3D999 > conf/options:MAXFILES opt_param.h > > I don't know how config interacts with the source - does it shadow the > subr_param.c value? Yes. If you use the MAXFILES option in your kernel config, config(8) will add a corresponding #define MAXFILES to opt_param.h. I doubt anyone would complain (or even notice) if you removed it entirely. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 16:50:22 2008 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 EFA9E106564A; Wed, 10 Dec 2008 16:50:22 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (adsl-63-193-123-122.dsl.snfc21.pacbell.net [63.193.123.122]) by mx1.freebsd.org (Postfix) with ESMTP id 9EAF48FC19; Wed, 10 Dec 2008 16:50:22 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (localhost [127.0.0.1]) by albert.catwhisker.org (8.14.3/8.14.3) with ESMTP id mBAGoMmB096841; Wed, 10 Dec 2008 08:50:22 -0800 (PST) (envelope-from david@albert.catwhisker.org) Received: (from david@localhost) by albert.catwhisker.org (8.14.3/8.14.3/Submit) id mBAGoMDE096840; Wed, 10 Dec 2008 08:50:22 -0800 (PST) (envelope-from david) Date: Wed, 10 Dec 2008 08:50:22 -0800 From: David Wolfskill To: Rick Macklem Message-ID: <20081210165022.GJ60731@albert.catwhisker.org> Mail-Followup-To: David Wolfskill , Rick Macklem , hackers@freebsd.org, current@freebsd.org References: <20081203001538.GC96383@bunrab.catwhisker.org> <20081209190110.GW60731@albert.catwhisker.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="tCj5P50694qw/4D5" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i Cc: hackers@freebsd.org, current@freebsd.org Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 10 Dec 2008 16:50:23 -0000 --tCj5P50694qw/4D5 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Dec 10, 2008 at 11:30:26AM -0500, Rick Macklem wrote: >...=20 > The different behaviour for -CURRENT could be the newer RPC layer that > was recently introduced, but that doesn't explain the basic problem. OK. > All I can think of is to ask the obvious question. "Are you using > interruptible or soft mounts?" If so, switch to hard mounts and see > if the problem goes away. (imho, neither interruptible nor soft mounts > are a good idea. You can use a forced dismount if there is a crashed > NFS server that isn't coming back anytime soon.) =46rom examination of /etc/amd* -- I don't see how to get mount(8) or amq(8) to report it -- it appears that we are using interruptible mounts, as we always have. The point is that the behavior has changed in an unexpected way. And I'm not so sure that the use of a forced dismount is generally available, as it would require logging in to the NFS client first, which may be difficult if the NFS server hosting non-root home directories is failing to respond and direct root login via ssh(1) is not permitted (as is the default). > If you are getting this with hard mounts, I'm afraid I have no idea > what the problem is, rick. What concerns me is that even if the attempted unmount gets EBUSY, the user-level process descending the directory hierarchy is getting ENOENT trying to issue fstatfs() against an open file descriptor. I'm having trouble figuring out any way that makes any sense. 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. --tCj5P50694qw/4D5 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (FreeBSD) iEYEARECAAYFAkk/800ACgkQmprOCmdXAD2NAQCfcV496CaI836vIAQjUOhGuQYW 1zgAn0/s2ng685xXauSQ5hRqX362lIMG =nYag -----END PGP SIGNATURE----- --tCj5P50694qw/4D5-- From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 17:06:27 2008 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 15C5A1065677; Wed, 10 Dec 2008 17:06:27 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.terabit.net.ua (mail.terabit.net.ua [195.137.202.147]) by mx1.freebsd.org (Postfix) with ESMTP id ABDC78FC1A; Wed, 10 Dec 2008 17:06:26 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from skuns.zoral.com.ua ([91.193.166.194] helo=mail.zoral.com.ua) by mail.terabit.net.ua with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63 (FreeBSD)) (envelope-from ) id 1LASW1-00054Z-16; Wed, 10 Dec 2008 19:06:25 +0200 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 mBAH6Kox055739 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 10 Dec 2008 19:06:21 +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.3/8.14.3) with ESMTP id mBAH6KEr027414; Wed, 10 Dec 2008 19:06:20 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.3/8.14.3/Submit) id mBAH6KFf027413; Wed, 10 Dec 2008 19:06:20 +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: Wed, 10 Dec 2008 19:06:20 +0200 From: Kostik Belousov To: David Wolfskill , Rick Macklem , hackers@freebsd.org, current@freebsd.org Message-ID: <20081210170620.GS2038@deviant.kiev.zoral.com.ua> References: <20081203001538.GC96383@bunrab.catwhisker.org> <20081209190110.GW60731@albert.catwhisker.org> <20081210165022.GJ60731@albert.catwhisker.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="TRAzd1zqvkbVQS90" Content-Disposition: inline In-Reply-To: <20081210165022.GJ60731@albert.catwhisker.org> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: ClamAV version 0.93.3, clamav-milter version 0.93.3 on skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua X-Virus-Scanned: mail.terabit.net.ua 1LASW1-00054Z-16 04fd08197217dfef5fa1386ec898a19d X-Terabit: YES Cc: Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 10 Dec 2008 17:06:27 -0000 --TRAzd1zqvkbVQS90 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Dec 10, 2008 at 08:50:22AM -0800, David Wolfskill wrote: > On Wed, Dec 10, 2008 at 11:30:26AM -0500, Rick Macklem wrote: > >...=20 > > The different behaviour for -CURRENT could be the newer RPC layer that > > was recently introduced, but that doesn't explain the basic problem. >=20 > OK. >=20 > > All I can think of is to ask the obvious question. "Are you using > > interruptible or soft mounts?" If so, switch to hard mounts and see > > if the problem goes away. (imho, neither interruptible nor soft mounts > > are a good idea. You can use a forced dismount if there is a crashed > > NFS server that isn't coming back anytime soon.) >=20 > From examination of /etc/amd* -- I don't see how to get mount(8) or > amq(8) to report it -- it appears that we are using interruptible > mounts, as we always have. >=20 > The point is that the behavior has changed in an unexpected way. And > I'm not so sure that the use of a forced dismount is generally > available, as it would require logging in to the NFS client first, which > may be difficult if the NFS server hosting non-root home directories is > failing to respond and direct root login via ssh(1) is not permitted (as > is the default). >=20 > > If you are getting this with hard mounts, I'm afraid I have no idea > > what the problem is, rick. >=20 > What concerns me is that even if the attempted unmount gets EBUSY, the > user-level process descending the directory hierarchy is getting ENOENT > trying to issue fstatfs() against an open file descriptor. >=20 > I'm having trouble figuring out any way that makes any sense. Basically, the problem is that NFS uses shared lookup, and this allows for the bug where several negative namecache entries are created for non-existent node. Then this node gets created, removing only the first negative namecache entry. For some reasons, vnode is reclaimed; amd' tasting of unmount is a good reason for vnode to be reclaimed. Now, you have existing path and a negative cache entry. This was reported by Peter Holm first, I listed relevant revisions that should fix this in previous mail. --TRAzd1zqvkbVQS90 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iEYEARECAAYFAkk/9wwACgkQC3+MBN1Mb4h0/QCgiRKkwR+u0kcvEVdC3RxdPskp c5MAoKKMfVJelmr3tQ1aOar81q7Ydpxt =nQ99 -----END PGP SIGNATURE----- --TRAzd1zqvkbVQS90-- From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 17:43:55 2008 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 564BD106567B for ; Wed, 10 Dec 2008 17:43:55 +0000 (UTC) (envelope-from prvs=julian=223e0e01c@elischer.org) Received: from smtp-outbound.ironport.com (smtp-outbound.ironport.com [63.251.108.112]) by mx1.freebsd.org (Postfix) with ESMTP id 43E438FC0C for ; Wed, 10 Dec 2008 17:43:55 +0000 (UTC) (envelope-from prvs=julian=223e0e01c@elischer.org) Received: from unknown (HELO julian-mac.elischer.org) ([10.251.60.167]) by smtp-outbound.ironport.com with ESMTP; 10 Dec 2008 09:15:17 -0800 Message-ID: <493FF924.7010100@elischer.org> Date: Wed, 10 Dec 2008 09:15:16 -0800 From: Julian Elischer User-Agent: Thunderbird 2.0.0.18 (Macintosh/20081105) MIME-Version: 1.0 To: rea-fbsd@codelabs.ru References: In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Cc: =?UTF-8?B?0K7Qu9C40Y8g0KHQvNC+0LvQuNC6?= , freebsd-hackers@freebsd.org Subject: Re: FreeBSD (russian) 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, 10 Dec 2008 17:43:55 -0000 Eygene Ryabinkin wrote: > Wed, Dec 10, 2008 at 04:17:48AM +0200, Ð®Ð»Ð¸Ñ Ð¡Ð¼Ð¾Ð»Ð¸Ðº wrote: >> Hello dear command of developers of FreeBSD. I wish to take part in the >> project on developing out of FreeBSD and to subscribe for dispatch. > > http://lists.freebsd.org/pipermail/freebsd-hackers/2008-November/026566.html > and especially http://www.freebsd.org/projects/index.html > http://wiki.freebsd.org/ will be good too. can we have a russian speaking developer contact him too? From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 18:32:21 2008 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 5D26A1065680 for ; Wed, 10 Dec 2008 18:32:21 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: from yx-out-2324.google.com (yx-out-2324.google.com [74.125.44.29]) by mx1.freebsd.org (Postfix) with ESMTP id 0B6638FC23 for ; Wed, 10 Dec 2008 18:32:20 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: by yx-out-2324.google.com with SMTP id 8so285260yxb.13 for ; Wed, 10 Dec 2008 10:32:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=AiU9Os0frClOx8Yph3DUf68mqx5IyUz6ZVadAflK56M=; b=x0sSOZtVMU0LH6K4uwFAYKLKda9s58u+tQdVisSVlCs9AgU2lPyqLuAjfv+o8rLPZg +l8lsB8OLXlLIkjVHRHs2g9IlBgKtebd4yrj6yQCrnc/TxaUpmO8OV4kPpeU2fTsvSlq gd4FtnUSYE/KSz/7VtCzhH89/VlnAPS2UhnWA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=IMtw/Jek5tDQZq4YTnvUjeurXzz6IiOZpgEphNBwmwRRs/1mz5w9t7/jQgMvMDe2+A Lrs+O+MbwfMJt8/J/7DPccV4Ksk+karKmLmULJ6+7Ed95zCOO3XKpBJD5x67BhROm8EI ELpBI2XTz7rXYGJ9w6iSml9nACUQZ+y08m9vM= Received: by 10.90.34.11 with SMTP id h11mr843394agh.114.1228933940003; Wed, 10 Dec 2008 10:32:20 -0800 (PST) Received: by 10.90.114.14 with HTTP; Wed, 10 Dec 2008 10:32:19 -0800 (PST) Message-ID: Date: Wed, 10 Dec 2008 21:32:19 +0300 From: pluknet To: "Julian Elischer" In-Reply-To: <493FF924.7010100@elischer.org> MIME-Version: 1.0 Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: base64 Content-Disposition: inline References: <493FF924.7010100@elischer.org> Cc: =?KOI8-R?B?4MzJ0SDzzc/Mycs=?= , freebsd-hackers@freebsd.org Subject: Re: FreeBSD (russian) 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, 10 Dec 2008 18:32:21 -0000 MjAwOC8xMi8xMCBKdWxpYW4gRWxpc2NoZXIgPGp1bGlhbkBlbGlzY2hlci5vcmc+Ogo+IEV5Z2Vu ZSBSeWFiaW5raW4gd3JvdGU6Cj4+Cj4+IFdlZCwgRGVjIDEwLCAyMDA4IGF0IDA0OjE3OjQ4QU0g KzAyMDAsIODMydEg883PzMnLIHdyb3RlOgo+Pj4KPj4+IEhlbGxvIGRlYXIgY29tbWFuZCBvZiBk ZXZlbG9wZXJzIG9mIEZyZWVCU0QuIEkgd2lzaCB0byB0YWtlIHBhcnQgaW4gdGhlCj4+PiBwcm9q ZWN0IG9uIGRldmVsb3Bpbmcgb3V0IG9mIEZyZWVCU0QgYW5kIHRvIHN1YnNjcmliZSBmb3IgZGlz cGF0Y2guCj4+Cj4+Cj4+IGh0dHA6Ly9saXN0cy5mcmVlYnNkLm9yZy9waXBlcm1haWwvZnJlZWJz ZC1oYWNrZXJzLzIwMDgtTm92ZW1iZXIvMDI2NTY2Lmh0bWwKPj4gYW5kIGVzcGVjaWFsbHkgaHR0 cDovL3d3dy5mcmVlYnNkLm9yZy9wcm9qZWN0cy9pbmRleC5odG1sCj4+IGh0dHA6Ly93aWtpLmZy ZWVic2Qub3JnLyB3aWxsIGJlIGdvb2QgdG9vLgo+Cj4KPiBjYW4gd2UgaGF2ZSBhIHJ1c3NpYW4g c3BlYWtpbmcgZGV2ZWxvcGVyIGNvbnRhY3QgaGltIHRvbz8KCml0J3MgaGVyIDopCgotLSAKd2Jy LApwbHVrbmV0Cg== From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 18:53:26 2008 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 385D31065673; Wed, 10 Dec 2008 18:53:26 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id A7AB38FC24; Wed, 10 Dec 2008 18:53:25 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from localhost.corp.yahoo.com (john@localhost [IPv6:::1]) (authenticated bits=0) by server.baldwin.cx (8.14.3/8.14.3) with ESMTP id mBAIqvkR024770; Wed, 10 Dec 2008 13:53:14 -0500 (EST) (envelope-from jhb@freebsd.org) From: John Baldwin To: freebsd-current@freebsd.org Date: Wed, 10 Dec 2008 13:31:23 -0500 User-Agent: KMail/1.9.7 References: <493DA269.2070805@FreeBSD.org> <20081208235119.GA46608@onelab2.iet.unipi.it> In-Reply-To: <20081208235119.GA46608@onelab2.iet.unipi.it> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200812101331.24182.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (server.baldwin.cx [IPv6:::1]); Wed, 10 Dec 2008 13:53:17 -0500 (EST) X-Virus-Scanned: ClamAV 0.94.2/8743/Wed Dec 10 10:08:45 2008 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-2.6 required=4.2 tests=AWL,BAYES_00,NO_RELAYS autolearn=ham version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on server.baldwin.cx Cc: Maxim Sobolev , Luigi Rizzo , hackers@freebsd.org, Luigi Rizzo , "current@freebsd.org" Subject: Re: Enhancing cdboot [patch for review] 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, 10 Dec 2008 18:53:26 -0000 On Monday 08 December 2008 06:51:19 pm Luigi Rizzo wrote: > On Mon, Dec 08, 2008 at 02:40:41PM -0800, Maxim Sobolev wrote: > > Hi, > > > > Below please find patch that enhances cdboot with two compile-time options: > ... > > Any comments/suggestions are appreciated. If there are no objections I > > would like to commit the change. The long-term goal is to make > > CDBOOT_PROMPT default mode for installation CD. > > > > http://sobomax.sippysoft.com/~sobomax/cdboot.diff > > Looks good. Some comments: > 1. since there is plenty of space in the cdboot sector, why don't you > make the two option always compiled in, controlling which one to > activate through flags in the bootsector itself, to be set > patching the binary sector itself using a mechanism similar to > boot0cfg. > Of course you cannot alter a cdrom after you burn it, > but it makes it easier to build CDs with one or the other defaults, > patching cdboot or the iso image itself before creating/burning it. I don't think this is very useful because CDs are read-only. You can just as easily build a different cdboot rather than having to write some custom cdbootcfg util to patch the binary. > 2. in fact, the 'silent' option could be disabled at runtime by > pressing some key (e.g. adding a short wait loop before proceeding; > if this is meant for custom, unattended CDs the extra delay should not > matter much); I don't imagine anyone will know to press a key to get verbose messages, and the CD boot process is quick enough you would have to add an artificial delay to it to allow for the keypress. > 3. one nitpick -- in one of the first chunks you replace $start > with $LOAD, but if i am not mistaken operation depends on $LOAD = $start, > so why don't you always use the same ? No, because he relocates it, $start is now the relocated address, but the BIOS loads it at LOAD which is now != $start. > Also in terms of relocation size, wouldn't it be the case of > hardwiring the size of the cd boot sector: > > - mov $((end_init - start)/2),%cx > + mov 1024,%cx I prefer the existing code to make sure and copy the full boot loader, whatever it's size is. Maxim, My only comment is to please make the new block comment match the style of the existing block comments by having '#\n' lines before and after. -- John Baldwin From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 20:06:41 2008 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 6C9121065673 for ; Wed, 10 Dec 2008 20:06:41 +0000 (UTC) (envelope-from prvs=julian=223e0e01c@elischer.org) Received: from smtp-outbound.ironport.com (smtp-outbound.ironport.com [63.251.108.112]) by mx1.freebsd.org (Postfix) with ESMTP id 560FA8FC08 for ; Wed, 10 Dec 2008 20:06:41 +0000 (UTC) (envelope-from prvs=julian=223e0e01c@elischer.org) Received: from unknown (HELO julian-mac.elischer.org) ([10.251.60.167]) by smtp-outbound.ironport.com with ESMTP; 10 Dec 2008 12:06:40 -0800 Message-ID: <4940214F.8040103@elischer.org> Date: Wed, 10 Dec 2008 12:06:39 -0800 From: Julian Elischer User-Agent: Thunderbird 2.0.0.18 (Macintosh/20081105) MIME-Version: 1.0 To: pluknet References: <493FF924.7010100@elischer.org> In-Reply-To: Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 8bit Cc: =?KOI8-R?Q?=E0=CC=C9=D1_=F3=CD=CF=CC=C9=CB?= , freebsd-hackers@freebsd.org Subject: Re: FreeBSD (russian) 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, 10 Dec 2008 20:06:41 -0000 pluknet wrote: > 2008/12/10 Julian Elischer : >> Eygene Ryabinkin wrote: >>> Wed, Dec 10, 2008 at 04:17:48AM +0200, àÌÉÑ óÍÏÌÉË wrote: >>>> Hello dear command of developers of FreeBSD. I wish to take part in the >>>> project on developing out of FreeBSD and to subscribe for dispatch. >>> >>> http://lists.freebsd.org/pipermail/freebsd-hackers/2008-November/026566.html >>> and especially http://www.freebsd.org/projects/index.html >>> http://wiki.freebsd.org/ will be good too. >> >> can we have a russian speaking developer contact him too? > > it's her :) > yeah you are the 3rd person to tell me it's "Julia".. I should know better :-) (and I see more emails ahead in my list that will probably tell me too. :-) From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 16:47:02 2008 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 D12911065670; Wed, 10 Dec 2008 16:47:02 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from phoenix.cs.uoguelph.ca (phoenix.cs.uoguelph.ca [131.104.94.216]) by mx1.freebsd.org (Postfix) with ESMTP id 91CD48FC1D; Wed, 10 Dec 2008 16:47:02 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from muncher.cs.uoguelph.ca (muncher.cs.uoguelph.ca [131.104.91.102]) by phoenix.cs.uoguelph.ca (8.13.1/8.13.1) with ESMTP id mBAGT07B031229; Wed, 10 Dec 2008 11:29:00 -0500 Received: from localhost (rmacklem@localhost) by muncher.cs.uoguelph.ca (8.11.7p3+Sun/8.11.6) with ESMTP id mBAGUQ125461; Wed, 10 Dec 2008 11:30:26 -0500 (EST) X-Authentication-Warning: muncher.cs.uoguelph.ca: rmacklem owned process doing -bs Date: Wed, 10 Dec 2008 11:30:26 -0500 (EST) From: Rick Macklem X-X-Sender: rmacklem@muncher.cs.uoguelph.ca To: David Wolfskill In-Reply-To: <20081209190110.GW60731@albert.catwhisker.org> Message-ID: References: <20081203001538.GC96383@bunrab.catwhisker.org> <20081209190110.GW60731@albert.catwhisker.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Scanned-By: MIMEDefang 2.63 on 131.104.94.216 X-Mailman-Approved-At: Wed, 10 Dec 2008 21:26:31 +0000 Cc: hackers@freebsd.org, current@freebsd.org Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 10 Dec 2008 16:47:02 -0000 On Tue, 9 Dec 2008, David Wolfskill wrote: > On Tue, Dec 02, 2008 at 04:15:38PM -0800, David Wolfskill wrote: >> I seem to have a fairly- (though not deterministly so) reproducible >> mode of failure with an NFS-mounted directory hierarchy: An attempt to >> traverse a "sufficiently large" hierarchy (e.g., via "tar zcpf" or "rm >> -fr") will fail to "visit" some subdirectories, typically apparently >> acting as if the subdirectories in question do not actually exist >> (despite the names having been returned in the output of a previous >> readdir()). >> ... > > I was able to reproduce the external symptoms of the failure running > CURRENT as of yesterday, using "rm -fr" of a copy of a recent > /usr/ports hierachy on an NFS-mounted file system as a test case. > However, I believe the mechanism may be a bit different -- while > still being other than what I would expect. > > One aspect in which the externally-observable symptoms were different > (under CURRENT, vs. RELENG_7) is that under CURRENT, once the error > condition occurred, the NFS client machine was in a state where it > merely kept repeating > > nfs server pid848@fbsd-build:/volume: not responding > > until I logged in as root & rebooted it. > The different behaviour for -CURRENT could be the newer RPC layer that was recently introduced, but that doesn't explain the basic problem. All I can think of is to ask the obvious question. "Are you using interruptible or soft mounts?" If so, switch to hard mounts and see if the problem goes away. (imho, neither interruptible nor soft mounts are a good idea. You can use a forced dismount if there is a crashed NFS server that isn't coming back anytime soon.) If you are getting this with hard mounts, I'm afraid I have no idea what the problem is, rick. From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 22:34:46 2008 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 93ABC1065676; Wed, 10 Dec 2008 22:34:46 +0000 (UTC) (envelope-from patfbsd@davenulle.org) Received: from smtp.lamaiziere.net (net.lamaiziere.net [91.121.44.19]) by mx1.freebsd.org (Postfix) with ESMTP id 54B1E8FC0C; Wed, 10 Dec 2008 22:34:46 +0000 (UTC) (envelope-from patfbsd@davenulle.org) Received: from baby-jane.lamaiziere.net (unknown [79.87.10.246]) by smtp.lamaiziere.net (Postfix) with ESMTPA id E114F63366E; Wed, 10 Dec 2008 23:34:44 +0100 (CET) Received: from baby-jane (localhost [127.0.0.1]) by baby-jane.lamaiziere.net (Postfix) with ESMTP id BE37E676D35; Wed, 10 Dec 2008 23:34:43 +0100 (CET) Date: Wed, 10 Dec 2008 23:34:40 +0100 From: Patrick =?ISO-8859-15?Q?Lamaizi=E8re?= To: Philip Paeps Message-ID: <20081210233440.41bd1c47@baby-jane> In-Reply-To: <20081208202155.GA7403@detritus.paeps.cx> References: <20081207224551.13ca3590@baby-jane> <20081208202155.GA7403@detritus.paeps.cx> Organization: /dave/nulle X-Mailer: Claws Mail 3.3.1 (GTK+ 2.12.9; i386-apple-darwin9.3.0) Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 8bit Cc: freebsd-hackers@freebsd.org Subject: Re: crypto(9) choose another driver if we cannot open a session on it 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, 10 Dec 2008 22:34:46 -0000 Le Mon, 8 Dec 2008 21:21:55 +0100, Philip Paeps a écrit : Hello, > On 2008-12-07 22:45:51 (+0100), Patrick Lamaizière > wrote: > > I wrote a small patch to allow the crypto framework to choose > > another cryptographic driver if we cannot open a session on the > > driver. > > Very cool. :-) I've been hacking on this too, mainly to get rid of > the code duplication that currently exists. Which code exactly? Yes I'm curious :-) I'm thinking about how to remove the need for a device to support all the algorithms when we open a session. By using a fake "crypto virtual device" to open and dispatch crypto requests to real devices or to cryptosoft. But i don't have any code to show yet. There is one thing I'm asking about crypto(9): - I doubt that the migration of a session is safe and I think that would be far easier to prevent a driver to unregister when there are some pending sessions on it? glxsb and padlock do not allow to unregister in this case. I've looked quickly the code of geli or ipsec. If the crypto framework returns EAGAIN because the migration of the session, they restart a crypto_dispatch(crp) but the datas in crp->crp_buf can be corrupted by the previous crypto operation (IMHO, may be i've missed something)? Thanks, regards. From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 22:50:56 2008 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 3E9821065677 for ; Wed, 10 Dec 2008 22:50:56 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from ebb.errno.com (ebb.errno.com [69.12.149.25]) by mx1.freebsd.org (Postfix) with ESMTP id D49738FC1C for ; Wed, 10 Dec 2008 22:50:55 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from trouble.errno.com (trouble.errno.com [10.0.0.248]) (authenticated bits=0) by ebb.errno.com (8.13.6/8.12.6) with ESMTP id mBAMopG9072826 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 10 Dec 2008 14:50:52 -0800 (PST) (envelope-from sam@freebsd.org) Message-ID: <494047CB.6050400@freebsd.org> Date: Wed, 10 Dec 2008 14:50:51 -0800 From: Sam Leffler Organization: FreeBSD Project User-Agent: Thunderbird 2.0.0.9 (X11/20071125) MIME-Version: 1.0 To: =?ISO-8859-1?Q?Patrick_Lamaizi=E8re?= References: <20081207224551.13ca3590@baby-jane> <20081208202155.GA7403@detritus.paeps.cx> <20081210233440.41bd1c47@baby-jane> In-Reply-To: <20081210233440.41bd1c47@baby-jane> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-DCC--Metrics: ebb.errno.com; whitelist Cc: freebsd-hackers@freebsd.org, Philip Paeps Subject: Re: crypto(9) choose another driver if we cannot open a session on it 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, 10 Dec 2008 22:50:56 -0000 Patrick Lamaizière wrote: > Le Mon, 8 Dec 2008 21:21:55 +0100, > Philip Paeps a écrit : > > Hello, > > >> On 2008-12-07 22:45:51 (+0100), Patrick Lamaizière >> wrote: >> >>> I wrote a small patch to allow the crypto framework to choose >>> another cryptographic driver if we cannot open a session on the >>> driver. >>> >> Very cool. :-) I've been hacking on this too, mainly to get rid of >> the code duplication that currently exists. >> > > Which code exactly? Yes I'm curious :-) > > I'm thinking about how to remove the need for a device to support all > the algorithms when we open a session. By using a fake "crypto > virtual device" to open and dispatch crypto requests to real devices or > to cryptosoft. But i don't have any code to show yet. > > There is one thing I'm asking about crypto(9): > - I doubt that the migration of a session is safe and I think that > would be far easier to prevent a driver to unregister when there are > some pending sessions on it? glxsb and padlock do not allow to > unregister in this case. > > I've looked quickly the code of geli or ipsec. If the crypto > framework returns EAGAIN because the migration of the session, they > restart a crypto_dispatch(crp) but the datas in crp->crp_buf can be > corrupted by the previous crypto operation (IMHO, may be i've missed > something)? > This sounds like the session management layer I wanted to insert a while back. It was a reason why I made the s/w driver into a pseudo device (so there'd be a handle). I want to look at your mods but haven't had time. As to unregister that was designed for devices like cardbus cards that might go away. About the only way to simulate it today is to unload a driver module. But it should work; if you see an issue we should try to fix it. OTOH the limitations of the existing crypto code are dramatic and the rationale for maintaining the obsd api's (both in kernel and user space) are no longer valid. It would be good to see someone take this stuff and overhaul it to do things like: o add a session management layer that falls back to s/w when a device is incapable and when operations are more efficiently done in s/w (e.g ops too small to incur the dma setup/overhead) o do load balancing over multiple devices o support cpu resources as pseudo drivers (e.g. pin a thread to a cpu) o replace the bogus fd session crud w/ device cloning The linux folks have done some of this and there may be lessons to be learned from their efforts. FWIW netbsd has some recent user api changes for doing async ops and batching to speedup openssl etc; if you're going to get into this stuff you might take a look. Sam From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 02:00:27 2008 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 8AD74106564A for ; Thu, 11 Dec 2008 02:00:26 +0000 (UTC) (envelope-from sheldon@sigsegv.ca) Received: from wf-out-1314.google.com (wf-out-1314.google.com [209.85.200.169]) by mx1.freebsd.org (Postfix) with ESMTP id 681848FC13 for ; Thu, 11 Dec 2008 02:00:26 +0000 (UTC) (envelope-from sheldon@sigsegv.ca) Received: by wf-out-1314.google.com with SMTP id 24so477202wfg.7 for ; Wed, 10 Dec 2008 18:00:26 -0800 (PST) Received: by 10.142.230.9 with SMTP id c9mr509842wfh.101.1228960825867; Wed, 10 Dec 2008 18:00:25 -0800 (PST) Received: by 10.142.136.4 with HTTP; Wed, 10 Dec 2008 18:00:25 -0800 (PST) Message-ID: Date: Wed, 10 Dec 2008 18:00:25 -0800 From: "Sheldon Givens" To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Small Change to chpass.c 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, 11 Dec 2008 02:00:27 -0000 Hi guys, When I was doing some user management today I noticed that chpass, and all the utilities that use chpass.c, only give one attempt to authenticate to make the change. After I messed this up once or twice (and after doing 4-5 minutes of editing only to have it lost when I typo'd the password) I wrote this little change in to chpass.c. When it needs the users password, it will enter into a for loop, increasing itr until it hits max_retries (defined at top of main() declaration). If one of these tries is successful (password given matches) then auth is set to '1' and we break from the loop, and update info. If, after three tries, auth is still '0' (the user didn't supply the proper password) we call baduser() to handle it. It's a pretty inconsequential change but it managed to relieve me of quite a bit of stress :-) Happy Holidays, everyone! Sheldon Givens ---snip--- --- /usr/src/usr.bin/chpass.c 2008-12-11 01:55:27.000000000 -0800 +++ /usr/src/usr.bin/chpass.c 2008-12-11 01:57:09.000000000 -0800 @@ -80,10 +80,11 @@ { enum { NEWSH, LOADENTRY, EDITENTRY, NEWPW, NEWEXP } op; struct passwd lpw, *old_pw, *pw; - int ch, pfd, tfd; + int ch, pfd, tfd, itr, auth; const char *password; char *arg = NULL; uid_t uid; + int max_retries = 3; #ifdef YP struct ypclnt *ypclnt; const char *yp_domain = NULL, *yp_host = NULL; @@ -227,9 +228,16 @@ } if (old_pw && !master_mode) { - password = getpass("Password: "); - if (strcmp(crypt(password, old_pw->pw_passwd), - old_pw->pw_passwd) != 0) + auth = 0; + for(itr=0;itrpw_passwd), + old_pw->pw_passwd) == 0) { + auth=1; + break; + } + } + if (!auth) baduser(); } else { password = ""; ---snip--- From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 04:52:50 2008 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 78F5E1065672 for ; Thu, 11 Dec 2008 04:52:50 +0000 (UTC) (envelope-from won.derick@yahoo.com) Received: from n30.bullet.mail.mud.yahoo.com (n30.bullet.mail.mud.yahoo.com [68.142.207.49]) by mx1.freebsd.org (Postfix) with SMTP id 33E918FC22 for ; Thu, 11 Dec 2008 04:52:49 +0000 (UTC) (envelope-from won.derick@yahoo.com) Received: from [68.142.200.227] by n30.bullet.mail.mud.yahoo.com with NNFMP; 11 Dec 2008 04:52:49 -0000 Received: from [68.142.201.247] by t8.bullet.mud.yahoo.com with NNFMP; 11 Dec 2008 04:52:49 -0000 Received: from [127.0.0.1] by omp408.mail.mud.yahoo.com with NNFMP; 11 Dec 2008 04:52:49 -0000 X-Yahoo-Newman-Property: ymail-3 X-Yahoo-Newman-Id: 436556.11565.bm@omp408.mail.mud.yahoo.com Received: (qmail 76419 invoked by uid 60001); 11 Dec 2008 04:52:48 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:X-Mailer:References:Date:From:Subject:To:Cc:MIME-Version:Content-Type:Message-ID; b=5R7L5Q4L5vAkDUMPfFkxGsAaaYx9kqg7h69o5P4QCFURrYGd/lQnh+YqFYCuKWfMR8UrSzA1lKiSeJs9mKkIye+B9R5gr6k19VdjAPMyDK6sbxRsF7+17BmURFWs37uVleMPzY3AFiddvE7maW01SIXT/ir6LtPz5/11D4DNNO0=; X-YMail-OSG: t9X3icoVM1mhCfBWo2il8PIL.3u5.tG5S54VEa7thQ5KOhm64JEftDLleHS9aG5Oguaw3ZjCYSs5_3EwfTqO0UHgvUQHUUucfNzLs4TN.FUFYn3V_yMzN2gaPMagU88i_kQe2uFPRCWPoXiXFdgsmG90XfNePI2S5y16Rm5NevI3qI_4qP432Y_FlngEKy299FnZpDxQMl.NWNUgQ1YV.zk6CB_YQDDj Received: from [58.71.34.137] by web45816.mail.sp1.yahoo.com via HTTP; Wed, 10 Dec 2008 20:52:48 PST X-Mailer: YahooMailRC/1155.32 YahooMailWebService/0.7.260.1 References: <547602.79284.qm@web45809.mail.sp1.yahoo.com> <4933A29B.8060907@gmx.de> <20081201090421.GA99082@rink.nu> <611173.7111.qm@web45805.mail.sp1.yahoo.com> <4933AFD4.3070501@gmx.de> Date: Wed, 10 Dec 2008 20:52:48 -0800 (PST) From: Won De Erick To: Christoph Mallon MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Message-ID: <832968.75350.qm@web45816.mail.sp1.yahoo.com> Cc: freebsd-hackers@freebsd.org, Rink Springer , freebsd-hardware@freebsd.org Subject: Re: Watchdog for Boser (HS-7001) 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, 11 Dec 2008 04:52:50 -0000 Christoph Mallon wrote: > > Won De Erick schrieb: >>> ----- Original Message ---- >> >>> From: Rink Springer >>> >>> >> On Mon, Dec 01, 2008 at 09:38:51AM +0100, Christoph Mallon wrote: >>>> Userland is not allowed to write to ports. That's the bus error you see. Also without a call to the exit syscall at the end, it will segfault. >>> Note that you can write to ports from userland by opening /dev/io - if >>> you have it opened, you can write to the ports. >>> >> >> I've added the following at the end >> >> mov eax, 1 ; SYS_exit >> call doint >> >> doint: >> int 0x80 >> ret >> >> Besides, I can see the following at /dev >> crw------- 1 root wheel 0, 16 Nov 27 01:53 io >> >> How should I make this open? do i need to %include this? > > You're probably better of writing this in C. Here is a wrapper for the out instruction: > > static inline outb(unsigned short port, unsigned char data) > { > asm("outb %0, %1" : : "a" (data), "dN" (port)); > } > > As Rink mentioned, you have to open /dev/io. The process must have super-user privileges, see io(4). > > OK thanks for all the tips. I have now a working watchdog. :) From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 06:32:34 2008 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 7980F1065670 for ; Thu, 11 Dec 2008 06:32:34 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from igloo.linux.gr (igloo.linux.gr [62.1.205.36]) by mx1.freebsd.org (Postfix) with ESMTP id EB5D08FC12 for ; Thu, 11 Dec 2008 06:32:33 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from kobe.laptop (adsl22-219.kln.forthnet.gr [77.49.149.219]) (authenticated bits=128) by igloo.linux.gr (8.14.3/8.14.3/Debian-5) with ESMTP id mBB6WNgS015051 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 11 Dec 2008 08:32:28 +0200 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.3/8.14.3) with ESMTP id mBB6WMs8003379; Thu, 11 Dec 2008 08:32:22 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) Received: (from keramida@localhost) by kobe.laptop (8.14.3/8.14.3/Submit) id mBB6WLki003378; Thu, 11 Dec 2008 08:32:21 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) From: Giorgos Keramidas To: "Sheldon Givens" References: Date: Thu, 11 Dec 2008 08:32:21 +0200 In-Reply-To: (Sheldon Givens's message of "Wed, 10 Dec 2008 18:00:25 -0800") Message-ID: <87vdtr9q8a.fsf@kobe.laptop> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-MailScanner-ID: mBB6WNgS015051 X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-3.86, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL 0.54, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@ceid.upatras.gr X-Spam-Status: No Cc: freebsd-hackers@freebsd.org Subject: Re: Small Change to chpass.c 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, 11 Dec 2008 06:32:34 -0000 On Wed, 10 Dec 2008 18:00:25 -0800, "Sheldon Givens" wrote: > Hi guys, > > When I was doing some user management today I noticed that chpass, and > all the utilities that use chpass.c, only give one attempt to > authenticate to make the change. After I messed this up once or twice > (and after doing 4-5 minutes of editing only to have it lost when I > typo'd the password) I wrote this little change in to chpass.c. This seems useful, thanks for submitting the patch :) > ---snip--- > --- /usr/src/usr.bin/chpass.c 2008-12-11 01:55:27.000000000 -0800 > +++ /usr/src/usr.bin/chpass.c 2008-12-11 01:57:09.000000000 -0800 > @@ -80,10 +80,11 @@ > { > enum { NEWSH, LOADENTRY, EDITENTRY, NEWPW, NEWEXP } op; > struct passwd lpw, *old_pw, *pw; > - int ch, pfd, tfd; > + int ch, pfd, tfd, itr, auth; > const char *password; > char *arg = NULL; > uid_t uid; > + int max_retries = 3; > #ifdef YP > struct ypclnt *ypclnt; > const char *yp_domain = NULL, *yp_host = NULL; > @@ -227,9 +228,16 @@ > } > > if (old_pw && !master_mode) { > - password = getpass("Password: "); > - if (strcmp(crypt(password, old_pw->pw_passwd), > - old_pw->pw_passwd) != 0) > + auth = 0; > + for(itr=0;itr + password = getpass("Password:"); > + if(strcmp(crypt(password, old_pw->pw_passwd), > + old_pw->pw_passwd) == 0) { > + auth=1; > + break; > + } > + } > + if (!auth) > baduser(); > } else { > password = ""; > ---snip--- You can probably do away with `auth' and reset password to NULL when strcmp() fails (note that we also use whitespace in for statements to separate everything more clearly): if (old_pw && !master_mode) { for (itr = 0; itr < max_retries; itr++) { password = getpass("Password:"); if (strcmp(crypt(password, old_pw->pw_passwd), old_pw->pw_passwd) != 0) break; password = NULL; } if (password == NULL) baduser(); } else { password = ""; From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 06:53:27 2008 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 EFD1A106564A for ; Thu, 11 Dec 2008 06:53:27 +0000 (UTC) (envelope-from jonathan+freebsd-hackers@hst.org.za) Received: from hermes.hst.org.za (onix.hst.org.za [209.203.2.133]) by mx1.freebsd.org (Postfix) with ESMTP id 2B8868FC17 for ; Thu, 11 Dec 2008 06:53:26 +0000 (UTC) (envelope-from jonathan+freebsd-hackers@hst.org.za) Received: from sysadmin.hst.org.za (sysadmin.int.dbn.hst.org.za [10.1.1.20]) (authenticated bits=0) by hermes.hst.org.za (8.13.8/8.13.8) with ESMTP id mBB6Ohnw012000 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Thu, 11 Dec 2008 08:24:43 +0200 (SAST) (envelope-from jonathan+freebsd-hackers@hst.org.za) From: Jonathan McKeown Organization: Health Systems Trust To: freebsd-hackers@freebsd.org User-Agent: KMail/1.9.7 References: <493DA269.2070805@FreeBSD.org> <20081208235119.GA46608@onelab2.iet.unipi.it> <200812101331.24182.jhb@freebsd.org> In-Reply-To: <200812101331.24182.jhb@freebsd.org> X-Face: $@VrUx^RHy/}yu]jKf/<4T%/d|F+$j-Ol2"2J$q+%OK1]&/G_S9(=?iso-8859-1?q?HkaQ*=60!=3FYOK=3FY!=27M=60C=0A=09aP=5C9nVPF8Q=7DCilHH8l?= =?iso-8859-1?q?=3B=7E!42HK6=273lg4J=7Daz?=@1Dqqh:J]M^"YPn*2IWrZON$1+G?oX3@ =?iso-8859-1?q?k=230=0A=0954XDRg=3DYn=5FF-etwot4U=24b?=dTS{i X-Spam-Score: -4.399 () ALL_TRUSTED,BAYES_00 X-Scanned-By: MIMEDefang 2.61 on 209.203.2.133 Subject: Re: Enhancing cdboot [patch for review] 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, 11 Dec 2008 06:53:28 -0000 While you're enhancing cdboot anyway, can I ask how complicated it would be to make cdboot serial-console capable? (I'm not a C programmer, I'm a sysadmin - but I'd be prepared to try and look at this myself if no-one else is interested). As it stands, the only way I've found to do a serial-console CD-based installation is by enabling the serial console in /boot/loader.conf, by which time you've already missed several useful points, particularly the entry to BIOS settings (if you have a serial-capable BIOS). Jonathan From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 07:11:31 2008 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 20FC6106567B for ; Thu, 11 Dec 2008 07:11:31 +0000 (UTC) (envelope-from trond@fagskolen.gjovik.no) Received: from ramstind.fig.ol.no (ramstind.fig.ol.no [IPv6:2001:700:1100:1:250:4ff:fe43:9d15]) by mx1.freebsd.org (Postfix) with ESMTP id 8E5CE8FC21 for ; Thu, 11 Dec 2008 07:11:30 +0000 (UTC) (envelope-from trond@fagskolen.gjovik.no) Received: from ramstind.fig.ol.no (trond@localhost [127.0.0.1]) by ramstind.fig.ol.no (8.13.8/8.13.8) with ESMTP id mBB7BPiv019074 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Thu, 11 Dec 2008 08:11:26 +0100 (CET) (envelope-from trond@fagskolen.gjovik.no) Received: from localhost (trond@localhost) by ramstind.fig.ol.no (8.13.8/8.13.8/Submit) with ESMTP id mBB7BPf7019071 for ; Thu, 11 Dec 2008 08:11:25 +0100 (CET) (envelope-from trond@fagskolen.gjovik.no) X-Authentication-Warning: ramstind.fig.ol.no: trond owned process doing -bs Date: Thu, 11 Dec 2008 08:11:20 +0100 (CET) From: =?ISO-8859-1?Q?Trond_Endrest=F8l?= Sender: Trond.Endrestol@fagskolen.gjovik.no To: freebsd-hackers@freebsd.org In-Reply-To: <87vdtr9q8a.fsf@kobe.laptop> Message-ID: <20081211080955.T60586@ramstind.fig.ol.no> References: <87vdtr9q8a.fsf@kobe.laptop> Organization: =?ISO-8859-1?Q?Fagskolen_i_Gj=F8vik?= OpenPGP: url=http://fagskolen.gjovik.no/~trond/trond.key MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="0-1840817174-1228979480=:60586" X-Spam-Status: No, hits=0.0 required=5.0 tests=none autolearn=failed X-Spam-Checker-Version: SpamAssassin on ramstind.fig.ol.no Subject: Re: Small Change to chpass.c 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, 11 Dec 2008 07:11:31 -0000 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --0-1840817174-1228979480=:60586 Content-Type: TEXT/PLAIN; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Thu, 11 Dec 2008 08:32+0200, Giorgos Keramidas wrote: > On Wed, 10 Dec 2008 18:00:25 -0800, "Sheldon Givens" wrote: > > --- /usr/src/usr.bin/chpass.c 2008-12-11 01:55:27.000000000 -0800 > > +++ /usr/src/usr.bin/chpass.c 2008-12-11 01:57:09.000000000 -0800 > > @@ -80,10 +80,11 @@ > > { > > enum { NEWSH, LOADENTRY, EDITENTRY, NEWPW, NEWEXP } op; > > struct passwd lpw, *old_pw, *pw; > > - int ch, pfd, tfd; > > + int ch, pfd, tfd, itr, auth; > > const char *password; > > char *arg = NULL; > > uid_t uid; > > + int max_retries = 3; > > #ifdef YP > > struct ypclnt *ypclnt; > > const char *yp_domain = NULL, *yp_host = NULL; > > @@ -227,9 +228,16 @@ > > } > > > > if (old_pw && !master_mode) { > > - password = getpass("Password: "); I'm sure you have noticed the trailing space in the string. > > - if (strcmp(crypt(password, old_pw->pw_passwd), > > - old_pw->pw_passwd) != 0) > > + auth = 0; > > + for(itr=0;itr > + password = getpass("Password:"); The space's missing in this string. It might be better to stay consistent with the original code. > > + if(strcmp(crypt(password, old_pw->pw_passwd), > > + old_pw->pw_passwd) == 0) { > > + auth=1; > > + break; > > + } > > + } > > + if (!auth) > > baduser(); > > } else { > > password = ""; - -- - ---------------------------------------------------------------------- Trond Endrestøl | Trond.Endrestol@fagskolen.gjovik.no ACM, NAS, NUUG, SAGE, USENIX | FreeBSD 6.2-STABLE & Pine 4.64 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (FreeBSD) iD8DBQFJQL0dbYWZalUoElsRAolhAJoC4iTyrVY3xeoChg3iWRsDLpvonwCeP0yT 1kM28vaxZtNH9LGqyZzZCTA= =0+CT -----END PGP SIGNATURE----- --0-1840817174-1228979480=:60586-- From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 08:45:59 2008 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 7707C1065672 for ; Thu, 11 Dec 2008 08:45:59 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from igloo.linux.gr (igloo.linux.gr [62.1.205.36]) by mx1.freebsd.org (Postfix) with ESMTP id E1C6A8FC1A for ; Thu, 11 Dec 2008 08:45:58 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from kobe.laptop (adsl22-219.kln.forthnet.gr [77.49.149.219]) (authenticated bits=128) by igloo.linux.gr (8.14.3/8.14.3/Debian-5) with ESMTP id mBB8jiqQ021515 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 11 Dec 2008 10:45:49 +0200 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.3/8.14.3) with ESMTP id mBB8jhrs004380; Thu, 11 Dec 2008 10:45:44 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) Received: (from keramida@localhost) by kobe.laptop (8.14.3/8.14.3/Submit) id mBB8jfEB004379; Thu, 11 Dec 2008 10:45:41 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) From: Giorgos Keramidas To: Jonathan McKeown References: <493DA269.2070805@FreeBSD.org> <20081208235119.GA46608@onelab2.iet.unipi.it> <200812101331.24182.jhb@freebsd.org> <200812110837.26316.jonathan+freebsd-hackers@hst.org.za> Date: Thu, 11 Dec 2008 10:45:41 +0200 In-Reply-To: <200812110837.26316.jonathan+freebsd-hackers@hst.org.za> (Jonathan McKeown's message of "Thu, 11 Dec 2008 08:37:26 +0200") Message-ID: <87prjzw156.fsf@kobe.laptop> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-MailScanner-ID: mBB8jiqQ021515 X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-3.86, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL 0.54, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@ceid.upatras.gr X-Spam-Status: No Cc: freebsd-hackers@freebsd.org Subject: Re: Enhancing cdboot [patch for review] 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, 11 Dec 2008 08:45:59 -0000 On Thu, 11 Dec 2008 08:37:26 +0200, Jonathan McKeown wrote: > While you're enhancing cdboot anyway, can I ask how complicated it > would be to make cdboot serial-console capable? (I'm not a C > programmer, I'm a sysadmin - but I'd be prepared to try and look at > this myself if no-one else is interested). > > As it stands, the only way I've found to do a serial-console CD-based > installation is by enabling the serial console in /boot/loader.conf, > by which time you've already missed several useful points, > particularly the entry to BIOS settings (if you have a serial-capable > BIOS). cdboot runs long after the prompt for BIOS setup. I don't think we can modify cdboot to add serial console support to systems whose BIOS setup doesn't support it. From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 09:08:56 2008 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 265B11065673; Thu, 11 Dec 2008 09:08:56 +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 D381E8FC16; Thu, 11 Dec 2008 09:08:55 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1LAhXS-000GQW-BW; Thu, 11 Dec 2008 11:08:54 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: Jaakko Heinonen In-reply-to: <20081210160059.GA3495@a91-153-125-115.elisa-laajakaista.fi> References: <20081210160059.GA3495@a91-153-125-115.elisa-laajakaista.fi> Comments: In-reply-to Jaakko Heinonen message dated "Wed, 10 Dec 2008 18:00:59 +0200." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 11 Dec 2008 11:08:54 +0200 From: Danny Braniss Message-ID: Cc: Jeremy Chadwick , hackers@FreeBSD.org, stable@FreeBSD.org Subject: Re: zfs panics 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, 11 Dec 2008 09:08:56 -0000 > > Hi, > > On 2008-12-10, Danny Braniss wrote: > > from a solaris or linux client, doing a ls(1) of a nfs exported zfs file, > > for example: ls /net/zfs-server/h/.zfs/snapshot, > > panics the server. The server is running latest 7.1-prerelease. > > This has been reported as PR kern/125149. I have described the problem > in this message: > > http://lists.freebsd.org/pipermail/freebsd-fs/2008-October/005217.html > > See the PR for RELENG_7 patches. > (http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/125149) > > -- > Jaakko Hi Jaakko, did you apply the patches and it solved the problem? and, btw, which patch? To Jeremy, How about adding a line explaining that it would be prudent to 'zfs set snapdir=hidden' ..., or, of cource fix the bug :-) I will apply the patch/es and see what happens. cheers, danny From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 09:43:25 2008 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 B0EED1065678 for ; Thu, 11 Dec 2008 09:43:25 +0000 (UTC) (envelope-from vasanth.raonaik@gmail.com) Received: from rn-out-0910.google.com (rn-out-0910.google.com [64.233.170.188]) by mx1.freebsd.org (Postfix) with ESMTP id 6D9D38FC1D for ; Thu, 11 Dec 2008 09:43:25 +0000 (UTC) (envelope-from vasanth.raonaik@gmail.com) Received: by rn-out-0910.google.com with SMTP id j71so969959rne.12 for ; Thu, 11 Dec 2008 01:43:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type; bh=4J7k24jzjkKm3DswR/MwW9B0mQWkQBvlZ6QL619w4w0=; b=ZQz7zAK8y0eoc67zAxaAZ7yHTFAMgiehwsXu+Gs25MwL5ilV9kxvnlY6oQ9d/bmfAJ t/sViF5jw36FclKxq5t2aOiryXQWdroq2HCe5iGqFWaC6hM5WUjwN45LoAQuS3/H7ygK bypjSLm1dlqcnFojuqadAqdhjbv67PEbz+zzk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type; b=VGVCv5T2fuBwltaSvrKfkD7n/QgcO3B4Uj1t6EQaWmWnICBEgkN4JAa+LiO79wdonP g+pJWdb/X9xDvNb9p9RiY7zdWIsnrGNz/QKDL/2OdeHrKuFJuXLfP3GT8mGjQ35rw6wp cT6HcR56YOybgoHjq51r7/s+nas2bH9Q46QwY= Received: by 10.90.90.4 with SMTP id n4mr1374686agb.103.1228986926425; Thu, 11 Dec 2008 01:15:26 -0800 (PST) Received: by 10.90.80.16 with HTTP; Thu, 11 Dec 2008 01:15:26 -0800 (PST) Message-ID: Date: Thu, 11 Dec 2008 14:45:26 +0530 From: "vasanth raonaik" To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: NTP: leap second adjustments. 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, 11 Dec 2008 09:43:25 -0000 Hello Hackers, I am working on ntpd 4.2.0-a. I need to test whether this version of ntpd is capable of handling leap second adjustments. Could any one please let me know any details of how i can simulate the leap count adjustments. I need to verify if the system does not crash with leap second and works fine. Thanks, Vasanth From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 10:28:34 2008 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 74BC5106564A; Thu, 11 Dec 2008 10:28:34 +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 2DEBE8FC13; Thu, 11 Dec 2008 10:28:34 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1LAimW-000HTT-JN; Thu, 11 Dec 2008 12:28:32 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: Jaakko Heinonen In-reply-to: References: <20081210160059.GA3495@a91-153-125-115.elisa-laajakaista.fi> Comments: In-reply-to Danny Braniss message dated "Thu, 11 Dec 2008 11:08:54 +0200." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 11 Dec 2008 12:28:32 +0200 From: Danny Braniss Message-ID: Cc: stable@FreeBSD.org, hackers@FreeBSD.org Subject: Re: zfs panics 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, 11 Dec 2008 10:28:34 -0000 > > > > Hi, > > > > On 2008-12-10, Danny Braniss wrote: > > > from a solaris or linux client, doing a ls(1) of a nfs exported zfs file, > > > for example: ls /net/zfs-server/h/.zfs/snapshot, > > > panics the server. The server is running latest 7.1-prerelease. > > > > This has been reported as PR kern/125149. I have described the problem > > in this message: > > > > http://lists.freebsd.org/pipermail/freebsd-fs/2008-October/005217.html > > > > See the PR for RELENG_7 patches. > > (http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/125149) > > > > -- > > Jaakko > > Hi Jaakko, > did you apply the patches and it solved the problem? > and, btw, which patch? > > To Jeremy, > How about adding a line explaining that it would be > prudent to 'zfs set snapdir=hidden' ..., or, of cource > fix the bug :-) > I will apply the patch/es and see what happens. > > cheers, > danny the patch to nfs_server.c does indeed prevent the panics. danny From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 10:38:40 2008 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 BDEFC1065672 for ; Thu, 11 Dec 2008 10:38:40 +0000 (UTC) (envelope-from rodrigo@bebik.net) Received: from postfix1-g20.free.fr (postfix1-g20.free.fr [212.27.60.42]) by mx1.freebsd.org (Postfix) with ESMTP id 335F18FC08 for ; Thu, 11 Dec 2008 10:38:40 +0000 (UTC) (envelope-from rodrigo@bebik.net) Received: from smtp2-g19.free.fr (smtp2-g19.free.fr [212.27.42.28]) by postfix1-g20.free.fr (Postfix) with ESMTP id 5DB792E96D61 for ; Thu, 11 Dec 2008 11:07:20 +0100 (CET) Received: from smtp2-g19.free.fr (localhost.localdomain [127.0.0.1]) by smtp2-g19.free.fr (Postfix) with ESMTP id 91D7612B72D; Thu, 11 Dec 2008 11:07:18 +0100 (CET) Received: from hodja.bebik.net (hodja.bebik.net [82.235.223.127]) by smtp2-g19.free.fr (Postfix) with ESMTP id 56DE712B714; Thu, 11 Dec 2008 11:07:18 +0100 (CET) Received: by hodja.bebik.net (Postfix, from userid 1001) id 98D512847A; Thu, 11 Dec 2008 11:07:18 +0100 (CET) Date: Thu, 11 Dec 2008 11:07:18 +0100 From: "Rodrigo OSORIO (ros)" To: Sheldon Givens Message-ID: <20081211100718.GA15362@hodja.bebik.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.2i Cc: freebsd-hackers@freebsd.org Subject: Re: Small Change to chpass.c 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, 11 Dec 2008 10:38:40 -0000 On 10/12/08 18:00 -0800, Sheldon Givens wrote: > Hi guys, > > When I was doing some user management today I noticed that chpass, and all > the utilities that use chpass.c, only give one attempt to authenticate to > make the change. After I messed this up once or twice (and after doing 4-5 > minutes of editing only to have it lost when I typo'd the password) I wrote > this little change in to chpass.c. > > When it needs the users password, it will enter into a for loop, increasing > itr until it hits max_retries (defined at top of main() declaration). If one > of these tries is successful (password given matches) then auth is set to > '1' and we break from the loop, and update info. If, after three tries, auth > is still '0' (the user didn't supply the proper password) we call baduser() > to handle it. > > It's a pretty inconsequential change but it managed to relieve me of quite a > bit of stress :-) > > Happy Holidays, everyone! > > Sheldon Givens > > > > ---snip--- > --- /usr/src/usr.bin/chpass.c 2008-12-11 01:55:27.000000000 -0800 > +++ /usr/src/usr.bin/chpass.c 2008-12-11 01:57:09.000000000 -0800 > @@ -80,10 +80,11 @@ > { > enum { NEWSH, LOADENTRY, EDITENTRY, NEWPW, NEWEXP } op; > struct passwd lpw, *old_pw, *pw; > - int ch, pfd, tfd; > + int ch, pfd, tfd, itr, auth; > const char *password; > char *arg = NULL; > uid_t uid; > + int max_retries = 3; > #ifdef YP > struct ypclnt *ypclnt; > const char *yp_domain = NULL, *yp_host = NULL; > @@ -227,9 +228,16 @@ > } > > if (old_pw && !master_mode) { > - password = getpass("Password: "); > - if (strcmp(crypt(password, old_pw->pw_passwd), > - old_pw->pw_passwd) != 0) > + auth = 0; > + for(itr=0;itr + password = getpass("Password:"); > + if(strcmp(crypt(password, old_pw->pw_passwd), > + old_pw->pw_passwd) == 0) { > + auth=1; > + break; > + } > + } > + if (!auth) > baduser(); > } else { > password = ""; > ---snip--- > _______________________________________________ > 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" Hi, Sure, your patch solves some admins nightmares :) Bus it impacts the scripts or applications using chpass interactively, no? - Rodrigo From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 08:52:31 2008 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 B98761065670 for ; Thu, 11 Dec 2008 08:52:31 +0000 (UTC) (envelope-from jonathan@hst.org.za) Received: from hermes.hst.org.za (onix.hst.org.za [209.203.2.133]) by mx1.freebsd.org (Postfix) with ESMTP id 97FA48FC20 for ; Thu, 11 Dec 2008 08:52:29 +0000 (UTC) (envelope-from jonathan@hst.org.za) Received: from sysadmin.hst.org.za (sysadmin.int.dbn.hst.org.za [10.1.1.20]) (authenticated bits=0) by hermes.hst.org.za (8.13.8/8.13.8) with ESMTP id mBB8e6ca014971 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 11 Dec 2008 10:40:07 +0200 (SAST) (envelope-from jonathan@hst.org.za) From: Jonathan McKeown Organization: Health Systems Trust To: freebsd-hackers@freebsd.org Date: Thu, 11 Dec 2008 10:52:49 +0200 User-Agent: KMail/1.9.7 References: <493DA269.2070805@FreeBSD.org> <200812110837.26316.jonathan+freebsd-hackers@hst.org.za> <87prjzw156.fsf@kobe.laptop> In-Reply-To: <87prjzw156.fsf@kobe.laptop> X-Face: $@VrUx^RHy/}yu]jKf/<4T%/d|F+$j-Ol2"2J$q+%OK1]&/G_S9(=?utf-8?q?HkaQ*=60!=3FYOK=3FY!=27M=60C=0A=09aP=5C9nVPF8Q=7DCilHH8l=3B=7E!4?= =?utf-8?q?2HK6=273lg4J=7Daz?=@1Dqqh:J]M^"YPn*2IWrZON$1+G?oX3@ =?utf-8?q?k=230=0A=0954XDRg=3DYn=5FF-etwot4U=24b?=dTS{i X-Spam-Score: -4.399 () ALL_TRUSTED,BAYES_00 X-Scanned-By: MIMEDefang 2.61 on 209.203.2.133 X-Mailman-Approved-At: Thu, 11 Dec 2008 12:39:33 +0000 Cc: Giorgos Keramidas , Jonathan McKeown Subject: Re: Enhancing cdboot [patch for review] 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, 11 Dec 2008 08:52:31 -0000 On Thursday 11 December 2008 10:45:41 Giorgos Keramidas wrote: > On Thu, 11 Dec 2008 08:37:26 +0200, Jonathan McKeown wrote: > > While you're enhancing cdboot anyway, can I ask how complicated it > > would be to make cdboot serial-console capable? (I'm not a C > > programmer, I'm a sysadmin - but I'd be prepared to try and look at > > this myself if no-one else is interested). > > > > As it stands, the only way I've found to do a serial-console CD-based > > installation is by enabling the serial console in /boot/loader.conf, > > by which time you've already missed several useful points, > > particularly the entry to BIOS settings (if you have a serial-capable > > BIOS). > > cdboot runs long after the prompt for BIOS setup. I don't think we can > modify cdboot to add serial console support to systems whose BIOS setup > doesn't support it. Sorry, of course you're right: I'm talking nonsense. It's the stage immediately after that that isn't available. I wish I could remember why I thought that had caused me a problem once. Certainly there's a big chunk of the boot process that is accessible through a serial console on a disk-based boot that's not available on a serial-console boot. From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 12:43:04 2008 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 8ABE41065670 for ; Thu, 11 Dec 2008 12:43:04 +0000 (UTC) (envelope-from keramida@freebsd.org) Received: from igloo.linux.gr (igloo.linux.gr [62.1.205.36]) by mx1.freebsd.org (Postfix) with ESMTP id F3C688FC0C for ; Thu, 11 Dec 2008 12:43:03 +0000 (UTC) (envelope-from keramida@freebsd.org) Received: from kobe.laptop (adsl22-219.kln.forthnet.gr [77.49.149.219]) (authenticated bits=128) by igloo.linux.gr (8.14.3/8.14.3/Debian-5) with ESMTP id mBBCgn5W001974 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 11 Dec 2008 14:42:55 +0200 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.3/8.14.3) with ESMTP id mBBCgnwN006407; Thu, 11 Dec 2008 14:42:49 +0200 (EET) (envelope-from keramida@freebsd.org) Received: (from keramida@localhost) by kobe.laptop (8.14.3/8.14.3/Submit) id mBBCglqQ006406; Thu, 11 Dec 2008 14:42:47 +0200 (EET) (envelope-from keramida@freebsd.org) From: Giorgos Keramidas To: Jonathan McKeown References: <493DA269.2070805@FreeBSD.org> <200812110837.26316.jonathan+freebsd-hackers@hst.org.za> <87prjzw156.fsf@kobe.laptop> <200812111052.50082.jonathan@hst.org.za> Date: Thu, 11 Dec 2008 14:42:46 +0200 In-Reply-To: <200812111052.50082.jonathan@hst.org.za> (Jonathan McKeown's message of "Thu, 11 Dec 2008 10:52:49 +0200") Message-ID: <87r64eopbt.fsf@kobe.laptop> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-MailScanner-ID: mBBCgn5W001974 X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-4.297, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL 0.10, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@freebsd.org X-Spam-Status: No Cc: freebsd-hackers@freebsd.org, Jonathan McKeown Subject: Re: Enhancing cdboot [patch for review] 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, 11 Dec 2008 12:43:04 -0000 On Thu, 11 Dec 2008 10:52:49 +0200, Jonathan McKeown wrote: >> cdboot runs long after the prompt for BIOS setup. I don't think we >> can modify cdboot to add serial console support to systems whose BIOS >> setup doesn't support it. > > Sorry, of course you're right: I'm talking nonsense. > > It's the stage immediately after that that isn't available. I wish I > could remember why I thought that had caused me a problem once. > > Certainly there's a big chunk of the boot process that is accessible > through a serial console on a disk-based boot that's not available on > a serial-console boot. I'm still not sure what sort of `serial console boot' we are talking about here. What's the difference between a `serial console on a disk-based boot' and a `serial console boot'? From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 13:08:53 2008 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 7CC24106564A for ; Thu, 11 Dec 2008 13:08:53 +0000 (UTC) (envelope-from jonathan+freebsd-hackers@hst.org.za) Received: from hermes.hst.org.za (onix.hst.org.za [209.203.2.133]) by mx1.freebsd.org (Postfix) with ESMTP id 8B2848FC1D for ; Thu, 11 Dec 2008 13:08:52 +0000 (UTC) (envelope-from jonathan+freebsd-hackers@hst.org.za) Received: from sysadmin.hst.org.za (sysadmin.int.dbn.hst.org.za [10.1.1.20]) (authenticated bits=0) by hermes.hst.org.za (8.13.8/8.13.8) with ESMTP id mBBCuYOF021255 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 11 Dec 2008 14:56:35 +0200 (SAST) (envelope-from jonathan+freebsd-hackers@hst.org.za) From: Jonathan McKeown Organization: Health Systems Trust To: freebsd-hackers@freebsd.org Date: Thu, 11 Dec 2008 15:09:18 +0200 User-Agent: KMail/1.9.7 References: <493DA269.2070805@FreeBSD.org> <200812111052.50082.jonathan@hst.org.za> <87r64eopbt.fsf@kobe.laptop> In-Reply-To: <87r64eopbt.fsf@kobe.laptop> X-Face: $@VrUx^RHy/}yu]jKf/<4T%/d|F+$j-Ol2"2J$q+%OK1]&/G_S9(=?utf-8?q?HkaQ*=60!=3FYOK=3FY!=27M=60C=0A=09aP=5C9nVPF8Q=7DCilHH8l=3B=7E!4?= =?utf-8?q?2HK6=273lg4J=7Daz?=@1Dqqh:J]M^"YPn*2IWrZON$1+G?oX3@ =?utf-8?q?k=230=0A=0954XDRg=3DYn=5FF-etwot4U=24b?=dTS{i X-Spam-Score: -4.399 () ALL_TRUSTED,BAYES_00 X-Scanned-By: MIMEDefang 2.61 on 209.203.2.133 Cc: Giorgos Keramidas , Jonathan McKeown Subject: Re: Enhancing cdboot [patch for review] 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, 11 Dec 2008 13:08:53 -0000 On Thursday 11 December 2008 14:42:46 Giorgos Keramidas wrote: > On Thu, 11 Dec 2008 10:52:49 +0200, Jonathan McKeown wrote: > >> cdboot runs long after the prompt for BIOS setup. I don't think we > >> can modify cdboot to add serial console support to systems whose BIOS > >> setup doesn't support it. > > > > Sorry, of course you're right: I'm talking nonsense. > > > > It's the stage immediately after that that isn't available. I wish I > > could remember why I thought that had caused me a problem once. > > > > Certainly there's a big chunk of the boot process that is accessible > > through a serial console on a disk-based boot that's not available on > > a serial-console boot. > > I'm still not sure what sort of `serial console boot' we are talking > about here. What's the difference between a `serial console on a > disk-based boot' and a `serial console boot'? Sorry, there's been an element of ``ready - fire - aim'' about my messages today - I'm trying to do several other things at once. Let me get a serial-boot CD out and play with it - it's a while since I did a headless install so I'm working from a vague memory. I think what I'm saying is that there are several stages in the boot process; when booting from a hard drive and using a serial console, all the stages are accessible: but when booting from a CD, only the last stage is. I seem to remember that causing me a problem with a headless machine once upon a time (perhaps there was an error at an early stage, with the first hard drive failing, and I couldn't see loader(8) to tell it to boot off the second drive which was a mirror of the first?). Certainly I've taken part in a couple of discussions in -questions over the last year or two in which people want to know how to make a serial-capable install CD - which is not as straightforward as it might be if there were a serial-capable cdboot (along the same lines as putting boot0sio instead of boot0 on a hard drive). Jonathan From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 13:15:35 2008 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 0DE24106564A for ; Thu, 11 Dec 2008 13:15:35 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from igloo.linux.gr (igloo.linux.gr [62.1.205.36]) by mx1.freebsd.org (Postfix) with ESMTP id 5BCAF8FC14 for ; Thu, 11 Dec 2008 13:15:33 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from kobe.laptop (adsl22-219.kln.forthnet.gr [77.49.149.219]) (authenticated bits=128) by igloo.linux.gr (8.14.3/8.14.3/Debian-5) with ESMTP id mBBDFEZp004259 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 11 Dec 2008 15:15:20 +0200 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.3/8.14.3) with ESMTP id mBBDFE6Q006679; Thu, 11 Dec 2008 15:15:14 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) Received: (from keramida@localhost) by kobe.laptop (8.14.3/8.14.3/Submit) id mBBDFDCX006678; Thu, 11 Dec 2008 15:15:13 +0200 (EET) (envelope-from keramida@ceid.upatras.gr) From: Giorgos Keramidas To: Trond =?iso-8859-1?Q?Endrest=F8l?= References: <87vdtr9q8a.fsf@kobe.laptop> <20081211080955.T60586@ramstind.fig.ol.no> Date: Thu, 11 Dec 2008 15:15:13 +0200 In-Reply-To: <20081211080955.T60586@ramstind.fig.ol.no> ("Trond =?iso-8859-1?Q?Endrest=F8l=22's?= message of "Thu, 11 Dec 2008 08:11:20 +0100 (CET)") Message-ID: <87zlj2kg4e.fsf@kobe.laptop> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-MailScanner-ID: mBBDFEZp004259 X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-3.859, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL 0.54, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@ceid.upatras.gr X-Spam-Status: No Cc: freebsd-hackers@freebsd.org Subject: Re: Small Change to chpass.c 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, 11 Dec 2008 13:15:35 -0000 On Thu, 11 Dec 2008 08:11:20 +0100 (CET), Trond Endrest=F8l wrote: >On Thu, 11 Dec 2008 08:32+0200, Giorgos Keramidas wrote: >> On Wed, 10 Dec 2008 18:00:25 -0800, "Sheldon Givens" wrote: >> > --- /usr/src/usr.bin/chpass.c 2008-12-11 01:55:27.000000000 -0800 >> > +++ /usr/src/usr.bin/chpass.c 2008-12-11 01:57:09.000000000 -0800 >> > @@ -80,10 +80,11 @@ >> > { >> > enum { NEWSH, LOADENTRY, EDITENTRY, NEWPW, NEWEXP } op; >> > struct passwd lpw, *old_pw, *pw; >> > - int ch, pfd, tfd; >> > + int ch, pfd, tfd, itr, auth; >> > const char *password; >> > char *arg =3D NULL; >> > uid_t uid; >> > + int max_retries =3D 3; >> > #ifdef YP >> > struct ypclnt *ypclnt; >> > const char *yp_domain =3D NULL, *yp_host =3D NULL; >> > @@ -227,9 +228,16 @@ >> > } >> > >> > if (old_pw && !master_mode) { >> > - password =3D getpass("Password: "); > > I'm sure you have noticed the trailing space in the string. > >> > - if (strcmp(crypt(password, old_pw->pw_passwd), >> > - old_pw->pw_passwd) !=3D 0) >> > + auth =3D 0; >> > + for(itr=3D0;itr> > + password =3D getpass("Password:"); > > The space's missing in this string. It might be better to stay > consistent with the original code. Good catch. No, I didn't notice the missing space the first time I read the diff :/ From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 16:40:55 2008 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 4623C1065673; Thu, 11 Dec 2008 16:40:55 +0000 (UTC) (envelope-from bms@FreeBSD.org) Received: from out1.smtp.messagingengine.com (out1.smtp.messagingengine.com [66.111.4.25]) by mx1.freebsd.org (Postfix) with ESMTP id 1BC398FC13; Thu, 11 Dec 2008 16:40:55 +0000 (UTC) (envelope-from bms@FreeBSD.org) Received: from compute1.internal (compute1.internal [10.202.2.41]) by out1.messagingengine.com (Postfix) with ESMTP id CA6821E7402; Thu, 11 Dec 2008 11:21:22 -0500 (EST) Received: from heartbeat2.messagingengine.com ([10.202.2.161]) by compute1.internal (MEProxy); Thu, 11 Dec 2008 11:21:22 -0500 X-Sasl-enc: yuuKBzYYFkRcpyqDX5dn75ylnXe1413rVhJ71WO1+6x0 1229012482 Received: from empiric.lon.incunabulum.net (82-35-112-254.cable.ubr07.dals.blueyonder.co.uk [82.35.112.254]) by mail.messagingengine.com (Postfix) with ESMTPSA id E33C841737; Thu, 11 Dec 2008 11:21:21 -0500 (EST) Message-ID: <49413DFF.9030004@FreeBSD.org> Date: Thu, 11 Dec 2008 16:21:19 +0000 From: "Bruce M. Simpson" User-Agent: Thunderbird 2.0.0.18 (X11/20081205) MIME-Version: 1.0 To: Maxim Sobolev References: <493DA269.2070805@FreeBSD.org> In-Reply-To: <493DA269.2070805@FreeBSD.org> X-Enigmail-Version: 0.95.6 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Luigi Rizzo , hackers@FreeBSD.org, "current@freebsd.org" Subject: Re: Enhancing cdboot [patch for review] 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, 11 Dec 2008 16:40:55 -0000 This sounds and looks cool, diff looks OK (haven't applied), Luigi's comments seem well thought out and expressed. cheers BMS From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 17:13:04 2008 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 70C9B1065675 for ; Thu, 11 Dec 2008 17:13:04 +0000 (UTC) (envelope-from danm@prime.gushi.org) Received: from prime.gushi.org (prime.gushi.org [72.9.101.130]) by mx1.freebsd.org (Postfix) with ESMTP id 7EBA98FC1C for ; Thu, 11 Dec 2008 17:13:02 +0000 (UTC) (envelope-from danm@prime.gushi.org) Received: from prime.gushi.org (localhost [127.0.0.1]) by prime.gushi.org (8.14.1/8.14.1) with ESMTP id mBBH0FDl037934 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 11 Dec 2008 12:00:16 -0500 (EST) (envelope-from danm@prime.gushi.org) X-DKIM: Sendmail DKIM Filter v2.7.2 prime.gushi.org mBBH0FDl037934 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=prime.gushi.org; s=primegushiorg; t=1228998284; bh=xYH6DaBpgIpo9O4ME5Wi4y2nvMJbRKcOY 4KuzhY4yWc=; h=Date:From:To:cc:Message-ID:MIME-Version:Content-Type; b=Y5Pid17yMOSwUQ73u+uJwLJx0gP9kIWRwl6PZXe4FB/ZAoVcHCoRH77lYbzT1URK2 norDlnGB1JXnOkwZ31MTg== X-DomainKeys: Sendmail DomainKeys Filter v1.0.0 prime.gushi.org mBBH0FDl037934 DomainKey-Signature: a=rsa-sha1; s=primegushiorg; d=prime.gushi.org; c=nofws; q=dns; h=received:date:from:to:cc:message-id:user-agent: x-openpgp-key-id:mime-version:content-type; b=MVJf0x2Xj9Zwc2RXwN0e2j16Oqe7sNAvxz/GEBFGiJJvJa75h2ZM95M5vBsRVhMsM fnhLcxwSzXurVuIJlHb1g== Received: (from danm@localhost) by prime.gushi.org (8.14.1/8.14.1/Submit) id mBBH04xx037883; Thu, 11 Dec 2008 12:00:04 -0500 (EST) (envelope-from danm) Date: Thu, 11 Dec 2008 12:00:04 -0500 (EST) From: "Dan Mahoney, System Admin" To: questions@freebsd.org Message-ID: User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) X-OpenPGP-Key-ID: 0x624BB249 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; format=flowed; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (prime.gushi.org [127.0.0.1]); Thu, 11 Dec 2008 12:24:44 +0000 (UTC) X-Mailman-Approved-At: Thu, 11 Dec 2008 17:20:30 +0000 Cc: hackers@freebsd.org Subject: (no subject) 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, 11 Dec 2008 17:13:04 -0000 Okay, new problem with regard to netgroups, NIS, and Pam: Given the following situation: * I want to be able to have su work normally in the event of an NIS disconnect, since I will likely need to su to fix said disconnect. * The wheel group needs to stay local * I want su to still use group ownership as a check I recently could not get an admin account (defined in NIS) to su to root. Even though "groups username" showed he was in wheel (and the wheel group has been propagated into NIS), pam_group and pw groupshow show him as not.) This is probably because the local wheel group overrode the NIS wheel group. (I'm not that thrilled by having the wheel group in NIS anyway). Since pam_group is "requisite", there's no easy way to call it multiple times, and no easy pam syntax to say "one of these two must pass". Required won't help, Otherwise I'd simply define an extra group, call it NISwheel or something, and configure access accordingly. What I instead would propose is for pam_group to take an optional argument list instead of a single group (or possibly, multiple group= requirements). Doing something with pam_exec is an option here as well, but I feel this functionality should be fairly elementary to add, moving forward. -Dan -- "You're a daddy. I'm a mommy. She's our baby. Deal with it." -Cali, 11/7/02, about 1:35 AM --------Dan Mahoney-------- Techie, Sysadmin, WebGeek Gushi on efnet/undernet IRC ICQ: 13735144 AIM: LarpGM Site: http://www.gushi.org --------------------------- From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 20:39:54 2008 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 4E1DD106564A for ; Thu, 11 Dec 2008 20:39:54 +0000 (UTC) (envelope-from yanefbsd@gmail.com) Received: from rv-out-0506.google.com (rv-out-0506.google.com [209.85.198.228]) by mx1.freebsd.org (Postfix) with ESMTP id 1FD5B8FC1F for ; Thu, 11 Dec 2008 20:39:54 +0000 (UTC) (envelope-from yanefbsd@gmail.com) Received: by rv-out-0506.google.com with SMTP id b25so1025911rvf.43 for ; Thu, 11 Dec 2008 12:39:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=kF95ohR+ivH8gzksLARBPZtn4BNBSYwWwMWjcpvLvkY=; b=MUlXpqRSeYEaer9w5WKeUShFSw5/5Vvwz1yvR7jc6yJzTjID0jmag8QrNfFtakYpFL mshAV4rj2eh90Y6P5w1S+nFooAzmEnWBYiyhleQvOOo7gCZaPESJdcrbN40PmHy1rOmX 8zkB6dn6g3YkMMvBlaTEa+hwyggB+d7O23Z1M= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=Z5t/LPgJq6gizJuPRur4t5+Wb5DvbZTV0o1OgvdXTCfYj0Y1A/FE1deQw3zS7tm1b8 CQvsEuy2PbrFBrPwvz4wjNs7YiMADmkvvAjzhQlWhxEYfS0ZhzZobJujlOYUaB40r4D2 XHT4HYGhQD8iK9Hv5TVdypNuHiVpoZthSO1S4= Received: by 10.141.29.16 with SMTP id g16mr1451514rvj.287.1229027993870; Thu, 11 Dec 2008 12:39:53 -0800 (PST) Received: by 10.140.158.13 with HTTP; Thu, 11 Dec 2008 12:39:53 -0800 (PST) Message-ID: <7d6fde3d0812111239i7a47037mf9b5e4e5386b540@mail.gmail.com> Date: Thu, 11 Dec 2008 12:39:53 -0800 From: "Garrett Cooper" To: "Giorgos Keramidas" In-Reply-To: <87zlj2kg4e.fsf@kobe.laptop> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <87vdtr9q8a.fsf@kobe.laptop> <20081211080955.T60586@ramstind.fig.ol.no> <87zlj2kg4e.fsf@kobe.laptop> Cc: freebsd-hackers@freebsd.org, =?ISO-8859-1?Q?Trond_Endrest=F8l?= Subject: Re: Small Change to chpass.c 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, 11 Dec 2008 20:39:54 -0000 On Thu, Dec 11, 2008 at 5:15 AM, Giorgos Keramidas wrote: > On Thu, 11 Dec 2008 08:11:20 +0100 (CET), Trond Endrest=F8l wrote: >>On Thu, 11 Dec 2008 08:32+0200, Giorgos Keramidas wrote: >>> On Wed, 10 Dec 2008 18:00:25 -0800, "Sheldon Givens" wrote: >>> > --- /usr/src/usr.bin/chpass.c 2008-12-11 01:55:27.000000000 -0800 >>> > +++ /usr/src/usr.bin/chpass.c 2008-12-11 01:57:09.000000000 -0800 >>> > @@ -80,10 +80,11 @@ >>> > { >>> > enum { NEWSH, LOADENTRY, EDITENTRY, NEWPW, NEWEXP } op; >>> > struct passwd lpw, *old_pw, *pw; >>> > - int ch, pfd, tfd; >>> > + int ch, pfd, tfd, itr, auth; >>> > const char *password; >>> > char *arg =3D NULL; >>> > uid_t uid; >>> > + int max_retries =3D 3; >>> > #ifdef YP >>> > struct ypclnt *ypclnt; >>> > const char *yp_domain =3D NULL, *yp_host =3D NULL; >>> > @@ -227,9 +228,16 @@ >>> > } >>> > >>> > if (old_pw && !master_mode) { >>> > - password =3D getpass("Password: "); >> >> I'm sure you have noticed the trailing space in the string. >> >>> > - if (strcmp(crypt(password, old_pw->pw_passwd), >>> > - old_pw->pw_passwd) !=3D 0) >>> > + auth =3D 0; >>> > + for(itr=3D0;itr>> > + password =3D getpass("Password:"); >> >> The space's missing in this string. It might be better to stay >> consistent with the original code. > > Good catch. No, I didn't notice the missing space the first time I read > the diff :/ A better way to solve this may be to add an option to set the number of retries before failure and then just pass it through to this function. -Garrett From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 11 22:53:50 2008 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 36BF71065675; Thu, 11 Dec 2008 22:53:50 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (adsl-63-193-123-122.dsl.snfc21.pacbell.net [63.193.123.122]) by mx1.freebsd.org (Postfix) with ESMTP id C9EB68FC24; Thu, 11 Dec 2008 22:53:49 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (localhost [127.0.0.1]) by albert.catwhisker.org (8.14.3/8.14.3) with ESMTP id mBBMrnth005935; Thu, 11 Dec 2008 14:53:49 -0800 (PST) (envelope-from david@albert.catwhisker.org) Received: (from david@localhost) by albert.catwhisker.org (8.14.3/8.14.3/Submit) id mBBMrn8J005934; Thu, 11 Dec 2008 14:53:49 -0800 (PST) (envelope-from david) Date: Thu, 11 Dec 2008 14:53:49 -0800 From: David Wolfskill To: Kostik Belousov Message-ID: <20081211225349.GB5597@albert.catwhisker.org> Mail-Followup-To: David Wolfskill , Kostik Belousov , hackers@freebsd.org, current@freebsd.org References: <20081203001538.GC96383@bunrab.catwhisker.org> <20081209190110.GW60731@albert.catwhisker.org> <20081210165022.GJ60731@albert.catwhisker.org> <20081210170620.GS2038@deviant.kiev.zoral.com.ua> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="O5XBE6gyVG5Rl6Rj" Content-Disposition: inline In-Reply-To: <20081210170620.GS2038@deviant.kiev.zoral.com.ua> User-Agent: Mutt/1.4.2.3i Cc: hackers@freebsd.org, current@freebsd.org Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 11 Dec 2008 22:53:50 -0000 --O5XBE6gyVG5Rl6Rj Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Dec 10, 2008 at 07:06:20PM +0200, Kostik Belousov wrote: > ... > > What concerns me is that even if the attempted unmount gets EBUSY, the > > user-level process descending the directory hierarchy is getting ENOENT > > trying to issue fstatfs() against an open file descriptor. > >=20 > > I'm having trouble figuring out any way that makes any sense. >=20 > Basically, the problem is that NFS uses shared lookup, and this allows > for the bug where several negative namecache entries are created for > non-existent node. Then this node gets created, removing only the first > negative namecache entry. For some reasons, vnode is reclaimed; amd' > tasting of unmount is a good reason for vnode to be reclaimed. >=20 > Now, you have existing path and a negative cache entry. This was > reported by Peter Holm first, I listed relevant revisions that > should fix this in previous mail. Well, I messed up the machine I had been using for testing, and needed to wait for IT to do something to it since I don't have physical or console access to it. So after I happened to demonstrate the effect using my desktop -- which had been running RELENG_7_1, sources updated as of around 0400 hrs. US/Pacific -- I decided to go ahead and update the desktop to RELENG_7_1 as of this morning (which had the commit to sys/kern/vfs_cache.c), then test. It still failed, apparently in the same way; details below. First, here's a list of the files that were changed: U lib/libarchive/archive_read_support_format_iso9660.c U lib/libarchive/archive_string.c U lib/libarchive/archive_string.h U lib/libc/gen/times.3 U lib/libc/i386/sys/pipe.S U lib/libc/i386/sys/reboot.S U lib/libc/i386/sys/setlogin.S U lib/libutil/Makefile U lib/libutil/kinfo_getfile.c U lib/libutil/kinfo_getvmmap.c U lib/libutil/libutil.h U share/man/man4/bce.4 U share/man/man5/Makefile U share/man/man5/fstab.5 U share/man/man5/nullfs.5 U sys/amd64/Makefile U sys/boot/forth/loader.conf.5 U sys/dev/ale/if_ale.c U sys/dev/bce/if_bce.c U sys/dev/cxgb/cxgb_main.c U sys/dev/cxgb/common/cxgb_ael1002.c U sys/dev/cxgb/common/cxgb_t3_hw.c U sys/dev/cxgb/common/cxgb_xgmac.c U sys/dev/re/if_re.c U sys/fs/nullfs/null_vnops.c U sys/kern/Make.tags.inc U sys/kern/kern_descrip.c U sys/kern/kern_proc.c U sys/kern/vfs_cache.c U sys/netinet/in_pcb.h U sys/pci/if_rlreg.h U sys/sys/sysctl.h U sys/sys/user.h U sys/ufs/ufs/ufs_quota.c U usr.bin/procstat/Makefile U usr.bin/procstat/procstat_files.c U usr.bin/procstat/procstat_vm.c U usr.bin/tar/util.c U usr.bin/tar/test/Makefile U usr.bin/tar/test/test_strip_components.c U usr.bin/tar/test/test_symlink_dir.c U usr.bin/xargs/xargs.1 U usr.sbin/mtree/mtree.c We see that sys/kern/vfs_cache.c is, indeed, among them. And: dwolf-bsd(7.1-P)[5] grep '\$FreeBSD' /sys/kern/vfs_cache.c __FBSDID("$FreeBSD: src/sys/kern/vfs_cache.c,v 1.114.2.3 2008/12/09 16:20:5= 8 kib Exp $"); dwolf-bsd(7.1-P)[6]=20 That should correspond to the desired version of the file. Here we see an excerpt from the ktrace output for the amd(8) process and its children; this is a point when amd(8) is trying an unmount() to see if it can get away with it: 977 amd 1229033597.269612 CALL gettimeofday(0x807ad48,0) 977 amd 1229033597.269620 RET gettimeofday 0 977 amd 1229033597.269630 CALL sigprocmask(SIG_BLOCK,0xbfbfeaec,0x= bfbfeadc) 977 amd 1229033597.269637 RET sigprocmask 0 977 amd 1229033597.269645 CALL fork 977 amd 1229033597.273810 RET fork 1712/0x6b0 1712 amd 1229033597.273811 RET fork 0 977 amd 1229033597.273836 CALL sigprocmask(SIG_SETMASK,0xbfbfeadc,= 0) 1712 amd 1229033597.273845 CALL getpid 977 amd 1229033597.273850 RET sigprocmask 0 1712 amd 1229033597.273855 RET getpid 1712/0x6b0 977 amd 1229033597.273864 CALL gettimeofday(0x807ad48,0) 977 amd 1229033597.273874 RET gettimeofday 0 1712 amd 1229033597.273878 CALL unmount(0x2832c610,0) =2E.. 1712 amd 1229033597.352643 RET unmount -1 errno 16 Device busy 1712 amd 1229033597.352695 CALL sigprocmask(SIG_BLOCK,0x28097c00,0x= bfbfea0c) 1712 amd 1229033597.352728 RET sigprocmask 0 1712 amd 1229033597.352751 CALL sigprocmask(SIG_SETMASK,0x28097c10,= 0) 1712 amd 1229033597.352769 RET sigprocmask 0 1712 amd 1229033597.352781 CALL sigprocmask(SIG_BLOCK,0x28097c00,0x= bfbfe9dc) 1712 amd 1229033597.352790 RET sigprocmask 0 1712 amd 1229033597.352801 CALL sigprocmask(SIG_SETMASK,0x28097c10,= 0) 1712 amd 1229033597.352805 RET sigprocmask 0 1712 amd 1229033597.352815 CALL exit(0x10) 977 amd 1229033597.353085 RET select -1 errno 4 Interrupted syste= m call 977 amd 1229033597.353093 PSIG SIGCHLD caught handler=3D0x805de50 = mask=3D0x0 code=3D0x0 977 amd 1229033597.353103 CALL wait4(0xffffffff,0xbfbfe83c,WNOHANG= ,0) 977 amd 1229033597.353116 RET wait4 1712/0x6b0 977 amd 1229033597.353122 CALL wait4(0xffffffff,0xbfbfe83c,WNOHANG= ,0) 977 amd 1229033597.353127 RET wait4 -1 errno 10 No child processes So amd(8) master process (pid 977) jorks off a child (pid 1712) to try an umount(), which it initiates at 1229033597.273878. At 1229033597.352643 the child gets control back, as well as an EBUSY, which I would expect to mean that the attempt failed. The child exits at 1229033597.352815 with a status code of 16. Armed with that, we look at a ktrace excerpt from "rm -fr": 1660 rm 1229033597.283277 CALL rmdir(0x2822b388) 1660 rm 1229033597.283283 NAMI "stvef-paks" 1660 rm 1229033597.285599 RET rmdir 0 1660 rm 1229033597.285620 CALL stat(0x2822b3e8,0xbfbfe8dc) 1660 rm 1229033597.285626 NAMI "stvef-server" 1660 rm 1229033597.286071 STRU struct stat {dev=3D83951372, ino=3D= 20124614, mode=3Ddrwxr-xr-x , nlink=3D3, uid=3D9874, gid=3D929, rdev=3D0, a= time=3D1228844788, stime=3D1227555769, ctime=3D1228845828.326650000, birtht= ime=3D0, size=3D4096, blksize=3D4096, blocks=3D8, flags=3D0x0 } 1660 rm 1229033597.286078 RET stat 0 1660 rm 1229033597.286084 CALL open(0x2822b3e8,O_NONBLOCK,= 0x1) 1660 rm 1229033597.286091 NAMI "stvef-server" 1660 rm 1229033597.287145 RET open 4 1660 rm 1229033597.287154 CALL fstat(0x4,0xbfbfe8dc) 1660 rm 1229033597.287161 STRU struct stat {dev=3D83951372, ino=3D= 20124614, mode=3Ddrwxr-xr-x , nlink=3D3, uid=3D9874, gid=3D929, rdev=3D0, a= time=3D1228844788, stime=3D1227555769, ctime=3D1228845828.326650000, birtht= ime=3D0, size=3D4096, blksize=3D4096, blocks=3D8, flags=3D0x0 } 1660 rm 1229033597.287166 RET fstat 0 1660 rm 1229033597.287171 CALL fcntl(0x4,F_SETFD,FD_CLOEXEC) 1660 rm 1229033597.287177 RET fcntl 0 1660 rm 1229033597.287187 CALL fstatfs(0x4,0xbfbfe704) 1660 rm 1229033597.287195 RET fstatfs -1 errno 2 No such file or = directory 1660 rm 1229033597.287202 CALL close(0x4) 1660 rm 1229033597.287211 RET close 0 [Sorry for the long lines....] Here we see that the "rm" process (pid 1660) removed a directory named stvef-paks sucessfully in the interval between 1229033597.283277 (when the request was made) and 1229033597.285599 (when the 0 return occurred). The "rm" process proceeds to process a directory named stvef-server: * At 1229033597.285620 it issues a stat(); the successful return is at 1229033597.286078. * At 1229033597.286084 it issues an open(); the successful return is at 1229033597.287145. The FD is 4. * At 1229033597.287154 it issues an fstat() against FD 4; the successful return is at 1229033597.287166. * At 1229033597.287171 it issues an fcntl() against FD 4; the successful return is at 1229033597.287177. * At 1229033597.287187 it issues an fstatfs() against FD 4; the unsuccessful return is at 1229033597.287195, claiming ENOENT. Say WHAT??!? I expect to be able to test a bit more promptly now. 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. --O5XBE6gyVG5Rl6Rj Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (FreeBSD) iEYEARECAAYFAklBmfwACgkQmprOCmdXAD1AEgCfdbAL8t/OB2S5QMtS2Yybo7rQ kqwAniaONokHwedGnl6LnGMCEfZjbwFc =8hTW -----END PGP SIGNATURE----- --O5XBE6gyVG5Rl6Rj-- From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 11:17:32 2008 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 3295C1065672 for ; Fri, 12 Dec 2008 11:17:32 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 5A9D48FC14 for ; Fri, 12 Dec 2008 11:17:31 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id NAA29825; Fri, 12 Dec 2008 13:17:19 +0200 (EET) (envelope-from avg@icyb.net.ua) Message-ID: <4942483D.8000003@icyb.net.ua> Date: Fri, 12 Dec 2008 13:17:17 +0200 From: Andriy Gapon User-Agent: Thunderbird 2.0.0.18 (X11/20081124) MIME-Version: 1.0 To: Peter Jeremy References: <4909DC03.1080901@icyb.net.ua> <20081030184625.GA99398@server.vk2pj.dyndns.org> <490B05BA.9090306@icyb.net.ua> In-Reply-To: <490B05BA.9090306@icyb.net.ua> Content-Type: text/plain; charset=KOI8-U Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: memtest86+ can not link: binutils issue? 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, 12 Dec 2008 11:17:32 -0000 on 31/10/2008 15:18 Andriy Gapon said the following: >>> ld --warn-constructors --warn-common -static -T memtest_shared.lds \ >>> -o memtest_shared head.o reloc.o main.o test.o init.o lib.o >>> patn.o screen_buffer.o config.o linuxbios.o memsize.o pci.o controller.o >>> random.o extra.o spd.o error.o dmi.o && \ >>> ld -shared -Bsymbolic -T memtest_shared.lds -o memtest_shared >>> head.o reloc.o main.o test.o init.o lib.o patn.o screen_buffer.o >>> config.o linuxbios.o memsize.o pci.o controller.o random.o extra.o spd.o >>> error.o dmi.o >>> head.o(.text+0x7): In function `startup_32': >>> : undefined reference to `_GLOBAL_OFFSET_TABLE_' >>> Segmentation fault (core dumped) Just in case anybody still remembers this issue. It seams that the main culprit here was the following line in the linker script: OUTPUT_FORMAT("elf32-i386"); I was tipped just today that it should have read: OUTPUT_FORMAT("elf32-i386-freebsd", "elf32-i386-freebsd", "elf32-i386-freebsd"); -- Andriy Gapon From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 11:45:47 2008 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 46F1E1065670 for ; Fri, 12 Dec 2008 11:45:47 +0000 (UTC) (envelope-from artis.caune@gmail.com) Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.244]) by mx1.freebsd.org (Postfix) with ESMTP id 014638FC13 for ; Fri, 12 Dec 2008 11:45:46 +0000 (UTC) (envelope-from artis.caune@gmail.com) Received: by an-out-0708.google.com with SMTP id c2so491994anc.13 for ; Fri, 12 Dec 2008 03:45:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type:content-transfer-encoding :content-disposition; bh=Y1gu3N9IAltWT8Nr6zxPQT8RRqN9y56+1yaoBmSFGhY=; b=kGjNDXbDdj43fRktD1b4PwTcS+P1MNZAq1DB5Lr8L4rUNUranf+58DBrJCYzk27n+m NE+7rK0t/ya8Z+ZkQW64hu85tXkJQMBiizWsoI04bb2TuE3rLNRQJbUrqU9RvKgQMpjv I5KbPtkCT4bdLl+w950vB3HF20G3OOsCwxQvk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type :content-transfer-encoding:content-disposition; b=B7JjxAtDBec3jf0/vqFFoJ5YwiJmtdWaAZW8M52tSv5efk7lDBhUSz7O0B7qlV2lpk dQTzrjxCADyC5vdJKI/RisU0oO1eA8JjCBuevgLIOrlggKltDAxIhfGpaq9tV1/aCVAt umRx9NHxeETNE/XUoLbfFt8swRlS6G1o6Y/K4= Received: by 10.100.166.10 with SMTP id o10mr2760627ane.126.1229080517559; Fri, 12 Dec 2008 03:15:17 -0800 (PST) Received: by 10.100.112.8 with HTTP; Fri, 12 Dec 2008 03:15:17 -0800 (PST) Message-ID: <9e20d71e0812120315l30d72b2doc899a8163fde829f@mail.gmail.com> Date: Fri, 12 Dec 2008 13:15:17 +0200 From: "Artis Caune" To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline Subject: Strange "changed paths" in svn commits 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, 12 Dec 2008 11:45:47 -0000 Hi, Is it how merging works or I'm missing something? Why /stable/7/sys and /stable/7/sys/contrib/pf are in changed paths in commit r185814? Starting from 2008 Aug they appear in almost all commits to stable/7. # svn log -v svn://svn.freebsd.org/base/stable/7 -r185814 Changed paths: M /stable/7/sys M /stable/7/sys/contrib/pf M /stable/7/sys/netinet/in_pcb.h Merge r185791 from head to stable/7: # svn diff svn://svn.freebsd.org/base/stable/7 -r185805:185814 ... diff to in_pcb.h ... Property changes on: sys/contrib/pf ___________________________________________________________________ Modified: svn:mergeinfo Merged /head/sys/contrib/pf:r185791 Property changes on: sys ___________________________________________________________________ Modified: svn:mergeinfo Merged /head/sys:r185791 # svn log -v svn://svn.freebsd.org/base/head -r185791 ------------------------------------------------------------------------ Changed paths: M /head/sys/netinet/in_pcb.h -- regards, Artis Caune <----. CCNA | BSDA <----|==================== <----' didii FreeBSD From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 09:58:37 2008 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 D5C92106564A for ; Fri, 12 Dec 2008 09:58:37 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from mx27.mail.ru (mx27.mail.ru [194.67.23.23]) by mx1.freebsd.org (Postfix) with ESMTP id 94F2B8FC08 for ; Fri, 12 Dec 2008 09:58:37 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from [217.25.27.27] (port=25123 helo=[217.25.27.27]) by mx27.mail.ru with asmtp id 1LB4n5-000IkE-00 for freebsd-hackers@freebsd.org; Fri, 12 Dec 2008 12:58:35 +0300 Message-ID: <494235CA.2050101@mail.ru> Date: Fri, 12 Dec 2008 13:58:34 +0400 From: rihad User-Agent: Icedove 1.5.0.14eol (X11/20080724) MIME-Version: 1.0 To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam: Not detected X-Mras: OK X-Mailman-Approved-At: Fri, 12 Dec 2008 12:47:59 +0000 Subject: preventing FIFO from EOF X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: rihad@mail.ru List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 Dec 2008 09:58:37 -0000 $ mkfifo /var/tmp/foo $ buffer -i /var/tmp/foo # misc/buffer # in another console: $ echo hi > /var/tmp/foo buffer prints hi and exits. I want it to keep reading and printing indefinitely. Further experimentation revealed that I need two writers: one dummy writer that just keeps /var/tmp/foo open for writing, and the other doing the "real work". This way buffer wouldn't exit. But how to emulate the dummy writer? It itself needs to block on something to keep /var/tmp/foo open. Any clean way to do this in shell? Maybe the solution is quite simple but isn't at the tip of my tongue. Thanks. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 13:24:10 2008 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 062A41065670 for ; Fri, 12 Dec 2008 13:24:10 +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 B3C468FC12 for ; Fri, 12 Dec 2008 13:24:09 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1LB7zz-0006kU-SU; Fri, 12 Dec 2008 15:24:07 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: rihad@mail.ru In-reply-to: <494235CA.2050101@mail.ru> References: <494235CA.2050101@mail.ru> Comments: In-reply-to rihad message dated "Fri, 12 Dec 2008 13:58:34 +0400." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 12 Dec 2008 15:24:07 +0200 From: Danny Braniss Message-ID: Cc: freebsd-hackers@freebsd.org Subject: Re: preventing FIFO from EOF 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, 12 Dec 2008 13:24:10 -0000 > $ mkfifo /var/tmp/foo > $ buffer -i /var/tmp/foo # misc/buffer > # in another console: > $ echo hi > /var/tmp/foo > > buffer prints hi and exits. I want it to keep reading and printing > indefinitely. > > Further experimentation revealed that I need two writers: one dummy > writer that just keeps /var/tmp/foo open for writing, and the other > doing the "real work". This way buffer wouldn't exit. But how to emulate > the dummy writer? It itself needs to block on something to keep > /var/tmp/foo open. Any clean way to do this in shell? Maybe the solution > is quite simple but isn't at the tip of my tongue. > > Thanks. too easy n csh: while 1 buffer -i /var/tmp/foo end or in sh: while true; do buffer -i /var/tmp/foo done From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 13:41:40 2008 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 7B1181065678; Fri, 12 Dec 2008 13:41:40 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.terabit.net.ua (mail.terabit.net.ua [195.137.202.147]) by mx1.freebsd.org (Postfix) with ESMTP id D70E38FC1B; Fri, 12 Dec 2008 13:41:39 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from skuns.zoral.com.ua ([91.193.166.194] helo=mail.zoral.com.ua) by mail.terabit.net.ua with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63 (FreeBSD)) (envelope-from ) id 1LB8Gv-0008X3-TJ; Fri, 12 Dec 2008 15:41:38 +0200 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 mBCDfUKM061875 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 12 Dec 2008 15:41:30 +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.3/8.14.3) with ESMTP id mBCDfTLm097664; Fri, 12 Dec 2008 15:41:30 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.3/8.14.3/Submit) id mBCDfTOC097663; Fri, 12 Dec 2008 15:41:29 +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, 12 Dec 2008 15:41:29 +0200 From: Kostik Belousov To: David Wolfskill , hackers@freebsd.org, current@freebsd.org Message-ID: <20081212134129.GD2038@deviant.kiev.zoral.com.ua> References: <20081203001538.GC96383@bunrab.catwhisker.org> <20081209190110.GW60731@albert.catwhisker.org> <20081210165022.GJ60731@albert.catwhisker.org> <20081210170620.GS2038@deviant.kiev.zoral.com.ua> <20081211225349.GB5597@albert.catwhisker.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="ZPyQn7mfIBXOql8K" Content-Disposition: inline In-Reply-To: <20081211225349.GB5597@albert.catwhisker.org> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: ClamAV version 0.93.3, clamav-milter version 0.93.3 on skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua X-Virus-Scanned: mail.terabit.net.ua 1LB8Gv-0008X3-TJ b4c2b8acd62b5bbc628e5797911f2a14 X-Terabit: YES Cc: Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 12 Dec 2008 13:41:40 -0000 --ZPyQn7mfIBXOql8K Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Dec 11, 2008 at 02:53:49PM -0800, David Wolfskill wrote: > On Wed, Dec 10, 2008 at 07:06:20PM +0200, Kostik Belousov wrote: > > ... > > > What concerns me is that even if the attempted unmount gets EBUSY, the > > > user-level process descending the directory hierarchy is getting ENOE= NT > > > trying to issue fstatfs() against an open file descriptor. > > >=20 > > > I'm having trouble figuring out any way that makes any sense. > >=20 > > Basically, the problem is that NFS uses shared lookup, and this allows > > for the bug where several negative namecache entries are created for > > non-existent node. Then this node gets created, removing only the first > > negative namecache entry. For some reasons, vnode is reclaimed; amd' > > tasting of unmount is a good reason for vnode to be reclaimed. > >=20 > > Now, you have existing path and a negative cache entry. This was > > reported by Peter Holm first, I listed relevant revisions that > > should fix this in previous mail. >=20 > Well, I messed up the machine I had been using for testing, and needed > to wait for IT to do something to it since I don't have physical or > console access to it. >=20 > So after I happened to demonstrate the effect using my desktop -- which > had been running RELENG_7_1, sources updated as of around 0400 hrs. > US/Pacific -- I decided to go ahead and update the desktop to RELENG_7_1 > as of this morning (which had the commit to sys/kern/vfs_cache.c), then > test. >=20 > It still failed, apparently in the same way; details below. >=20 > First, here's a list of the files that were changed: >=20 > U lib/libarchive/archive_read_support_format_iso9660.c > U lib/libarchive/archive_string.c > U lib/libarchive/archive_string.h > U lib/libc/gen/times.3 > U lib/libc/i386/sys/pipe.S > U lib/libc/i386/sys/reboot.S > U lib/libc/i386/sys/setlogin.S > U lib/libutil/Makefile > U lib/libutil/kinfo_getfile.c > U lib/libutil/kinfo_getvmmap.c > U lib/libutil/libutil.h > U share/man/man4/bce.4 > U share/man/man5/Makefile > U share/man/man5/fstab.5 > U share/man/man5/nullfs.5 > U sys/amd64/Makefile > U sys/boot/forth/loader.conf.5 > U sys/dev/ale/if_ale.c > U sys/dev/bce/if_bce.c > U sys/dev/cxgb/cxgb_main.c > U sys/dev/cxgb/common/cxgb_ael1002.c > U sys/dev/cxgb/common/cxgb_t3_hw.c > U sys/dev/cxgb/common/cxgb_xgmac.c > U sys/dev/re/if_re.c > U sys/fs/nullfs/null_vnops.c > U sys/kern/Make.tags.inc > U sys/kern/kern_descrip.c > U sys/kern/kern_proc.c > U sys/kern/vfs_cache.c > U sys/netinet/in_pcb.h > U sys/pci/if_rlreg.h > U sys/sys/sysctl.h > U sys/sys/user.h > U sys/ufs/ufs/ufs_quota.c > U usr.bin/procstat/Makefile > U usr.bin/procstat/procstat_files.c > U usr.bin/procstat/procstat_vm.c > U usr.bin/tar/util.c > U usr.bin/tar/test/Makefile > U usr.bin/tar/test/test_strip_components.c > U usr.bin/tar/test/test_symlink_dir.c > U usr.bin/xargs/xargs.1 > U usr.sbin/mtree/mtree.c >=20 > We see that sys/kern/vfs_cache.c is, indeed, among them. And: >=20 > dwolf-bsd(7.1-P)[5] grep '\$FreeBSD' /sys/kern/vfs_cache.c > __FBSDID("$FreeBSD: src/sys/kern/vfs_cache.c,v 1.114.2.3 2008/12/09 16:20= :58 kib Exp $"); > dwolf-bsd(7.1-P)[6]=20 >=20 > That should correspond to the desired version of the file. >=20 > Here we see an excerpt from the ktrace output for the amd(8) process and > its children; this is a point when amd(8) is trying an unmount() to see > if it can get away with it: >=20 > 977 amd 1229033597.269612 CALL gettimeofday(0x807ad48,0) > 977 amd 1229033597.269620 RET gettimeofday 0 > 977 amd 1229033597.269630 CALL sigprocmask(SIG_BLOCK,0xbfbfeaec,= 0xbfbfeadc) > 977 amd 1229033597.269637 RET sigprocmask 0 > 977 amd 1229033597.269645 CALL fork > 977 amd 1229033597.273810 RET fork 1712/0x6b0 > 1712 amd 1229033597.273811 RET fork 0 > 977 amd 1229033597.273836 CALL sigprocmask(SIG_SETMASK,0xbfbfead= c,0) > 1712 amd 1229033597.273845 CALL getpid > 977 amd 1229033597.273850 RET sigprocmask 0 > 1712 amd 1229033597.273855 RET getpid 1712/0x6b0 > 977 amd 1229033597.273864 CALL gettimeofday(0x807ad48,0) > 977 amd 1229033597.273874 RET gettimeofday 0 > 1712 amd 1229033597.273878 CALL unmount(0x2832c610,0) > ... > 1712 amd 1229033597.352643 RET unmount -1 errno 16 Device busy > 1712 amd 1229033597.352695 CALL sigprocmask(SIG_BLOCK,0x28097c00,= 0xbfbfea0c) > 1712 amd 1229033597.352728 RET sigprocmask 0 > 1712 amd 1229033597.352751 CALL sigprocmask(SIG_SETMASK,0x28097c1= 0,0) > 1712 amd 1229033597.352769 RET sigprocmask 0 > 1712 amd 1229033597.352781 CALL sigprocmask(SIG_BLOCK,0x28097c00,= 0xbfbfe9dc) > 1712 amd 1229033597.352790 RET sigprocmask 0 > 1712 amd 1229033597.352801 CALL sigprocmask(SIG_SETMASK,0x28097c1= 0,0) > 1712 amd 1229033597.352805 RET sigprocmask 0 > 1712 amd 1229033597.352815 CALL exit(0x10) > 977 amd 1229033597.353085 RET select -1 errno 4 Interrupted sys= tem call > 977 amd 1229033597.353093 PSIG SIGCHLD caught handler=3D0x805de5= 0 mask=3D0x0 code=3D0x0 > 977 amd 1229033597.353103 CALL wait4(0xffffffff,0xbfbfe83c,WNOHA= NG,0) > 977 amd 1229033597.353116 RET wait4 1712/0x6b0 > 977 amd 1229033597.353122 CALL wait4(0xffffffff,0xbfbfe83c,WNOHA= NG,0) > 977 amd 1229033597.353127 RET wait4 -1 errno 10 No child proces= ses >=20 >=20 > So amd(8) master process (pid 977) jorks off a child (pid 1712) to > try an umount(), which it initiates at 1229033597.273878. At > 1229033597.352643 the child gets control back, as well as an EBUSY, > which I would expect to mean that the attempt failed. The child > exits at 1229033597.352815 with a status code of 16. >=20 > Armed with that, we look at a ktrace excerpt from "rm -fr": >=20 > 1660 rm 1229033597.283277 CALL rmdir(0x2822b388) > 1660 rm 1229033597.283283 NAMI "stvef-paks" > 1660 rm 1229033597.285599 RET rmdir 0 > 1660 rm 1229033597.285620 CALL stat(0x2822b3e8,0xbfbfe8dc) > 1660 rm 1229033597.285626 NAMI "stvef-server" > 1660 rm 1229033597.286071 STRU struct stat {dev=3D83951372, ino= =3D20124614, mode=3Ddrwxr-xr-x , nlink=3D3, uid=3D9874, gid=3D929, rdev=3D0= , atime=3D1228844788, stime=3D1227555769, ctime=3D1228845828.326650000, bir= thtime=3D0, size=3D4096, blksize=3D4096, blocks=3D8, flags=3D0x0 } > 1660 rm 1229033597.286078 RET stat 0 > 1660 rm 1229033597.286084 CALL open(0x2822b3e8,O_NONBLOCK,0x1) > 1660 rm 1229033597.286091 NAMI "stvef-server" > 1660 rm 1229033597.287145 RET open 4 > 1660 rm 1229033597.287154 CALL fstat(0x4,0xbfbfe8dc) > 1660 rm 1229033597.287161 STRU struct stat {dev=3D83951372, ino= =3D20124614, mode=3Ddrwxr-xr-x , nlink=3D3, uid=3D9874, gid=3D929, rdev=3D0= , atime=3D1228844788, stime=3D1227555769, ctime=3D1228845828.326650000, bir= thtime=3D0, size=3D4096, blksize=3D4096, blocks=3D8, flags=3D0x0 } > 1660 rm 1229033597.287166 RET fstat 0 > 1660 rm 1229033597.287171 CALL fcntl(0x4,F_SETFD,FD_CLOEXEC) > 1660 rm 1229033597.287177 RET fcntl 0 > 1660 rm 1229033597.287187 CALL fstatfs(0x4,0xbfbfe704) > 1660 rm 1229033597.287195 RET fstatfs -1 errno 2 No such file o= r directory > 1660 rm 1229033597.287202 CALL close(0x4) > 1660 rm 1229033597.287211 RET close 0 >=20 > [Sorry for the long lines....] >=20 > Here we see that the "rm" process (pid 1660) removed a directory > named stvef-paks sucessfully in the interval between 1229033597.283277 > (when the request was made) and 1229033597.285599 (when the 0 return > occurred). The "rm" process proceeds to process a directory named > stvef-server: >=20 > * At 1229033597.285620 it issues a stat(); the successful return > is at 1229033597.286078. >=20 > * At 1229033597.286084 it issues an open(); the successful return > is at 1229033597.287145. The FD is 4. >=20 > * At 1229033597.287154 it issues an fstat() against FD 4; the successful > return is at 1229033597.287166. >=20 > * At 1229033597.287171 it issues an fcntl() against FD 4; the > successful return is at 1229033597.287177. >=20 > * At 1229033597.287187 it issues an fstatfs() against FD 4; the > unsuccessful return is at 1229033597.287195, claiming ENOENT. >=20 > Say WHAT??!? >=20 > I expect to be able to test a bit more promptly now. But is this error transient or permanent ? I.e., would restart of rm successful or failing ? Anyway, this error looks different too. --ZPyQn7mfIBXOql8K Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iEYEARECAAYFAklCagkACgkQC3+MBN1Mb4jOBgCeJtuwzLJH5kX0gUBlu2VqG/yD lzAAoK6FmV53wAKwPlQDbf0Ryd4LXsbZ =pDvh -----END PGP SIGNATURE----- --ZPyQn7mfIBXOql8K-- From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 13:50:59 2008 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 F2BF3106564A for ; Fri, 12 Dec 2008 13:50:59 +0000 (UTC) (envelope-from christoph.mallon@gmx.de) Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by mx1.freebsd.org (Postfix) with SMTP id 44C2F8FC17 for ; Fri, 12 Dec 2008 13:50:59 +0000 (UTC) (envelope-from christoph.mallon@gmx.de) Received: (qmail invoked by alias); 12 Dec 2008 13:50:57 -0000 Received: from p54A3E756.dip.t-dialin.net (EHLO tron.homeunix.org) [84.163.231.86] by mail.gmx.net (mp028) with SMTP; 12 Dec 2008 14:50:57 +0100 X-Authenticated: #1673122 X-Provags-ID: V01U2FsdGVkX183bqEY1G03lmnHtV2ing/PGolRoPmSaEriyM0S8X 1TJoeWeLMmrFAA Message-ID: <49426C40.6050802@gmx.de> Date: Fri, 12 Dec 2008 14:50:56 +0100 From: Christoph Mallon User-Agent: Thunderbird 2.0.0.18 (X11/20081124) MIME-Version: 1.0 To: rihad@mail.ru References: <494235CA.2050101@mail.ru> In-Reply-To: <494235CA.2050101@mail.ru> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-FuHaFi: 0.74 Cc: freebsd-hackers@freebsd.org Subject: Re: preventing FIFO from EOF 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, 12 Dec 2008 13:51:00 -0000 rihad schrieb: > $ mkfifo /var/tmp/foo > $ buffer -i /var/tmp/foo # misc/buffer > # in another console: > $ echo hi > /var/tmp/foo > > buffer prints hi and exits. I want it to keep reading and printing > indefinitely. > > Further experimentation revealed that I need two writers: one dummy > writer that just keeps /var/tmp/foo open for writing, and the other > doing the "real work". This way buffer wouldn't exit. But how to emulate > the dummy writer? It itself needs to block on something to keep > /var/tmp/foo open. Any clean way to do this in shell? Maybe the solution > is quite simple but isn't at the tip of my tongue. Maybe "tail -f" is what you are looking for. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 14:36:43 2008 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 CFD1A1065670; Fri, 12 Dec 2008 14:36:43 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (adsl-63-193-123-122.dsl.snfc21.pacbell.net [63.193.123.122]) by mx1.freebsd.org (Postfix) with ESMTP id 900888FC17; Fri, 12 Dec 2008 14:36:43 +0000 (UTC) (envelope-from david@catwhisker.org) Received: from albert.catwhisker.org (localhost [127.0.0.1]) by albert.catwhisker.org (8.14.3/8.14.3) with ESMTP id mBCEahKY010819; Fri, 12 Dec 2008 06:36:43 -0800 (PST) (envelope-from david@albert.catwhisker.org) Received: (from david@localhost) by albert.catwhisker.org (8.14.3/8.14.3/Submit) id mBCEahXe010818; Fri, 12 Dec 2008 06:36:43 -0800 (PST) (envelope-from david) Date: Fri, 12 Dec 2008 06:36:43 -0800 From: David Wolfskill To: Kostik Belousov Message-ID: <20081212143643.GE5597@albert.catwhisker.org> Mail-Followup-To: David Wolfskill , Kostik Belousov , hackers@freebsd.org, current@freebsd.org References: <20081203001538.GC96383@bunrab.catwhisker.org> <20081209190110.GW60731@albert.catwhisker.org> <20081210165022.GJ60731@albert.catwhisker.org> <20081210170620.GS2038@deviant.kiev.zoral.com.ua> <20081211225349.GB5597@albert.catwhisker.org> <20081212134129.GD2038@deviant.kiev.zoral.com.ua> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="0H629O+sVkh21xTi" Content-Disposition: inline In-Reply-To: <20081212134129.GD2038@deviant.kiev.zoral.com.ua> User-Agent: Mutt/1.4.2.3i Cc: hackers@freebsd.org, current@freebsd.org Subject: Re: NFS (& amd?) dysfunction descending a hierarchy 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, 12 Dec 2008 14:36:44 -0000 --0H629O+sVkh21xTi Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Dec 12, 2008 at 03:41:29PM +0200, Kostik Belousov wrote: > ... > > * At 1229033597.287187 it issues an fstatfs() against FD 4; the > > unsuccessful return is at 1229033597.287195, claiming ENOENT. > >=20 > > Say WHAT??!? > ... >=20 > But is this error transient or permanent ? I.e., would restart of rm > successful or failing ? In a test yesterday, it took 3 attempts (each attempt being an invocations of "rm -fr ~bspace/ports") to actually complete removal of the hierarchy. Please note that: * Done on a locally-mounted file systen (vs. NFS), a single invocation is sufficient and terminates normally. Each of the above-cited attempts but the last terminated with a status code of 1 (as well as a whine that one or more subdirectories was not empty -- this, as a result of "rm" getting inconsistent information about the status of the file system). * Done on either a locally- or NFS-mounted file system in FreeBSD 6.x, a single invocation is sufficient and terminates normally. In other words, this is a regression. > Anyway, this error looks different too. ? From the earlier-posted results in 7.x? Not that I can tell. In each case, the amd(8) child process is forked to attempt an unmount(), tries it, gets EBUSY, and exits. Meanwhile, rm(1) is descending a directory tree. It had performed a readdir(), and had been unlinking files and performing rmdir() against empty subdirectories. It encounters an entry, issues stat(), finds that it's a subdirectory, open()s it, gets an FD, issues fstat(), gets results that match those of the earlier stat(), issues fcntl() against the FD (which returns 0), tries to issue fstatfs() against the FD *that is still open*, and gets told ENOENT. It does differ from the behavior in 8-CURRENT, in that the amd(8) child process in 8-CURRENT does not appear to get EBUSY. The behavior from rm(1)'s perspective is very similar, though. If it would help, I could try getting a ktrace from a 6.x system, but I expect it will be very boring: the amd(8) child process should get EBUSY (as it does in 7.x), and nothing else should happen, since the unmount() attempt failed. And since it failed, rm(1) doesn't get told inconsistent information, so things Just Work. I admit that I'm no expert on VFS or much of the rest of the kernel, for that matter. But what I have observed happening in recent 7.x is both wrong and a regression. 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. --0H629O+sVkh21xTi Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (FreeBSD) iEYEARECAAYFAklCdvkACgkQmprOCmdXAD0uAwCeOCN2mO3bpUGorAOu2wCSLxlY mgkAoIBbaJTfCWkCNclH+N2ADyZRPrOp =Bmdx -----END PGP SIGNATURE----- --0H629O+sVkh21xTi-- From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 15:58:34 2008 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 D48E4106564A for ; Fri, 12 Dec 2008 15:58:34 +0000 (UTC) (envelope-from rick@kiwi-computer.com) Received: from kiwi-computer.com (keira.kiwi-computer.com [63.224.10.3]) by mx1.freebsd.org (Postfix) with SMTP id 6C4348FC21 for ; Fri, 12 Dec 2008 15:58:34 +0000 (UTC) (envelope-from rick@kiwi-computer.com) Received: (qmail 82884 invoked by uid 2001); 12 Dec 2008 15:58:33 -0000 Date: Fri, 12 Dec 2008 09:58:33 -0600 From: "Rick C. Petty" To: Artis Caune Message-ID: <20081212155833.GB82667@keira.kiwi-computer.com> References: <9e20d71e0812120315l30d72b2doc899a8163fde829f@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <9e20d71e0812120315l30d72b2doc899a8163fde829f@mail.gmail.com> User-Agent: Mutt/1.4.2.3i Cc: freebsd-hackers@freebsd.org Subject: Re: Strange "changed paths" in svn commits X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: rick-freebsd2008@kiwi-computer.com List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 Dec 2008 15:58:34 -0000 On Fri, Dec 12, 2008 at 01:15:17PM +0200, Artis Caune wrote: > Hi, > > Is it how merging works or I'm missing something? I suspect you've run into a well-known svn bug that affects "svn merge". I thought they had fixed it with subversion 1.5.4, but apparently it's still around. When doing a merge, it seems to randomly touch a bunch of files.. it only updates the svn:mergeinfo property on those files, but it's still annoying. Whenever I do a merge, I always merge into a working copy, then double-check the work with "svn diff" before committing. When I see it bring in extra files, I just do a revert on those, then the commit is clean. I'm hoping the tigris folks are working on this issue. -- Rick C. Petty From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 16:14:08 2008 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 339FF1065678 for ; Fri, 12 Dec 2008 16:14:08 +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 E165B8FC22 for ; Fri, 12 Dec 2008 16:14:07 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1LBAeU-00086X-I3; Fri, 12 Dec 2008 18:14:06 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: rihad In-reply-to: <49426B64.1070004@mail.ru> References: <494235CA.2050101@mail.ru> <49426B64.1070004@mail.ru> Comments: In-reply-to rihad message dated "Fri, 12 Dec 2008 17:47:16 +0400." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 12 Dec 2008 18:14:06 +0200 From: Danny Braniss Message-ID: Cc: freebsd-hackers@freebsd.org Subject: Re: preventing FIFO from EOF 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, 12 Dec 2008 16:14:08 -0000 > Danny Braniss wrote: > >> $ mkfifo /var/tmp/foo > >> $ buffer -i /var/tmp/foo # misc/buffer > >> # in another console: > >> $ echo hi > /var/tmp/foo > >> > >> buffer prints hi and exits. I want it to keep reading and printing > >> indefinitely. > >> > >> Further experimentation revealed that I need two writers: one dummy > >> writer that just keeps /var/tmp/foo open for writing, and the other > >> doing the "real work". This way buffer wouldn't exit. But how to emulate > >> the dummy writer? It itself needs to block on something to keep > >> /var/tmp/foo open. Any clean way to do this in shell? Maybe the solution > >> is quite simple but isn't at the tip of my tongue. > >> > >> Thanks. > > > > too easy > > n csh: > > while 1 > > buffer -i /var/tmp/foo > > end > > or in sh: > > while true; do > > buffer -i /var/tmp/foo > > done > > > > > Thanks, but I should have said that buffer must always run to never miss any data. > > The reason being that buffer's output gets fed into another program that > shouldn't be restarted. use 'tail -f' instead of 'buffer -i' then, or place the while in file and execute that. BTW, buffer was written way back when memory was measured in kilobytes and the ethernet was 10 mgb, so things have changed a bit, and its effectivness is questionable :-) danny From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 16:21:30 2008 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 B78841065672 for ; Fri, 12 Dec 2008 16:21:30 +0000 (UTC) (envelope-from kientzle@freebsd.org) Received: from kientzle.com (kientzle.com [66.166.149.50]) by mx1.freebsd.org (Postfix) with ESMTP id 90B308FC0C for ; Fri, 12 Dec 2008 16:21:30 +0000 (UTC) (envelope-from kientzle@freebsd.org) Received: from [10.123.2.178] (p53.kientzle.com [66.166.149.53]) by kientzle.com (8.12.9/8.12.9) with ESMTP id mBCGLUtv078637; Fri, 12 Dec 2008 08:21:30 -0800 (PST) (envelope-from kientzle@freebsd.org) Message-ID: <49428F85.7030701@freebsd.org> Date: Fri, 12 Dec 2008 08:21:25 -0800 From: Tim Kientzle User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.12) Gecko/20060422 X-Accept-Language: en-us, en MIME-Version: 1.0 To: rick-freebsd2008@kiwi-computer.com References: <9e20d71e0812120315l30d72b2doc899a8163fde829f@mail.gmail.com> <20081212155833.GB82667@keira.kiwi-computer.com> In-Reply-To: <20081212155833.GB82667@keira.kiwi-computer.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org, Artis Caune Subject: Re: Strange "changed paths" in svn commits 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, 12 Dec 2008 16:21:30 -0000 Rick C. Petty wrote: > On Fri, Dec 12, 2008 at 01:15:17PM +0200, Artis Caune wrote: > > I suspect you've run into a well-known svn bug that affects "svn merge". I > thought they had fixed it with subversion 1.5.4, but apparently it's still > around. When doing a merge, it seems to randomly touch a bunch of files.. > it only updates the svn:mergeinfo property on those files ... I've seen this happen only once and eventually figured out that I had a partial checkout underneath the merge point. It was especially confusing in my case because I actually had a complete checkout---nothing was missing---but one of the directories was marked "depth=immediates" so it was treated as a partial checkout. If the svn:mergeinfo has asterisks in it, this is why. Tim From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 17:47:40 2008 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 273491065680 for ; Fri, 12 Dec 2008 17:47: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 D39038FC14 for ; Fri, 12 Dec 2008 17:47:39 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by kabab.cs.huji.ac.il with esmtp id 1LBC70-0008qm-Gl; Fri, 12 Dec 2008 19:47:38 +0200 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: rihad In-reply-to: <49429027.8060701@mail.ru> References: <494235CA.2050101@mail.ru> <49426B64.1070004@mail.ru> <49429027.8060701@mail.ru> Comments: In-reply-to rihad message dated "Fri, 12 Dec 2008 20:24:07 +0400." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 12 Dec 2008 19:47:38 +0200 From: Danny Braniss Message-ID: Cc: freebsd-hackers@freebsd.org Subject: Re: preventing FIFO from EOF 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, 12 Dec 2008 17:47:40 -0000 > > BTW, buffer was written way back when memory was measured > > in kilobytes and the ethernet was 10 mgb, so things have changed a bit, and > > its effectivness is questionable :-) > > > My scenario: > > prog1 | prog2 > > where both are daemons. prog1 does all the work, and sends commands for > prog2 to do when needed. I don't want prog1 to block while prog2 is busy > executing the command. So a buffer is inserted between the two: > > prog1 | buffer | prog2 > > Asynchronous execution of commands. It's as simple as that. ahh, but you see, you have now 4 processes, which the scheduler has no real reason to treat specialy, each can block. Then again, I have no idea how much data you are moving around, and how fast you need to process it. buffer was designed to keep a magnetic tape writing at full speed - streaming, or at least for some longer time. then again, there is nothing better than trying it out, instead of out guessing the os :-) cheers, danny From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 13:42:21 2008 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 C0261106567C for ; Fri, 12 Dec 2008 13:42:21 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from mx40.mail.ru (mx40.mail.ru [194.67.23.36]) by mx1.freebsd.org (Postfix) with ESMTP id 7DDBE8FC17 for ; Fri, 12 Dec 2008 13:42:21 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from [217.25.27.27] (port=48487 helo=[217.25.27.27]) by mx40.mail.ru with asmtp id 1LB8Hb-000Hcr-00 for freebsd-hackers@freebsd.org; Fri, 12 Dec 2008 16:42:19 +0300 Message-ID: <49426A3A.4070806@mail.ru> Date: Fri, 12 Dec 2008 17:42:18 +0400 From: rihad User-Agent: Icedove 1.5.0.14eol (X11/20080724) MIME-Version: 1.0 To: freebsd-hackers@freebsd.org References: <494235CA.2050101@mail.ru> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam: Not detected X-Mras: OK X-Mailman-Approved-At: Fri, 12 Dec 2008 18:22:47 +0000 Subject: Re: preventing FIFO from EOF 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, 12 Dec 2008 13:42:21 -0000 Danny Braniss wrote: >> $ mkfifo /var/tmp/foo >> $ buffer -i /var/tmp/foo # misc/buffer >> # in another console: >> $ echo hi > /var/tmp/foo >> >> buffer prints hi and exits. I want it to keep reading and printing >> indefinitely. >> >> Further experimentation revealed that I need two writers: one dummy >> writer that just keeps /var/tmp/foo open for writing, and the other >> doing the "real work". This way buffer wouldn't exit. But how to emulate >> the dummy writer? It itself needs to block on something to keep >> /var/tmp/foo open. Any clean way to do this in shell? Maybe the solution >> is quite simple but isn't at the tip of my tongue. >> >> Thanks. > > too easy > n csh: > while 1 > buffer -i /var/tmp/foo > end > or in sh: > while true; do > buffer -i /var/tmp/foo > done > Thanks, but I should have said that buffer must always run to never miss any data. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 13:47:20 2008 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 177C01065677 for ; Fri, 12 Dec 2008 13:47:20 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from mx39.mail.ru (mx39.mail.ru [194.67.23.35]) by mx1.freebsd.org (Postfix) with ESMTP id C80AD8FC0C for ; Fri, 12 Dec 2008 13:47:19 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from [217.25.27.27] (port=53078 helo=[217.25.27.27]) by mx39.mail.ru with asmtp id 1LB8MP-0009X0-00; Fri, 12 Dec 2008 16:47:17 +0300 Message-ID: <49426B64.1070004@mail.ru> Date: Fri, 12 Dec 2008 17:47:16 +0400 From: rihad User-Agent: Icedove 1.5.0.14eol (X11/20080724) MIME-Version: 1.0 To: Danny Braniss References: <494235CA.2050101@mail.ru> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam: Not detected X-Mras: OK X-Mailman-Approved-At: Fri, 12 Dec 2008 18:33:37 +0000 Cc: freebsd-hackers@freebsd.org Subject: Re: preventing FIFO from EOF 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, 12 Dec 2008 13:47:20 -0000 Danny Braniss wrote: >> $ mkfifo /var/tmp/foo >> $ buffer -i /var/tmp/foo # misc/buffer >> # in another console: >> $ echo hi > /var/tmp/foo >> >> buffer prints hi and exits. I want it to keep reading and printing >> indefinitely. >> >> Further experimentation revealed that I need two writers: one dummy >> writer that just keeps /var/tmp/foo open for writing, and the other >> doing the "real work". This way buffer wouldn't exit. But how to emulate >> the dummy writer? It itself needs to block on something to keep >> /var/tmp/foo open. Any clean way to do this in shell? Maybe the solution >> is quite simple but isn't at the tip of my tongue. >> >> Thanks. > > too easy > n csh: > while 1 > buffer -i /var/tmp/foo > end > or in sh: > while true; do > buffer -i /var/tmp/foo > done > > Thanks, but I should have said that buffer must always run to never miss any data. The reason being that buffer's output gets fed into another program that shouldn't be restarted. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 14:12:47 2008 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 6C2EA1065675 for ; Fri, 12 Dec 2008 14:12:47 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from mx7.mail.ru (mx7.mail.ru [194.67.23.27]) by mx1.freebsd.org (Postfix) with ESMTP id 2AD5D8FC19 for ; Fri, 12 Dec 2008 14:12:46 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from [217.25.27.27] (port=13997 helo=[217.25.27.27]) by mx7.mail.ru with asmtp id 1LB8l2-000H42-00; Fri, 12 Dec 2008 17:12:44 +0300 Message-ID: <4942715B.7090509@mail.ru> Date: Fri, 12 Dec 2008 18:12:43 +0400 From: rihad User-Agent: Icedove 1.5.0.14eol (X11/20080724) MIME-Version: 1.0 To: Christoph Mallon References: <494235CA.2050101@mail.ru> <49426C40.6050802@gmx.de> In-Reply-To: <49426C40.6050802@gmx.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam: Not detected X-Mras: OK X-Mailman-Approved-At: Fri, 12 Dec 2008 18:33:46 +0000 Cc: freebsd-hackers@freebsd.org Subject: Re: preventing FIFO from EOF 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, 12 Dec 2008 14:12:47 -0000 Christoph Mallon wrote: > rihad schrieb: > Something as simple as this: > $ sh < /dev/null > /var/tmp/kick 2>/dev/null > seems to block indefinitely, but exits as soon as I run > $ buffer -i /var/tmp/foo > (and buffer exits too) Strangely enough, something as stupid as this does the trick: sh < /dev/stdout > /var/tmp/kick 2>/dev/null i.e. reading from stdout blocks. Now sh keeps buffer block on /var/tmp/kick and never exit ;) I'm not sure what this does or why and how it works Unix-wise. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 15:48:10 2008 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 7F4E01065672 for ; Fri, 12 Dec 2008 15:48:10 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from mx28.mail.ru (mx28.mail.ru [194.67.23.67]) by mx1.freebsd.org (Postfix) with ESMTP id 3B78D8FC30 for ; Fri, 12 Dec 2008 15:48:10 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from mx48.mail.ru (unknown [194.67.23.231]) by mx28.mail.ru (mPOP.Fallback_MX) with ESMTP id 4579C6108E for ; Fri, 12 Dec 2008 17:07:38 +0300 (MSK) Received: from [217.25.27.27] (port=9560 helo=[217.25.27.27]) by mx48.mail.ru with asmtp id 1LB8g4-000Ad6-00; Fri, 12 Dec 2008 17:07:36 +0300 Message-ID: <49427027.60800@mail.ru> Date: Fri, 12 Dec 2008 18:07:35 +0400 From: rihad User-Agent: Icedove 1.5.0.14eol (X11/20080724) MIME-Version: 1.0 To: Christoph Mallon References: <494235CA.2050101@mail.ru> <49426C40.6050802@gmx.de> In-Reply-To: <49426C40.6050802@gmx.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam: Not detected X-Mras: OK X-Mailman-Approved-At: Fri, 12 Dec 2008 18:33:55 +0000 Cc: freebsd-hackers@freebsd.org Subject: Re: preventing FIFO from EOF 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, 12 Dec 2008 15:48:10 -0000 Christoph Mallon wrote: > rihad schrieb: >> $ mkfifo /var/tmp/foo >> $ buffer -i /var/tmp/foo # misc/buffer >> # in another console: >> $ echo hi > /var/tmp/foo >> >> buffer prints hi and exits. I want it to keep reading and printing >> indefinitely. >> >> Further experimentation revealed that I need two writers: one dummy >> writer that just keeps /var/tmp/foo open for writing, and the other >> doing the "real work". This way buffer wouldn't exit. But how to >> emulate the dummy writer? It itself needs to block on something to >> keep /var/tmp/foo open. Any clean way to do this in shell? Maybe the >> solution is quite simple but isn't at the tip of my tongue. > > Maybe "tail -f" is what you are looking for. > > You mean in place of buffer? buffer is there for a reason (so that writers never block). Something as simple as this: $ sh < /dev/null > /var/tmp/kick 2>/dev/null seems to block indefinitely, but exits as soon as I run $ buffer -i /var/tmp/foo (and buffer exits too) From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 16:24:11 2008 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 5A7BA1065675 for ; Fri, 12 Dec 2008 16:24:11 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from mx27.mail.ru (mx27.mail.ru [194.67.23.23]) by mx1.freebsd.org (Postfix) with ESMTP id 178568FC12 for ; Fri, 12 Dec 2008 16:24:11 +0000 (UTC) (envelope-from rihad@mail.ru) Received: from [217.25.27.27] (port=56947 helo=[217.25.27.27]) by mx27.mail.ru with asmtp id 1LBAoC-0009je-00; Fri, 12 Dec 2008 19:24:08 +0300 Message-ID: <49429027.8060701@mail.ru> Date: Fri, 12 Dec 2008 20:24:07 +0400 From: rihad User-Agent: Icedove 1.5.0.14eol (X11/20080724) MIME-Version: 1.0 To: Danny Braniss References: <494235CA.2050101@mail.ru> <49426B64.1070004@mail.ru> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam: Not detected X-Mras: OK X-Mailman-Approved-At: Fri, 12 Dec 2008 18:34:04 +0000 Cc: freebsd-hackers@freebsd.org Subject: Re: preventing FIFO from EOF 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, 12 Dec 2008 16:24:11 -0000 > BTW, buffer was written way back when memory was measured > in kilobytes and the ethernet was 10 mgb, so things have changed a bit, and > its effectivness is questionable :-) > My scenario: prog1 | prog2 where both are daemons. prog1 does all the work, and sends commands for prog2 to do when needed. I don't want prog1 to block while prog2 is busy executing the command. So a buffer is inserted between the two: prog1 | buffer | prog2 Asynchronous execution of commands. It's as simple as that. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 18:39:33 2008 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 53C8C106564A for ; Fri, 12 Dec 2008 18:39:33 +0000 (UTC) (envelope-from rick@kiwi-computer.com) Received: from kiwi-computer.com (keira.kiwi-computer.com [63.224.10.3]) by mx1.freebsd.org (Postfix) with SMTP id DD1C38FC12 for ; Fri, 12 Dec 2008 18:39:32 +0000 (UTC) (envelope-from rick@kiwi-computer.com) Received: (qmail 84610 invoked by uid 2001); 12 Dec 2008 18:39:31 -0000 Date: Fri, 12 Dec 2008 12:39:31 -0600 From: "Rick C. Petty" To: Tim Kientzle Message-ID: <20081212183931.GC82667@keira.kiwi-computer.com> References: <9e20d71e0812120315l30d72b2doc899a8163fde829f@mail.gmail.com> <20081212155833.GB82667@keira.kiwi-computer.com> <49428F85.7030701@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <49428F85.7030701@freebsd.org> User-Agent: Mutt/1.4.2.3i Cc: freebsd-hackers@freebsd.org, Artis Caune Subject: Re: Strange "changed paths" in svn commits X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: rick-freebsd2008@kiwi-computer.com List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 Dec 2008 18:39:33 -0000 On Fri, Dec 12, 2008 at 08:21:25AM -0800, Tim Kientzle wrote: > Rick C. Petty wrote: > >On Fri, Dec 12, 2008 at 01:15:17PM +0200, Artis Caune wrote: > > > >I suspect you've run into a well-known svn bug that affects "svn merge". I > >thought they had fixed it with subversion 1.5.4, but apparently it's still > >around. When doing a merge, it seems to randomly touch a bunch of files.. > >it only updates the svn:mergeinfo property on those files ... > > I've seen this happen only once and eventually figured > out that I had a partial checkout underneath the merge point. > It was especially confusing in my case because I actually > had a complete checkout---nothing was missing---but > one of the directories was marked "depth=immediates" > so it was treated as a partial checkout. > > If the svn:mergeinfo has asterisks in it, this is why. In my case, I had a fresh copy that I merged a single file into, but it touched 5 other random files; files I had never seen, much less ever edited. We've seen this behavior for weeks, but the rate of occurances dropped significantly with svn 1.5.4-- dropped, not disappeared completely. -- Rick C. Petty From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 12 22:57:39 2008 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 689A91065675 for ; Fri, 12 Dec 2008 22:57:39 +0000 (UTC) (envelope-from patfbsd@davenulle.org) Received: from smtp.lamaiziere.net (net.lamaiziere.net [91.121.44.19]) by mx1.freebsd.org (Postfix) with ESMTP id 213558FC21 for ; Fri, 12 Dec 2008 22:57:39 +0000 (UTC) (envelope-from patfbsd@davenulle.org) Received: from baby-jane.lamaiziere.net (246.10.87-79.rev.gaoland.net [79.87.10.246]) by smtp.lamaiziere.net (Postfix) with ESMTPA id 7AB2C63366E; Fri, 12 Dec 2008 23:57:37 +0100 (CET) Received: from baby-jane (localhost [127.0.0.1]) by baby-jane.lamaiziere.net (Postfix) with ESMTP id DBFBA678E9D; Fri, 12 Dec 2008 23:57:36 +0100 (CET) Date: Fri, 12 Dec 2008 23:57:35 +0100 From: Patrick =?ISO-8859-15?Q?Lamaizi=E8re?= To: Sam Leffler Message-ID: <20081212235735.7deaea52@baby-jane> In-Reply-To: <494047CB.6050400@freebsd.org> References: <20081207224551.13ca3590@baby-jane> <20081208202155.GA7403@detritus.paeps.cx> <20081210233440.41bd1c47@baby-jane> <494047CB.6050400@freebsd.org> Organization: /dave/nulle X-Mailer: Claws Mail 3.3.1 (GTK+ 2.12.9; i386-apple-darwin9.3.0) Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 8bit Cc: freebsd-hackers@freebsd.org Subject: Re: crypto(9) choose another driver if we cannot open a session on it 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, 12 Dec 2008 22:57:39 -0000 Le Wed, 10 Dec 2008 14:50:51 -0800, Sam Leffler a écrit : Hello, > > Which code exactly? Yes I'm curious :-) > > > > I'm thinking about how to remove the need for a device to support > > all the algorithms when we open a session. By using a fake "crypto > > virtual device" to open and dispatch crypto requests to real > > devices or to cryptosoft. But i don't have any code to show yet. > > > > There is one thing I'm asking about crypto(9): > > - I doubt that the migration of a session is safe and I think that > > would be far easier to prevent a driver to unregister when there are > > some pending sessions on it? glxsb and padlock do not allow to > > unregister in this case. > > > > I've looked quickly the code of geli or ipsec. If the crypto > > framework returns EAGAIN because the migration of the session, they > > restart a crypto_dispatch(crp) but the datas in crp->crp_buf can be > > corrupted by the previous crypto operation (IMHO, may be i've missed > > something)? > > > This sounds like the session management layer I wanted to insert a > while back. It was a reason why I made the s/w driver into a pseudo > device (so there'd be a handle). That is the easiest way to do, i think. > As to unregister that was designed for devices like cardbus cards > that might go away. About the only way to simulate it today is to > unload a driver module. But it should work; if you see an issue we > should try to fix it. Ok, thank you. I will try to tests it. > OTOH the limitations of the existing crypto > code are dramatic and the rationale for maintaining the obsd api's > (both in kernel and user space) are no longer valid. It would be > good to see someone take this stuff and overhaul it to do things like: > > o add a session management layer that falls back to s/w when a device > is incapable and when operations are more efficiently done in s/w > (e.g ops too small to incur the dma setup/overhead) > o do load balancing over multiple devices > o support cpu resources as pseudo drivers (e.g. pin a thread to a cpu) > o replace the bogus fd session crud w/ device cloning > > The linux folks have done some of this and there may be lessons to be > learned from their efforts. FWIW netbsd has some recent user api > changes for doing async ops and batching to speedup openssl etc; if > you're going to get into this stuff you might take a look. I don't know enough the kernel to make a revolution. Anyway I can make some evolutions and try to help. Is there someone working on the crypto framework ? Regards.