From owner-freebsd-hackers@FreeBSD.ORG Sun Sep 30 11:19:24 2007 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 C8B3316A417 for ; Sun, 30 Sep 2007 11:19:24 +0000 (UTC) (envelope-from krad@snaffler.net) Received: from mk-filter-2-a-4.mail.uk.tiscali.com (mk-filter-2-a-1.mail.uk.tiscali.com [212.74.100.53]) by mx1.freebsd.org (Postfix) with ESMTP id 7B45F13C467 for ; Sun, 30 Sep 2007 11:19:24 +0000 (UTC) (envelope-from krad@snaffler.net) X-Trace: 617880034-mk-filter-2.mail.uk.tiscali.com-B2C-$TRUSTED-IMPLICITLY_TRUSTED X-SBRS: None X-RemoteIP: 212.74.112.53 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgAAAOcg/0bUSnA1/2dsb2JhbAAM Received: from e1-1.ns500-1.ts.milt.as9105.net (HELO [10.44.30.84]) ([212.74.112.53]) by smtp.business.co.uk with ESMTP; 30 Sep 2007 12:09:19 +0100 Message-ID: <46FF83DF.6040108@snaffler.net> Date: Sun, 30 Sep 2007 12:09:19 +0100 From: "chris.scott" User-Agent: Thunderbird 1.5.0.13 (X11/20070824) MIME-Version: 1.0 To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Sun, 30 Sep 2007 12:22:18 +0000 Subject: pci serial card problems X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 30 Sep 2007 11:19:24 -0000 Hi i'm running freebsd stable (last build 28th) and am having a few issues with 2 pci serial cards. Basically I'm trying to build a serial server. However the driver doesn't seem to work correctly. Sep 28 22:18:56 boxster puc0: port 0xce00-0xce07,0xcc00-0xcc07,0xca00-0xca07,0xc800-0xc807,0xc600-0xc607,0xc400-0xc40f irq 9 at device 8.0 on pci0 Sep 28 22:18:56 boxster puc1: port 0xde00-0xde07,0xdc00-0xdc07,0xda00-0xda07,0xd800-0xd807,0xd600-0xd607,0xd400-0xd40f irq 10 at device 11.0 on pci0 Sep 28 22:18:56 boxster puc1: could not get resource they are both 6 port serial pci cards, and are listed in the puc driver as supported. The pc is quite old so Im not sure if whats causing any issues. I have tried the bios with pnpos enables and disabled but it makes little difference. I have also tried with one card and the issue is the same. I have also disabled the pcs onboard serial ports and still no go I have disabled ACPI with hint.acpi.0.disabled="1" this seems to stop the resource error but I dont get any additional cuad devices $ pciconf -l -v | grep -B 4 UART puc0@pci0:8:0: class=0x070002 card=0x00061000 chip=0x98459710 rev=0x01 hdr=0x00 vendor = 'MosChip Semiconductors (Was: Netmos Technology)' device = 'Nm9845 Parallel/Serial Port Adapter' class = simple comms subclass = UART -- puc1@pci0:11:0: class=0x070002 card=0x00061000 chip=0x98459710 rev=0x01 hdr=0x00 vendor = 'MosChip Semiconductors (Was: Netmos Technology)' device = 'Nm9845 Parallel/Serial Port Adapter' class = simple comms subclass = UART Any help much appreciated chris From owner-freebsd-hackers@FreeBSD.ORG Sun Sep 30 11:22:25 2007 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 9A0CF16A417 for ; Sun, 30 Sep 2007 11:22:25 +0000 (UTC) (envelope-from krad@snaffler.net) Received: from mk-filter-3-a-4.mail.uk.tiscali.com (mk-filter-3-a-1.mail.uk.tiscali.com [212.74.100.54]) by mx1.freebsd.org (Postfix) with ESMTP id 4840813C4A8 for ; Sun, 30 Sep 2007 11:22:25 +0000 (UTC) (envelope-from krad@snaffler.net) X-Trace: 628818405-mk-filter-3.mail.uk.tiscali.com-B2C-$TRUSTED-IMPLICITLY_TRUSTED X-SBRS: None X-RemoteIP: 212.74.112.53 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgAAAGAh/0bUSnA1/2dsb2JhbAAM Received: from e1-1.ns500-1.ts.milt.as9105.net (HELO [10.44.30.84]) ([212.74.112.53]) by smtp.tiscali.co.uk with ESMTP; 30 Sep 2007 12:12:21 +0100 Message-ID: <46FF8493.2050901@snaffler.net> Date: Sun, 30 Sep 2007 12:12:19 +0100 From: "chris.scott" User-Agent: Thunderbird 1.5.0.13 (X11/20070824) MIME-Version: 1.0 To: "chris.scott" References: <46FF83DF.6040108@snaffler.net> In-Reply-To: <46FF83DF.6040108@snaffler.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Sun, 30 Sep 2007 12:22:18 +0000 Cc: freebsd-hackers@freebsd.org Subject: Re: pci serial card problems X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 30 Sep 2007 11:22:25 -0000 hmm not sure this is the correct list now apologies if it isnt chris.scott wrote: > Hi > > i'm running freebsd stable (last build 28th) and am having a few > issues with 2 pci serial cards. Basically I'm trying to build a serial > server. However the driver doesn't seem to work correctly. > > Sep 28 22:18:56 boxster puc0: port > 0xce00-0xce07,0xcc00-0xcc07,0xca00-0xca07,0xc800-0xc807,0xc600-0xc607,0xc400-0xc40f > irq 9 at device 8.0 on pci0 > Sep 28 22:18:56 boxster puc1: port > 0xde00-0xde07,0xdc00-0xdc07,0xda00-0xda07,0xd800-0xd807,0xd600-0xd607,0xd400-0xd40f > irq 10 at device 11.0 on pci0 > Sep 28 22:18:56 boxster puc1: could not get resource > > > they are both 6 port serial pci cards, and are listed in the puc > driver as supported. The pc is quite old so Im not sure if whats > causing any issues. I have tried the bios with pnpos enables and > disabled but it makes little difference. I have also tried with one > card and the issue is the same. > > I have also disabled the pcs onboard serial ports and still no go > > I have disabled ACPI with hint.acpi.0.disabled="1" this seems to stop > the resource error but I dont get any additional cuad devices > > > $ pciconf -l -v | grep -B 4 UART > puc0@pci0:8:0: class=0x070002 card=0x00061000 chip=0x98459710 > rev=0x01 hdr=0x00 > vendor = 'MosChip Semiconductors (Was: Netmos Technology)' > device = 'Nm9845 Parallel/Serial Port Adapter' > class = simple comms > subclass = UART > -- > puc1@pci0:11:0: class=0x070002 card=0x00061000 chip=0x98459710 > rev=0x01 hdr=0x00 > vendor = 'MosChip Semiconductors (Was: Netmos Technology)' > device = 'Nm9845 Parallel/Serial Port Adapter' > class = simple comms > subclass = UART > > > > Any help much appreciated > > chris > From owner-freebsd-hackers@FreeBSD.ORG Sun Sep 30 15:47:23 2007 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 3339116A419 for ; Sun, 30 Sep 2007 15:47:23 +0000 (UTC) (envelope-from prvs=17937e6df8=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 C5AE713C455 for ; Sun, 30 Sep 2007 15:47:22 +0000 (UTC) (envelope-from prvs=17937e6df8=killing@multiplay.co.uk) DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=multiplay.co.uk; s=Multiplay; t=1191166209; x=1191771009; q=dns/txt; h=Received: Message-ID:From:To:Subject:Date:MIME-Version:Content-Type: Content-Transfer-Encoding; bh=U6DqQklZ12FGTBN77gSZZPAvX4RdkL+sdS CLiHJcMdE=; b=kxzm0vIJ8K4GQc38/Ie/LQf6BTE1SvtOGEG6G8SAw1AW3OGLJ+ t4SYpxpzTwiIbPUZ0A+6vNtmusvVojOymHzYc1SZd+ebh0s8sWxU+ZvlXgmPFiDJ 7zt+XUWeBD1lLo8PlyLca3hKsVEsvJfgkfTHWEEZ9iKF/E8MRIT0VmP8M= 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, 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.0) with ESMTP id md50004260558.msg for ; Sun, 30 Sep 2007 16:30:08 +0100 Message-ID: <00fe01c80376$c6adead0$b6db87d4@multiplay.co.uk> From: "Steven Hartland" To: Date: Sun, 30 Sep 2007 16:30:05 +0100 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.3138 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138 X-Authenticated-Sender: Killing@multiplay.co.uk X-MDRemoteIP: 212.135.219.182 X-Return-Path: prvs=17937e6df8=killing@multiplay.co.uk X-Envelope-From: killing@multiplay.co.uk X-MDaemon-Deliver-To: freebsd-hackers@freebsd.org X-Spam-Processed: mail1.multiplay.co.uk, Sun, 30 Sep 2007 16:30:08 +0100 X-MDAV-Processed: mail1.multiplay.co.uk, Sun, 30 Sep 2007 16:30:09 +0100 Subject: truss with -f = application 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: Sun, 30 Sep 2007 15:47:23 -0000 When trying to trace an app with truss -f to trace descendants the application will always hang. Without -f everything is fine but we dont get the decendants calls. This is when running on FreeBSD 6.2-RELEASE-p7, the application in this test is a linux app and we are running linux_base-fc-4_9. Anyone got any ideas about this? 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 Sun Sep 30 23:34:51 2007 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 4382916A4E1 for ; Sun, 30 Sep 2007 23:34:51 +0000 (UTC) (envelope-from arun.sharma@gmail.com) Received: from wa-out-1112.google.com (wa-out-1112.google.com [209.85.146.177]) by mx1.freebsd.org (Postfix) with ESMTP id 1CA4613C43E for ; Sun, 30 Sep 2007 23:34:50 +0000 (UTC) (envelope-from arun.sharma@gmail.com) Received: by wa-out-1112.google.com with SMTP id k17so4458039waf for ; Sun, 30 Sep 2007 16:34:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; 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=1WGNspKiIK4TTj6RL+x8DBz9X4fjIUs7DeV5JYKlTYc=; b=JwPCpmus+1J74uWUs2U8n2PoWnWqyHcQoQXBAvn27+pEEVWRGuM6eOaByZo0IXhS4hGUiLW3oStLJzaBiKxWRes204tNktsnqLXRabKwzTIXHSHBmFOdX7nGuNKkhAdEqs3QcpT6tx4FPUE5xO7Zqm1h4P0FeOgVZZxJFFqjslA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=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; b=gh7/BNVJSXXxlsuJbidZ73Pd1Frr6aF3OR9O45IpT6rKR5RZo5jFbVavfXOZczFQVtv5Ulo5/J5b5GSeBZS2YM9E/XyI/OjypGWuQw23irjmJbefPTZgkaAiuLRncRP6lbOKRt/jlQpXDFsPeVzZearHw1+N3W4f+0VRvbppeLA= Received: by 10.115.90.1 with SMTP id s1mr3447835wal.1191193804600; Sun, 30 Sep 2007 16:10:04 -0700 (PDT) Received: by 10.114.145.17 with HTTP; Sun, 30 Sep 2007 16:10:04 -0700 (PDT) Message-ID: Date: Sun, 30 Sep 2007 16:10:04 -0700 From: "Arun Sharma" Sender: arun.sharma@gmail.com To: "Mike Meyer" In-Reply-To: <20070929172228.36e10dc8@bhuda.mired.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20070929151437.GA35489@sharma-home.net> <20070929172228.36e10dc8@bhuda.mired.org> X-Google-Sender-Auth: 9334340cf0025986 X-Mailman-Approved-At: Mon, 01 Oct 2007 01:39:29 +0000 Cc: Arun Sharma , freebsd-hackers@freebsd.org, tbb-develop@lists.sourceforge.net, kfarnham@users.sourceforge.net Subject: Re: TBB support for 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: Sun, 30 Sep 2007 23:34:51 -0000 On 9/29/07, Mike Meyer wrote: > > Any chance of getting this packaged as a FreeBSD port, which can apply > the patch until it gets rolled into the distributed tarball? I don't > see a TBB port. I just send-pr'ed it. You can also get it from: http://www.sharma-home.net/people/arun/misc/tbb.shar -Arun From owner-freebsd-hackers@FreeBSD.ORG Mon Oct 1 04:53:49 2007 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 C87FA16A417 for ; Mon, 1 Oct 2007 04:53:49 +0000 (UTC) (envelope-from jfb@mr-happy.com) Received: from hatpro.mr-paradox.net (hatpro.mr-paradox.net [204.11.33.143]) by mx1.freebsd.org (Postfix) with ESMTP id 9BA0C13C49D for ; Mon, 1 Oct 2007 04:53:49 +0000 (UTC) (envelope-from jfb@mr-happy.com) Received: from crow.mr-happy.com (crow.mr-happy.com [10.1.0.2]) by hatpro.mr-paradox.net (Postfix) with ESMTP id 8D1F8C159; Mon, 1 Oct 2007 00:25:51 -0400 (EDT) Received: by crow.mr-happy.com (Postfix, from userid 16139) id 670835CB0; Mon, 1 Oct 2007 00:25:51 -0400 (EDT) Date: Mon, 1 Oct 2007 00:25:51 -0400 From: Jeff Blank To: freebsd-hackers@freebsd.org Message-ID: <20071001042551.GA63314@mr-happy.com> References: <20070928185042.GB73316@mr-happy.com> <46FE620F.7000809@mchsi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <46FE620F.7000809@mchsi.com> X-Face: #0jV*~a}VtKS-&E/!EJpH('H1Va}24dxF0oT&+.R3Gu8C; xhSC+<|+H84&YLbMvphuRT4cp3.|8EN_(2Eix/6{.Up~u`a^}0Ln&b+9Fw|BPig@-{y\pL_46d&ZwA]5%_AU?}DezfE&1!>H?3E$!Yve7.O<+..Jnb4:'6Ey_]FtFzU9=*l$1p/@gA,Ze>^5<]+r(XJ+m7`/vMDc$'wy|`e X-Virus-Scanned: ClamAV 0.91.1/4443/Sun Sep 30 18:16:01 2007 on hatpro.mr-paradox.net X-Virus-Status: Clean Cc: nick.thompson@comtrol.com Subject: Re: Comtrol RocketPort 550 uPCI, 16-port 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, 01 Oct 2007 04:53:49 -0000 On Sat, Sep 29, 2007 at 09:32:47AM -0500, nick thompson wrote: > Hi. First off, to get it out of the way, I work for Comtrol. This is a > Comtrol GMBH (used to be Comtrol UK, now Comtrol GMBH [Switzerland]) > product. The two are separate companies now. Anyhow, if you have had > this card for less than 30 days, I would hi,ghly recommend returning it > to the distributor for a RocketPort uPCI 16 port card, as this is a > Comtrol U.S. product and we have a 6.2 driver for our entire RocketPort > line. Thanks for the info. Is the external box with the RJ-45 serial ports (part # 99420-6) compatible with the Comtrol US card you're about to send the link for, or would I need to send that back as well? > other Unices guy in tech support at Comtrol U.S. and I would definitely > like to extend an invitation for anyone who would like a copy of the > driver to email me at my work address Does this mean that the US card is not supported by the rp driver that comes with FreeBSD 6.2, or was that mostly aimed at folks who run an OS (version) that doesn't include a driver? Thanks again, Jeff From owner-freebsd-hackers@FreeBSD.ORG Mon Oct 1 09:02:40 2007 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 C8C9F16A419 for ; Mon, 1 Oct 2007 09:02:40 +0000 (UTC) (envelope-from prvs=1794298331=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 53DE413C457 for ; Mon, 1 Oct 2007 09:02:40 +0000 (UTC) (envelope-from prvs=1794298331=killing@multiplay.co.uk) DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=multiplay.co.uk; s=Multiplay; t=1191228185; x=1191832985; q=dns/txt; h=Received: Message-ID:From:To:Subject:Date:MIME-Version:Content-Type: Content-Transfer-Encoding; bh=GflyuJoOVpy5U9YLLK2hLZqlYqEVUHJYic /luHPZQWk=; b=gl9616Jt7ZHJZw5fn4XL+XIAUL10rWOGCNZcLaw+p4hnbC2NRY IONLavRcJkxJCEKjG5VlUxOFLq7w9YgSnMMHMXtyCAa9yYH9SnICHD6M/oJCOFqz UiM8wpPD2/wVn3Ze6vTzV0UfkQTp+jjarX1bTLIfHgHNNDNXbtf/idb9M= 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, 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.0) with ESMTP id md50004262422.msg for ; Mon, 01 Oct 2007 09:43:03 +0100 Message-ID: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> From: "Steven Hartland" To: Date: Mon, 1 Oct 2007 09:43:01 +0100 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.3138 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138 X-Authenticated-Sender: Killing@multiplay.co.uk X-MDRemoteIP: 212.135.219.182 X-Return-Path: prvs=1794298331=killing@multiplay.co.uk X-Envelope-From: killing@multiplay.co.uk X-MDaemon-Deliver-To: freebsd-hackers@freebsd.org X-Spam-Processed: mail1.multiplay.co.uk, Mon, 01 Oct 2007 09:43:04 +0100 X-MDAV-Processed: mail1.multiplay.co.uk, Mon, 01 Oct 2007 09:43:05 +0100 Subject: How to enable more than 256 pty's? 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, 01 Oct 2007 09:02:40 -0000 Is it really a matter of editing: /usr/src/sys/kern/tty_pty.c And changing: static char *names = "pqrsPQRS"; To increase the number of available pty's ( FreeBSD 5.4 ) or is there a nicer way? 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 Mon Oct 1 09:22:41 2007 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 4E41E16A421 for ; Mon, 1 Oct 2007 09:22:41 +0000 (UTC) (envelope-from prvs=1794298331=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 CC5D113C43E for ; Mon, 1 Oct 2007 09:22:40 +0000 (UTC) (envelope-from prvs=1794298331=killing@multiplay.co.uk) DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=multiplay.co.uk; s=Multiplay; t=1191230506; x=1191835306; q=dns/txt; h=Received: Message-ID:From:To:References:Subject:Date:MIME-Version: Content-Type:Content-Transfer-Encoding; bh=A7N2gb+BGcAwdSqimGJ0L dnsxvQsz7Tpyv9B67yKDas=; b=a67ikTE/dbCT5plNy/ez5zvLRoEJwAX7e8gQM dN5hYD9P4nWQaP8h6J9A1SEqrBI3E38TOAto66eCq+NX4+gjNeSH8LQjJ1rXffRH oQBeZ1LB5Jl42pfIeZ8T1z2Aqpmkz7RKB3QnND/WPdf8IAB0w47+dJ0JT1g9uC/B vFfL40= 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, 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.0) with ESMTP id md50004263286.msg for ; Mon, 01 Oct 2007 10:21:45 +0100 Message-ID: <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> From: "Steven Hartland" To: "Steven Hartland" , References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> Date: Mon, 1 Oct 2007 10:21:44 +0100 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=response Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.3138 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138 X-Authenticated-Sender: Killing@multiplay.co.uk X-MDRemoteIP: 212.135.219.182 X-Return-Path: prvs=1794298331=killing@multiplay.co.uk X-Envelope-From: killing@multiplay.co.uk X-MDaemon-Deliver-To: freebsd-hackers@freebsd.org X-Spam-Processed: mail1.multiplay.co.uk, Mon, 01 Oct 2007 10:21:45 +0100 X-MDAV-Processed: mail1.multiplay.co.uk, Mon, 01 Oct 2007 10:21:46 +0100 Cc: Subject: Re: How to enable more than 256 pty's? 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, 01 Oct 2007 09:22:41 -0000 Well looked like that might work but clearly not, should have looked closer. Is there a way to do this? Regards Steve ----- Original Message ----- > Is it really a matter of editing: > /usr/src/sys/kern/tty_pty.c > > And changing: > static char *names = "pqrsPQRS"; > > To increase the number of available pty's ( FreeBSD 5.4 ) or is there > a nicer way? > > 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. > > _______________________________________________ > 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" > ================================================ 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 Mon Oct 1 19:33:24 2007 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 76FCE16A417; Mon, 1 Oct 2007 19:33:24 +0000 (UTC) (envelope-from so14k@valentine.liquidneon.com) Received: from valentine.liquidneon.com (valentine.liquidneon.com [216.87.78.132]) by mx1.freebsd.org (Postfix) with ESMTP id 6E62C13C4B2; Mon, 1 Oct 2007 19:33:24 +0000 (UTC) (envelope-from so14k@valentine.liquidneon.com) Received: by valentine.liquidneon.com (Postfix, from userid 1018) id B3A378FD38; Mon, 1 Oct 2007 13:15:49 -0600 (MDT) Date: Mon, 1 Oct 2007 13:15:49 -0600 From: Brad Davis To: freebsd-hackers@FreeBSD.org Message-ID: <20071001191549.GE26700@valentine.liquidneon.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.3i Cc: freebsd-current@FreeBSD.org Subject: FreeBSD status reports due: Oct 6th, 2007 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, 01 Oct 2007 19:33:24 -0000 Hi Everyone, It is that time again. We would like to remind everybody who has exciting news to share to write a report about their project. This is a good way to improve exposure of your work, receive feedback and help. As we are closing in on 7.0 everybody is interested to know what's new - so please, do tell! Looking forward to your reports. As always you can either use the template or the generator CGI and mail the result to monthly@ by 2007/10/06. http://www.freebsd.org/news/status/ http://www.freebsd.org/cgi/monthly.cgi http://www.freebsd.org/news/status/report-sample.xml Regards, Brad Davis From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 11:34:17 2007 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 837C216A419; Tue, 2 Oct 2007 11:34:17 +0000 (UTC) (envelope-from prvs=17958a6d43=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 DB54D13C45B; Tue, 2 Oct 2007 11:34:16 +0000 (UTC) (envelope-from prvs=17958a6d43=killing@multiplay.co.uk) DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=multiplay.co.uk; s=Multiplay; t=1191323901; x=1191928701; q=dns/txt; h=Received: Message-ID:From:To:References:Subject:Date:MIME-Version: Content-Type:Content-Transfer-Encoding; bh=0rQQyLijNzCsIQvyP7m1x ciGfpnuCnwa9xdRtiXlJtI=; b=KmVmq7V4Cn3Z1Tu/0Fo3RD9UYYTc9iXYfdUyB TyhHEvcUwHfBYnuNXHP4n+si1UExw08m+nFno4c/gptMae/b5CcNpioNPaQuYKS/ Mt3cnZM639WTV8/7NTRjHbLKo8Z77/sFhyBs8uQAMsY2fG+Wi5iEYAmOzJnrhbAh 6X/plA= 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, 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.2) with ESMTP id md50004268080.msg; Tue, 02 Oct 2007 12:18:20 +0100 Message-ID: <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> From: "Steven Hartland" To: , References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> Date: Tue, 2 Oct 2007 12:18:19 +0100 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=response Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.3138 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138 X-Authenticated-Sender: Killing@multiplay.co.uk X-MDRemoteIP: 212.135.219.182 X-Return-Path: prvs=17958a6d43=killing@multiplay.co.uk X-Envelope-From: killing@multiplay.co.uk X-Spam-Processed: mail1.multiplay.co.uk, Tue, 02 Oct 2007 12:18:20 +0100 X-MDAV-Processed: mail1.multiplay.co.uk, Tue, 02 Oct 2007 12:18:21 +0100 Cc: Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 11:34:17 -0000 Any one got any pointers on this, the machine we running this app on is over 90% idle so I really don't want to have to install a second machine just to workaround a limit on the number of pty's, surely there's a way to increase this? 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 Tue Oct 2 12:05:14 2007 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 1980516A418 for ; Tue, 2 Oct 2007 12:05:14 +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 B550613C448 for ; Tue, 2 Oct 2007 12:05:13 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (localhost [127.0.0.1]) by spam.des.no (Postfix) with ESMTP id 2E0422091; Tue, 2 Oct 2007 14:05:04 +0200 (CEST) X-Spam-Tests: AWL X-Spam-Learn: disabled X-Spam-Score: 0.0/3.0 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on tim.des.no Received: from ds4.des.no (des.no [80.203.243.180]) by smtp.des.no (Postfix) with ESMTP id 111C0208E; Tue, 2 Oct 2007 14:05:04 +0200 (CEST) Received: by ds4.des.no (Postfix, from userid 1001) id EC26D844A1; Tue, 2 Oct 2007 14:05:03 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: "Steven Hartland" References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> Date: Tue, 02 Oct 2007 14:05:03 +0200 In-Reply-To: <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> (Steven Hartland's message of "Tue\, 2 Oct 2007 12\:18\:19 +0100") Message-ID: <86abr1yb68.fsf@ds4.des.no> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org, freebsd-stable@freebsd.org Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:05:14 -0000 "Steven Hartland" writes: > Any one got any pointers on this, the machine we running this app on is o= ver > 90% idle so I really don't want to have to install a second machine just = to > workaround a limit on the number of pty's, surely there's a way to increa= se > this? You need to change the way ptys are named in pty_create_slave() and pty_clone() in sys/kern/tty_pty.c. Just changing names won't help as the sequence is also hardcoded in pty_clone(). You also need to change grantpt(), openpty() and any other userland code which has hardcoded knowledge of the naming scheme: des@ds4 ~% gfs pqrsPQRS src/sys/kern/tty_pty.c: static char *names =3D "pqrsPQRS"; src/sys/kern/tty_pty.c: * pts =3D=3D /dev/tty[pqrsPQRS][0123456789abcdefgh= ijklmnopqrstuv] src/sys/kern/tty_pty.c: * ptc =3D=3D /dev/pty[pqrsPQRS][0123456789abcdefgh= ijklmnopqrstuv] src/contrib/telnet/telnetd/sys_term.c: for (cp =3D "pqrsPQRS"; *cp; cp++) { src/usr.sbin/ac/ac.c: strchr("pqrsPQRS", usr.= ut_line[3]) !=3D 0 || src/lib/libutil/pty.c: for (cp1 =3D "pqrsPQRS"; *cp1; cp1++) { src/lib/libc/stdlib/grantpt.c: #define PT_DEV1 "pqrsPQRS" Alternatively, set kern.pts.enable to 1, and find and fix the hang-on-close bug in the pts code (if it hasn't been fixed already) DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:09:49 2007 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 49A2716A418 for ; Tue, 2 Oct 2007 12:09:49 +0000 (UTC) (envelope-from erikt@midgard.homeip.net) Received: from ch-smtp01.sth.basefarm.net (ch-smtp01.sth.basefarm.net [80.76.149.212]) by mx1.freebsd.org (Postfix) with ESMTP id BB38A13C458 for ; Tue, 2 Oct 2007 12:09:48 +0000 (UTC) (envelope-from erikt@midgard.homeip.net) Received: from c83-253-31-60.bredband.comhem.se ([83.253.31.60]:52415 helo=falcon.midgard.homeip.net) by ch-smtp01.sth.basefarm.net with esmtp (Exim 4.66) (envelope-from ) id 1IcgZP-0003Cd-5R for freebsd-hackers@freebsd.org; Tue, 02 Oct 2007 14:09:48 +0200 Received: (qmail 30290 invoked from network); 2 Oct 2007 14:09:44 +0200 Received: from owl.midgard.homeip.net (10.1.5.7) by falcon.midgard.homeip.net with ESMTP; 2 Oct 2007 14:09:44 +0200 Received: (qmail 33374 invoked by uid 1001); 2 Oct 2007 14:09:44 +0200 Date: Tue, 2 Oct 2007 14:09:44 +0200 From: Erik Trulsson To: Dag-Erling =?iso-8859-1?Q?Sm=F8rgrav?= Message-ID: <20071002120944.GA33356@owl.midgard.homeip.net> Mail-Followup-To: Dag-Erling =?iso-8859-1?Q?Sm=F8rgrav?= , Steven Hartland , freebsd-hackers@freebsd.org, freebsd-stable@freebsd.org References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable In-Reply-To: <86abr1yb68.fsf@ds4.des.no> User-Agent: Mutt/1.5.16 (2007-06-09) X-Originating-IP: 83.253.31.60 X-Scan-Result: No virus found in message 1IcgZP-0003Cd-5R. X-Scan-Signature: ch-smtp01.sth.basefarm.net 1IcgZP-0003Cd-5R 6be146b8bab4f705f4bb441bb99c4c07 Cc: freebsd-hackers@freebsd.org, Steven Hartland , freebsd-stable@freebsd.org Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:09:49 -0000 On Tue, Oct 02, 2007 at 02:05:03PM +0200, Dag-Erling Sm=F8rgrav wrote: > "Steven Hartland" writes: > > Any one got any pointers on this, the machine we running this app on is= over > > 90% idle so I really don't want to have to install a second machine jus= t to > > workaround a limit on the number of pty's, surely there's a way to incr= ease > > this? >=20 > You need to change the way ptys are named in pty_create_slave() and > pty_clone() in sys/kern/tty_pty.c. Just changing names won't help as > the sequence is also hardcoded in pty_clone(). >=20 > You also need to change grantpt(), openpty() and any other userland code > which has hardcoded knowledge of the naming scheme: >=20 > des@ds4 ~% gfs pqrsPQRS > src/sys/kern/tty_pty.c: static char *names =3D "pqrsPQRS"; > src/sys/kern/tty_pty.c: * pts =3D=3D /dev/tty[pqrsPQRS][0123456789abcdef= ghijklmnopqrstuv] > src/sys/kern/tty_pty.c: * ptc =3D=3D /dev/pty[pqrsPQRS][0123456789abcdef= ghijklmnopqrstuv] > src/contrib/telnet/telnetd/sys_term.c: for (cp =3D "pqrsPQRS"; *cp; cp++= ) { > src/usr.sbin/ac/ac.c: strchr("pqrsPQRS", us= r.ut_line[3]) !=3D 0 || > src/lib/libutil/pty.c: for (cp1 =3D "pqrsPQRS"; *cp1; cp1++) { > src/lib/libc/stdlib/grantpt.c: #define PT_DEV1 "pqrsPQRS" >=20 > Alternatively, set kern.pts.enable to 1, and find and fix the > hang-on-close bug in the pts code (if it hasn't been fixed already) This last option is only available if you are running 7-CURRENT though. The pts code is not in 6-STABLE (or older.) --=20 Erik Trulsson ertr1013@student.uu.se From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:16:31 2007 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 7107716A41A; Tue, 2 Oct 2007 12:16:31 +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 1AF3C13C468; Tue, 2 Oct 2007 12:16:31 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (localhost [127.0.0.1]) by spam.des.no (Postfix) with ESMTP id B4D2A2082; Tue, 2 Oct 2007 14:16:23 +0200 (CEST) X-Spam-Tests: AWL X-Spam-Learn: disabled X-Spam-Score: 0.0/3.0 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on tim.des.no Received: from ds4.des.no (des.no [80.203.243.180]) by smtp.des.no (Postfix) with ESMTP id 9BFA42049; Tue, 2 Oct 2007 14:16:23 +0200 (CEST) Received: by ds4.des.no (Postfix, from userid 1001) id 86155844A1; Tue, 2 Oct 2007 14:16:23 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: "Vlad GALU" References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> Date: Tue, 02 Oct 2007 14:16:23 +0200 In-Reply-To: (Vlad GALU's message of "Tue\, 2 Oct 2007 15\:14\:18 +0300") Message-ID: <86641pyanc.fsf@ds4.des.no> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org, Steven Hartland , freebsd-stable@freebsd.org Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:16:31 -0000 Vlad GALU writes: > Dag-Erling Sm=C3=B8rgrav writes: > > Alternatively, set kern.pts.enable to 1, and find and fix the > > hang-on-close bug in the pts code (if it hasn't been fixed already) > Looks like it hasn't been. A friend who tried to set up an access > server for his company stumbled upon it. kib@ says it has as of sys/kern/tty_pts.c rev 1.15 (2007-07-03). Has your friend tried with a sufficiently recent kernel? DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:26:01 2007 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 0DAC916A41B for ; Tue, 2 Oct 2007 12:26:01 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: from fk-out-0910.google.com (fk-out-0910.google.com [209.85.128.188]) by mx1.freebsd.org (Postfix) with ESMTP id 8D2AA13C45D for ; Tue, 2 Oct 2007 12:26:00 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: by fk-out-0910.google.com with SMTP id b27so4972339fka for ; Tue, 02 Oct 2007 05:25:59 -0700 (PDT) Received: by 10.82.119.17 with SMTP id r17mr8163831buc.1191327543651; Tue, 02 Oct 2007 05:19:03 -0700 (PDT) Received: by 10.82.148.14 with HTTP; Tue, 2 Oct 2007 05:19:03 -0700 (PDT) Message-ID: Date: Tue, 2 Oct 2007 15:19:03 +0300 From: "Vlad GALU" To: "=?ISO-8859-1?Q?Dag-Erling_Sm=F8rgrav?=" In-Reply-To: <86641pyanc.fsf@ds4.des.no> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> Cc: freebsd-hackers@freebsd.org, Steven Hartland , freebsd-stable@freebsd.org Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:26:01 -0000 On 10/2/07, Dag-Erling Sm=F8rgrav wrote: > Vlad GALU writes: > > Dag-Erling Sm=F8rgrav writes: > > > Alternatively, set kern.pts.enable to 1, and find and fix the > > > hang-on-close bug in the pts code (if it hasn't been fixed already) > > Looks like it hasn't been. A friend who tried to set up an access > > server for his company stumbled upon it. > > kib@ says it has as of sys/kern/tty_pts.c rev 1.15 (2007-07-03). Has > your friend tried with a sufficiently recent kernel? I can't tell for sure, he tried a week or two ago, with a recent snapshot. I forwarded him your mail, I hope he'll retry and get back to me. > > DES > -- > Dag-Erling Sm=F8rgrav - des@des.no > --=20 If it's there, and you can see it, it's real. If it's not there, and you can see it, it's virtual. If it's there, and you can't see it, it's transparent. If it's not there, and you can't see it, you erased it. From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:37:31 2007 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 36DE916A46C for ; Tue, 2 Oct 2007 12:37:31 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: from mu-out-0910.google.com (mu-out-0910.google.com [209.85.134.185]) by mx1.freebsd.org (Postfix) with ESMTP id 7D03713C494 for ; Tue, 2 Oct 2007 12:37:30 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: by mu-out-0910.google.com with SMTP id w9so5138667mue for ; Tue, 02 Oct 2007 05:37:29 -0700 (PDT) Received: by 10.82.134.12 with SMTP id h12mr4205426bud.1191328648748; Tue, 02 Oct 2007 05:37:28 -0700 (PDT) Received: by 10.82.148.14 with HTTP; Tue, 2 Oct 2007 05:37:28 -0700 (PDT) Message-ID: Date: Tue, 2 Oct 2007 15:37:28 +0300 From: "Vlad GALU" To: "=?ISO-8859-1?Q?Dag-Erling_Sm=F8rgrav?=" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> Cc: freebsd-hackers@freebsd.org, Steven Hartland , freebsd-stable@freebsd.org, gepu@flow.rdsnet.ro Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:37:31 -0000 On 10/2/07, Vlad GALU wrote: > On 10/2/07, Dag-Erling Sm=F8rgrav wrote: > > Vlad GALU writes: > > > Dag-Erling Sm=F8rgrav writes: > > > > Alternatively, set kern.pts.enable to 1, and find and fix the > > > > hang-on-close bug in the pts code (if it hasn't been fixed already) > > > Looks like it hasn't been. A friend who tried to set up an access > > > server for his company stumbled upon it. > > > > kib@ says it has as of sys/kern/tty_pts.c rev 1.15 (2007-07-03). Has > > your friend tried with a sufficiently recent kernel? > > I can't tell for sure, he tried a week or two ago, with a recent > snapshot. I forwarded him your mail, I hope he'll retry and get back > to me. > The symptoms were exhibited even with rev. 1.16. I've CC'ed him so he can catch up with the thread. > > > > DES > > -- > > Dag-Erling Sm=F8rgrav - des@des.no > > > > > -- > If it's there, and you can see it, it's real. > If it's not there, and you can see it, it's virtual. > If it's there, and you can't see it, it's transparent. > If it's not there, and you can't see it, you erased it. > --=20 If it's there, and you can see it, it's real. If it's not there, and you can see it, it's virtual. If it's there, and you can't see it, it's transparent. If it's not there, and you can't see it, you erased it. From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:39:06 2007 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 CFC2816A41B for ; Tue, 2 Oct 2007 12:39:06 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: from fk-out-0910.google.com (fk-out-0910.google.com [209.85.128.186]) by mx1.freebsd.org (Postfix) with ESMTP id 8C3F313C474 for ; Tue, 2 Oct 2007 12:39:05 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: by fk-out-0910.google.com with SMTP id b27so4976045fka for ; Tue, 02 Oct 2007 05:39:04 -0700 (PDT) Received: by 10.82.177.3 with SMTP id z3mr12023300bue.1191327258053; Tue, 02 Oct 2007 05:14:18 -0700 (PDT) Received: by 10.82.148.14 with HTTP; Tue, 2 Oct 2007 05:14:18 -0700 (PDT) Message-ID: Date: Tue, 2 Oct 2007 15:14:18 +0300 From: "Vlad GALU" To: "=?ISO-8859-1?Q?Dag-Erling_Sm=F8rgrav?=" In-Reply-To: <86abr1yb68.fsf@ds4.des.no> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> Cc: freebsd-hackers@freebsd.org, Steven Hartland , freebsd-stable@freebsd.org Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:39:06 -0000 On 10/2/07, Dag-Erling Sm=F8rgrav wrote: > "Steven Hartland" writes: > > Any one got any pointers on this, the machine we running this app on is= over > > 90% idle so I really don't want to have to install a second machine jus= t to > > workaround a limit on the number of pty's, surely there's a way to incr= ease > > this? > > You need to change the way ptys are named in pty_create_slave() and > pty_clone() in sys/kern/tty_pty.c. Just changing names won't help as > the sequence is also hardcoded in pty_clone(). > > You also need to change grantpt(), openpty() and any other userland code > which has hardcoded knowledge of the naming scheme: > > des@ds4 ~% gfs pqrsPQRS > src/sys/kern/tty_pty.c: static char *names =3D "pqrsPQRS"; > src/sys/kern/tty_pty.c: * pts =3D=3D /dev/tty[pqrsPQRS][0123456789abcdef= ghijklmnopqrstuv] > src/sys/kern/tty_pty.c: * ptc =3D=3D /dev/pty[pqrsPQRS][0123456789abcdef= ghijklmnopqrstuv] > src/contrib/telnet/telnetd/sys_term.c: for (cp =3D "pqrsPQRS"; *cp; cp++= ) { > src/usr.sbin/ac/ac.c: strchr("pqrsPQRS", us= r.ut_line[3]) !=3D 0 || > src/lib/libutil/pty.c: for (cp1 =3D "pqrsPQRS"; *cp1; cp1++) { > src/lib/libc/stdlib/grantpt.c: #define PT_DEV1 "pqrsPQRS" > > Alternatively, set kern.pts.enable to 1, and find and fix the > hang-on-close bug in the pts code (if it hasn't been fixed already) Looks like it hasn't been. A friend who tried to set up an access server for his company stumbled upon it. > > DES > -- > Dag-Erling Sm=F8rgrav - des@des.no > _______________________________________________ > 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= " > --=20 If it's there, and you can see it, it's real. If it's not there, and you can see it, it's virtual. If it's there, and you can't see it, it's transparent. If it's not there, and you can't see it, you erased it. From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:40:25 2007 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 9A09B16A41B; Tue, 2 Oct 2007 12:40:25 +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 44ED213C474; Tue, 2 Oct 2007 12:40:25 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (localhost [127.0.0.1]) by spam.des.no (Postfix) with ESMTP id 801782099; Tue, 2 Oct 2007 14:40:17 +0200 (CEST) X-Spam-Tests: AWL X-Spam-Learn: disabled X-Spam-Score: 0.0/3.0 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on tim.des.no Received: from ds4.des.no (des.no [80.203.243.180]) by smtp.des.no (Postfix) with ESMTP id F0D9D2093; Tue, 2 Oct 2007 14:40:16 +0200 (CEST) Received: by ds4.des.no (Postfix, from userid 1001) id DCA84844A4; Tue, 2 Oct 2007 14:40:16 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: "Vlad GALU" References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> Date: Tue, 02 Oct 2007 14:40:16 +0200 In-Reply-To: (Vlad GALU's message of "Tue\, 2 Oct 2007 15\:37\:28 +0300") Message-ID: <86wsu5wuz3.fsf@ds4.des.no> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org, Steven Hartland , freebsd-stable@freebsd.org, gepu@flow.rdsnet.ro Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:40:25 -0000 "Vlad GALU" writes: > The symptoms were exhibited even with rev. 1.16. I've CC'ed him so > he can catch up with the thread. Which symptoms? I can no longer reproduce the hang-on-close bug. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:41:41 2007 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 67E5516A41A for ; Tue, 2 Oct 2007 12:41:41 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: from fk-out-0910.google.com (fk-out-0910.google.com [209.85.128.190]) by mx1.freebsd.org (Postfix) with ESMTP id E061B13C480 for ; Tue, 2 Oct 2007 12:41:40 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: by fk-out-0910.google.com with SMTP id b27so4976801fka for ; Tue, 02 Oct 2007 05:41:40 -0700 (PDT) Received: by 10.82.138.6 with SMTP id l6mr9562350bud.1191328899591; Tue, 02 Oct 2007 05:41:39 -0700 (PDT) Received: by 10.82.148.14 with HTTP; Tue, 2 Oct 2007 05:41:39 -0700 (PDT) Message-ID: Date: Tue, 2 Oct 2007 15:41:39 +0300 From: "Vlad GALU" To: "=?ISO-8859-1?Q?Dag-Erling_Sm=F8rgrav?=" In-Reply-To: <86wsu5wuz3.fsf@ds4.des.no> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> <86wsu5wuz3.fsf@ds4.des.no> Cc: freebsd-hackers@freebsd.org, Steven Hartland , freebsd-stable@freebsd.org, gepu@flow.rdsnet.ro Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:41:41 -0000 On 10/2/07, Dag-Erling Sm=F8rgrav wrote: > "Vlad GALU" writes: > > The symptoms were exhibited even with rev. 1.16. I've CC'ed him so > > he can catch up with the thread. > > Which symptoms? I can no longer reproduce the hang-on-close bug. Strangely enough, me neither. In his case, allocated pts' wouldn't get deallocated once the sessions ended. > > DES > -- > Dag-Erling Sm=F8rgrav - des@des.no > --=20 If it's there, and you can see it, it's real. If it's not there, and you can see it, it's virtual. If it's there, and you can't see it, it's transparent. If it's not there, and you can't see it, you erased it. From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:52:27 2007 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 6D8FD16A46B; Tue, 2 Oct 2007 12:52:27 +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 160E113C448; Tue, 2 Oct 2007 12:52:27 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (localhost [127.0.0.1]) by spam.des.no (Postfix) with ESMTP id A17872082; Tue, 2 Oct 2007 14:52:18 +0200 (CEST) X-Spam-Tests: AWL X-Spam-Learn: disabled X-Spam-Score: 0.0/3.0 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on tim.des.no Received: from ds4.des.no (des.no [80.203.243.180]) by smtp.des.no (Postfix) with ESMTP id 8C0502089; Tue, 2 Oct 2007 14:52:18 +0200 (CEST) Received: by ds4.des.no (Postfix, from userid 1001) id 73101844A4; Tue, 2 Oct 2007 14:52:18 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: "Vlad GALU" References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> <86wsu5wuz3.fsf@ds4.des.no> Date: Tue, 02 Oct 2007 14:52:18 +0200 In-Reply-To: (Vlad GALU's message of "Tue\, 2 Oct 2007 15\:41\:39 +0300") Message-ID: <86sl4twuf1.fsf@ds4.des.no> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org, Steven Hartland , freebsd-stable@freebsd.org, gepu@flow.rdsnet.ro Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:52:27 -0000 "Vlad GALU" writes: > Dag-Erling Sm=C3=B8rgrav writes: > > "Vlad GALU" writes: > > > The symptoms were exhibited even with rev. 1.16. I've CC'ed him so > > > he can catch up with the thread. > > Which symptoms? I can no longer reproduce the hang-on-close bug. > Strangely enough, me neither. In his case, allocated pts' wouldn't get > deallocated once the sessions ended. Wouldn't get deallocated right away, or wouldn't get deallocated at all? Apparently, it is not unusual for pts reclamation to be delayed a bit by a non-zero refcnt. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:56:35 2007 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 700DA16A501 for ; Tue, 2 Oct 2007 12:56:35 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: from mu-out-0910.google.com (mu-out-0910.google.com [209.85.134.191]) by mx1.freebsd.org (Postfix) with ESMTP id B419913C53C for ; Tue, 2 Oct 2007 12:56:27 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: by mu-out-0910.google.com with SMTP id w9so5145297mue for ; Tue, 02 Oct 2007 05:56:26 -0700 (PDT) Received: by 10.82.181.10 with SMTP id d10mr14707884buf.1191329785031; Tue, 02 Oct 2007 05:56:25 -0700 (PDT) Received: by 10.82.148.14 with HTTP; Tue, 2 Oct 2007 05:56:24 -0700 (PDT) Message-ID: Date: Tue, 2 Oct 2007 15:56:24 +0300 From: "Vlad GALU" To: "=?ISO-8859-1?Q?Dag-Erling_Sm=F8rgrav?=" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> <86wsu5wuz3.fsf@ds4.des.no> Cc: freebsd-hackers@freebsd.org, Steven Hartland , freebsd-stable@freebsd.org, gepu@flow.rdsnet.ro Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:56:35 -0000 On 10/2/07, Vlad GALU wrote: > On 10/2/07, Dag-Erling Sm=F8rgrav wrote: > > "Vlad GALU" writes: > > > The symptoms were exhibited even with rev. 1.16. I've CC'ed him so > > > he can catch up with the thread. > > > > Which symptoms? I can no longer reproduce the hang-on-close bug. > > Strangely enough, me neither. In his case, allocated pts' wouldn't > get deallocated once the sessions ended. > > However, I see that, if I use pts/0-7, for instance, then log off pts/7, the next assigned pts will be pts/8. Is this expected? I tried lowering kern.pts.max to 20. If I open 20 of them and close them afterwards, on the next try I get "no more ptys" from my screen. > > DES > > -- > > Dag-Erling Sm=F8rgrav - des@des.no > > > > > -- > If it's there, and you can see it, it's real. > If it's not there, and you can see it, it's virtual. > If it's there, and you can't see it, it's transparent. > If it's not there, and you can't see it, you erased it. > --=20 If it's there, and you can see it, it's real. If it's not there, and you can see it, it's virtual. If it's there, and you can't see it, it's transparent. If it's not there, and you can't see it, you erased it. From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:57:05 2007 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 1959816A46E; Tue, 2 Oct 2007 12:57:05 +0000 (UTC) (envelope-from ed@hoeg.nl) Received: from palm.hoeg.nl (mx0.hoeg.nl [IPv6:2001:610:652::211]) by mx1.freebsd.org (Postfix) with ESMTP id B911B13C4B6; Tue, 2 Oct 2007 12:57:04 +0000 (UTC) (envelope-from ed@hoeg.nl) Received: by palm.hoeg.nl (Postfix, from userid 1000) id 36A1D1CC0D; Tue, 2 Oct 2007 14:57:02 +0200 (CEST) Date: Tue, 2 Oct 2007 14:57:02 +0200 From: Ed Schouten To: Vlad GALU Message-ID: <20071002125702.GQ12364@hoeg.nl> References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> <86wsu5wuz3.fsf@ds4.des.no> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="kkcDP0v44wDpNmbp" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.16 (2007-06-09) Cc: Dag-Erling =?iso-8859-1?Q?Sm=F8rgrav?= , gepu@flow.rdsnet.ro, Steven Hartland , freebsd-stable@freebsd.org, FreeBSD Hackers Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:57:05 -0000 --kkcDP0v44wDpNmbp Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable * Vlad GALU wrote: > On 10/2/07, Dag-Erling Sm=F8rgrav wrote: > > "Vlad GALU" writes: > > > The symptoms were exhibited even with rev. 1.16. I've CC'ed him so > > > he can catch up with the thread. > > > > Which symptoms? I can no longer reproduce the hang-on-close bug. >=20 > Strangely enough, me neither. In his case, allocated pts' wouldn't > get deallocated once the sessions ended. This is a known issue IIRC. See line 245 of tty_pts.c 1.16. Can be easily reproduced by killing the sshd while apps are still running in the shell. I thought we weren't able to destroy the device there, because you can't destroy a TTY when it is used by an application (i.e. when it's the controlling terminal). --=20 Ed Schouten WWW: http://g-rave.nl/ --kkcDP0v44wDpNmbp Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (FreeBSD) iD8DBQFHAkAe52SDGA2eCwURAhalAJ0ajoMl6IaEP1+71iPYXuAC7hsnBQCfVlwN CJwNl5i3+BsJ9BIP8KeLDaw= =5tlY -----END PGP SIGNATURE----- --kkcDP0v44wDpNmbp-- From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 12:58:52 2007 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 68EB716A468 for ; Tue, 2 Oct 2007 12:58:52 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: from mu-out-0910.google.com (mu-out-0910.google.com [209.85.134.185]) by mx1.freebsd.org (Postfix) with ESMTP id E543613C4B0 for ; Tue, 2 Oct 2007 12:58:51 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: by mu-out-0910.google.com with SMTP id w9so5146169mue for ; Tue, 02 Oct 2007 05:58:50 -0700 (PDT) Received: by 10.82.111.8 with SMTP id j8mr7558730buc.1191329930215; Tue, 02 Oct 2007 05:58:50 -0700 (PDT) Received: by 10.82.148.14 with HTTP; Tue, 2 Oct 2007 05:58:49 -0700 (PDT) Message-ID: Date: Tue, 2 Oct 2007 15:58:49 +0300 From: "Vlad GALU" To: "=?ISO-8859-1?Q?Dag-Erling_Sm=F8rgrav?=" In-Reply-To: <86sl4twuf1.fsf@ds4.des.no> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> <86wsu5wuz3.fsf@ds4.des.no> <86sl4twuf1.fsf@ds4.des.no> Cc: freebsd-hackers@freebsd.org, Steven Hartland , freebsd-stable@freebsd.org, gepu@flow.rdsnet.ro Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 12:58:52 -0000 On 10/2/07, Dag-Erling Sm=F8rgrav wrote: > "Vlad GALU" writes: > > Dag-Erling Sm=F8rgrav writes: > > > "Vlad GALU" writes: > > > > The symptoms were exhibited even with rev. 1.16. I've CC'ed him so > > > > he can catch up with the thread. > > > Which symptoms? I can no longer reproduce the hang-on-close bug. > > Strangely enough, me neither. In his case, allocated pts' wouldn't get > > deallocated once the sessions ended. > > Wouldn't get deallocated right away, or wouldn't get deallocated at all? > Apparently, it is not unusual for pts reclamation to be delayed a bit by > a non-zero refcnt. > As per my other mail, they wouldn't get deallocated at all. They still show up in /dev/pts/ even after closing, and the next integer index is picked up upon the next terminal creation. > DES > -- > Dag-Erling Sm=F8rgrav - des@des.no > --=20 If it's there, and you can see it, it's real. If it's not there, and you can see it, it's virtual. If it's there, and you can't see it, it's transparent. If it's not there, and you can't see it, you erased it. From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 13:02:26 2007 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 5F3CF16A418; Tue, 2 Oct 2007 13:02:26 +0000 (UTC) (envelope-from ed@hoeg.nl) Received: from palm.hoeg.nl (mx0.hoeg.nl [IPv6:2001:610:652::211]) by mx1.freebsd.org (Postfix) with ESMTP id 0FD8713C45D; Tue, 2 Oct 2007 13:02:26 +0000 (UTC) (envelope-from ed@hoeg.nl) Received: by palm.hoeg.nl (Postfix, from userid 1000) id 6FE6B1CC37; Tue, 2 Oct 2007 15:02:25 +0200 (CEST) Date: Tue, 2 Oct 2007 15:02:25 +0200 From: Ed Schouten To: Vlad GALU Message-ID: <20071002130225.GR12364@hoeg.nl> References: <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> <86wsu5wuz3.fsf@ds4.des.no> <20071002125702.GQ12364@hoeg.nl> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="8CNmCRe8Sh4keFKJ" Content-Disposition: inline In-Reply-To: <20071002125702.GQ12364@hoeg.nl> User-Agent: Mutt/1.5.16 (2007-06-09) Cc: Dag-Erling =?iso-8859-1?Q?Sm=F8rgrav?= , FreeBSD Hackers , Steven Hartland , freebsd-stable@freebsd.org, gepu@flow.rdsnet.ro Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 13:02:26 -0000 --8CNmCRe8Sh4keFKJ Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable * Ed Schouten wrote: > * Vlad GALU wrote: > > On 10/2/07, Dag-Erling Sm=F8rgrav wrote: > > > "Vlad GALU" writes: > > > > The symptoms were exhibited even with rev. 1.16. I've CC'ed him so > > > > he can catch up with the thread. > > > > > > Which symptoms? I can no longer reproduce the hang-on-close bug. > >=20 > > Strangely enough, me neither. In his case, allocated pts' wouldn't > > get deallocated once the sessions ended. >=20 > This is a known issue IIRC. See line 245 of tty_pts.c 1.16. Can be > easily reproduced by killing the sshd while apps are still running in > the shell. >=20 > I thought we weren't able to destroy the device there, because you can't > destroy a TTY when it is used by an application (i.e. when it's the > controlling terminal). Thought about this 2 seconds after I sent my message: this is also responsible for the `zombie jails': tty's are made with make_dev_cred, which causes ucred's to be leaked, which eventually causes prisons to be leaked. --=20 Ed Schouten WWW: http://g-rave.nl/ --8CNmCRe8Sh4keFKJ Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (FreeBSD) iD8DBQFHAkFh52SDGA2eCwURAo5gAJ9hrgjycx8KCSDaMMCAYWO9TAFoaQCggExV nLwhxxIHRHwW/UNjLqqKHKI= =8+HJ -----END PGP SIGNATURE----- --8CNmCRe8Sh4keFKJ-- From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 13:19:57 2007 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 B8D0116A41A; Tue, 2 Oct 2007 13:19:57 +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 5FD8313C457; Tue, 2 Oct 2007 13:19:57 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (localhost [127.0.0.1]) by spam.des.no (Postfix) with ESMTP id 929C72084; Tue, 2 Oct 2007 15:19:48 +0200 (CEST) X-Spam-Tests: AWL X-Spam-Learn: disabled X-Spam-Score: -0.0/3.0 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on tim.des.no Received: from ds4.des.no (des.no [80.203.243.180]) by smtp.des.no (Postfix) with ESMTP id 7DE4D2049; Tue, 2 Oct 2007 15:19:48 +0200 (CEST) Received: by ds4.des.no (Postfix, from userid 1001) id 68ACC844A8; Tue, 2 Oct 2007 15:19:48 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Ed Schouten References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> <86wsu5wuz3.fsf@ds4.des.no> <20071002125702.GQ12364@hoeg.nl> Date: Tue, 02 Oct 2007 15:19:48 +0200 In-Reply-To: <20071002125702.GQ12364@hoeg.nl> (Ed Schouten's message of "Tue\, 2 Oct 2007 14\:57\:02 +0200") Message-ID: <86odfhwt57.fsf@ds4.des.no> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: FreeBSD Hackers , Vlad GALU , Steven Hartland , freebsd-stable@freebsd.org, gepu@flow.rdsnet.ro Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 13:19:57 -0000 Ed Schouten writes: > This is a known issue IIRC. See line 245 of tty_pts.c 1.16. Can be > easily reproduced by killing the sshd while apps are still running in > the shell. It's not that simple. The question is why t_refcnt > 1 when there are no processes left attached to the tty. I managed to reproduce this as follows: $ script -q 1 script -q 2 script -q 3 script -q 4 tty if nothing else is going on at the same time, you should always see the same output, but instead you see a steadily increasing pts number. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Tue Oct 2 15:34:27 2007 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 1B6A716A41B; Tue, 2 Oct 2007 15:34:27 +0000 (UTC) (envelope-from prvs=17958a6d43=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 69C8A13C4B5; Tue, 2 Oct 2007 15:34:25 +0000 (UTC) (envelope-from prvs=17958a6d43=killing@multiplay.co.uk) DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=multiplay.co.uk; s=Multiplay; t=1191338985; x=1191943785; q=dns/txt; h=Received: Message-ID:From:To:Cc:References:Subject:Date:MIME-Version: Content-Type:Content-Transfer-Encoding; bh=rWGTnKcFvV4rOZkUD5asl e6B0d3LY9qPHrkIqIY75kk=; b=Pd+SkGdLa5rest5EYi85rd2l35+aj5FIJ99ID /Z3sE52wfYZdsTkDFQ0RztqfVVQUzZ3qYnM70IsjwZKks9UdWOGOLmSwSuJ5sjDd Ih/MlSUFoZxom133204g/zg/DjY3bPFt5m8CwhQzvtTG7Q+5oe1yTRskPhnCqwwY vSp9BI= 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, 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.2) with ESMTP id md50004269074.msg; Tue, 02 Oct 2007 16:29:43 +0100 Message-ID: <032f01c80509$0ddc8720$b6db87d4@multiplay.co.uk> From: "Steven Hartland" To: =?UTF-8?Q?Dag-Erling_Sm=C3=B8rgrav?= References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk><00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk><012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> Date: Tue, 2 Oct 2007 16:29:42 +0100 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="UTF-8"; reply-type=original Content-Transfer-Encoding: 8bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.3138 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138 X-Authenticated-Sender: Killing@multiplay.co.uk X-MDRemoteIP: 212.135.219.182 X-Return-Path: prvs=17958a6d43=killing@multiplay.co.uk X-Envelope-From: killing@multiplay.co.uk X-Spam-Processed: mail1.multiplay.co.uk, Tue, 02 Oct 2007 16:29:44 +0100 X-MDAV-Processed: mail1.multiplay.co.uk, Tue, 02 Oct 2007 16:29:45 +0100 Cc: freebsd-hackers@freebsd.org, freebsd-stable@freebsd.org Subject: Re: How to enable more than 256 pty's? 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, 02 Oct 2007 15:34:27 -0000 Thanks for the tip there but I cant find any function called pty_create_slave in the source. N.B. Machine is running 5.4 but I also looked on 6.2 which we could upgrade to but still couldn't find it, so I assume you may be talking about something that's in current which we couldn't risk on this machine. Is this something that's possible on 5.x / 6.2 or something that will need a lot of work? Regards Steve ----- Original Message ----- From: "Dag-Erling Smørgrav" You need to change the way ptys are named in pty_create_slave() and pty_clone() in sys/kern/tty_pty.c. Just changing names won't help as the sequence is also hardcoded in pty_clone(). You also need to change grantpt(), openpty() and any other userland code which has hardcoded knowledge of the naming scheme: des@ds4 ~% gfs pqrsPQRS src/sys/kern/tty_pty.c: static char *names = "pqrsPQRS"; src/sys/kern/tty_pty.c: * pts == /dev/tty[pqrsPQRS][0123456789abcdefghijklmnopqrstuv] src/sys/kern/tty_pty.c: * ptc == /dev/pty[pqrsPQRS][0123456789abcdefghijklmnopqrstuv] src/contrib/telnet/telnetd/sys_term.c: for (cp = "pqrsPQRS"; *cp; cp++) { src/usr.sbin/ac/ac.c: strchr("pqrsPQRS", usr.ut_line[3]) != 0 || src/lib/libutil/pty.c: for (cp1 = "pqrsPQRS"; *cp1; cp1++) { src/lib/libc/stdlib/grantpt.c: #define PT_DEV1 "pqrsPQRS" Alternatively, set kern.pts.enable to 1, and find and fix the hang-on-close bug in the pts code (if it hasn't been fixed already) DES -- Dag-Erling Smørgrav - des@des.no ================================================ 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 Tue Oct 2 22:01:46 2007 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 2F60A16A46D for ; Tue, 2 Oct 2007 22:01:46 +0000 (UTC) (envelope-from Nick.Thompson@comtrol.com) Received: from Exchange.comtrol.com (exchange.comtrol.com [204.73.219.163]) by mx1.freebsd.org (Postfix) with ESMTP id 71E9113C458 for ; Tue, 2 Oct 2007 22:01:44 +0000 (UTC) (envelope-from Nick.Thompson@comtrol.com) X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Date: Tue, 2 Oct 2007 16:49:39 -0500 Message-ID: In-Reply-To: <20071001042551.GA63314@mr-happy.com> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Comtrol RocketPort 550 uPCI, 16-port Thread-Index: AcgD4zLStWBZcUtkTKOkqhvAbkAUQQASZszQ From: "Nick Thompson" To: "Jeff Blank" X-Mailman-Approved-At: Tue, 02 Oct 2007 22:41:15 +0000 Cc: freebsd-hackers@freebsd.org Subject: RE: Comtrol RocketPort 550 uPCI, 16-port 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, 02 Oct 2007 22:01:46 -0000 >> Hi. First off, to get it out of the way, I work for Comtrol. This is = a >> Comtrol GMBH (used to be Comtrol UK, now Comtrol GMBH [Switzerland]) >> product. The two are separate companies now. Anyhow, if you have had >> this card for less than 30 days, I would hi,ghly recommend returning = it >> to the distributor for a RocketPort uPCI 16 port card, as this is a >> Comtrol U.S. product and we have a 6.2 driver for our entire = RocketPort >> line. >Thanks for the info. Is the external box with the RJ-45 serial ports=20 >(part # 99420-6) compatible with the Comtrol US card you're about to >send the link for, or would I need to send that back as well? You can hang onto the interface, it's compatible with both the = RocketPort 550 uPCI 16p as well as the RocketPort uPCI 16p. Here is the = link to the page about the RocketPort uPCI 16p:=20 http://www.comtrol.com/products/specifications/99355-1 >> other Unices guy in tech support at Comtrol U.S. and I would = definitely >> like to extend an invitation for anyone who would like a copy of the >> driver to email me at my work address=20 >Does this mean that the US card is not supported by the rp driver that >comes with FreeBSD 6.2, or was that mostly aimed at folks who run an >OS (version) that doesn't include a driver? > >Thanks again, >Jeff What that meant was that the driver that comes with FreeBSD 6.2 is an = older version of the driver. (Much older, 8 years older I believe.) I've = heard from folks who've had success with the driver that comes with 6.2 = with certain cards, and heard from folks who've had success after = hacking the code a bit with other cards. Either way, I am trying to get = things to a point that our FreeBSD customers can be confident that their = cards will be supported now, and into the future. When I arrived here, = the last release was for FreeBSD 5.3: ftp://ftp.comtrol.com/rport/drivers/u_pci/freebsd/5_x/1800255a.tgz Since I personally run FreeBSD at home, and can see the value in keeping = our drivers up to date with the current release, I wanted to get things = up to date. I put in an engineering request for a 6.x driver, and we = have it now.=20 It's in the beta phase, and we have beta customers running it with no = complaints at the moment. I will have to put the link up into this = thread once it gets uploaded to the ftp server, which should be by the = end of the week. Regards, Nick Nick Thompson Technical Support Specialist nick.thompson@comtrol.com Comtrol Corporation ftp://ftp.comtrol.com 6655 Wedgwood Rd. Ste 120 http://www.comtrol.com Maple Grove, MN. 55311 Sales: (800)GO-ROCKET From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 02:19:10 2007 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 5E44B16A41A for ; Wed, 3 Oct 2007 02:19:10 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 5CAFF13C469 for ; Wed, 3 Oct 2007 02:19:10 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id 1432E1A4D7E; Tue, 2 Oct 2007 18:52:31 -0700 (PDT) Date: Tue, 2 Oct 2007 18:52:31 -0700 From: Alfred Perlstein To: hackers@freebsd.org Message-ID: <20071003015231.GJ31826@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.3i Cc: Subject: Critical Sections for userland. 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, 03 Oct 2007 02:19:10 -0000 Hi guys, we need critical sections for userland here. This is basically to avoid a process being switched out while holding a user level spinlock. The way I envisioned doing this was as follows: 1) syscall that sets a pointer in the struct thread. 2) user mlocks that page. 3) when scheduler goes to switch out a process due to quantum it checks this pointer, if set it will give the process more time to run and not switch it out. (*) 4) the load would seem to have to be non-faulting. So my questions are: 1) Where would be a good place to add this code in the scheduler and how? 2) How does one do a read/write to userland address, but if the access would fault, then return an error rather than trap? I'm quite sure the scheduling decisions would be made inside of the timer interrupt, (am I right?), and hence would not be allowed to fault in pages. (*) Note, we will implement limits to this so that a haywire application is not able to be "critical" forever. Any help would be appreciated. -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 02:46:57 2007 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 428E416A41B; Wed, 3 Oct 2007 02:46:57 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from mail.netplex.net (mail.netplex.net [204.213.176.10]) by mx1.freebsd.org (Postfix) with ESMTP id ED5A913C48D; Wed, 3 Oct 2007 02:46:56 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.netplex.net (8.14.1/8.14.1/NETPLEX) with ESMTP id l932ktpP011502; Tue, 2 Oct 2007 22:46:55 -0400 (EDT) X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.netplex.net) X-Greylist: Message whitelisted by DRAC access database, not delayed by milter-greylist-3.0 (mail.netplex.net [204.213.176.10]); Tue, 02 Oct 2007 22:46:55 -0400 (EDT) Date: Tue, 2 Oct 2007 22:46:55 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Alfred Perlstein In-Reply-To: <20071003015231.GJ31826@elvis.mu.org> Message-ID: References: <20071003015231.GJ31826@elvis.mu.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 Oct 2007 02:46:57 -0000 On Tue, 2 Oct 2007, Alfred Perlstein wrote: > Hi guys, we need critical sections for userland here. > > This is basically to avoid a process being switched out while holding > a user level spinlock. Setting the scheduling class to real-time and using SCHED_FIFO and adjusting the thread priority around the lock doesn't work? -- DE From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 02:54:19 2007 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 22E1016A418; Wed, 3 Oct 2007 02:54:19 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 1C17713C458; Wed, 3 Oct 2007 02:54:19 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id E921D1A4D7E; Tue, 2 Oct 2007 19:54:18 -0700 (PDT) Date: Tue, 2 Oct 2007 19:54:18 -0700 From: Alfred Perlstein To: Daniel Eischen Message-ID: <20071003025418.GN31826@elvis.mu.org> References: <20071003015231.GJ31826@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 03 Oct 2007 02:54:19 -0000 * Daniel Eischen [071002 19:46] wrote: > On Tue, 2 Oct 2007, Alfred Perlstein wrote: > > >Hi guys, we need critical sections for userland here. > > > >This is basically to avoid a process being switched out while holding > >a user level spinlock. > > Setting the scheduling class to real-time and using SCHED_FIFO > and adjusting the thread priority around the lock doesn't work? Too heavy weight, we want to basically have this sort of code in userland: /* assume single threaded process for now */ static int is_critical; atomic_mutex_lock(); /* implies ++is_critical */ ...do stuff... atomic_mutex_unlock(); /* implies --is_critical */ We don't want two or more syscalls per lock operation. :) -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 03:02:09 2007 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 8500B16A41B; Wed, 3 Oct 2007 03:02:09 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from mail.netplex.net (mail.netplex.net [204.213.176.10]) by mx1.freebsd.org (Postfix) with ESMTP id 2D0AD13C480; Wed, 3 Oct 2007 03:02:09 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.netplex.net (8.14.1/8.14.1/NETPLEX) with ESMTP id l93327hb017389; Tue, 2 Oct 2007 23:02:07 -0400 (EDT) X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.netplex.net) X-Greylist: Message whitelisted by DRAC access database, not delayed by milter-greylist-3.0 (mail.netplex.net [204.213.176.10]); Tue, 02 Oct 2007 23:02:08 -0400 (EDT) Date: Tue, 2 Oct 2007 23:02:07 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Alfred Perlstein In-Reply-To: <20071003025418.GN31826@elvis.mu.org> Message-ID: References: <20071003015231.GJ31826@elvis.mu.org> <20071003025418.GN31826@elvis.mu.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 Oct 2007 03:02:09 -0000 On Tue, 2 Oct 2007, Alfred Perlstein wrote: > * Daniel Eischen [071002 19:46] wrote: >> On Tue, 2 Oct 2007, Alfred Perlstein wrote: >> >>> Hi guys, we need critical sections for userland here. >>> >>> This is basically to avoid a process being switched out while holding >>> a user level spinlock. >> >> Setting the scheduling class to real-time and using SCHED_FIFO >> and adjusting the thread priority around the lock doesn't work? > > Too heavy weight, we want to basically have this sort of code > in userland: Well, yeah, but are you _really_ sure that you aren't just running something that should be real-time and have priority over other applications? SCHED_FIFO means you will run until you relinquish the CPU (you can only do this as root). If all your threads are well behaved, would this work? Have you tried it? Are you trying to prevent switching out of the thread amongst other threads of the same application, or all threads in the system? -- DE From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 03:08:17 2007 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 6C2B616A417; Wed, 3 Oct 2007 03:08:17 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 62EA413C45A; Wed, 3 Oct 2007 03:08:17 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id 3CD3D1A4D7E; Tue, 2 Oct 2007 20:08:17 -0700 (PDT) Date: Tue, 2 Oct 2007 20:08:17 -0700 From: Alfred Perlstein To: Kip Macy Message-ID: <20071003030817.GP31826@elvis.mu.org> References: <20071003015231.GJ31826@elvis.mu.org> <20071003025418.GN31826@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i Cc: Daniel Eischen , hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 03 Oct 2007 03:08:17 -0000 * Kip Macy [071002 20:00] wrote: > On 10/2/07, Alfred Perlstein wrote: > > * Daniel Eischen [071002 19:46] wrote: > > > On Tue, 2 Oct 2007, Alfred Perlstein wrote: > > > > > > >Hi guys, we need critical sections for userland here. > > > > > > > >This is basically to avoid a process being switched out while holding > > > >a user level spinlock. > > > > > > Setting the scheduling class to real-time and using SCHED_FIFO > > > and adjusting the thread priority around the lock doesn't work? > > > > Too heavy weight, we want to basically have this sort of code > > in userland: > > > > /* assume single threaded process for now */ > > static int is_critical; > > > > > > > > atomic_mutex_lock(); /* implies ++is_critical */ > > ...do stuff... > > atomic_mutex_unlock(); /* implies --is_critical */ > > > > We don't want two or more syscalls per lock operation. :) > > > I assume these processes are running as root? There is nothing to > prevent the process from never dropping the lock. Yes there is... The part that I ommitted detailed keeping a count of the number of times this happens and if it exceeds a threshold then killing the process. Additionally, the kernel would write a byte into the user shared area indicating, "please call me because you need to yield after you're done with your critical section", if the kernel is not listened to, then we beat the process with a rusty tire iron. Sheesh, now can I get some help with this? If I wanted this kind of treatment, I'd be asking on irc! :) -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 03:09:44 2007 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 0E9DF16A46B; Wed, 3 Oct 2007 03:09:44 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 05C4013C4A3; Wed, 3 Oct 2007 03:09:43 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id C72231A4D7E; Tue, 2 Oct 2007 20:09:43 -0700 (PDT) Date: Tue, 2 Oct 2007 20:09:43 -0700 From: Alfred Perlstein To: Daniel Eischen Message-ID: <20071003030943.GQ31826@elvis.mu.org> References: <20071003015231.GJ31826@elvis.mu.org> <20071003025418.GN31826@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 03 Oct 2007 03:09:44 -0000 * Daniel Eischen [071002 20:02] wrote: > On Tue, 2 Oct 2007, Alfred Perlstein wrote: > > >* Daniel Eischen [071002 19:46] wrote: > >>On Tue, 2 Oct 2007, Alfred Perlstein wrote: > >> > >>>Hi guys, we need critical sections for userland here. > >>> > >>>This is basically to avoid a process being switched out while holding > >>>a user level spinlock. > >> > >>Setting the scheduling class to real-time and using SCHED_FIFO > >>and adjusting the thread priority around the lock doesn't work? > > > >Too heavy weight, we want to basically have this sort of code > >in userland: > > Well, yeah, but are you _really_ sure that you aren't just > running something that should be real-time and have priority > over other applications? SCHED_FIFO means you will run until > you relinquish the CPU (you can only do this as root). If > all your threads are well behaved, would this work? Have > you tried it? No, because it wouldn't work. How do we know when to let go of the cpu? In my system, the kernel tells you without polling. > > Are you trying to prevent switching out of the thread > amongst other threads of the same application, or all > threads in the system? All threads on that CPU. It's basically, almost like a "soft spl" for userland. Right? -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 03:16:17 2007 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 1602616A46B; Wed, 3 Oct 2007 03:16:17 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from mail.netplex.net (mail.netplex.net [204.213.176.10]) by mx1.freebsd.org (Postfix) with ESMTP id D5B6E13C494; Wed, 3 Oct 2007 03:16:16 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.netplex.net (8.14.1/8.14.1/NETPLEX) with ESMTP id l933GFun022967; Tue, 2 Oct 2007 23:16:15 -0400 (EDT) X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.netplex.net) X-Greylist: Message whitelisted by DRAC access database, not delayed by milter-greylist-3.0 (mail.netplex.net [204.213.176.10]); Tue, 02 Oct 2007 23:16:15 -0400 (EDT) Date: Tue, 2 Oct 2007 23:16:15 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Alfred Perlstein In-Reply-To: <20071003030943.GQ31826@elvis.mu.org> Message-ID: References: <20071003015231.GJ31826@elvis.mu.org> <20071003025418.GN31826@elvis.mu.org> <20071003030943.GQ31826@elvis.mu.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 Oct 2007 03:16:17 -0000 On Tue, 2 Oct 2007, Alfred Perlstein wrote: > * Daniel Eischen [071002 20:02] wrote: >> On Tue, 2 Oct 2007, Alfred Perlstein wrote: >> >>> * Daniel Eischen [071002 19:46] wrote: >>>> On Tue, 2 Oct 2007, Alfred Perlstein wrote: >>>> >>>>> Hi guys, we need critical sections for userland here. >>>>> >>>>> This is basically to avoid a process being switched out while holding >>>>> a user level spinlock. >>>> >>>> Setting the scheduling class to real-time and using SCHED_FIFO >>>> and adjusting the thread priority around the lock doesn't work? >>> >>> Too heavy weight, we want to basically have this sort of code >>> in userland: >> >> Well, yeah, but are you _really_ sure that you aren't just >> running something that should be real-time and have priority >> over other applications? SCHED_FIFO means you will run until >> you relinquish the CPU (you can only do this as root). If >> all your threads are well behaved, would this work? Have >> you tried it? > > No, because it wouldn't work. How do we know when to let go > of the cpu? In my system, the kernel tells you without polling. You don't have to know when to "let go of the cpu" if your threads are well behaved (meaning they block on some event, or have periods when they wait). They will let go of the CPU normally. When they're busy, they will not be switched out (unless perhaps there is an interrupt thread that needs to run -- I'm not sure how real-time threads get scheduled against ithreads). If your threads are not well behaved (CPU hogs), then that isn't going to work because they'll probably bog down the system. -- DE From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 03:22:43 2007 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 155E016A418; Wed, 3 Oct 2007 03:22:43 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 0A09D13C4B7; Wed, 3 Oct 2007 03:22:42 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id DC8F41A4D7E; Tue, 2 Oct 2007 20:22:42 -0700 (PDT) Date: Tue, 2 Oct 2007 20:22:42 -0700 From: Alfred Perlstein To: Daniel Eischen Message-ID: <20071003032242.GR31826@elvis.mu.org> References: <20071003015231.GJ31826@elvis.mu.org> <20071003025418.GN31826@elvis.mu.org> <20071003030943.GQ31826@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 03 Oct 2007 03:22:43 -0000 * Daniel Eischen [071002 20:16] wrote: > On Tue, 2 Oct 2007, Alfred Perlstein wrote: > > >* Daniel Eischen [071002 20:02] wrote: > >>On Tue, 2 Oct 2007, Alfred Perlstein wrote: > >> > >>>* Daniel Eischen [071002 19:46] wrote: > >>>>On Tue, 2 Oct 2007, Alfred Perlstein wrote: > >>>> > >>>>>Hi guys, we need critical sections for userland here. > >>>>> > >>>>>This is basically to avoid a process being switched out while holding > >>>>>a user level spinlock. > >>>> > >>>>Setting the scheduling class to real-time and using SCHED_FIFO > >>>>and adjusting the thread priority around the lock doesn't work? > >>> > >>>Too heavy weight, we want to basically have this sort of code > >>>in userland: > >> > >>Well, yeah, but are you _really_ sure that you aren't just > >>running something that should be real-time and have priority > >>over other applications? SCHED_FIFO means you will run until > >>you relinquish the CPU (you can only do this as root). If > >>all your threads are well behaved, would this work? Have > >>you tried it? > > > >No, because it wouldn't work. How do we know when to let go > >of the cpu? In my system, the kernel tells you without polling. > > You don't have to know when to "let go of the cpu" if your > threads are well behaved (meaning they block on some event, > or have periods when they wait). They will let go of the > CPU normally. When they're busy, they will not be switched > out (unless perhaps there is an interrupt thread that needs > to run -- I'm not sure how real-time threads get scheduled > against ithreads). > > If your threads are not well behaved (CPU hogs), then that > isn't going to work because they'll probably bog down the > system. Yes, I know how threading works. Unfortunately, your solution is not workable for us. thank you, -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 03:23:52 2007 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 4073A16A46C for ; Wed, 3 Oct 2007 03:23:52 +0000 (UTC) (envelope-from kip.macy@gmail.com) Received: from wa-out-1112.google.com (wa-out-1112.google.com [209.85.146.182]) by mx1.freebsd.org (Postfix) with ESMTP id 18B5C13C457 for ; Wed, 3 Oct 2007 03:23:51 +0000 (UTC) (envelope-from kip.macy@gmail.com) Received: by wa-out-1112.google.com with SMTP id k17so5409253waf for ; Tue, 02 Oct 2007 20:23:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; 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=dIGBHhIOOrrHrF8rnHU6iFVAsk42UtwSkxyx+dLcSb0=; b=mYO5xzCHHnALWOuIRO69teoKVVNP5XWX+ySTow1izNT9zXqfBwNS4eTQuDtzoLS9a8UC4Ot4Z0rB9/XgS1CGLhiHYjcp3wTofg2Ksf9szeYEWmElfgSq5Pk8P+sfR7MehIZBUEamn2CtZllrTOgABqaoAv/s5Flc9lAwdoL0sAM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=ED3VcOMkFw8AVxe9JftnpYWR9XLQHDNvDZ4RavZ5UaCrM+2/0naM1Sbu4tVlpFGrPiEyb7LrFLaVJFLLpAME7GHZRmqUgHzbH8xXZ5yxvdK9S7Z+U0Ue50/rTHmphxLOvPWPkQn8kbGRlkfAlgClzDxaDo7NowuLy5DKXE5eOfw= Received: by 10.114.111.1 with SMTP id j1mr3482452wac.1191381823236; Tue, 02 Oct 2007 20:23:43 -0700 (PDT) Received: by 10.114.13.15 with HTTP; Tue, 2 Oct 2007 20:23:43 -0700 (PDT) Message-ID: Date: Tue, 2 Oct 2007 20:23:43 -0700 From: "Kip Macy" To: "Daniel Eischen" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20071003015231.GJ31826@elvis.mu.org> <20071003025418.GN31826@elvis.mu.org> <20071003030943.GQ31826@elvis.mu.org> Cc: hackers@freebsd.org, Alfred Perlstein Subject: Re: Critical Sections for userland. 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, 03 Oct 2007 03:23:52 -0000 On 10/2/07, Daniel Eischen wrote: > On Tue, 2 Oct 2007, Alfred Perlstein wrote: > > > * Daniel Eischen [071002 20:02] wrote: > >> On Tue, 2 Oct 2007, Alfred Perlstein wrote: > >> > >>> * Daniel Eischen [071002 19:46] wrote: > >>>> On Tue, 2 Oct 2007, Alfred Perlstein wrote: > >>>> > >>>>> Hi guys, we need critical sections for userland here. > >>>>> > >>>>> This is basically to avoid a process being switched out while holding > >>>>> a user level spinlock. > >>>> > >>>> Setting the scheduling class to real-time and using SCHED_FIFO > >>>> and adjusting the thread priority around the lock doesn't work? > >>> > >>> Too heavy weight, we want to basically have this sort of code > >>> in userland: > >> > >> Well, yeah, but are you _really_ sure that you aren't just > >> running something that should be real-time and have priority > >> over other applications? SCHED_FIFO means you will run until > >> you relinquish the CPU (you can only do this as root). If > >> all your threads are well behaved, would this work? Have > >> you tried it? > > > > No, because it wouldn't work. How do we know when to let go > > of the cpu? In my system, the kernel tells you without polling. > > You don't have to know when to "let go of the cpu" if your > threads are well behaved (meaning they block on some event, > or have periods when they wait). They will let go of the > CPU normally. When they're busy, they will not be switched > out (unless perhaps there is an interrupt thread that needs > to run -- I'm not sure how real-time threads get scheduled > against ithreads). > > If your threads are not well behaved (CPU hogs), then that > isn't going to work because they'll probably bog down the > system. > See /sys/priority.h realtime is right below ithreads in terms of priority. One of the big motivations for gang scheduling and part of the reason why SMP guests often perform poorly is that apps / VMs don't scale well if they're descheduled from the cpu while holding a lock. -Kip From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 03:27:20 2007 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 0574D16A468 for ; Wed, 3 Oct 2007 03:27:20 +0000 (UTC) (envelope-from kip.macy@gmail.com) Received: from nz-out-0506.google.com (nz-out-0506.google.com [64.233.162.233]) by mx1.freebsd.org (Postfix) with ESMTP id BED9613C469 for ; Wed, 3 Oct 2007 03:27:19 +0000 (UTC) (envelope-from kip.macy@gmail.com) Received: by nz-out-0506.google.com with SMTP id l8so2782319nzf for ; Tue, 02 Oct 2007 20:27:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; 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=BfPB0fSw1q3KAj48256BVQI+MqM2jQ0dNr9o7zAzVI0=; b=tiCwKFzT4hvrDbJ3YHxvyK2vfAkIcYo84NPLlP2hN7putqGsEEfnxR1qzIgUkjyjLgDr5TL8icPCJtrKee+5JeW1x+Wa9hHuVuhfW0cJjLF9v1reZl+tEBQvnaj5qgkpD5N0OXILXgvhDX3wFPfWDI7Ikdjo9X9pwqAmMyN3BHM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=G7fJK9ccTypqo3y3GmARxc6+mzmawSJfFodMMG8i6lylu8FjddQqLE5vizbNY5DoWlxCA+CoS6JvZaLQlr5DxDzdYG48kC7ocACucKcnWIkbGrgQDNF+bAir5hfug0uBWkaRhNq072+iSTw9r6MtWxbO1Xe9yMIFPifmw8k3Aus= Received: by 10.114.107.19 with SMTP id f19mr3274179wac.1191380422476; Tue, 02 Oct 2007 20:00:22 -0700 (PDT) Received: by 10.114.13.15 with HTTP; Tue, 2 Oct 2007 20:00:22 -0700 (PDT) Message-ID: Date: Tue, 2 Oct 2007 20:00:22 -0700 From: "Kip Macy" To: "Alfred Perlstein" In-Reply-To: <20071003025418.GN31826@elvis.mu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20071003015231.GJ31826@elvis.mu.org> <20071003025418.GN31826@elvis.mu.org> Cc: Daniel Eischen , hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 03 Oct 2007 03:27:20 -0000 On 10/2/07, Alfred Perlstein wrote: > * Daniel Eischen [071002 19:46] wrote: > > On Tue, 2 Oct 2007, Alfred Perlstein wrote: > > > > >Hi guys, we need critical sections for userland here. > > > > > >This is basically to avoid a process being switched out while holding > > >a user level spinlock. > > > > Setting the scheduling class to real-time and using SCHED_FIFO > > and adjusting the thread priority around the lock doesn't work? > > Too heavy weight, we want to basically have this sort of code > in userland: > > /* assume single threaded process for now */ > static int is_critical; > > > > atomic_mutex_lock(); /* implies ++is_critical */ > ...do stuff... > atomic_mutex_unlock(); /* implies --is_critical */ > > We don't want two or more syscalls per lock operation. :) I assume these processes are running as root? There is nothing to prevent the process from never dropping the lock. -Kip From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 03:30:04 2007 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 EEBD516A417; Wed, 3 Oct 2007 03:30:04 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id E394613C455; Wed, 3 Oct 2007 03:30:04 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id B82C31A4D7E; Tue, 2 Oct 2007 20:30:04 -0700 (PDT) Date: Tue, 2 Oct 2007 20:30:04 -0700 From: Alfred Perlstein To: Kip Macy Message-ID: <20071003033004.GS31826@elvis.mu.org> References: <20071003015231.GJ31826@elvis.mu.org> <20071003025418.GN31826@elvis.mu.org> <20071003030943.GQ31826@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i Cc: Daniel Eischen , hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 03 Oct 2007 03:30:05 -0000 * Kip Macy [071002 20:24] wrote: > See /sys/priority.h realtime is right below ithreads in terms of > priority. One of the big motivations for gang scheduling and part of > the reason why SMP guests often perform poorly is that apps / VMs > don't scale well if they're descheduled from the cpu while holding a > lock. Yes, exactly the problem, it sucks when process A on CPU 1 runs out of quantum while holding a lock that a runner on CPU 2 wants. -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Wed Oct 3 06:21:04 2007 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 4212416A41A; Wed, 3 Oct 2007 06:21:04 +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 049DB13C47E; Wed, 3 Oct 2007 06:21:03 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (localhost [127.0.0.1]) by spam.des.no (Postfix) with ESMTP id 41B5E2089; Wed, 3 Oct 2007 08:20:54 +0200 (CEST) X-Spam-Tests: AWL X-Spam-Learn: disabled X-Spam-Score: -0.0/3.0 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on tim.des.no Received: from ds4.des.no (des.no [80.203.243.180]) by smtp.des.no (Postfix) with ESMTP id 2C86B2088; Wed, 3 Oct 2007 08:20:54 +0200 (CEST) Received: by ds4.des.no (Postfix, from userid 1001) id EF0F78447F; Wed, 3 Oct 2007 08:20:53 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: "Steven Hartland" References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <032f01c80509$0ddc8720$b6db87d4@multiplay.co.uk> Date: Wed, 03 Oct 2007 08:20:53 +0200 In-Reply-To: <032f01c80509$0ddc8720$b6db87d4@multiplay.co.uk> (Steven Hartland's message of "Tue\, 2 Oct 2007 16\:29\:42 +0100") Message-ID: <86r6kcbtx6.fsf@ds4.des.no> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org, freebsd-stable@freebsd.org Subject: Re: How to enable more than 256 pty's? 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, 03 Oct 2007 06:21:04 -0000 "Steven Hartland" writes: > Thanks for the tip there but I cant find any function called pty_create_s= lave > in the source. Just grep your source tree for occurrences of pqrsPQRS. > Is this something that's possible on 5.x / 6.2 or something that will nee= d a > lot of work? It shouldn't be any harder on 5.x / 6.x than on 7.x. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 02:24:10 2007 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 869E316A418 for ; Thu, 4 Oct 2007 02:24:10 +0000 (UTC) (envelope-from obrien@NUXI.org) Received: from dragon.nuxi.org (trang.nuxi.org [74.95.12.85]) by mx1.freebsd.org (Postfix) with ESMTP id 5FDB613C45D for ; Thu, 4 Oct 2007 02:24:10 +0000 (UTC) (envelope-from obrien@NUXI.org) Received: from dragon.nuxi.org (obrien@localhost [127.0.0.1]) by dragon.nuxi.org (8.14.1/8.14.1) with ESMTP id l942Nifg007323; Wed, 3 Oct 2007 19:23:44 -0700 (PDT) (envelope-from obrien@dragon.nuxi.org) Received: (from obrien@localhost) by dragon.nuxi.org (8.14.1/8.14.1/Submit) id l942Ni3E007322; Wed, 3 Oct 2007 19:23:44 -0700 (PDT) (envelope-from obrien) Date: Wed, 3 Oct 2007 19:23:44 -0700 From: "David O'Brien" To: Yar Tikhiy , freebsd-hackers@freebsd.org Message-ID: <20071004022344.GA60878@dragon.NUXI.org> Mail-Followup-To: obrien@freebsd.org, Yar Tikhiy , freebsd-hackers@freebsd.org References: <20070901073440.GL85633@comp.chem.msu.su> <46DAFE5C.6070806@freebsd.org> <20070903120353.GH30502@comp.chem.msu.su> <200709261028.43378.jhb@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200709261028.43378.jhb@freebsd.org> X-Operating-System: FreeBSD 7.0-CURRENT Organization: The NUXI BSD Group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 User-Agent: Mutt/1.5.16 (2007-06-09) Cc: Subject: Re: Useful tools missing from /rescue X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: obrien@freebsd.org List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Oct 2007 02:24:10 -0000 > > > Yar Tikhiy wrote: > > > >I've had to use /rescue recently and felt lack of a few basic tools > > > >in it, namely pgrep(1), head(1), tail(1), tee(1), and a text filter, > > > >e.g., sed(1). Well, in fact most functionality of pgrep(1), head(1), > > > >tail(1), and even tee(1) can be emulated if one has sed(1), but the > > > >tools are so tiny and convenient that it's a pity not to have them > > > >all handy during hard times. I also don't see the need for pgrep - I think needing that says your system is running multiuser pretty well. Also head and tail - why not just add 'more' as that would give more functionality if you're trying to read a file in /etc to fix something. > > > >In addition, there are chflags and chmod in /rescue, but there's > > > >no chown in it, so the toolset is a bit incomplete. I don't see the purpose of chown - if you have to fall back to /rescue you're user 'root' - and you're trying to fix enough so you can use standard /*lib & /*bin chflags is needed so you can overwrite a file and chmod is needed so you can "chmod +x" something - those needs are clear. Please don't pestimize the build - unless there is a clear benefit. -- -- David (obrien@FreeBSD.org) Q: Because it reverses the logical flow of conversation. A: Why is top-posting (putting a reply at the top of the message) frowned upon? Let's not play "Jeopardy-style quoting" From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 05:09:47 2007 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 D7BAF16A417 for ; Thu, 4 Oct 2007 05:09:47 +0000 (UTC) (envelope-from dexterclarke@Safe-mail.net) Received: from tapuz.safe-mail.net (tapuz.safe-mail.net [213.8.161.230]) by mx1.freebsd.org (Postfix) with ESMTP id 8935213C4B0 for ; Thu, 4 Oct 2007 05:09:47 +0000 (UTC) (envelope-from dexterclarke@Safe-mail.net) Received: by tapuz.safe-mail.net with Safe-mail (Exim 4.52) id 1IdID9-0003Nu-Th for freebsd-hackers@freebsd.org; Thu, 04 Oct 2007 00:21:19 -0400 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=N1-0105; d=Safe-mail.net; b=M3DmaDGrNcVCIc7MYir/EkcZ6ba+PdJWnbLzRFfsa3Y8iQXP6qychg6J3MGMM91J 5Tbh4IpAsq0kCk5W5dL8TQAAn9JZZgBQ3mJeh+I9cSQ/Cllshwwa4hUqVbYt6r2f mw3413f7ze+Ec9Y9X+xPkyQiSWHzuZ0J/Jo0FSV7fKE=; Received: from pc ([81.86.41.187]) by Safe-mail.net with https Date: Thu, 4 Oct 2007 00:21:19 -0400 From: dexterclarke@Safe-mail.net To: freebsd-hackers@freebsd.org X-SMType: Regular X-SMRef: N1-_oTpkG9K9c Message-Id: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-SMSignature: lT2MqIHYghAcO40PXfKFXgffTyPQENxEsr/REXKKMa8JMXDxXi3zsmL8b/urHY/r F4eobUh2RlqfKq25j41OOsnW54Uqsex27ku/YroxJ6yduP4rkrTSlkQY7PIsXe8I tz6stE/LWNvKDRai6Bv1RDhiQjDWodXne0bqfgxnM4A= Subject: audit doesn't seem to be working correctly. 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, 04 Oct 2007 05:09:47 -0000 After reading this article: http://www.regdeveloper.co.uk/2006/11/13/freebsd_security_event_auditing/ I decided to try audit. I edited /etc/security/audit_control as the article (and the handbook example) shows: dir:/var/audit flags:lo,+ex minfree:20 naflags:lo policy:cnt filesz:0 But having restarted auditd, I don't see audit events for process execution being generated. However, if I do this: dir:/var/audit flags:lo minfree:20 naflags:lo,+ex policy:cnt filesz:0 I get audit records for users executing programs. This seems completely wrong to me. Why are these events being classed as non-attributable when they're clearly being created by authenticated users? I am running 6.2-RELEASE-p7 which is vanilla apart from the addition of options MAC, AUDIT and VESA. -- dc From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 09:21:58 2007 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 4824416A421 for ; Thu, 4 Oct 2007 09:21:58 +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 0272B13C447 for ; Thu, 4 Oct 2007 09:21:57 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (localhost [127.0.0.1]) by spam.des.no (Postfix) with ESMTP id C762120C0; Thu, 4 Oct 2007 11:05:11 +0200 (CEST) X-Spam-Tests: AWL X-Spam-Learn: disabled X-Spam-Score: -0.0/3.0 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on tim.des.no Received: from ds4.des.no (des.no [80.203.243.180]) by smtp.des.no (Postfix) with ESMTP id AA65A20BF; Thu, 4 Oct 2007 11:05:11 +0200 (CEST) Received: by ds4.des.no (Postfix, from userid 1001) id 9568D84486; Thu, 4 Oct 2007 11:05:11 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Alfred Perlstein References: <20071003015231.GJ31826@elvis.mu.org> Date: Thu, 04 Oct 2007 11:05:11 +0200 In-Reply-To: <20071003015231.GJ31826@elvis.mu.org> (Alfred Perlstein's message of "Tue\, 2 Oct 2007 18\:52\:31 -0700") Message-ID: <86zlyzqmgo.fsf@ds4.des.no> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 09:21:58 -0000 Alfred Perlstein writes: > Hi guys, we need critical sections for userland here. > > This is basically to avoid a process being switched out while holding > a user level spinlock. Yeah, great idea, cooperative multitasking is the new black! DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 09:48:21 2007 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 7278716A418 for ; Thu, 4 Oct 2007 09:48:21 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 5F52D13C45A for ; Thu, 4 Oct 2007 09:48:21 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id 4BF381A4D81; Thu, 4 Oct 2007 02:48:21 -0700 (PDT) Date: Thu, 4 Oct 2007 02:48:21 -0700 From: Alfred Perlstein To: Dag-Erling Sm??rgrav Message-ID: <20071004094821.GM31826@elvis.mu.org> References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <86zlyzqmgo.fsf@ds4.des.no> User-Agent: Mutt/1.4.2.3i Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 09:48:21 -0000 * Dag-Erling Sm??rgrav [071004 02:05] wrote: > Alfred Perlstein writes: > > Hi guys, we need critical sections for userland here. > > > > This is basically to avoid a process being switched out while holding > > a user level spinlock. > > Yeah, great idea, cooperative multitasking is the new black! Do you have: a) Evidence or a paper to prove that this is a bad idea? b) A helpful suggestion? c) An obvious understanding of the problem? If not then perhaps one ought to restrict snarky comments to private mail where they will be at least somewhat appreciated. -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 10:01:05 2007 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 EFD6A16A417; Thu, 4 Oct 2007 10:01:05 +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 7196313C455; Thu, 4 Oct 2007 10:01:05 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (localhost [127.0.0.1]) by spam.des.no (Postfix) with ESMTP id CDF9220BA; Thu, 4 Oct 2007 12:00:56 +0200 (CEST) X-Spam-Tests: AWL X-Spam-Learn: disabled X-Spam-Score: -0.0/3.0 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on tim.des.no Received: from ds4.des.no (des.no [80.203.243.180]) by smtp.des.no (Postfix) with ESMTP id B632520AE; Thu, 4 Oct 2007 12:00:56 +0200 (CEST) Received: by ds4.des.no (Postfix, from userid 1001) id 9E08F84486; Thu, 4 Oct 2007 12:00:56 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Alfred Perlstein References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> <20071004094821.GM31826@elvis.mu.org> Date: Thu, 04 Oct 2007 12:00:56 +0200 In-Reply-To: <20071004094821.GM31826@elvis.mu.org> (Alfred Perlstein's message of "Thu\, 4 Oct 2007 02\:48\:21 -0700") Message-ID: <86ejgbqjvr.fsf@ds4.des.no> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 10:01:06 -0000 Alfred Perlstein writes: > Do you have: > > a) Evidence or a paper to prove that this is a bad idea? I need evidence or a paper to prove that it is a bad idea to allow a userland process to hold the CPU indefinitely? > b) A helpful suggestion? Why don't you tell us what you're actually trying to do, so we can tell you how to do it. > c) An obvious understanding of the problem? I'll show you mine if you show me yours. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 10:19:02 2007 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 5217D16A419 for ; Thu, 4 Oct 2007 10:19:02 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 3BCE113C474 for ; Thu, 4 Oct 2007 10:19:02 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id 209631A4D87; Thu, 4 Oct 2007 03:19:02 -0700 (PDT) Date: Thu, 4 Oct 2007 03:19:02 -0700 From: Alfred Perlstein To: Dag-Erling Sm??rgrav Message-ID: <20071004101902.GN31826@elvis.mu.org> References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> <20071004094821.GM31826@elvis.mu.org> <86ejgbqjvr.fsf@ds4.des.no> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <86ejgbqjvr.fsf@ds4.des.no> User-Agent: Mutt/1.4.2.3i Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 10:19:02 -0000 * Dag-Erling Sm??rgrav [071004 03:01] wrote: > Alfred Perlstein writes: > > Do you have: > > > > a) Evidence or a paper to prove that this is a bad idea? > > I need evidence or a paper to prove that it is a bad idea to allow a > userland process to hold the CPU indefinitely? > > > b) A helpful suggestion? > > Why don't you tell us what you're actually trying to do, so we can tell > you how to do it. > > > c) An obvious understanding of the problem? > > I'll show you mine if you show me yours. It's not worth my time to engage someone with your mind set, you posses neither the technical nor interpersonal skill to be useful to me. For context see my replies in this thread to Kip Macy which explains how one deals with the false-problems you mention. For evidence of existing, however suboptimal, run-to-completion systems see the RTPRIO scheduling knobs. -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 10:28:40 2007 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 6190616A421; Thu, 4 Oct 2007 10:28:40 +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 E611113C478; Thu, 4 Oct 2007 10:28:39 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (localhost [127.0.0.1]) by spam.des.no (Postfix) with ESMTP id 4740020BA; Thu, 4 Oct 2007 12:28:30 +0200 (CEST) X-Spam-Tests: AWL X-Spam-Learn: disabled X-Spam-Score: -0.0/3.0 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on tim.des.no Received: from ds4.des.no (des.no [80.203.243.180]) by smtp.des.no (Postfix) with ESMTP id C20B420AE; Thu, 4 Oct 2007 12:28:29 +0200 (CEST) Received: by ds4.des.no (Postfix, from userid 1001) id 9CDEE8448A; Thu, 4 Oct 2007 12:28:29 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Alfred Perlstein References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> <20071004094821.GM31826@elvis.mu.org> <86ejgbqjvr.fsf@ds4.des.no> <20071004101902.GN31826@elvis.mu.org> Date: Thu, 04 Oct 2007 12:28:29 +0200 In-Reply-To: <20071004101902.GN31826@elvis.mu.org> (Alfred Perlstein's message of "Thu\, 4 Oct 2007 03\:19\:02 -0700") Message-ID: <863awrqilu.fsf@ds4.des.no> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 10:28:40 -0000 Alfred Perlstein writes: > It's not worth my time to engage someone with your mind set, you > posses neither the technical nor interpersonal skill to be useful > to me. This could be the beginning of a wonderful friendship... > For context see my replies in this thread to Kip Macy which explains > how one deals with the false-problems you mention. I did read them, and I'm not convinced at all. You are asking for a large amount of complexity to be added to the system, but you refuse to tell us what you're actually trying to do. Are you worried that we might actually figure out a way to do it without raping the scheduler? DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 09:56:08 2007 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 D6B5A16A419 for ; Thu, 4 Oct 2007 09:56:08 +0000 (UTC) (envelope-from pb@ludd.ltu.se) Received: from mother.ludd.ltu.se (mother.ludd.ltu.se [130.240.16.3]) by mx1.freebsd.org (Postfix) with ESMTP id 401A013C4B3 for ; Thu, 4 Oct 2007 09:56:07 +0000 (UTC) (envelope-from pb@ludd.ltu.se) Received: from brother.ludd.ltu.se (root@brother.ludd.ltu.se [130.240.16.78]) by mother.ludd.ltu.se (8.13.6+Sun/8.12.10) with ESMTP id l949XQ6l017060 for ; Thu, 4 Oct 2007 11:33:26 +0200 (MEST) Received: from brother.ludd.ltu.se (pb@localhost [127.0.0.1]) by brother.ludd.ltu.se (8.13.6+Sun/8.12.2) with ESMTP id l949XQWE025180 for ; Thu, 4 Oct 2007 11:33:26 +0200 (MEST) Received: (from pb@localhost) by brother.ludd.ltu.se (8.13.6+Sun/8.13.6/Submit) id l949XQiO025178 for freebsd-hackers@freebsd.org; Thu, 4 Oct 2007 11:33:26 +0200 (MEST) From: Peter B Message-Id: <200710040933.l949XQiO025178@brother.ludd.ltu.se> To: freebsd-hackers@freebsd.org Date: Thu, 4 Oct 2007 11:33:26 +0200 (MEST) X-Mailer: ELM [version 2.5 PL6] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Thu, 04 Oct 2007 11:51:04 +0000 Subject: Recommended S-ATA controller? 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, 04 Oct 2007 09:56:08 -0000 What PCI 32/33 S-ATA controller is recommended for a x86/FreeBSD-6 system that is stable and reliable in terms of hardware design, and software drivers ? My current Promise card is said to abuse PCI burst mode, in essence it will exploit to tight timing margins. And the motherboard doesn't have any option to disable pci-burst. This gives intermittent errors. sos@ comments on SII chipsets isn't encourageing either. /P From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 11:35:02 2007 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 C929C16A417 for ; Thu, 4 Oct 2007 11:35:02 +0000 (UTC) (envelope-from wb@freebie.xs4all.nl) Received: from smtp-vbr17.xs4all.nl (smtp-vbr17.xs4all.nl [194.109.24.37]) by mx1.freebsd.org (Postfix) with ESMTP id 5EEF613C48E for ; Thu, 4 Oct 2007 11:35:01 +0000 (UTC) (envelope-from wb@freebie.xs4all.nl) Received: from freebie.xs4all.nl (obsolete.xs4all.nl [82.95.250.254]) by smtp-vbr17.xs4all.nl (8.13.8/8.13.8) with ESMTP id l94BFamp093482; Thu, 4 Oct 2007 13:15:37 +0200 (CEST) (envelope-from wb@freebie.xs4all.nl) Received: from freebie.xs4all.nl (localhost [127.0.0.1]) by freebie.xs4all.nl (8.13.8/8.13.3) with ESMTP id l94BFamP042138; Thu, 4 Oct 2007 13:15:36 +0200 (CEST) (envelope-from wb@freebie.xs4all.nl) Received: (from wb@localhost) by freebie.xs4all.nl (8.13.8/8.13.6/Submit) id l94BFZRZ042137; Thu, 4 Oct 2007 13:15:35 +0200 (CEST) (envelope-from wb) Date: Thu, 4 Oct 2007 13:15:35 +0200 From: Wilko Bulte To: Alfred Perlstein Message-ID: <20071004111535.GA42121@freebie.xs4all.nl> References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> <20071004094821.GM31826@elvis.mu.org> <86ejgbqjvr.fsf@ds4.des.no> <20071004101902.GN31826@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20071004101902.GN31826@elvis.mu.org> User-Agent: Mutt/1.5.11 X-Virus-Scanned: by XS4ALL Virus Scanner X-Mailman-Approved-At: Thu, 04 Oct 2007 12:01:08 +0000 Cc: Dag-Erling Sm??rgrav , hackers@FreeBSD.ORG Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 11:35:02 -0000 Quoting Alfred Perlstein, who wrote on Thu, Oct 04, 2007 at 03:19:02AM -0700 .. > * Dag-Erling Sm??rgrav [071004 03:01] wrote: > > Alfred Perlstein writes: > > > Do you have: > > > > > > a) Evidence or a paper to prove that this is a bad idea? > > > > I need evidence or a paper to prove that it is a bad idea to allow a > > userland process to hold the CPU indefinitely? > > > > > b) A helpful suggestion? > > > > Why don't you tell us what you're actually trying to do, so we can tell > > you how to do it. > > > > > c) An obvious understanding of the problem? > > > > I'll show you mine if you show me yours. > > It's not worth my time to engage someone with your mind set, you > posses neither the technical nor interpersonal skill to be useful > to me. Gentlemen... please? -- Wilko Bulte wilko@FreeBSD.org From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 12:49:13 2007 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 2053216A516 for ; Thu, 4 Oct 2007 12:49:13 +0000 (UTC) (envelope-from SRS0=8Q+U=O6=firebadger.net=richard@srs.kundenserver.de) Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.177]) by mx1.freebsd.org (Postfix) with ESMTP id 8A46F13C4AC for ; Thu, 4 Oct 2007 12:49:12 +0000 (UTC) (envelope-from SRS0=8Q+U=O6=firebadger.net=richard@srs.kundenserver.de) Received: from [149.254.192.192] (helo=[10.32.70.83]) by mrelayeu.kundenserver.de (node=mrelayeu6) with ESMTP (Nemesis) id 0ML29c-1IdPwK0IXE-0004Ao; Thu, 04 Oct 2007 14:36:29 +0200 Message-ID: <4704DE42.20509@firebadger.net> Date: Thu, 04 Oct 2007 13:36:18 +0100 From: Richard Collyer User-Agent: Thunderbird 2.0.0.6 (Windows/20070728) MIME-Version: 1.0 To: Peter B , freebsd-hackers@freebsd.org References: <200710040933.l949XQiO025178@brother.ludd.ltu.se> In-Reply-To: <200710040933.l949XQiO025178@brother.ludd.ltu.se> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V01U2FsdGVkX1+y4sanq6A9l7T3DlZxmtWcasFYHh/ZzsF6ghi Lwpisq+jQaqqpjqB5SxvKHZHPe91UgfUW3d44bfbbSBWUgS23h 4g+/ePkSO4AeRVK0k3ad2doawCCXPmZcYKzGogQy2g= Cc: Subject: Re: Recommended S-ATA controller? 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, 04 Oct 2007 12:49:13 -0000 Peter B wrote: > What PCI 32/33 S-ATA controller is recommended for a x86/FreeBSD-6 system > that is stable and reliable in terms of hardware design, and software drivers ? > > My current Promise card is said to abuse PCI burst mode, in essence it will > exploit to tight timing margins. And the motherboard doesn't have any option to > disable pci-burst. This gives intermittent errors. > > sos@ comments on SII chipsets isn't encourageing either. > > /P > 3ware 7000 or 9000 series are working fine in my 5.4 box Cheers Richard From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 12:28:17 2007 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 CFC7D16A417 for ; Thu, 4 Oct 2007 12:28:17 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from in.niksun.com (210.18.76.166.sify.net [210.18.76.166]) by mx1.freebsd.org (Postfix) with ESMTP id 7728713C455 for ; Thu, 4 Oct 2007 12:28:17 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from sharadc.in.niksun.com (unknown [10.60.5.27]) by in.niksun.com (Postfix) with ESMTP id C31535CBF for ; Thu, 4 Oct 2007 17:36:13 +0530 (IST) From: Sharad Chandra Organization: NIKSUN To: freebsd-hackers@freebsd.org Date: Thu, 4 Oct 2007 17:25:00 +0530 User-Agent: KMail/1.9.4 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200710041725.00842.sharadc@in.niksun.com> X-Mailman-Approved-At: Thu, 04 Oct 2007 12:59:44 +0000 Subject: SCSI and SAN 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, 04 Oct 2007 12:28:17 -0000 Hello, How to distinguish if /dev/da* devices are internal scsi drivers or LUNs of external SAN? Is there any tool? Thanks for any advice. Sharad Chandra From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 13:05:27 2007 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 E44E816A420; Thu, 4 Oct 2007 13:05:27 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from mail.netplex.net (mail.netplex.net [204.213.176.10]) by mx1.freebsd.org (Postfix) with ESMTP id A4F4B13C494; Thu, 4 Oct 2007 13:05:27 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.netplex.net (8.14.1/8.14.1/NETPLEX) with ESMTP id l94D5Ojt004561; Thu, 4 Oct 2007 09:05:24 -0400 (EDT) X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.netplex.net) X-Greylist: Message whitelisted by DRAC access database, not delayed by milter-greylist-3.0 (mail.netplex.net [204.213.176.10]); Thu, 04 Oct 2007 09:05:24 -0400 (EDT) Date: Thu, 4 Oct 2007 09:05:24 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Alfred Perlstein In-Reply-To: <20071004101902.GN31826@elvis.mu.org> Message-ID: References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> <20071004094821.GM31826@elvis.mu.org> <86ejgbqjvr.fsf@ds4.des.no> <20071004101902.GN31826@elvis.mu.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: Dag-Erling Sm??rgrav , hackers@freebsd.org Subject: Re: Critical Sections for userland. X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Oct 2007 13:05:28 -0000 On Thu, 4 Oct 2007, Alfred Perlstein wrote: > * Dag-Erling Sm??rgrav [071004 03:01] wrote: >> Alfred Perlstein writes: >>> Do you have: >>> >>> a) Evidence or a paper to prove that this is a bad idea? >> >> I need evidence or a paper to prove that it is a bad idea to allow a >> userland process to hold the CPU indefinitely? >> >>> b) A helpful suggestion? >> >> Why don't you tell us what you're actually trying to do, so we can tell >> you how to do it. >> >>> c) An obvious understanding of the problem? >> >> I'll show you mine if you show me yours. > > It's not worth my time to engage someone with your mind set, you > posses neither the technical nor interpersonal skill to be useful > to me. > > For context see my replies in this thread to Kip Macy which explains > how one deals with the false-problems you mention. > > For evidence of existing, however suboptimal, run-to-completion > systems see the RTPRIO scheduling knobs. His point about telling us what you're really doing, so we might off other ways to do it is valid. We don't know why you are using homegrown user-level spinlocks instead of pthread mutexes. Priority ceiling mutexes and running in SCHED_RR or SCHED_FIFO is really what tries to address this problem, at least from the vague desciption you give. If you have tried this and they don't work correctly, then one solution is to fix them ;-) -- DE From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 13:23:05 2007 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 B7F6416A516 for ; Thu, 4 Oct 2007 13:23:05 +0000 (UTC) (envelope-from wb@freebie.xs4all.nl) Received: from smtp-vbr6.xs4all.nl (smtp-vbr6.xs4all.nl [194.109.24.26]) by mx1.freebsd.org (Postfix) with ESMTP id 36C3713C447 for ; Thu, 4 Oct 2007 13:23:04 +0000 (UTC) (envelope-from wb@freebie.xs4all.nl) Received: from freebie.xs4all.nl (obsolete.xs4all.nl [82.95.250.254]) by smtp-vbr6.xs4all.nl (8.13.8/8.13.8) with ESMTP id l94D9RM2051286; Thu, 4 Oct 2007 15:09:31 +0200 (CEST) (envelope-from wb@freebie.xs4all.nl) Received: from freebie.xs4all.nl (localhost [127.0.0.1]) by freebie.xs4all.nl (8.13.8/8.13.3) with ESMTP id l94D9RxK042696; Thu, 4 Oct 2007 15:09:27 +0200 (CEST) (envelope-from wb@freebie.xs4all.nl) Received: (from wb@localhost) by freebie.xs4all.nl (8.13.8/8.13.6/Submit) id l94D9QWl042695; Thu, 4 Oct 2007 15:09:26 +0200 (CEST) (envelope-from wb) Date: Thu, 4 Oct 2007 15:09:26 +0200 From: Wilko Bulte To: Sharad Chandra Message-ID: <20071004130926.GA42680@freebie.xs4all.nl> References: <200710041725.00842.sharadc@in.niksun.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200710041725.00842.sharadc@in.niksun.com> User-Agent: Mutt/1.5.11 X-Virus-Scanned: by XS4ALL Virus Scanner X-Mailman-Approved-At: Thu, 04 Oct 2007 13:25:02 +0000 Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 04 Oct 2007 13:23:05 -0000 Quoting Sharad Chandra, who wrote on Thu, Oct 04, 2007 at 05:25:00PM +0530 .. > Hello, > > How to distinguish if /dev/da* devices are internal scsi drivers or LUNs of > external SAN? > > Is there any tool? /var/run/dmesg.boot I would think. And then you would need to map things manually. -- Wilko Bulte wilko@FreeBSD.org From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 13:36:33 2007 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 F381216A419 for ; Thu, 4 Oct 2007 13:36:32 +0000 (UTC) (envelope-from anderson@freebsd.org) Received: from ns.trinitel.com (186.161.36.72.static.reverse.ltdomains.com [72.36.161.186]) by mx1.freebsd.org (Postfix) with ESMTP id AEDED13C43E for ; Thu, 4 Oct 2007 13:36:32 +0000 (UTC) (envelope-from anderson@freebsd.org) Received: from proton.storspeed.com (209-163-168-124.static.twtelecom.net [209.163.168.124]) (authenticated bits=0) by ns.trinitel.com (8.14.1/8.14.1) with ESMTP id l94DLrpB041607; Thu, 4 Oct 2007 08:21:53 -0500 (CDT) (envelope-from anderson@freebsd.org) Message-ID: <4704E8F1.8070000@freebsd.org> Date: Thu, 04 Oct 2007 08:21:53 -0500 From: Eric Anderson User-Agent: Thunderbird 2.0.0.6 (Macintosh/20070728) MIME-Version: 1.0 To: Sharad Chandra References: <200710041725.00842.sharadc@in.niksun.com> In-Reply-To: <200710041725.00842.sharadc@in.niksun.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.1.8 X-Spam-Checker-Version: SpamAssassin 3.1.8 (2007-02-13) on ns.trinitel.com Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 04 Oct 2007 13:36:33 -0000 Sharad Chandra wrote: > Hello, > > How to distinguish if /dev/da* devices are internal scsi drivers or LUNs of > external SAN? > camcontrol devlist -v Might help you.. Eric From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 14:45:53 2007 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 D722316A41A for ; Thu, 4 Oct 2007 14:45:53 +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 4BB8813C45B for ; Thu, 4 Oct 2007 14:45:53 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from kobe.laptop (vader.bytemobile.ondsl.gr [83.235.244.135]) (authenticated bits=128) by igloo.linux.gr (8.14.1/8.14.1/Debian-9) with ESMTP id l94EhetS011378 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 4 Oct 2007 17:44:07 +0300 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.1/8.14.1) with ESMTP id l94EhJo0006451; Thu, 4 Oct 2007 17:43:39 +0300 (EEST) (envelope-from keramida@ceid.upatras.gr) Received: (from keramida@localhost) by kobe.laptop (8.14.1/8.14.1/Submit) id l94EhGq8006450; Thu, 4 Oct 2007 17:43:16 +0300 (EEST) (envelope-from keramida@ceid.upatras.gr) Date: Thu, 4 Oct 2007 17:43:16 +0300 From: Giorgos Keramidas To: Vlad GALU Message-ID: <20071004144315.GA6377@kobe.laptop> References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <00ab01c8040c$7c408160$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> <86wsu5wuz3.fsf@ds4.des.no> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-3.977, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL 0.42, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@ceid.upatras.gr X-Spam-Status: No Cc: Dag-Erling Sm?rgrav , gepu@flow.rdsnet.ro, Steven Hartland , freebsd-stable@freebsd.org, freebsd-hackers@freebsd.org Subject: Re: How to enable more than 256 pty's? 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, 04 Oct 2007 14:45:53 -0000 On 2007-10-02 15:41, Vlad GALU wrote: > On 10/2/07, Dag-Erling Sm?rgrav wrote: > > "Vlad GALU" writes: > > > The symptoms were exhibited even with rev. 1.16. I've CC'ed him so > > > he can catch up with the thread. > > > > Which symptoms? I can no longer reproduce the hang-on-close bug. > > Strangely enough, me neither. In his case, allocated pts' wouldn't > get deallocated once the sessions ended. There was an old bug, which caused pts consumers to get stuck in "devdrn". This has been fixed, AFAICT, a long time ago. At least, I can't reproduce it any more with the usual tests: * Closing xterm windows. * Closing telnet sessions. * Exiting from screen(1) windows. From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 15:05:51 2007 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 6234D16A418 for ; Thu, 4 Oct 2007 15:05:51 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: from fk-out-0910.google.com (fk-out-0910.google.com [209.85.128.189]) by mx1.freebsd.org (Postfix) with ESMTP id F1A1813C480 for ; Thu, 4 Oct 2007 15:05:50 +0000 (UTC) (envelope-from dudu@dudu.ro) Received: by fk-out-0910.google.com with SMTP id b27so202010fka for ; Thu, 04 Oct 2007 08:05:49 -0700 (PDT) Received: by 10.82.154.12 with SMTP id b12mr17392992bue.1191510349452; Thu, 04 Oct 2007 08:05:49 -0700 (PDT) Received: by 10.82.148.14 with HTTP; Thu, 4 Oct 2007 08:05:49 -0700 (PDT) Message-ID: Date: Thu, 4 Oct 2007 18:05:49 +0300 From: "Vlad GALU" To: "Giorgos Keramidas" In-Reply-To: <20071004144315.GA6377@kobe.laptop> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <001f01c80407$1358d490$b6db87d4@multiplay.co.uk> <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> <86wsu5wuz3.fsf@ds4.des.no> <20071004144315.GA6377@kobe.laptop> Cc: Dag-Erling Sm?rgrav , gepu@flow.rdsnet.ro, Steven Hartland , freebsd-stable@freebsd.org, freebsd-hackers@freebsd.org Subject: Re: How to enable more than 256 pty's? 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, 04 Oct 2007 15:05:51 -0000 On 10/4/07, Giorgos Keramidas wrote: > On 2007-10-02 15:41, Vlad GALU wrote: > > On 10/2/07, Dag-Erling Sm?rgrav wrote: > > > "Vlad GALU" writes: > > > > The symptoms were exhibited even with rev. 1.16. I've CC'ed him so > > > > he can catch up with the thread. > > > > > > Which symptoms? I can no longer reproduce the hang-on-close bug. > > > > Strangely enough, me neither. In his case, allocated pts' wouldn't > > get deallocated once the sessions ended. > > There was an old bug, which caused pts consumers to get stuck in > "devdrn". This has been fixed, AFAICT, a long time ago. At least, I > can't reproduce it any more with the usual tests: > > * Closing xterm windows. > > * Closing telnet sessions. > > * Exiting from screen(1) windows. > Weird. 3 people on this thread already saw the symptoms :( > -- If it's there, and you can see it, it's real. If it's not there, and you can see it, it's virtual. If it's there, and you can't see it, it's transparent. If it's not there, and you can't see it, you erased it. From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 15:17:57 2007 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 611F916A417; Thu, 4 Oct 2007 15:17:57 +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 973BD13C4AA; Thu, 4 Oct 2007 15:17:56 +0000 (UTC) (envelope-from keramida@ceid.upatras.gr) Received: from kobe.laptop (vader.bytemobile.ondsl.gr [83.235.244.135]) (authenticated bits=128) by igloo.linux.gr (8.14.1/8.14.1/Debian-9) with ESMTP id l94FFjiB014021 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 4 Oct 2007 18:16:05 +0300 Received: from kobe.laptop (kobe.laptop [127.0.0.1]) by kobe.laptop (8.14.1/8.14.1) with ESMTP id l94FFO6l006829; Thu, 4 Oct 2007 18:15:42 +0300 (EEST) (envelope-from keramida@ceid.upatras.gr) Received: (from keramida@localhost) by kobe.laptop (8.14.1/8.14.1/Submit) id l94FFLBj006828; Thu, 4 Oct 2007 18:15:21 +0300 (EEST) (envelope-from keramida@ceid.upatras.gr) Date: Thu, 4 Oct 2007 18:15:21 +0300 From: Giorgos Keramidas To: Vlad GALU Message-ID: <20071004151520.GB6684@kobe.laptop> References: <012101c804e5$efa7e9c0$b6db87d4@multiplay.co.uk> <86abr1yb68.fsf@ds4.des.no> <86641pyanc.fsf@ds4.des.no> <86wsu5wuz3.fsf@ds4.des.no> <20071004144315.GA6377@kobe.laptop> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Hellug-MailScanner: Found to be clean X-Hellug-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-3.978, required 5, autolearn=not spam, ALL_TRUSTED -1.80, AWL 0.42, BAYES_00 -2.60) X-Hellug-MailScanner-From: keramida@ceid.upatras.gr X-Spam-Status: No Cc: Dag-Erling Sm?rgrav , gepu@flow.rdsnet.ro, Steven Hartland , freebsd-stable@freebsd.org, freebsd-hackers@freebsd.org Subject: Re: How to enable more than 256 pty's? 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, 04 Oct 2007 15:17:57 -0000 On 2007-10-04 18:05, Vlad GALU wrote: >On 10/4/07, Giorgos Keramidas wrote: >>On 2007-10-02 15:41, Vlad GALU wrote: >>>On 10/2/07, Dag-Erling Sm?rgrav wrote: >>>>"Vlad GALU" writes: >>>>> The symptoms were exhibited even with rev. 1.16. I've CC'ed him so >>>>> he can catch up with the thread. >>>> >>>> Which symptoms? I can no longer reproduce the hang-on-close bug. >>> >>> Strangely enough, me neither. In his case, allocated pts' wouldn't >>> get deallocated once the sessions ended. >> >> There was an old bug, which caused pts consumers to get stuck in >> "devdrn". This has been fixed, AFAICT, a long time ago. At least, I >> can't reproduce it any more with the usual tests: >> >> * Closing xterm windows. >> >> * Closing telnet sessions. >> >> * Exiting from screen(1) windows. > > Weird. 3 people on this thread already saw the symptoms :( It must be a different problem, then. I used to have a local patch which reverted the devdrn wait in kern_conf.c:destroy_devl() near the lines: 753 while (dev->si_threadcount != 0) { 754 /* Use unique dummy wait ident */ 755 msleep(&csw, &devmtx, PRIBIO, "devdrn", hz / 10); 756 } but the original problem I was seeing seems to have been fixed. At least, I can't reproduce it was easily anymore... From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 16:17:22 2007 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 26B1416A417 for ; Thu, 4 Oct 2007 16:17:21 +0000 (UTC) (envelope-from tom@tomjudge.com) Received: from s200aog10.obsmtp.com (s200aog10.obsmtp.com [207.126.144.124]) by mx1.freebsd.org (Postfix) with SMTP id 58D0013C494 for ; Thu, 4 Oct 2007 16:17:11 +0000 (UTC) (envelope-from tom@tomjudge.com) Received: from source ([217.206.187.80]) by eu1sys200aob010.postini.com ([207.126.147.11]) with SMTP; Thu, 04 Oct 2007 16:17:09 UTC Received: from [10.0.0.89] (bill.mintel.co.uk [10.0.0.89]) by rodney.mintel.co.uk (Postfix) with ESMTP id 6B84D18141C; Thu, 4 Oct 2007 17:17:09 +0100 (BST) Message-ID: <47051204.6020905@tomjudge.com> Date: Thu, 04 Oct 2007 17:17:08 +0100 From: Tom Judge User-Agent: Thunderbird 1.5.0.12 (X11/20070604) MIME-Version: 1.0 To: Sharad Chandra References: <200710041725.00842.sharadc@in.niksun.com> In-Reply-To: <200710041725.00842.sharadc@in.niksun.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 04 Oct 2007 16:17:22 -0000 Sharad Chandra wrote: > Hello, > > How to distinguish if /dev/da* devices are internal scsi drivers or LUNs of > external SAN? > > Is there any tool? > > Thanks for any advice. > Sharad Chandra > _______________________________________________ > 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" Once you have identified the devices (using methods already suggested) you may want to take a look at geom_label to give friendly names to your partitions that are more descriptive than the da... names you have at the moment. Tom From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 16:56:00 2007 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 437AC16A417 for ; Thu, 4 Oct 2007 16:56:00 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 3AD2513C45B for ; Thu, 4 Oct 2007 16:55:55 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id 193E71A4D8B; Thu, 4 Oct 2007 09:55:55 -0700 (PDT) Date: Thu, 4 Oct 2007 09:55:55 -0700 From: Alfred Perlstein To: Dag-Erling Sm??rgrav Message-ID: <20071004165555.GQ31826@elvis.mu.org> References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> <20071004094821.GM31826@elvis.mu.org> <86ejgbqjvr.fsf@ds4.des.no> <20071004101902.GN31826@elvis.mu.org> <863awrqilu.fsf@ds4.des.no> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <863awrqilu.fsf@ds4.des.no> User-Agent: Mutt/1.4.2.3i Cc: hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 16:56:00 -0000 * Dag-Erling Sm??rgrav [071004 03:28] wrote: > Alfred Perlstein writes: > > It's not worth my time to engage someone with your mind set, you > > posses neither the technical nor interpersonal skill to be useful > > to me. > > This could be the beginning of a wonderful friendship... > > > For context see my replies in this thread to Kip Macy which explains > > how one deals with the false-problems you mention. > > I did read them, and I'm not convinced at all. You are asking for a > large amount of complexity to be added to the system, but you refuse to > tell us what you're actually trying to do. Are you worried that we > might actually figure out a way to do it without raping the scheduler? As already explained by Kip, the goal is to avoid switching out a lock owner due to quantum exhaustion at an inopportune time. We have needs that may wind up not being applicable to FreeBSD, however if we can accomplish this in a way that is not too awful we would likely be sharing the code, no matter how annoying you make it. :) -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 17:03:54 2007 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 2FD3716A41A; Thu, 4 Oct 2007 17:03:54 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 25B3413C447; Thu, 4 Oct 2007 17:03:54 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id EE6E01A4D8B; Thu, 4 Oct 2007 10:03:53 -0700 (PDT) Date: Thu, 4 Oct 2007 10:03:53 -0700 From: Alfred Perlstein To: Daniel Eischen Message-ID: <20071004170353.GR31826@elvis.mu.org> References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> <20071004094821.GM31826@elvis.mu.org> <86ejgbqjvr.fsf@ds4.des.no> <20071004101902.GN31826@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i Cc: Dag-Erling Sm??rgrav , hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 17:03:54 -0000 * Daniel Eischen [071004 06:05] wrote: > > His point about telling us what you're really doing, so we might > off other ways to do it is valid. > > We don't know why you are using homegrown user-level spinlocks > instead of pthread mutexes. Priority ceiling mutexes and running > in SCHED_RR or SCHED_FIFO is really what tries to address this > problem, at least from the vague desciption you give. If you > have tried this and they don't work correctly, then one solution > is to fix them ;-) First of all we're stuck on 6.x, how is threads on this platform? Second off we are contending against other devices in the system that do not run FreeBSD, How do we address that? -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 17:11:42 2007 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 349E616A41B for ; Thu, 4 Oct 2007 17:11:42 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id 2C45413C447 for ; Thu, 4 Oct 2007 17:11:42 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id 08EE71A4D8B; Thu, 4 Oct 2007 10:11:42 -0700 (PDT) Date: Thu, 4 Oct 2007 10:11:41 -0700 From: Alfred Perlstein To: Wilko Bulte Message-ID: <20071004171141.GS31826@elvis.mu.org> References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> <20071004094821.GM31826@elvis.mu.org> <86ejgbqjvr.fsf@ds4.des.no> <20071004101902.GN31826@elvis.mu.org> <20071004111535.GA42121@freebie.xs4all.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20071004111535.GA42121@freebie.xs4all.nl> User-Agent: Mutt/1.4.2.3i Cc: Dag-Erling Sm??rgrav , hackers@FreeBSD.ORG Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 17:11:42 -0000 * Wilko Bulte [071004 04:15] wrote: > Quoting Alfred Perlstein, who wrote on Thu, Oct 04, 2007 at 03:19:02AM -0700 .. > > * Dag-Erling Sm??rgrav [071004 03:01] wrote: > > > Alfred Perlstein writes: > > > > Do you have: > > > > > > > > a) Evidence or a paper to prove that this is a bad idea? > > > > > > I need evidence or a paper to prove that it is a bad idea to allow a > > > userland process to hold the CPU indefinitely? > > > > > > > b) A helpful suggestion? > > > > > > Why don't you tell us what you're actually trying to do, so we can tell > > > you how to do it. > > > > > > > c) An obvious understanding of the problem? > > > > > > I'll show you mine if you show me yours. > > > > It's not worth my time to engage someone with your mind set, you > > posses neither the technical nor interpersonal skill to be useful > > to me. > > Gentlemen... please? I think that it would behoove us to explain to developers that perhaps helping the users instead of talking down to them would probably catch more flies. I'm really tired of being told what I need by people that do not understand what environment I'm coming from. By not fielding these annoying responses I come across as clueless or perhaps even satiated by the non-help, conversely by answering I am forced to play this game with people that I'm quite certain will not help me even if they are somehow satisfied by the intellectual or sadistic things they are trying to extract. Even after making it clear with Kip what is needed, I have two more developers toying/trolling/etc with me rather than helping me. Here is how I handle the "holy crap your idea is hair-brained", I simply say, "well if you do that, you'll be worse off because of X, Y or Z and missing out on feature A, B or C, buuuuuuut, here's how you might accomplish that...." So not only do I come across as smart, but also somewhat helpful. I think we should all know that too much of the former without the latter does not paint us in a good light. thank you, -- - Alfred Perlstein From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 17:43:29 2007 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 73D3316A41B; Thu, 4 Oct 2007 17:43:29 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from mail.netplex.net (mail.netplex.net [204.213.176.10]) by mx1.freebsd.org (Postfix) with ESMTP id B829C13C478; Thu, 4 Oct 2007 17:43:23 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.netplex.net (8.14.1/8.14.1/NETPLEX) with ESMTP id l94HhKxA020047; Thu, 4 Oct 2007 13:43:20 -0400 (EDT) X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.netplex.net) X-Greylist: Message whitelisted by DRAC access database, not delayed by milter-greylist-3.0 (mail.netplex.net [204.213.176.10]); Thu, 04 Oct 2007 13:43:20 -0400 (EDT) Date: Thu, 4 Oct 2007 13:43:20 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Alfred Perlstein In-Reply-To: <20071004170353.GR31826@elvis.mu.org> Message-ID: References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> <20071004094821.GM31826@elvis.mu.org> <86ejgbqjvr.fsf@ds4.des.no> <20071004101902.GN31826@elvis.mu.org> <20071004170353.GR31826@elvis.mu.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: Dag-Erling Sm??rgrav , hackers@freebsd.org Subject: Re: Critical Sections for userland. X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Oct 2007 17:43:29 -0000 On Thu, 4 Oct 2007, Alfred Perlstein wrote: > * Daniel Eischen [071004 06:05] wrote: >> >> His point about telling us what you're really doing, so we might >> off other ways to do it is valid. >> >> We don't know why you are using homegrown user-level spinlocks >> instead of pthread mutexes. Priority ceiling mutexes and running >> in SCHED_RR or SCHED_FIFO is really what tries to address this >> problem, at least from the vague desciption you give. If you >> have tried this and they don't work correctly, then one solution >> is to fix them ;-) > > First of all we're stuck on 6.x, how is threads on this platform? I don't _think_ there is anything prohibitive of MFC'ing any libthr bug fixes into 6.x. I would have thought that you would have tried libthr on 6.x and possibly offered up "libthr performance sucks for me, and here's why" :-) You should probably ask David Xu about priority ceiling mutexes work on 6.x. > Second off we are contending against other devices in the system > that do not run FreeBSD, How do we address that? If you're running in real-time, then you are suppose to have priority over anything else except for ithreads. How much interrupt load is on your system and is ithread processing really going to impact you? If everything is working correctly and your thread that holds a priority ceiling mutex gets swapped out for an ithread, that thread should run again after the ithread. It shouldn't get swapped out for a different thread that doesn't also have its priority elevated (due to holding a similar mutex). I don't know if anyone other than possibly David Xu have tested SCHED_RR or SCHED_FIFO and priority ceiling mutexes, so they may not work as they're suppose to. -- DE From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 18:19:26 2007 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 5AA9A16A418 for ; Thu, 4 Oct 2007 18:19:26 +0000 (UTC) (envelope-from asmrookie@gmail.com) Received: from nf-out-0910.google.com (nf-out-0910.google.com [64.233.182.188]) by mx1.freebsd.org (Postfix) with ESMTP id E247713C46E for ; Thu, 4 Oct 2007 18:19:25 +0000 (UTC) (envelope-from asmrookie@gmail.com) Received: by nf-out-0910.google.com with SMTP id b2so230876nfb for ; Thu, 04 Oct 2007 11:19:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; 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=WJu+oFz5GcjlszjBnJdvIlk96OBYG0wB5i3VeVzh1O0=; b=D0Kj295xLQ37UncH82jYxRsj5YAIKcUSkDUcepKOImw3UdEN9yA9pWwtl+j3FzH8wBqsZcRnbEee5XwbN22PuslzDGwtXiMqWB6aJqblDvLgz1ZcCV5vTTVnktyDg+a1CbnEXTHlPMS6rlnI/jCNXEmGlZK0oFwaBj5FO+AC6AI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=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; b=oBL67iXkw939xxywCqe1yjcz0u7XprgVVAUsrBSbivBnlsZG82GP/3tKpwRg1zFp69ukSccMj2FMGYW2CeTBhIl3vuTE70lSSXhWh0PZcWZfX0cBbl2IvCLrE/rHTskMxTrzy85RBe8QFWvnJlke3+GNML3FoAG37zKubwl6LGw= Received: by 10.78.183.8 with SMTP id g8mr1349001huf.1191520469744; Thu, 04 Oct 2007 10:54:29 -0700 (PDT) Received: by 10.78.97.18 with HTTP; Thu, 4 Oct 2007 10:54:29 -0700 (PDT) Message-ID: <3bbf2fe10710041054x1c580bb2m892bf389a70c0e6c@mail.gmail.com> Date: Thu, 4 Oct 2007 19:54:29 +0200 From: "Attilio Rao" Sender: asmrookie@gmail.com To: "Alfred Perlstein" In-Reply-To: <20071003025418.GN31826@elvis.mu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20071003015231.GJ31826@elvis.mu.org> <20071003025418.GN31826@elvis.mu.org> X-Google-Sender-Auth: 04137b305c274307 Cc: Daniel Eischen , hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 18:19:26 -0000 2007/10/3, Alfred Perlstein : > * Daniel Eischen [071002 19:46] wrote: > > On Tue, 2 Oct 2007, Alfred Perlstein wrote: > > > > >Hi guys, we need critical sections for userland here. > > > > > >This is basically to avoid a process being switched out while holding > > >a user level spinlock. > > > > Setting the scheduling class to real-time and using SCHED_FIFO > > and adjusting the thread priority around the lock doesn't work? > > Too heavy weight, we want to basically have this sort of code > in userland: > > /* assume single threaded process for now */ > static int is_critical; > > > > atomic_mutex_lock(); /* implies ++is_critical */ > ...do stuff... > atomic_mutex_unlock(); /* implies --is_critical */ > > We don't want two or more syscalls per lock operation. :) Basically, preemption in kernelspace is handled by using the td_critnest counter which should work in this way: - critical_enter() bumps td_critnest - if preemption is required or an ipi arrives and the operation is signalled with the td_owepreempt flag and will be deferred. - once critical_exit() is called the counter is decreased. If necessary (checking for td_critnest and td_owepreempt) the preemptive operation happens instantanely. It is all very fast and highly scalable as scope of operation is entirely per-thread so it doesn't require any lock. I think maybe you should use a very similar scheme to this. Attilio -- Peace can only be achieved by understanding - A. Einstein From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 4 19:38:22 2007 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 3D91616A421 for ; Thu, 4 Oct 2007 19:38:22 +0000 (UTC) (envelope-from julian@elischer.org) Received: from outG.internet-mail-service.net (outG.internet-mail-service.net [216.240.47.230]) by mx1.freebsd.org (Postfix) with ESMTP id 2437F13C474 for ; Thu, 4 Oct 2007 19:38:21 +0000 (UTC) (envelope-from julian@elischer.org) Received: from mx0.idiom.com (HELO idiom.com) (216.240.32.160) by out.internet-mail-service.net (qpsmtpd/0.40) with ESMTP; Thu, 04 Oct 2007 12:25:24 -0700 X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e Received: from julian-mac.elischer.org (home.elischer.org [216.240.48.38]) by idiom.com (Postfix) with ESMTP id D79F01265BA; Thu, 4 Oct 2007 12:25:23 -0700 (PDT) Message-ID: <47053E26.1020309@elischer.org> Date: Thu, 04 Oct 2007 12:25:26 -0700 From: Julian Elischer User-Agent: Thunderbird 2.0.0.6 (Macintosh/20070728) MIME-Version: 1.0 To: Attilio Rao References: <20071003015231.GJ31826@elvis.mu.org> <20071003025418.GN31826@elvis.mu.org> <3bbf2fe10710041054x1c580bb2m892bf389a70c0e6c@mail.gmail.com> In-Reply-To: <3bbf2fe10710041054x1c580bb2m892bf389a70c0e6c@mail.gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: Daniel Eischen , Alfred Perlstein , hackers@freebsd.org Subject: Re: Critical Sections for userland. 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, 04 Oct 2007 19:38:22 -0000 Attilio Rao wrote: > 2007/10/3, Alfred Perlstein : >> * Daniel Eischen [071002 19:46] wrote: >>> On Tue, 2 Oct 2007, Alfred Perlstein wrote: >>> >>>> Hi guys, we need critical sections for userland here. >>>> >>>> This is basically to avoid a process being switched out while holding >>>> a user level spinlock. >>> Setting the scheduling class to real-time and using SCHED_FIFO >>> and adjusting the thread priority around the lock doesn't work? >> Too heavy weight, we want to basically have this sort of code >> in userland: >> >> /* assume single threaded process for now */ >> static int is_critical; >> >> >> >> atomic_mutex_lock(); /* implies ++is_critical */ >> ...do stuff... >> atomic_mutex_unlock(); /* implies --is_critical */ >> >> We don't want two or more syscalls per lock operation. :) > > Basically, preemption in kernelspace is handled by using the > td_critnest counter which should work in this way: > - critical_enter() bumps td_critnest > - if preemption is required or an ipi arrives and the operation is > signalled with the td_owepreempt flag and will be deferred. > - once critical_exit() is called the counter is decreased. If > necessary (checking for td_critnest and td_owepreempt) the preemptive > operation happens instantanely. > > It is all very fast and highly scalable as scope of operation is > entirely per-thread so it doesn't require any lock. I think maybe you > should use a very similar scheme to this. > > Attilio > > I suggest that we map a per-thread page into the address space if it requests it. (and a per process page). The scheduler could look at it for behavioural hints when it is present. there are ways this could be done. it sort of dovetails into work other people have been considering.. From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 01:15:37 2007 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 7C77E16A420; Fri, 5 Oct 2007 01:15:37 +0000 (UTC) (envelope-from xcllnt@mac.com) Received: from smtpoutm.mac.com (smtpoutm.mac.com [17.148.16.79]) by mx1.freebsd.org (Postfix) with ESMTP id 6878C13C4AC; Fri, 5 Oct 2007 01:15:37 +0000 (UTC) (envelope-from xcllnt@mac.com) Received: from mac.com (smtpin04-en2 [10.13.10.149]) by smtpoutm.mac.com (Xserve/smtpout016/MantshX 4.0) with ESMTP id l950eORW024861; Thu, 4 Oct 2007 17:40:24 -0700 (PDT) Received: from [172.24.104.86] (natint3.juniper.net [66.129.224.36]) (authenticated bits=0) by mac.com (Xserve/smtpin04/MantshX 4.0) with ESMTP id l950eMVG003106 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Thu, 4 Oct 2007 17:40:23 -0700 (PDT) In-Reply-To: References: <20071003015231.GJ31826@elvis.mu.org> <86zlyzqmgo.fsf@ds4.des.no> <20071004094821.GM31826@elvis.mu.org> <86ejgbqjvr.fsf@ds4.des.no> <20071004101902.GN31826@elvis.mu.org> <20071004170353.GR31826@elvis.mu.org> Mime-Version: 1.0 (Apple Message framework v752.3) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: Content-Transfer-Encoding: 7bit From: Marcel Moolenaar Date: Thu, 4 Oct 2007 17:40:07 -0700 To: Daniel Eischen X-Mailer: Apple Mail (2.752.3) Cc: hackers@freebsd.org, Dag-Erling Sm??rgrav , Alfred Perlstein Subject: Re: Critical Sections for userland. 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, 05 Oct 2007 01:15:37 -0000 On Oct 4, 2007, at 10:43 AM, Daniel Eischen wrote: > On Thu, 4 Oct 2007, Alfred Perlstein wrote: > >> * Daniel Eischen [071004 06:05] wrote: >>> >>> His point about telling us what you're really doing, so we might >>> off other ways to do it is valid. >>> >>> We don't know why you are using homegrown user-level spinlocks >>> instead of pthread mutexes. Priority ceiling mutexes and running >>> in SCHED_RR or SCHED_FIFO is really what tries to address this >>> problem, at least from the vague desciption you give. If you >>> have tried this and they don't work correctly, then one solution >>> is to fix them ;-) >> >> First of all we're stuck on 6.x, how is threads on this platform? > > I don't _think_ there is anything prohibitive of MFC'ing > any libthr bug fixes into 6.x. I would have thought that > you would have tried libthr on 6.x and possibly offered up > "libthr performance sucks for me, and here's why" :-) Alfred: The Hurricane team uses 1x1 threading on PowerPC without problems. The patch below fixes a NULL pointer dereference in the POSIX priority cases: diff -up /b/marcelm/freebsd/6.x/src/lib/libthr/thread/thr_mutex.c ./ thr_mutex.c --- /b/marcelm/freebsd/6.x/src/lib/libthr/thread/thr_mutex.c Sun Jan 15 21:36:30 2006 +++ ./thr_mutex.c Sun Sep 9 20:58:20 2007 @@ -629,10 +629,14 @@ mutex_lock_common(struct pthread *curthr /* Unlock the mutex structure: */ THR_LOCK_RELEASE(curthread, &(*m)- >m_lock); - clock_gettime(CLOCK_REALTIME, &ts); - TIMESPEC_SUB(&ts2, abstime, &ts); - ret = _thr_umtx_wait(&curthread- >cycle, cycle, - &ts2); + if (abstime != NULL) { + clock_gettime(CLOCK_REALTIME, &ts); + TIMESPEC_SUB(&ts2, abstime, &ts); + ret = _thr_umtx_wait (&curthread->cycle, + cycle, &ts2); + } else + ret = _thr_umtx_wait (&curthread->cycle, + cycle, NULL); if (ret == EINTR) ret = 0; @@ -712,10 +716,14 @@ mutex_lock_common(struct pthread *curthr /* Unlock the mutex structure: */ THR_LOCK_RELEASE(curthread, &(*m)- >m_lock); - clock_gettime(CLOCK_REALTIME, &ts); - TIMESPEC_SUB(&ts2, abstime, &ts); - ret = _thr_umtx_wait(&curthread- >cycle, cycle, - &ts2); + if (abstime != NULL) { + clock_gettime(CLOCK_REALTIME, &ts); + TIMESPEC_SUB(&ts2, abstime, &ts); + ret = _thr_umtx_wait (&curthread->cycle, + cycle, &ts2); + } else + ret = _thr_umtx_wait (&curthread->cycle, + cycle, NULL); if (ret == EINTR) ret = 0; > I don't know if anyone other than possibly David Xu have > tested SCHED_RR or SCHED_FIFO and priority ceiling mutexes, > so they may not work as they're suppose to. We use it successfully with the above patch. FYI, -- Marcel Moolenaar xcllnt@mac.com From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 04:32:51 2007 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 4B50F16A41A for ; Fri, 5 Oct 2007 04:32:51 +0000 (UTC) (envelope-from pb@ludd.ltu.se) Received: from mother.ludd.ltu.se (mother.ludd.ltu.se [130.240.16.3]) by mx1.freebsd.org (Postfix) with ESMTP id A7B5D13C458 for ; Fri, 5 Oct 2007 04:32:50 +0000 (UTC) (envelope-from pb@ludd.ltu.se) Received: from brother.ludd.ltu.se (root@brother.ludd.ltu.se [130.240.16.78]) by mother.ludd.ltu.se (8.13.6+Sun/8.12.10) with ESMTP id l954WkYR023777 for ; Fri, 5 Oct 2007 06:32:46 +0200 (MEST) Received: from brother.ludd.ltu.se (pb@localhost [127.0.0.1]) by brother.ludd.ltu.se (8.13.6+Sun/8.12.2) with ESMTP id l954WkYv000216 for ; Fri, 5 Oct 2007 06:32:46 +0200 (MEST) Received: (from pb@localhost) by brother.ludd.ltu.se (8.13.6+Sun/8.13.6/Submit) id l954WhFS000214 for freebsd-hackers@freebsd.org; Fri, 5 Oct 2007 06:32:43 +0200 (MEST) From: Peter B Message-Id: <200710050432.l954WhFS000214@brother.ludd.ltu.se> To: freebsd-hackers@freebsd.org Date: Fri, 5 Oct 2007 06:32:43 +0200 (MEST) X-Mailer: ELM [version 2.5 PL6] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Fri, 05 Oct 2007 05:08:09 +0000 Subject: FYI: 3Ware 9650 can cause data corruption 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, 05 Oct 2007 04:32:51 -0000 3ware 9650 in RAID6 mode with firmware version 3.08.00.004 seems to cause data corruption when rebuilding a single disc with raid6. http://www.webmasternetwork.se/f4t23551.html (Swedish) I thought this was serious enough for people to know. If another mailinglist is more appropiate for this kind of FYI then tell. From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 05:48:43 2007 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 297DE16A417 for ; Fri, 5 Oct 2007 05:48:43 +0000 (UTC) (envelope-from freebsd@bitfreak.org) Received: from mail.twinthornes.com (mail.twinthornes.com [65.75.198.147]) by mx1.freebsd.org (Postfix) with ESMTP id F0FB913C49D for ; Fri, 5 Oct 2007 05:48:42 +0000 (UTC) (envelope-from freebsd@bitfreak.org) Received: from [10.9.70.100] (pool-71-117-232-141.ptldor.fios.verizon.net [71.117.232.141]) by mail.twinthornes.com (Postfix) with ESMTP id 5C7338F; Thu, 4 Oct 2007 22:27:14 -0700 (PDT) Message-ID: <4705CB32.8080001@bitfreak.org> Date: Thu, 04 Oct 2007 22:27:14 -0700 From: Darren Pilgrim User-Agent: Thunderbird 2.0.0.6 (Windows/20070728) MIME-Version: 1.0 To: Peter B References: <200710050432.l954WhFS000214@brother.ludd.ltu.se> In-Reply-To: <200710050432.l954WhFS000214@brother.ludd.ltu.se> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: FYI: 3Ware 9650 can cause data corruption 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, 05 Oct 2007 05:48:43 -0000 Peter B wrote: > 3ware 9650 in RAID6 mode with firmware version 3.08.00.004 seems to cause > data corruption when rebuilding a single disc with raid6. > > http://www.webmasternetwork.se/f4t23551.html (Swedish) > > I thought this was serious enough for people to know. If another mailinglist > is more appropiate for this kind of FYI then tell. This is a known issue with 3ware software v9.4.1.0 and 9.4.1.1 (firmware v3.08.00.004). 3ware released software v9.4.1.2 (firmware 3.08.02.005) that corrects the problem over three months ago and it has since been obsoleted by 9.4.1.3 and 9.5.0 (released earlier this week). In fact, the link you cite links to 3ware's advisory: http://www.3ware.com/support/UserDocs/RAID6-data-integrity-customer-notification_061907-FINAL.pdf While it is appreciated that you felt obligated to post this important bug notice, it would be even more appreciated if in the future, you would do a bit of research before clicking send. From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 11:19:28 2007 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 5FFAD16A41A; Fri, 5 Oct 2007 11:19:28 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from in.niksun.com (210.18.76.166.sify.net [210.18.76.166]) by mx1.freebsd.org (Postfix) with ESMTP id E6A7913C49D; Fri, 5 Oct 2007 11:19:27 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from sharadc.in.niksun.com (unknown [10.60.5.27]) by in.niksun.com (Postfix) with ESMTP id 535215C9C; Fri, 5 Oct 2007 16:57:29 +0530 (IST) From: Sharad Chandra Organization: NIKSUN To: Eric Anderson Date: Fri, 5 Oct 2007 16:46:17 +0530 User-Agent: KMail/1.9.4 References: <200710041725.00842.sharadc@in.niksun.com> <4704E8F1.8070000@freebsd.org> In-Reply-To: <4704E8F1.8070000@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200710051646.17618.sharadc@in.niksun.com> Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 11:19:28 -0000 Yes, right by analyzing camcontrol devlist it can be told, but i guess not= =20 always. [root@qa7 ~]# camcontrol devlist =A0 =A0 =A0 =A0 =A0 =A0 =A0at scbus0 target 0 lun 0 (= da0,pass0) =A0 =A0 =A0 =A0 =A0 =A0 =A0at scbus0 target 0 lun 1 (= da1,pass1) =A0 =A0 =A0 =A0 =A0 =A0 =A0at scbus0 target 0 lun 2 (= da2,pass2) =A0 =A0 =A0 =A0 =A0 =A0 =A0at scbus0 target 0 lun 3 (= da3,pass3) Here luns are increasing, so it is SAN confirmed by tool. Now my point is i= f i=20 have a SAN of less than 1TB and i make only 1 LUN. what should be output? guessing: similar to =A0 =A0 =A0 =A0 =A0 =A0 =A0at scbus0 target 0 lun 0 (= da0,pass0) Then it will be difficult to tell, whether it is regular SCSI drives or SAN= =2E=20 Then we need a tool that can tell this da0 belongs to SAN/SCSI or not Thanks for any suggestion. Sharad Chandra On Thursday 04 October 2007 6:51 pm, Eric Anderson wrote: > Sharad Chandra wrote: > > Hello, > > > > How to distinguish if /dev/da* devices are internal scsi drivers or LU= Ns > > of external SAN? > > camcontrol devlist -v > > Might help you.. > > Eric From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 11:55:13 2007 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 CD05616A419 for ; Fri, 5 Oct 2007 11:55:13 +0000 (UTC) (envelope-from anderson@freebsd.org) Received: from ns.trinitel.com (186.161.36.72.static.reverse.ltdomains.com [72.36.161.186]) by mx1.freebsd.org (Postfix) with ESMTP id 90BE013C47E for ; Fri, 5 Oct 2007 11:55:13 +0000 (UTC) (envelope-from anderson@freebsd.org) Received: from proton.storspeed.com (209-163-168-124.static.twtelecom.net [209.163.168.124]) (authenticated bits=0) by ns.trinitel.com (8.14.1/8.14.1) with ESMTP id l95BtAPq032970; Fri, 5 Oct 2007 06:55:12 -0500 (CDT) (envelope-from anderson@freebsd.org) Message-ID: <4706261B.1050202@freebsd.org> Date: Fri, 05 Oct 2007 06:55:07 -0500 From: Eric Anderson User-Agent: Thunderbird 2.0.0.6 (Macintosh/20070728) MIME-Version: 1.0 To: Sharad Chandra References: <200710041725.00842.sharadc@in.niksun.com> <4704E8F1.8070000@freebsd.org> <200710051646.17618.sharadc@in.niksun.com> In-Reply-To: <200710051646.17618.sharadc@in.niksun.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.1.8 X-Spam-Checker-Version: SpamAssassin 3.1.8 (2007-02-13) on ns.trinitel.com Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 11:55:13 -0000 Sharad Chandra wrote: > On Thursday 04 October 2007 6:51 pm, Eric Anderson wrote: >> Sharad Chandra wrote: >>> Hello, >>> >>> How to distinguish if /dev/da* devices are internal scsi drivers or LUNs >>> of external SAN? >> camcontrol devlist -v >> >> Might help you.. >> >> Eric > Yes, right by analyzing camcontrol devlist it can be told, but i guess not > always. > > [root@qa7 ~]# camcontrol devlist > at scbus0 target 0 lun 0 (da0,pass0) > at scbus0 target 0 lun 1 (da1,pass1) > at scbus0 target 0 lun 2 (da2,pass2) > at scbus0 target 0 lun 3 (da3,pass3) > > Here luns are increasing, so it is SAN confirmed by tool. Now my point is if i > have a SAN of less than 1TB and i make only 1 LUN. what should be output? > guessing: similar to > at scbus0 target 0 lun 0 (da0,pass0) > > Then it will be difficult to tell, whether it is regular SCSI drives or SAN. > Then we need a tool that can tell this da0 belongs to SAN/SCSI or not Notice the -v to camcontrol. It will tell you which controller the device belongs to, and the controller will help you determine whether it is connected to a SAN or not. Other than that, I'm not sure of the distinction that could be made between the devices whether it is on a SAN or not. It could be a directly connected fiber channel device, in which case, it isn't quite a SAN, yet the FreeBSD system doesn't know (or care) how it's connected. Eric From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 11:56:06 2007 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 9027C16A46C for ; Fri, 5 Oct 2007 11:56:06 +0000 (UTC) (envelope-from tevans.uk@googlemail.com) Received: from rv-out-0910.google.com (rv-out-0910.google.com [209.85.198.191]) by mx1.freebsd.org (Postfix) with ESMTP id 334F213C45A for ; Fri, 5 Oct 2007 11:56:05 +0000 (UTC) (envelope-from tevans.uk@googlemail.com) Received: by rv-out-0910.google.com with SMTP id l15so75702rvb for ; Fri, 05 Oct 2007 04:56:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=beta; h=domainkey-signature:received:received:subject:from:to:cc:in-reply-to:references:content-type:date:message-id:mime-version:x-mailer; bh=S2uIAGu93VwRfiR2L6klLVo5SEg5P0kHnvoP+teIn+c=; b=kzfXkxsSUHOmbffuqA5Bu+Amm6rQogVSZIeGaRsZdwW5QtkBC9IOfFNeHI6wQv1MpwbgvHS0ncUq7TfcNUOlDx3RjRvV/4FC347dgCbzGsNXpmPR9nmSSrwAOJ6zvzhhY6A1G9//ObPfwCKt8kWf13kcctS+sbWtTKslxw0Xb20= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=beta; h=received:subject:from:to:cc:in-reply-to:references:content-type:date:message-id:mime-version:x-mailer; b=YizT0ED/IqMzugWbb42mhz5MYaAQ3Rclm1TJ31TmycHJOsi5D1bCzwfCrlTdFb2etXs94HgG6qCeMmkGxCvOqdS55cjptSnKBWS/jVSZ1PqwQfUpDwJCKTir10CTvlelVTuPjMz3gODORxD/zisGWuKFJhdUnWKMdW66fMT/85U= Received: by 10.141.205.10 with SMTP id h10mr1581248rvq.1191584944650; Fri, 05 Oct 2007 04:49:04 -0700 (PDT) Received: from ?127.0.0.1? ( [217.206.187.79]) by mx.google.com with ESMTPS id i7sm5164855nfh.2007.10.05.04.49.03 (version=SSLv3 cipher=RC4-MD5); Fri, 05 Oct 2007 04:49:03 -0700 (PDT) From: Tom Evans To: Sharad Chandra In-Reply-To: <1191584622.1475.86.camel@localhost> References: <200710041725.00842.sharadc@in.niksun.com> <4704E8F1.8070000@freebsd.org> <200710051646.17618.sharadc@in.niksun.com> <1191584622.1475.86.camel@localhost> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-GPoRonUycik2iQgtCRqs" Date: Fri, 05 Oct 2007 12:49:02 +0100 Message-Id: <1191584942.1475.92.camel@localhost> Mime-Version: 1.0 X-Mailer: Evolution 2.10.2 FreeBSD GNOME Team Port Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 11:56:06 -0000 --=-GPoRonUycik2iQgtCRqs Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On Fri, 2007-10-05 at 12:43 +0100, Tom Evans wrote: .... Excuse the formatting, my keyboard went nuts and decided I was done editing :o In addition to the example I showed, I was just going to say that the purpose of glabel is to stop referring to /dev/da[0-9]* and instead be able to refer to /dev/label/san_0_lun_0 (or whatever you like). I don't know of a way to automagically determine if a disk is in fact a SAN, but it cannot be too hard to figure out from dmesg + information about the disk.=20 Once you have identified it LABEL IT! Then there is no more ambiguity. Regards Tom --=-GPoRonUycik2iQgtCRqs Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (FreeBSD) iD8DBQBHBiSulcRvFfyds/cRAuzfAKCsNQ8E4MW9+c0a69dlui+keL5C2QCgnJgL vb2FrheeX1O0zS56YMkSOI8= =u5YU -----END PGP SIGNATURE----- --=-GPoRonUycik2iQgtCRqs-- From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 11:59:52 2007 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 21CBF16A419; Fri, 5 Oct 2007 11:59:52 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from in.niksun.com (210.18.76.166.sify.net [210.18.76.166]) by mx1.freebsd.org (Postfix) with ESMTP id B145013C480; Fri, 5 Oct 2007 11:59:51 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from sharadc.in.niksun.com (unknown [10.60.5.27]) by in.niksun.com (Postfix) with ESMTP id E25E45D86; Fri, 5 Oct 2007 17:37:53 +0530 (IST) From: Sharad Chandra Organization: NIKSUN To: Eric Anderson Date: Fri, 5 Oct 2007 17:26:41 +0530 User-Agent: KMail/1.9.4 References: <200710041725.00842.sharadc@in.niksun.com> <4704E8F1.8070000@freebsd.org> <200710051646.17618.sharadc@in.niksun.com> In-Reply-To: <200710051646.17618.sharadc@in.niksun.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200710051726.41982.sharadc@in.niksun.com> Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 11:59:52 -0000 Wether it is SCSI or SANs LUNS, "sysctl kern.disks" always shows da. it= =20 don't distinguish b/w them. and similarly "/usr/local/sbin/smartctl -i da0"= =20 also gives results that is acceptable. Although i don't know what is that=20 Serial no in SANs LUN case. ex: [root@qa7 ~]# /usr/local/sbin/smartctl -i da0 smartctl version 5.37 [amd64-portbld-freebsd6.2] Copyright (C) 2002-6 Bruce= =20 Allen Home page is http://smartmontools.sourceforge.net/ Device: IFT A16F-G2422 Version: 348C Serial number: 0D7A8A6DC19F3500 Device type: disk (pass0:isp0:0:0:0): MODE SENSE(06). CDB: 1a 0 19 0 40 0 (pass0:isp0:0:0:0): CAM Status: SCSI Status Error (pass0:isp0:0:0:0): SCSI Status: Check Condition (pass0:isp0:0:0:0): ILLEGAL REQUEST asc:24,0 (pass0:isp0:0:0:0): Invalid field in CDB Local Time is: Fri Oct 5 03:37:54 2007 EDT Device supports SMART and is Enabled Temperature Warning Disabled or Not Supported on SCSI device pass0 errors don't come. Thanks Sharad Chandra On Friday 05 October 2007 4:46 pm, Sharad Chandra wrote: > Yes, right by analyzing camcontrol devlist it can be told, but i guess not > always. > > [root@qa7 ~]# camcontrol devlist > =A0 =A0 =A0 =A0 =A0 =A0 =A0at scbus0 target 0 lun 0= (da0,pass0) > =A0 =A0 =A0 =A0 =A0 =A0 =A0at scbus0 target 0 lun 1= (da1,pass1) > =A0 =A0 =A0 =A0 =A0 =A0 =A0at scbus0 target 0 lun 2= (da2,pass2) > =A0 =A0 =A0 =A0 =A0 =A0 =A0at scbus0 target 0 lun 3= (da3,pass3) > > Here luns are increasing, so it is SAN confirmed by tool. Now my point is > if i have a SAN of less than 1TB and i make only 1 LUN. what should be > output? guessing: similar to > =A0 =A0 =A0 =A0 =A0 =A0 =A0at scbus0 target 0 lun 0= (da0,pass0) > > Then it will be difficult to tell, whether it is regular SCSI drives or > SAN. Then we need a tool that can tell this da0 belongs to SAN/SCSI or not > > Thanks for any suggestion. > Sharad Chandra > > On Thursday 04 October 2007 6:51 pm, Eric Anderson wrote: > > Sharad Chandra wrote: > > > Hello, > > > > > > How to distinguish if /dev/da* devices are internal scsi drivers or > > > LUNs of external SAN? > > > > camcontrol devlist -v > > > > Might help you.. > > > > Eric From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 12:09:08 2007 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 805AC16A418 for ; Fri, 5 Oct 2007 12:09:08 +0000 (UTC) (envelope-from tevans.uk@googlemail.com) Received: from nf-out-0910.google.com (nf-out-0910.google.com [64.233.182.186]) by mx1.freebsd.org (Postfix) with ESMTP id 0104013C467 for ; Fri, 5 Oct 2007 12:09:07 +0000 (UTC) (envelope-from tevans.uk@googlemail.com) Received: by nf-out-0910.google.com with SMTP id b2so427084nfb for ; Fri, 05 Oct 2007 05:09:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=beta; h=domainkey-signature:received:received:subject:from:to:cc:in-reply-to:references:content-type:date:message-id:mime-version:x-mailer; bh=g3WvF5dzem4oHQ5cuUu/bSoSqtV/eILD+ZO27hMeIfk=; b=Abe/icI/rqqzRMOZIS2tQdaz+ehFAdUDyfobemL1RmqFEvRcsI0R52UXl3eRre+WR+lxkGDBB4R6EQ59l2y5w6aBx5bJyRO0zRfAj3vyLoMhuqD34ZyvGhm60eGmu8ezTnfLtGSH88ic+fhZ69tmWBoUKz54fllRSwOEJCWfo+4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=beta; h=received:subject:from:to:cc:in-reply-to:references:content-type:date:message-id:mime-version:x-mailer; b=MFoTkkDpFmqWR3bT/nPbHxEu/tpdTq69xGY5yQxpU7r6+vSluowY4hPY75x/s4SVSo9Peip6OK/l6gBL3Dfsh0ewQ9at5dRdQ8kDM23b3Xli+KIsWV3uFU0f00NQezoYpeE+VLnC6pahl8wy67L9MYcJyiKVSBd0uEawYuZlCBk= Received: by 10.78.149.15 with SMTP id w15mr300135hud.1191584626198; Fri, 05 Oct 2007 04:43:46 -0700 (PDT) Received: from ?127.0.0.1? ( [217.206.187.79]) by mx.google.com with ESMTPS id d24sm2250429nfh.2007.10.05.04.43.44 (version=SSLv3 cipher=RC4-MD5); Fri, 05 Oct 2007 04:43:44 -0700 (PDT) From: Tom Evans To: Sharad Chandra In-Reply-To: <200710051646.17618.sharadc@in.niksun.com> References: <200710041725.00842.sharadc@in.niksun.com> <4704E8F1.8070000@freebsd.org> <200710051646.17618.sharadc@in.niksun.com> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-J6TNgEX639D+Y46OWQL+" Date: Fri, 05 Oct 2007 12:43:42 +0100 Message-Id: <1191584622.1475.86.camel@localhost> Mime-Version: 1.0 X-Mailer: Evolution 2.10.2 FreeBSD GNOME Team Port Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 12:09:08 -0000 --=-J6TNgEX639D+Y46OWQL+ Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On Fri, 2007-10-05 at 16:46 +0530, Sharad Chandra wrote: > Yes, right by analyzing camcontrol devlist it can be told, but i guess no= t=20 > always. >=20 > [root@qa7 ~]# camcontrol devlist > at scbus0 target 0 lun 0 (da0,pass0) > at scbus0 target 0 lun 1 (da1,pass1) > at scbus0 target 0 lun 2 (da2,pass2) > at scbus0 target 0 lun 3 (da3,pass3) >=20 > Here luns are increasing, so it is SAN confirmed by tool. Now my point is= if i=20 > have a SAN of less than 1TB and i make only 1 LUN. what should be output? > guessing: similar to > at scbus0 target 0 lun 0 (da0,pass0) >=20 > Then it will be difficult to tell, whether it is regular SCSI drives or S= AN.=20 > Then we need a tool that can tell this da0 belongs to SAN/SCSI or not >=20 > Thanks for any suggestion. > Sharad Chandra >=20 > On Thursday 04 October 2007 6:51 pm, Eric Anderson wrote: > > Sharad Chandra wrote: > > > Hello, > > > > > > How to distinguish if /dev/da* devices are internal scsi drivers or = LUNs > > > of external SAN? > > > > camcontrol devlist -v > > > > Might help you.. > > > > Eric Hi As previously suggested, glabel(8) your da devices so you can distinguish between them. Example: glabel label -v usr /dev/da2 newfs /dev/label/usr mount /dev/label/usr /usr [...] umount /glabel stop usr glabel unload --=-J6TNgEX639D+Y46OWQL+ Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (FreeBSD) iD8DBQBHBiNulcRvFfyds/cRAlB0AKCdtyU9ZPPVoC0S2YLiSXrGobF30QCeL/m9 Baln11HNVXB1IHT5N0C797k= =USRL -----END PGP SIGNATURE----- --=-J6TNgEX639D+Y46OWQL+-- From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 12:45:03 2007 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 B673216A46E for ; Fri, 5 Oct 2007 12:45:03 +0000 (UTC) (envelope-from idefix@fechner.net) Received: from anny.lostinspace.de (anny.ipv6.lostinspace.de [IPv6:2a01:138:100:1:219:d1ff:fe6a:ef49]) by mx1.freebsd.org (Postfix) with ESMTP id 322FA13C46A for ; Fri, 5 Oct 2007 12:45:00 +0000 (UTC) (envelope-from idefix@fechner.net) Received: from server.idefix.lan (ppp-82-135-79-183.dynamic.mnet-online.de [82.135.79.183]) (authenticated bits=0) by anny.lostinspace.de (8.14.1/8.14.1) with ESMTP id l95Cik9I013755 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 5 Oct 2007 14:44:51 +0200 (CEST) (envelope-from idefix@fechner.net) Received: from idefix by server.idefix.lan with local (Exim 4.68 (FreeBSD)) (envelope-from ) id 1IdmXt-0009nL-Ig for freebsd-hackers@freebsd.org; Fri, 05 Oct 2007 14:44:45 +0200 Date: Fri, 5 Oct 2007 14:44:45 +0200 From: Matthias Fechner To: freebsd-hackers@freebsd.org Message-ID: <20071005124443.GB19621@server.idefix.lan> References: <46F22228.5070203@fechner.net> <20070923151916.GB1444@roadrunner.spoerlein.net> <20070924225841.GA75866@server.idefix.lan> <7ad7ddd90709250927o772264b1v34446145d292b8bd@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <7ad7ddd90709250927o772264b1v34446145d292b8bd@mail.gmail.com> X-Crypto: GnuPG/1.0.6 http://www.gnupg.org X-GnuPG: 0x1B756EF6 User-Agent: Mutt/1.5.16 (2007-06-09) Sender: Matthias Fechner X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-3.0 (anny.lostinspace.de [80.190.182.2]); Fri, 05 Oct 2007 14:44:51 +0200 (CEST) X-Spam-Status: No, score=-2.1 required=5.0 tests=AWL,BAYES_00, UNPARSEABLE_RELAY autolearn=ham version=3.2.3 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on anny.lostinspace.de X-Virus-Scanned: ClamAV 0.91.2/4477/Fri Oct 5 11:58:57 2007 on anny.lostinspace.de X-Virus-Status: Clean Subject: Re: Own Install CD with custom kernel 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, 05 Oct 2007 12:45:03 -0000 Hello Ulrich, * Ulrich Spoerlein [25-09-07 18:27]: > [...] > install.cfg, take a look at > /usr/src/usr.sbin/sysinstall/install.cfg thx a lot for your emails I was now able to generate the CD so it does exactly what i want. Best regards, Matthias -- "Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the universe trying to produce bigger and better idiots. So far, the universe is winning." -- Rich Cook From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 12:53:27 2007 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 68E7216A418; Fri, 5 Oct 2007 12:53:27 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from in.niksun.com (210.18.76.166.sify.net [210.18.76.166]) by mx1.freebsd.org (Postfix) with ESMTP id 018E413C48A; Fri, 5 Oct 2007 12:53:26 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from sharadc.in.niksun.com (unknown [10.60.5.27]) by in.niksun.com (Postfix) with ESMTP id 376635DE9; Fri, 5 Oct 2007 18:31:29 +0530 (IST) From: Sharad Chandra Organization: NIKSUN To: Tom Evans Date: Fri, 5 Oct 2007 18:20:17 +0530 User-Agent: KMail/1.9.4 References: <200710041725.00842.sharadc@in.niksun.com> <1191584622.1475.86.camel@localhost> <1191584942.1475.92.camel@localhost> In-Reply-To: <1191584942.1475.92.camel@localhost> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200710051820.17587.sharadc@in.niksun.com> Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 12:53:27 -0000 That's very right, but it needs a manual setup. Whereas I need to work on storage disks attached to system, to accomplish that i have to write a script and know in itself whether it is attached to SAN or not. I know mainly there are "sysctl kern.disks" storage attached to system, nothing else. Thanks Sharad Chandra On Friday 05 October 2007 5:19 pm, Tom Evans wrote: > On Fri, 2007-10-05 at 12:43 +0100, Tom Evans wrote: > .... > > Excuse the formatting, my keyboard went nuts and decided I was done > editing :o > > In addition to the example I showed, I was just going to say that the > purpose of glabel is to stop referring to /dev/da[0-9]* and instead be > able to refer to /dev/label/san_0_lun_0 (or whatever you like). I don't > know of a way to automagically determine if a disk is in fact a SAN, but > it cannot be too hard to figure out from dmesg + information about the > disk. > > Once you have identified it LABEL IT! Then there is no more ambiguity. > > Regards > > Tom From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 12:55:35 2007 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 9B57716A46E for ; Fri, 5 Oct 2007 12:55:35 +0000 (UTC) (envelope-from anderson@freebsd.org) Received: from ns.trinitel.com (186.161.36.72.static.reverse.ltdomains.com [72.36.161.186]) by mx1.freebsd.org (Postfix) with ESMTP id 5F56F13C461 for ; Fri, 5 Oct 2007 12:55:35 +0000 (UTC) (envelope-from anderson@freebsd.org) Received: from proton.storspeed.com (209-163-168-124.static.twtelecom.net [209.163.168.124]) (authenticated bits=0) by ns.trinitel.com (8.14.1/8.14.1) with ESMTP id l95CtWrK054770; Fri, 5 Oct 2007 07:55:34 -0500 (CDT) (envelope-from anderson@freebsd.org) Message-ID: <47063441.4080002@freebsd.org> Date: Fri, 05 Oct 2007 07:55:29 -0500 From: Eric Anderson User-Agent: Thunderbird 2.0.0.6 (Macintosh/20070728) MIME-Version: 1.0 To: Sharad Chandra References: <200710041725.00842.sharadc@in.niksun.com> <1191584622.1475.86.camel@localhost> <1191584942.1475.92.camel@localhost> <200710051820.17587.sharadc@in.niksun.com> In-Reply-To: <200710051820.17587.sharadc@in.niksun.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.1.8 X-Spam-Checker-Version: SpamAssassin 3.1.8 (2007-02-13) on ns.trinitel.com Cc: Tom Evans , freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 12:55:35 -0000 Sharad Chandra wrote: > That's very right, but it needs a manual setup. Whereas I need to work on > storage disks attached to system, to accomplish that i have to write a script > and know in itself whether it is attached to SAN or not. I know mainly there > are "sysctl kern.disks" storage attached to system, nothing else. You must be blocking my mails. camcontrol devlist -v ^^^^^^ It will tell you which controllers the devices are on. You can even show devices on a particular controller, say, an isp device. Eric > On Friday 05 October 2007 5:19 pm, Tom Evans wrote: >> On Fri, 2007-10-05 at 12:43 +0100, Tom Evans wrote: >> .... >> >> Excuse the formatting, my keyboard went nuts and decided I was done >> editing :o >> >> In addition to the example I showed, I was just going to say that the >> purpose of glabel is to stop referring to /dev/da[0-9]* and instead be >> able to refer to /dev/label/san_0_lun_0 (or whatever you like). I don't >> know of a way to automagically determine if a disk is in fact a SAN, but >> it cannot be too hard to figure out from dmesg + information about the >> disk. >> >> Once you have identified it LABEL IT! Then there is no more ambiguity. >> >> Regards >> >> Tom From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 13:01:18 2007 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 BA46F16A417; Fri, 5 Oct 2007 13:01:18 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from in.niksun.com (210.18.76.166.sify.net [210.18.76.166]) by mx1.freebsd.org (Postfix) with ESMTP id 5278E13C48E; Fri, 5 Oct 2007 13:01:18 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from sharadc.in.niksun.com (unknown [10.60.5.27]) by in.niksun.com (Postfix) with ESMTP id 6A7795CC0; Fri, 5 Oct 2007 18:39:20 +0530 (IST) From: Sharad Chandra Organization: NIKSUN To: Eric Anderson Date: Fri, 5 Oct 2007 18:28:08 +0530 User-Agent: KMail/1.9.4 References: <200710041725.00842.sharadc@in.niksun.com> <200710051646.17618.sharadc@in.niksun.com> <4706261B.1050202@freebsd.org> In-Reply-To: <4706261B.1050202@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200710051828.08343.sharadc@in.niksun.com> Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 13:01:18 -0000 On Friday 05 October 2007 5:25 pm, Eric Anderson wrote: > Sharad Chandra wrote: > > On Thursday 04 October 2007 6:51 pm, Eric Anderson wrote: > >> Sharad Chandra wrote: > >>> Hello, > >>> > >>> How to distinguish if /dev/da* devices are internal scsi drivers > > or LUNs > > >>> of external SAN? > >> > >> camcontrol devlist -v > >> > >> Might help you.. > >> > >> Eric > > > > Yes, right by analyzing camcontrol devlist it can be told, but i guess > > not always. > > > > [root@qa7 ~]# camcontrol devlist > > at scbus0 target 0 lun 0 (da0,pass0) > > at scbus0 target 0 lun 1 (da1,pass1) > > at scbus0 target 0 lun 2 (da2,pass2) > > at scbus0 target 0 lun 3 (da3,pass3) > > > > Here luns are increasing, so it is SAN confirmed by tool. Now my point is > > if i have a SAN of less than 1TB and i make only 1 LUN. what should be > > output? guessing: similar to > > at scbus0 target 0 lun 0 (da0,pass0) > > > > Then it will be difficult to tell, whether it is regular SCSI drives or > > SAN. Then we need a tool that can tell this da0 belongs to SAN/SCSI or > > not > > Notice the -v to camcontrol. It will tell you which controller the > device belongs to, and the controller will help you determine whether it > is connected to a SAN or not. [root@qa7 ~]# camcontrol devlist -v scbus0 on isp0 bus 0: at scbus0 target 0 lun 0 (da0,pass0) at scbus0 target 0 lun 1 (da1,pass1) at scbus0 target 0 lun 2 (da2,pass2) at scbus0 target 0 lun 3 (da3,pass3) < > at scbus0 target -1 lun -1 () scbus-1 on xpt0 bus 0: < > at scbus-1 target -1 lun -1 (xpt0) Does it? > > Other than that, I'm not sure of the distinction that could be made > between the devices whether it is on a SAN or not. It could be a > directly connected fiber channel device, in which case, it isn't quite a > SAN, yet the FreeBSD system doesn't know (or care) how it's connected. > > Eric From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 13:03:28 2007 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 D367916A419 for ; Fri, 5 Oct 2007 13:03:28 +0000 (UTC) (envelope-from anderson@freebsd.org) Received: from ns.trinitel.com (186.161.36.72.static.reverse.ltdomains.com [72.36.161.186]) by mx1.freebsd.org (Postfix) with ESMTP id 9C18D13C465 for ; Fri, 5 Oct 2007 13:03:28 +0000 (UTC) (envelope-from anderson@freebsd.org) Received: from proton.storspeed.com (209-163-168-124.static.twtelecom.net [209.163.168.124]) (authenticated bits=0) by ns.trinitel.com (8.14.1/8.14.1) with ESMTP id l95D3ROe055236; Fri, 5 Oct 2007 08:03:28 -0500 (CDT) (envelope-from anderson@freebsd.org) Message-ID: <4706361D.9030505@freebsd.org> Date: Fri, 05 Oct 2007 08:03:25 -0500 From: Eric Anderson User-Agent: Thunderbird 2.0.0.6 (Macintosh/20070728) MIME-Version: 1.0 To: Sharad Chandra References: <200710041725.00842.sharadc@in.niksun.com> <200710051646.17618.sharadc@in.niksun.com> <4706261B.1050202@freebsd.org> <200710051828.08343.sharadc@in.niksun.com> In-Reply-To: <200710051828.08343.sharadc@in.niksun.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.1.8 X-Spam-Checker-Version: SpamAssassin 3.1.8 (2007-02-13) on ns.trinitel.com Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 13:03:28 -0000 Sharad Chandra wrote: > On Friday 05 October 2007 5:25 pm, Eric Anderson wrote: >> Sharad Chandra wrote: >> > On Thursday 04 October 2007 6:51 pm, Eric Anderson wrote: >> >> Sharad Chandra wrote: >> >>> Hello, >> >>> >> >>> How to distinguish if /dev/da* devices are internal scsi drivers >> >> or LUNs >> >> >>> of external SAN? >> >> >> >> camcontrol devlist -v >> >> >> >> Might help you.. >> >> >> >> Eric >>> Yes, right by analyzing camcontrol devlist it can be told, but i guess >>> not always. >>> >>> [root@qa7 ~]# camcontrol devlist >>> at scbus0 target 0 lun 0 (da0,pass0) >>> at scbus0 target 0 lun 1 (da1,pass1) >>> at scbus0 target 0 lun 2 (da2,pass2) >>> at scbus0 target 0 lun 3 (da3,pass3) >>> >>> Here luns are increasing, so it is SAN confirmed by tool. Now my point is >>> if i have a SAN of less than 1TB and i make only 1 LUN. what should be >>> output? guessing: similar to >>> at scbus0 target 0 lun 0 (da0,pass0) >>> >>> Then it will be difficult to tell, whether it is regular SCSI drives or >>> SAN. Then we need a tool that can tell this da0 belongs to SAN/SCSI or >>> not >> Notice the -v to camcontrol. It will tell you which controller the >> device belongs to, and the controller will help you determine whether it >> is connected to a SAN or not. > > [root@qa7 ~]# camcontrol devlist -v > scbus0 on isp0 bus 0: > at scbus0 target 0 lun 0 (da0,pass0) > at scbus0 target 0 lun 1 (da1,pass1) > at scbus0 target 0 lun 2 (da2,pass2) > at scbus0 target 0 lun 3 (da3,pass3) > < > at scbus0 target -1 lun -1 () > scbus-1 on xpt0 bus 0: > < > at scbus-1 target -1 lun -1 (xpt0) > > Does it? Well, isp0 is a QLogic fiber channel card, so that's as much as you will ever know. You could possibly use camcontrol to show WWN's (world wide names) which are present on fiber channel, but I don't think they are on other SCSI devices (oh boy, someone correct me if that is wrong - Scott Long, are you listening?). Eric From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 06:54:33 2007 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 3E79016A419 for ; Fri, 5 Oct 2007 06:54:33 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from in.niksun.com (210.18.76.166.sify.net [210.18.76.166]) by mx1.freebsd.org (Postfix) with ESMTP id CD88313C480 for ; Fri, 5 Oct 2007 06:54:32 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from sharadc.in.niksun.com (unknown [10.60.5.27]) by in.niksun.com (Postfix) with ESMTP id E66E95D82; Fri, 5 Oct 2007 12:32:33 +0530 (IST) From: Sharad Chandra Organization: NIKSUN To: Eric Anderson Date: Fri, 5 Oct 2007 12:21:22 +0530 User-Agent: KMail/1.9.4 References: <200710041725.00842.sharadc@in.niksun.com> <4704E8F1.8070000@freebsd.org> In-Reply-To: <4704E8F1.8070000@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200710051221.22496.sharadc@in.niksun.com> X-Mailman-Approved-At: Fri, 05 Oct 2007 14:47:36 +0000 Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 06:54:33 -0000 Yes, right by analyzing camcontrol devlist it can be told, but i guess not always. [root@qa7 ~]# camcontrol devlist at scbus0 target 0 lun 0 (da0,pass0) at scbus0 target 0 lun 1 (da1,pass1) at scbus0 target 0 lun 2 (da2,pass2) at scbus0 target 0 lun 3 (da3,pass3) Here luns are increasing, so it is SAN confirmed by tool. Now my point is if i have a SAN of less than 1TB and i make only 1 LUN. what should be output? guessing: similar to at scbus0 target 0 lun 0 (da0,pass0) Then it will be difficult to tell, whether it is regular SCSI drives or SAN. Then we need a tool that can tell this da0 belongs to SAN/SCSI or not Thanks Sharad Chandra On Thursday 04 October 2007 6:51 pm, Eric Anderson wrote: > Sharad Chandra wrote: > > Hello, > > > > How to distinguish if /dev/da* devices are internal scsi drivers or LUNs > > of external SAN? > > camcontrol devlist -v > > Might help you.. > > Eric From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 13:29:13 2007 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 4576E16A473 for ; Fri, 5 Oct 2007 13:29:13 +0000 (UTC) (envelope-from wb@freebie.xs4all.nl) Received: from smtp-vbr9.xs4all.nl (smtp-vbr9.xs4all.nl [194.109.24.29]) by mx1.freebsd.org (Postfix) with ESMTP id 9A52513C469 for ; Fri, 5 Oct 2007 13:29:12 +0000 (UTC) (envelope-from wb@freebie.xs4all.nl) Received: from freebie.xs4all.nl (obsolete.xs4all.nl [82.95.250.254]) by smtp-vbr9.xs4all.nl (8.13.8/8.13.8) with ESMTP id l95DT7Ip084270; Fri, 5 Oct 2007 15:29:07 +0200 (CEST) (envelope-from wb@freebie.xs4all.nl) Received: from freebie.xs4all.nl (localhost [127.0.0.1]) by freebie.xs4all.nl (8.13.8/8.13.3) with ESMTP id l95DT6Zn050095; Fri, 5 Oct 2007 15:29:06 +0200 (CEST) (envelope-from wb@freebie.xs4all.nl) Received: (from wb@localhost) by freebie.xs4all.nl (8.13.8/8.13.6/Submit) id l95DT6HY050094; Fri, 5 Oct 2007 15:29:06 +0200 (CEST) (envelope-from wb) Date: Fri, 5 Oct 2007 15:29:06 +0200 From: Wilko Bulte To: Eric Anderson Message-ID: <20071005132906.GA50050@freebie.xs4all.nl> References: <200710041725.00842.sharadc@in.niksun.com> <200710051646.17618.sharadc@in.niksun.com> <4706261B.1050202@freebsd.org> <200710051828.08343.sharadc@in.niksun.com> <4706361D.9030505@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4706361D.9030505@freebsd.org> User-Agent: Mutt/1.5.11 X-Virus-Scanned: by XS4ALL Virus Scanner X-Mailman-Approved-At: Fri, 05 Oct 2007 14:47:36 +0000 Cc: freebsd-hackers@freebsd.org, Sharad Chandra Subject: Re: SCSI and SAN 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, 05 Oct 2007 13:29:13 -0000 Quoting Eric Anderson, who wrote on Fri, Oct 05, 2007 at 08:03:25AM -0500 .. > Sharad Chandra wrote: > >On Friday 05 October 2007 5:25 pm, Eric Anderson wrote: > >>Sharad Chandra wrote: > >> > On Thursday 04 October 2007 6:51 pm, Eric Anderson wrote: > >> >> Sharad Chandra wrote: > >> >>> Hello, > >> >>> > >> >>> How to distinguish if /dev/da* devices are internal scsi > >> drivers > >> > >>or LUNs > >> > >> >>> of external SAN? > >> >> > >> >> camcontrol devlist -v > >> >> > >> >> Might help you.. > >> >> > >> >> Eric > >>>Yes, right by analyzing camcontrol devlist it can be told, but i guess > >>>not always. > >>> > >>>[root@qa7 ~]# camcontrol devlist > >>> at scbus0 target 0 lun 0 (da0,pass0) > >>> at scbus0 target 0 lun 1 (da1,pass1) > >>> at scbus0 target 0 lun 2 (da2,pass2) > >>> at scbus0 target 0 lun 3 (da3,pass3) > >>> > >>>Here luns are increasing, so it is SAN confirmed by tool. Now my point is > >>>if i have a SAN of less than 1TB and i make only 1 LUN. what should be > >>>output? guessing: similar to > >>> at scbus0 target 0 lun 0 (da0,pass0) > >>> > >>>Then it will be difficult to tell, whether it is regular SCSI drives or > >>>SAN. Then we need a tool that can tell this da0 belongs to SAN/SCSI or > >>>not > >>Notice the -v to camcontrol. It will tell you which controller the > >>device belongs to, and the controller will help you determine whether it > >>is connected to a SAN or not. > > > >[root@qa7 ~]# camcontrol devlist -v > >scbus0 on isp0 bus 0: > > at scbus0 target 0 lun 0 (da0,pass0) > > at scbus0 target 0 lun 1 (da1,pass1) > > at scbus0 target 0 lun 2 (da2,pass2) > > at scbus0 target 0 lun 3 (da3,pass3) > >< > at scbus0 target -1 lun -1 () > >scbus-1 on xpt0 bus 0: > >< > at scbus-1 target -1 lun -1 (xpt0) > > > >Does it? > > Well, isp0 is a QLogic fiber channel card, so that's as much as you will or a parallel SCSI one, that uses same driver. -- Wilko Bulte wilko@FreeBSD.org From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 15:57:23 2007 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 E3BFB16A419 for ; Fri, 5 Oct 2007 15:57:22 +0000 (UTC) (envelope-from ap@bnc.net) Received: from mailomat.net (mailomat.net [217.110.117.101]) by mx1.freebsd.org (Postfix) with ESMTP id 6121F13C480 for ; Fri, 5 Oct 2007 15:57:22 +0000 (UTC) (envelope-from ap@bnc.net) X-Spam-Checker-Version: SpamAssassin 3.1.7 (2006-10-05) on f-1.mailomat.net X-Spam-Level: X-Spam-Status: No, hits=-4.2 required=4.0 tests=ALL_TRUSTED=-1.8, AWL=0.237, BAYES_00=-2.599 autolearn=ham version=3.1.7 X-TFF-CGPSA-Version: 1.5 X-Mailomat-CGPSA-Filter: Scanned X-Mailomat-SpamCatcher-Score: 2 [X] X-Mailomat-Cloudmark-Score: 0.000000 [] Received: from [194.39.192.125] (account bnc-mail@mailrelay.mailomat.net HELO bnc.net) by mailomat.net (CommuniGate Pro SMTP 5.1.9) with ESMTPSA id 29934719; Fri, 05 Oct 2007 16:16:37 +0200 X-BNC-SpamCatcher-Score: 2 [X] Received: from [194.39.194.123] (account ap HELO [194.39.194.123]) by bnc.net (CommuniGate Pro SMTP 5.1.9) with ESMTPSA id 2953132; Fri, 05 Oct 2007 16:16:34 +0200 In-Reply-To: <200710051646.17618.sharadc@in.niksun.com> References: <200710041725.00842.sharadc@in.niksun.com> <4704E8F1.8070000@freebsd.org> <200710051646.17618.sharadc@in.niksun.com> Mime-Version: 1.0 (Apple Message framework v752.3) Content-Type: multipart/signed; micalg=sha1; boundary=Apple-Mail-4-685690634; protocol="application/pkcs7-signature" Message-Id: From: Achim Patzner Date: Fri, 5 Oct 2007 16:16:11 +0200 To: Sharad Chandra X-Mailer: Apple Mail (2.752.3) X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-hackers@freebsd.org Subject: Re: SCSI and SAN 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, 05 Oct 2007 15:57:23 -0000 --Apple-Mail-4-685690634 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Am 05.10.2007 um 13:16 schrieb Sharad Chandra: > [root@qa7 ~]# camcontrol devlist > at scbus0 target 0 lun 0 > (da0,pass0) > at scbus0 target 0 lun 1 > (da1,pass1) > at scbus0 target 0 lun 2 > (da2,pass2) > at scbus0 target 0 lun 3 > (da3,pass3) > > Here luns are increasing, so it is SAN confirmed by tool. A rather bold assumption. In this case the only hint I can see is the product ID (A16F-G2422) - the "F" tells me that it is an Infortrend FC controller. I've got an A24U-G2421-1 (S-ATA to SCSI) which could be configured just the same. Achim Patzner --Apple-Mail-4-685690634-- From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 5 17:34:39 2007 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 5143916A418 for ; Fri, 5 Oct 2007 17:34:39 +0000 (UTC) (envelope-from julian@elischer.org) Received: from outA.internet-mail-service.net (outA.internet-mail-service.net [216.240.47.224]) by mx1.freebsd.org (Postfix) with ESMTP id EFAD513C457 for ; Fri, 5 Oct 2007 17:34:38 +0000 (UTC) (envelope-from julian@elischer.org) Received: from mx0.idiom.com (HELO idiom.com) (216.240.32.160) by out.internet-mail-service.net (qpsmtpd/0.40) with ESMTP; Fri, 05 Oct 2007 10:34:38 -0700 X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e Received: from julian-mac.elischer.org (nat.ironport.com [63.251.108.100]) by idiom.com (Postfix) with ESMTP id C38261265CA; Fri, 5 Oct 2007 10:34:37 -0700 (PDT) Message-ID: <470675B1.3050209@elischer.org> Date: Fri, 05 Oct 2007 10:34:41 -0700 From: Julian Elischer User-Agent: Thunderbird 2.0.0.6 (Macintosh/20070728) MIME-Version: 1.0 To: Peter B References: <200710050432.l954WhFS000214@brother.ludd.ltu.se> In-Reply-To: <200710050432.l954WhFS000214@brother.ludd.ltu.se> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: FYI: 3Ware 9650 can cause data corruption 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, 05 Oct 2007 17:34:39 -0000 Peter B wrote: > 3ware 9650 in RAID6 mode with firmware version 3.08.00.004 seems to cause > data corruption when rebuilding a single disc with raid6. > > http://www.webmasternetwork.se/f4t23551.html (Swedish) > > I thought this was serious enough for people to know. If another mailinglist > is more appropiate for this kind of FYI then tell. well I guess that's better than the 7800 that just corrupted data during standard writes. > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" From owner-freebsd-hackers@FreeBSD.ORG Sat Oct 6 06:30:18 2007 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 2D11016A418 for ; Sat, 6 Oct 2007 06:30:18 +0000 (UTC) (envelope-from nicholas.thompson1@mchsi.com) Received: from sccmmhc92.asp.att.net (sccmmhc92.asp.att.net [204.127.203.212]) by mx1.freebsd.org (Postfix) with ESMTP id F33D113C43E for ; Sat, 6 Oct 2007 06:30:17 +0000 (UTC) (envelope-from nicholas.thompson1@mchsi.com) Received: from [192.168.1.75] (12-218-7-27.client.mchsi.com[12.218.7.27]) by sccmmhc92.asp.att.net (sccmmhc92) with ESMTP id <20071006063016m92002q9d6e>; Sat, 6 Oct 2007 06:30:17 +0000 Message-ID: <47072884.4080604@mchsi.com> Date: Sat, 06 Oct 2007 01:17:40 -0500 From: nick thompson User-Agent: Thunderbird 2.0.0.6 (X11/20070908) MIME-Version: 1.0 To: Nick Thompson , freebsd-hackers@freebsd.org, nick.thompson@comtrol.com References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Subject: Re: Comtrol RocketPort 550 uPCI, 16-port X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 06 Oct 2007 06:30:18 -0000 Nick Thompson wrote: > What that meant was that the driver that comes with FreeBSD 6.2 is an older version of the driver. (Much older, 8 years older I believe.) I've heard from folks who've had success with the driver that comes with 6.2 with certain cards, and heard from folks who've had success after hacking the code a bit with other cards. Either way, I am trying to get things to a point that our FreeBSD customers can be confident that their cards will be supported now, and into the future. When I arrived here, the last release was for FreeBSD 5.3: > > ftp://ftp.comtrol.com/rport/drivers/u_pci/freebsd/5_x/1800255a.tgz > > Since I personally run FreeBSD at home, and can see the value in keeping our drivers up to date with the current release, I wanted to get things up to date. I put in an engineering request for a 6.x driver, and we have it now. > > It's in the beta phase, and we have beta customers running it with no complaints at the moment. I will have to put the link up into this thread once it gets uploaded to the ftp server, which should be by the end of the week. > > Regards, > > Nick > > Nick Thompson > Technical Support Specialist nick.thompson@comtrol.com > Comtrol Corporation ftp://ftp.comtrol.com > 6655 Wedgwood Rd. Ste 120 http://www.comtrol.com > Maple Grove, MN. 55311 Sales: (800)GO-ROCKET > Jeff & the others who emailed me, The FreeBSD 6.2 (6.x) RocketPort uPCI, PCI, and ISA Driver version 1.02 is now officially out on our ftp site. The link is: ftp://ftp.comtrol.com/beta/rport/drivers/u_pci/freebsd/6.x/rocket_freebsd6_1.02.tgz Please feel free to email me at my work address, or at this my main personal address, as I am doing BSD and Linux stuff whether I'm at work or home. And as I mentioned in a previous post, I am the FreeBSD / Linux / SCO / Solaris / etc. person in Tech Support at Comtrol, and I very much would like to give an invitation to anyone with a Comtrol related issue to email me, be it on a weekend at this address, or a weekday at work. In fact, I prefer a cc so that both addresses get a copy, whichever you choose, as it makes keeping track of work related emails that come in on my home address very simple. Also, here are some other links of interest: RocketPort uPCI, PCI, and ISA driver for FreeBSD 5.x: ftp://ftp.comtrol.com/rport/drivers/u_pci/freebsd/5_x/1800255a.tgz RocketPort driver for FreeBSD 4.x: ftp://ftp.comtrol.com/rport/drivers/u_pci/freebsd/4_x/1800254a.tgz Also, we released a new product line this week, and right off the bat we have FreeBSD drivers. The RocketPort Infinity was released a few days ago, here is a link to info about the RocketPort Infinity card family: http://www.comtrol.com/products/family/rp_INFINITY And, here are the drivers for FreeBSD 6.x and 5.x for the RocketPort Infinity: ftp://ftp.comtrol.com/rport_infinity/drivers/freebsd/6.x/rpinfinity_freebsd6.tar.z ftp://ftp.comtrol.com/rport_infinity/drivers/freebsd/5.x/rpinfinity_freebsd5.tar.z The RocketPort Infinity family are all low profile, will fit in a 3.3v or 5v uPCI or PCI-X slot, and can communicate RS-232, RS-422, and RS-485. This is software selectable. Thanks for reading, and I just wanted to thank all of the people who have written me here and at work telling me how pleased they were that Comtrol has people monitoring FreeBSD mailing lists. Regards, Nick "All unix, all the time." http://npt.ath.cx From owner-freebsd-hackers@FreeBSD.ORG Sat Oct 6 10:17:07 2007 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 2E7ED16A41B for ; Sat, 6 Oct 2007 10:17:07 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from in.niksun.com (210.18.76.166.sify.net [210.18.76.166]) by mx1.freebsd.org (Postfix) with ESMTP id D208113C469 for ; Sat, 6 Oct 2007 10:17:06 +0000 (UTC) (envelope-from sharadc@in.niksun.com) Received: from sharadc.in.niksun.com (unknown [10.60.5.27]) by in.niksun.com (Postfix) with ESMTP id 68FA95D27 for ; Sat, 6 Oct 2007 15:55:09 +0530 (IST) From: Sharad Chandra Organization: NIKSUN To: freebsd-hackers@freebsd.org Date: Sat, 6 Oct 2007 15:43:56 +0530 User-Agent: KMail/1.9.4 References: <200710041725.00842.sharadc@in.niksun.com> <200710051646.17618.sharadc@in.niksun.com> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200710061543.56730.sharadc@in.niksun.com> Subject: Re: SCSI and SAN X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 06 Oct 2007 10:17:07 -0000 Can't we differentiate relating to some parameter? What about transfer rate "camcontrol inquiry da0". on SCSI its 320MB/Sec and on san its 200MB/Sec any other parameter? Thanks in advance Sharad Chandra On Friday 05 October 2007 7:46 pm, Achim Patzner wrote: > Am 05.10.2007 um 13:16 schrieb Sharad Chandra: > > [root@qa7 ~]# camcontrol devlist > > at scbus0 target 0 lun 0 > > (da0,pass0) > > at scbus0 target 0 lun 1 > > (da1,pass1) > > at scbus0 target 0 lun 2 > > (da2,pass2) > > at scbus0 target 0 lun 3 > > (da3,pass3) > > > > Here luns are increasing, so it is SAN confirmed by tool. > > A rather bold assumption. In this case the only hint I can see is the > product ID (A16F-G2422) - the "F" tells me that it is an Infortrend FC > controller. I've got an A24U-G2421-1 (S-ATA to SCSI) which could be > configured just the same. > > > Achim Patzner