From owner-freebsd-hackers Sun Oct 6 2:21:15 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E122737B406 for ; Sun, 6 Oct 2002 02:21:12 -0700 (PDT) Received: from yahoo.com (r-pd037-4a75.tin.it [62.211.176.75]) by mx1.FreeBSD.org (Postfix) with SMTP id 9112D43E6E for ; Sun, 6 Oct 2002 02:21:11 -0700 (PDT) (envelope-from assirianint@yahoo.com) From: "Assirian Movement" To: 152.163.207.134@FreeBSD.ORG Subject: Basically, I got on the plane with a bomb. Basically, I tried to ignite it. Basically, yeah, I intended to damage the plane. Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Date: Sun, 6 Oct 2002 11.21.53 +0200 Content-Transfer-Encoding: 8bit Message-Id: <20021006092111.9112D43E6E@mx1.FreeBSD.org> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG WESTERN PEOPLE, WESTERN GOVERNMENT, DO NOT HELP SADDAM BEING SOFT! IF YOU GO ON WITH YOUR SICK/SOFT UN POLICY YOU WILL FIND THE BOMBERS INSIDE YOUR BUS. WESTERN GOVERNMENT YOUR ELECTORS WILL PUNISH YOU IF YOU HELP SADDAM. SADDAM = WAR TODAY = 100 WARS TOMORROW "Basically, I got on the plane with a bomb. Basically, I tried to ignite it. Basically, yeah, I intended to damage the plane." RICHARD REID Four in U.S. Charged in Post-9/11 Plan to Join Al Qaeda Federal officials said they had broken up a terrorist cell in Portland, Ore., arresting four native-born citizens accused of plotting to join with Al Qaeda and Taliban fighters. Association of assirian countrymen "Bat-Nac" Aims and Tasks of organization: Active contribution to the revival, preservation, development of assirian culture, propaganda among population of historical heritage of assirian people of Iraq and Saudi Arabia. Leader of organization: Bat-Nac Phone: 113 27 27 Date of registration: 05.03.79 This is nor Spam write back to us for removal. Write to assirianint@yahoo.com with 'REMOVE ME PLEASE AS A SUBJECT' Study assirian,Be Proud of being! http://www.acl.edu.au/choose_lang_ass.html Our assirian page went on top of all the searchs consulting the Traffic Security Experts: http://www.msn.com/ + Security Traffic Expert http://search.msn.com/results.asp?q=security+traffic+expert&origq=traffic+ex pert&RS=CHECKED&FORM=SMCRT&v=1&cfg=SMCINITIAL&nosp=0&thr=&submitbutton.x=32& submitbutton.y=16 WESTERN GOVERNMENT: YOUR ELECTORS WILL PUNISH YOU IF YOU HELP SADDAM. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sun Oct 6 3:35:24 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EB28737B401 for ; Sun, 6 Oct 2002 03:35:20 -0700 (PDT) Received: from storm.FreeBSD.org.uk (storm.FreeBSD.org.uk [194.242.157.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 37E7F43E4A for ; Sun, 6 Oct 2002 03:35:20 -0700 (PDT) (envelope-from mark@grimreaper.grondar.org) Received: from storm.FreeBSD.org.uk (uucp@localhost [127.0.0.1]) by storm.FreeBSD.org.uk (8.12.6/8.12.6) with ESMTP id g96AZIW1098552; Sun, 6 Oct 2002 11:35:18 +0100 (BST) (envelope-from mark@grimreaper.grondar.org) Received: (from uucp@localhost) by storm.FreeBSD.org.uk (8.12.6/8.12.6/Submit) with UUCP id g96AZIdC098551; Sun, 6 Oct 2002 11:35:18 +0100 (BST) Received: from grimreaper.grondar.org (localhost [127.0.0.1]) by grimreaper.grondar.org (8.12.6/8.12.5) with ESMTP id g96AVUh5011845; Sun, 6 Oct 2002 11:31:30 +0100 (BST) (envelope-from mark@grimreaper.grondar.org) Message-Id: <200210061031.g96AVUh5011845@grimreaper.grondar.org> To: "Firsto Lasto" Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: PRNG not seeded - error in non-root ssh inside 4.6.2 jails... References: In-Reply-To: ; from "Firsto Lasto" "Thu, 03 Oct 2002 15:29:01 PDT." Date: Sun, 06 Oct 2002 11:31:30 +0100 From: Mark Murray Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > Ok, I am not sure how I can do that though - I cannot successfully run > `rndcontrol -s X` inside a jail. > > On the other hand, I already have: > > rand_irqs="9 10 11 13 14" > > In my rc.conf on the underlying host machine, and have done several boots > with that in place. So presumably I should be seeded just fine, but if I am > not, I cannot change that in the jail because it seems I cannot set that (I > assume it is a sysctl issue). > > Willing to try whatever you can think of next :) Hokay. Can you grovel around inside OpenSSL (src/crypto/openssl/...) and find where the random device is read? If it is /dev/random, then change that to /dev/urandom. See how that works. M > > > I can't seed it by banging on the keyboard - it is a headless server in > >a > > > rack thousands of miles from me :) > > > > > > Perhaps there is another way to do it ? > > > >Yes. > > > >You need to find sources of entropy in interrupts. Look at a > >dmesg, and note which IRQ's your network device(s) and mass > >storage controller(s) (both SCSI and ATA). Use any other > >irq's that aren't too busy and may be somewhat random. > >Staring at a 'systat 2 -vmstat' screen (right hand side) > >may give some clues. > > > >Then use rndcontrol(8) to set up the seeding. There is a knob > >in rc.conf to make this setting survive the next reboot. > > > >M > > > > > >Date: Thu, 03 Oct 2002 21:54:30 +0100 > > > > > > > > > Sorry, here is the rest: > > > > > > > > > > Here is the output of the `dd` command using urandom: > > > > > > > > > > dd if=/dev/urandom of=/dev/stdout bs=512 count=1 | hexdump -C > > > > > 1+0 records in > > > > > 1+0 records out > > > > > 00000000 a0 69 1a 7c 8f 32 e5 21 ae 7a 33 14 68 0b 8e a6 > > > > > |.i.|.2.!.z3.h...| > > > > > > > >... etc. Looking good. > > > > > > > > > $ ls -l /dev/*rand* > > > > > crw-r--r-- 1 root wheel 2, 3 Sep 3 21:46 /dev/random > > > > > crw-r--r-- 1 root wheel 2, 4 Sep 3 21:46 /dev/urandom > > > > > > > >Also good. > > > > > > > > > > > So then, as root I ran: `chmod 0666 /dev/stdout` and then I ran > >your > > > > > >`dd` > > > > > > > command and got: > > > > > > > > > > > > > > $ dd if=/dev/random of=/dev/stdout bs=512 count=1 | hexdump -C > > > > > > > 0+0 records in > > > > > > > 0+0 records out > > > > > > > 0 bytes transferred in 0.000036 secs (0 bytes/sec) > > > > > > > >Can you try a few of these while furiously abusing your keyboard? > > > >I'm trying to see if /dev/random can be persuaded to give _any_ > > > >aoutput at all. > > > > > > > >Maybe do it on a vty instead of in X. > > > > > > > >M > > > >-- > > > >o Mark Murray > > > >\_ > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > _________________________________________________________________ > > > Chat with friends online, try MSN Messenger: http://messenger.msn.com > > > > >-- > >o Mark Murray > >\_ > >O.\_ Warning: this .sig is umop ap!sdn > > > > > _________________________________________________________________ > Send and receive Hotmail on your mobile device: http://mobile.msn.com > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message -- o Mark Murray \_ O.\_ Warning: this .sig is umop ap!sdn To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sun Oct 6 7:18:48 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CB69B37B401; Sun, 6 Oct 2002 07:18:46 -0700 (PDT) Received: from gw.nectar.cc (gw.nectar.cc [208.42.49.153]) by mx1.FreeBSD.org (Postfix) with ESMTP id 62EE043E65; Sun, 6 Oct 2002 07:18:46 -0700 (PDT) (envelope-from nectar@nectar.cc) Received: by gw.nectar.cc (Postfix, from userid 1001) id F37B510; Sun, 6 Oct 2002 09:18:45 -0500 (CDT) Date: Sun, 6 Oct 2002 09:18:45 -0500 From: "Jacques A. Vidrine" To: Gregory Sutter Cc: developers@FreeBSD.org, hackers@FreeBSD.org Subject: Re: FreeBSD Developer Status Report: July 2002 - August 2002 Message-ID: <20021006141845.GE20885@hellblazer.nectar.cc> References: <20021003202851.GA912@klapaucius.zer0.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20021003202851.GA912@klapaucius.zer0.org> User-Agent: Mutt/1.3.27i X-Url: http://www.celabo.org/ Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Oct 03, 2002 at 01:28:51PM -0700, Gregory Sutter wrote: > On 2002-10-03 15:38 -0400, Robert Watson wrote: > > > > July - August 2002 Status Report > > > > ---------------------------------------------------------------------- > > > > FreeBSD Security Officer Team > > > > URL: http://www.freebsd.org/security/ > > > > Contact: Jacques Vidrine > > > > In September, the FreeBSD Security Officer published a new PGP key (ID > > 0xCA6CDFB2, found on the FTP site and in the Handbook). This aligned the > > set of those who possess the corresponding private key with the membership > > of the security-officer alias published on the FreeBSD Security web site. > > It also worked around an issue with the deprecated PGP key being found > > corrupted on some public key servers. > > The key in the published handbook remains: > > pub 1024R/73D288A5 1996-04-22 FreeBSD Security Officer > > This was verified from the www copy of the handbook as well as the > FTP site. The key is also unavailable from pgpkeys.mit.edu. > > Where can I get this new key? Sorry for the confusion. The new key was expected to be published, but there remain some minor unresolved issues with regard to key signatures. There was a comment in the submitted report, but I don't think it was read. I shouldn't have counted on that :-) Cheers, -- Jacques A. Vidrine http://www.celabo.org/ NTT/Verio SME . FreeBSD UNIX . Heimdal Kerberos jvidrine@verio.net . nectar@FreeBSD.org . nectar@kth.se To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sun Oct 6 15: 0:44 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BCD5237B401 for ; Sun, 6 Oct 2002 15:00:42 -0700 (PDT) Received: from sabre.velocet.net (sabre.velocet.net [216.138.209.205]) by mx1.FreeBSD.org (Postfix) with ESMTP id 02B8C43E86 for ; Sun, 6 Oct 2002 15:00:33 -0700 (PDT) (envelope-from dgilbert@velocet.ca) Received: from trooper.velocet.ca (trooper.velocet.net [216.138.242.2]) by sabre.velocet.net (Postfix) with ESMTP id D5C98137F3A; Sun, 6 Oct 2002 18:00:32 -0400 (EDT) Received: by trooper.velocet.ca (Postfix, from userid 66) id 9C789745B2; Sun, 6 Oct 2002 18:00:32 -0400 (EDT) Received: by canoe.velocet.net (Postfix, from userid 101) id A1F26567606; Sun, 6 Oct 2002 18:00:28 -0400 (EDT) From: David Gilbert MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15776.45692.149994.514416@canoe.velocet.net> Date: Sun, 6 Oct 2002 18:00:28 -0400 To: Neal Nelson Cc: freebsd-hackers@freebsd.org Subject: [hackers] Writing a PCI ADSL Driver In-Reply-To: <20021006011546.GA322@thinkpad> References: <20021006011546.GA322@thinkpad> X-Mailer: VM 7.07 under 21.1 (patch 14) "Cuyahoga Valley" XEmacs Lucid Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG >>>>> "Neal" == Neal Nelson writes: Neal> Hi there. I'm thinking of writing a device driver for a Neal> Traverse Pulsar PCI ADSL card and I was looking for some ideas Neal> before I committed myself. I've been offered hardware and Neal> support by the makers (http://www.traverse.com.au/) but I want Neal> to make sure that I can actually do the job before accepting. Neal> I was wondering what kind of device driver I would need to Neal> create. I use ADSL at home but I only know how to use it, I Neal> don't know how it really works. Would I be able to create a Neal> character device and just pretend it was a modem or would I need Neal> to create a network device so that it can talk PPPoE over it? My Neal> main concern is how to get ppp to talk to the device. Neal> Hopefully I'll be able to get hold of the Linux driver soon and Neal> see how that does things but I want to be very careful about the Neal> licensing issues, so that I can make the driver available under Neal> the normal BSD license. I'll have to see what the makers say Neal> about that first though. Neal> Any advice would be gratefully accepted. I would expect that the most sensible "class" for the driver would be somewhat like an ethernet device. Most commonly they're used with PPPoE or bridged ethernet. This may irk some ... the underlying implementation is almost always ATM, but they try very hard to behave like ethernet devices. One of the common internal ADSL cards that we sell (we're an ISP) probes in FreeBSD as an sis0 (or somesuch... I forget just what driver it is). I can't convince the interface to come up, but there is an ethernet controller chip common to other ethernet cards on the ADSL card. Of course, YMMV. Dave. -- ============================================================================ |David Gilbert, Velocet Communications. | Two things can only be | |Mail: dgilbert@velocet.net | equal if and only if they | |http://daveg.ca | are precisely opposite. | =========================================================GLO================ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sun Oct 6 15:49:15 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DD14637B401 for ; Sun, 6 Oct 2002 15:49:13 -0700 (PDT) Received: from valu.uninet.ee (valu.uninet.ee [194.204.34.51]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2FFBF43E42 for ; Sun, 6 Oct 2002 15:49:13 -0700 (PDT) (envelope-from taavi@uninet.ee) Received: by valu.uninet.ee (Postfix, from userid 1002) id 6469136420; Mon, 7 Oct 2002 01:48:57 +0300 (EEST) Received: from localhost (localhost [127.0.0.1]) by valu.uninet.ee (Postfix) with ESMTP id 62ABE3261A; Mon, 7 Oct 2002 01:48:57 +0300 (EEST) Date: Mon, 7 Oct 2002 01:48:57 +0300 (EEST) From: Taavi Talvik To: David Gilbert Cc: Neal Nelson , Subject: Re: [hackers] Writing a PCI ADSL Driver In-Reply-To: <15776.45692.149994.514416@canoe.velocet.net> Message-ID: <20021007013551.S98477-100000@valu.uninet.ee> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun, 6 Oct 2002, David Gilbert wrote: > Neal> Hi there. I'm thinking of writing a device driver for a > Neal> Traverse Pulsar PCI ADSL card and I was looking for some ideas > Neal> before I committed myself. I've been offered hardware and > Neal> support by the makers (http://www.traverse.com.au/) but I want > Neal> to make sure that I can actually do the job before accepting. > > Neal> I was wondering what kind of device driver I would need to > Neal> create. I use ADSL at home but I only know how to use it, I > Neal> don't know how it really works. Would I be able to create a > Neal> character device and just pretend it was a modem or would I need > Neal> to create a network device so that it can talk PPPoE over it? My > Neal> main concern is how to get ppp to talk to the device. > > I would expect that the most sensible "class" for the driver would be > somewhat like an ethernet device. Most commonly they're used with > PPPoE or bridged ethernet. This may irk some ... the underlying > implementation is almost always ATM, but they try very hard to behave > like ethernet devices. Problem with ADSL is that there are actually too many link layer encapsualtions in use - PPPoE, PPPoA, plain rfc1348 (if i remember rfc number correctly) etc. Due to above, most sensible is to take netgraph approach. Afterwards it's easy to adapt to different encapsulations. Actually it should be possible to autodetect all of this and connect appropriate netgraph hooks. best regards, taavi To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 1: 7:41 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3B8D537B401 for ; Mon, 7 Oct 2002 01:07:40 -0700 (PDT) Received: from insomnia.spc.org (insomnia.spc.org [195.224.94.183]) by mx1.FreeBSD.org (Postfix) with SMTP id 32D9543E81 for ; Mon, 7 Oct 2002 01:07:39 -0700 (PDT) (envelope-from bms@insomnia.spc.org) Received: (qmail 15272 invoked by uid 1031); 7 Oct 2002 08:02:48 -0000 Date: Mon, 7 Oct 2002 09:02:48 +0100 From: Bruce M Simpson To: freebsd-hackers@freebsd.org Cc: Neal Nelson Subject: Re: Writing a PCI ADSL Driver Message-ID: <20021007080248.GG17186@spc.org> Mail-Followup-To: Bruce M Simpson , freebsd-hackers@freebsd.org, Neal Nelson References: <20021006011546.GA322@thinkpad> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20021006011546.GA322@thinkpad> User-Agent: Mutt/1.3.28i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I finally got to play with my ENI 3060 at the weekend. It probes as a PCI ATM adapter. I also found that the debugging symbols and code hadn't been stripped from the drivers which shipped with my particular card. Windows attaches its native ATM stack to the card's NDIS5 PCI/ATM miniport driver and the Alcatel DynaMiTe firmware is clearly visible in the data segment. I'm planning on writing a HARP driver for this thing eventually so any advice would be appreciated. The en(4) driver looks a bit aged and scary, though. Talk about setting onesself a challenge... I bought this card with the express intention of subjecting myself to that, it's either that or get a little black box router with ethernet output (or *spit* Windows on the gateway.) Julian: How would netgraph fit with ATM? I should point out that all the NDIS5 entry points are clearly visible, and I also have a nice IDA library which covers a fair bit of NDIS5. I've been down with a mystery virus, so haven't made progress elsewhere. BMS To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 1:40:11 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E0D9737B401 for ; Mon, 7 Oct 2002 01:40:09 -0700 (PDT) Received: from sccrmhc03.attbi.com (sccrmhc03.attbi.com [204.127.202.63]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5C7AE43E9C for ; Mon, 7 Oct 2002 01:40:09 -0700 (PDT) (envelope-from julian@elischer.org) Received: from InterJet.elischer.org ([12.232.206.8]) by sccrmhc03.attbi.com (InterMail vM.4.01.03.27 201-229-121-127-20010626) with ESMTP id <20021007084008.UDNF22381.sccrmhc03.attbi.com@InterJet.elischer.org>; Mon, 7 Oct 2002 08:40:08 +0000 Received: from localhost (localhost.elischer.org [127.0.0.1]) by InterJet.elischer.org (8.9.1a/8.9.1) with ESMTP id BAA32630; Mon, 7 Oct 2002 01:21:19 -0700 (PDT) Date: Mon, 7 Oct 2002 01:21:17 -0700 (PDT) From: Julian Elischer To: Bruce M Simpson Cc: freebsd-hackers@freebsd.org, Neal Nelson Subject: Re: Writing a PCI ADSL Driver In-Reply-To: <20021007080248.GG17186@spc.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, 7 Oct 2002, Bruce M Simpson wrote: > I finally got to play with my ENI 3060 at the weekend. It probes as a PCI > ATM adapter. I also found that the debugging symbols and code hadn't been > stripped from the drivers which shipped with my particular card. Windows > attaches its native ATM stack to the card's NDIS5 PCI/ATM miniport driver > and the Alcatel DynaMiTe firmware is clearly visible in the data segment. > > I'm planning on writing a HARP driver for this thing eventually so any > advice would be appreciated. The en(4) driver looks a bit aged and scary, > though. Talk about setting onesself a challenge... I bought this card with > the express intention of subjecting myself to that, it's either that or get > a little black box router with ethernet output (or *spit* Windows on the > gateway.) > > Julian: How would netgraph fit with ATM? there is a project mentionned in the latest status report to do a netgraph ATM implementation... start there... > > I should point out that all the NDIS5 entry points are clearly visible, and > I also have a nice IDA library which covers a fair bit of NDIS5. > > I've been down with a mystery virus, so haven't made progress elsewhere. > > BMS > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 8:37:31 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AF17337B401 for ; Mon, 7 Oct 2002 08:37:25 -0700 (PDT) Received: from shared1-mail.whowhere.com (shared1-mail.whowhere.com [209.202.220.30]) by mx1.FreeBSD.org (Postfix) with SMTP id 79F7D43E9E for ; Mon, 7 Oct 2002 08:37:23 -0700 (PDT) (envelope-from john_15ng@eudoramail.com) Received: from Unknown/Local ([?.?.?.?]) by shared1-mail.whowhere.com; Mon Oct 7 08:37:08 2002 To: john_45ng@yahoo.com Date: Mon, 07 Oct 2002 08:37:08 -0700 From: "john giwa" Message-ID: Mime-Version: 1.0 X-Sent-Mail: off Reply-To: john_15ng@eudoramail.com X-Expiredinmiddle: true X-Mailer: MailCity Service Subject: URGENT X-Sender-Ip: 216.139.177.146 Organization: QUALCOMM Eudora Web-Mail (http://www.eudoramail.com:80) Content-Type: text/plain; charset=us-ascii Content-Language: en Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG REQUEST FOR URGENT ASSISTANCE/INVESTMENT. Dear Sir/Madam , I am the eldest son of my father. It might be a surprise to you where I got your contact address, I got it from network on line During the current crises against the farmers of Zimbabwe by the supporters of our President Robert Mugabe to claim all the white owned farms in our country, he ordered all the white farmers to surrender their farms to his party members and their followers. My father was one of the best farmers in the country and knowing that he did not support the presidents political ideology, the presidents supporters invaded my fathers farm burnt down everything, shot him and as a result of the wounds sustained, he became sick and died a! after two days. And after his death, I with my younger Brother decided to move out of Zimbabwe for the safety of our lives. BUT, before he died HE WROTE HIS WILL, which reads "(MY BELOVEED SON ,I WISH TO DRAW YOUR ATTENTION TO THE SUM OF ($9,500,000=00). MILLION U.S DOLLARS WHICH I DEPOSITED IN CASE OF MY ABSENCE ON EARTH CAUSED BY DEATH ONLY". You should solicit for reliable foreign partner to assist you to transfer this money for investment purpose. I deposited the money in your name and it can be claimed by you alone with the deposit code. your mother has all the documents. Take good care of your mother and brother." From the above, you will understand that the lives and future of my family depends on this money as much, I will be very grateful if you can assist us. I with my younger bro! are now living as POLITICAL ASYLUM SEEKERS and the financial law does not allow ASYLUM SEEKERS certain financial rights to such huge amount of money .In view of this, I cannot invest this money, hence I am asking you to assist me transfer this money out for investment purposes. For your efforts, I am prepared to offer you 20% of the total fund, while 5% will be set aside for local and international expenses and 75% will be kept for me and my family. Finally modalities on how the transfer will be done will be conveyed to you once we establish trust and confidence between ourselves. Looking forward to your urgent reply .For detailed information. NOTE: THE KEY WORD TO THIS TRANSACTION IS ABSOLUTE CONFIDENTIALITY AND SECRECY. THIS TRANSACTION IS 100% RISK FREE. YOUR URGENT RESPONSE WILL BE HIGHLY APPRECIATED. BEST REGARDS, JOHN GIWA Join 18 million Eudora users by signing up for a free Eudora Web-Mail account at http://www.eudoramail.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 8:39:38 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2722337B404 for ; Mon, 7 Oct 2002 08:39:08 -0700 (PDT) Received: from HAL9000.homeunix.com (12-232-220-15.client.attbi.com [12.232.220.15]) by mx1.FreeBSD.org (Postfix) with ESMTP id CA00A43EA3 for ; Mon, 7 Oct 2002 08:39:06 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Received: from HAL9000.homeunix.com (localhost [127.0.0.1]) by HAL9000.homeunix.com (8.12.6/8.12.5) with ESMTP id g97Fd4FI000466; Mon, 7 Oct 2002 08:39:04 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Received: (from das@localhost) by HAL9000.homeunix.com (8.12.6/8.12.5/Submit) id g97FcjfU000465; Mon, 7 Oct 2002 08:38:45 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Date: Mon, 7 Oct 2002 08:38:45 -0700 From: David Schultz To: Matthew Dillon Cc: Peter Wemm , Sean Kelly , hackers@FreeBSD.ORG Subject: Re: swapoff? Message-ID: <20021007153845.GA371@HAL9000.homeunix.com> Mail-Followup-To: Matthew Dillon , Peter Wemm , Sean Kelly , hackers@FreeBSD.ORG References: <20020713071911.GA1558@HAL9000.wox.org> <20020713073404.9869A3811@overcee.wemm.org> <20020713115746.GA2162@HAL9000.wox.org> <200207131636.g6DGaoqh081285@apollo.backplane.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200207131636.g6DGaoqh081285@apollo.backplane.com> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I'm resurrecting this thread because I finally got around to finishing up the patches to implement swapoff. I would appreciate some review of them, particularly to verify that I have done the right thing WRT synchronization. I have not optimized it to do read clustering, but I have ensured that such an optimization could be made. Other than that, I don't know of any deficiencies. Index: include/unistd.h =================================================================== RCS file: /home/ncvs/src/include/unistd.h,v retrieving revision 1.60 diff -u -r1.60 unistd.h --- include/unistd.h 2002/09/25 01:58:56 1.60 +++ include/unistd.h 2002/10/07 13:55:19 @@ -512,6 +512,7 @@ void setusershell(void); int strtofflags(char **, u_long *, u_long *); int swapon(const char *); +int swapoff(const char *); int syscall(int, ...); off_t __syscall(quad_t, ...); int ttyslot(void); Index: lib/libc/sys/Makefile.inc =================================================================== RCS file: /home/ncvs/src/lib/libc/sys/Makefile.inc,v retrieving revision 1.96 diff -u -r1.96 Makefile.inc --- lib/libc/sys/Makefile.inc 2002/10/02 18:01:51 1.96 +++ lib/libc/sys/Makefile.inc 2002/10/07 13:55:24 @@ -130,6 +130,7 @@ MLINKS+=stat.2 fstat.2 stat.2 lstat.2 MLINKS+=statfs.2 fstatfs.2 MLINKS+=syscall.2 __syscall.2 +MLINKS+=swapon.2 swapoff.2 MLINKS+=truncate.2 ftruncate.2 MLINKS+=utimes.2 futimes.2 utimes.2 lutimes.2 MLINKS+=wait.2 wait3.2 wait.2 wait4.2 wait.2 waitpid.2 Index: lib/libc/sys/swapon.2 =================================================================== RCS file: /home/ncvs/src/lib/libc/sys/swapon.2,v retrieving revision 1.12 diff -u -r1.12 swapon.2 --- lib/libc/sys/swapon.2 2001/10/01 16:09:03 1.12 +++ lib/libc/sys/swapon.2 2002/10/07 13:55:24 @@ -36,14 +36,16 @@ .Dt SWAPON 2 .Os .Sh NAME -.Nm swapon -.Nd add a swap device for interleaved paging/swapping +.Nm swapon , swapoff +.Nd control devices for interleaved paging/swapping .Sh LIBRARY .Lb libc .Sh SYNOPSIS .In unistd.h .Ft int .Fn swapon "const char *special" +.Ft int +.Fn swapoff "const char *special" .Sh DESCRIPTION .Fn Swapon makes the block device @@ -55,13 +57,22 @@ .Fa special is calculated at the time the device is first made available for swapping. +.Pp +The +.Fn swapoff +system call disables paging and swapping on the given device. +All associated swap metadata are deallocated, and the device +is made available for other purposes. .Sh RETURN VALUES If an error has occurred, a value of -1 is returned and .Va errno is set to indicate the error. .Sh ERRORS -.Fn Swapon -succeeds unless: +Both +.Fn swapon +and +.Fn swapoff +can fail if: .Bl -tag -width Er .It Bq Er ENOTDIR A component of the path prefix is not a directory. @@ -76,6 +87,19 @@ Too many symbolic links were encountered in translating the pathname. .It Bq Er EPERM The caller is not the super-user. +.It Bq Er EFAULT +.Fa Special +points outside the process's allocated address space. +.El +.Pp +Additionally, +.Fn swapon +can fail for the following reasons: +.Bl -tag -width Er +.It Bq Er EINVAL +The system has reached the boot-time limit on the number of +swap devices, +.Va vm.nswapdev . .It Bq Er ENOTBLK .Fa Special is not a block device. @@ -84,11 +108,6 @@ .Fa special has already been made available for swapping -.It Bq Er EINVAL -The device configured by -.Fa special -was not -configured into the system as a swap device. .It Bq Er ENXIO The major device number of .Fa special @@ -96,20 +115,28 @@ for the associated hardware). .It Bq Er EIO An I/O error occurred while opening the swap device. -.It Bq Er EFAULT -.Fa Special -points outside the process's allocated address space. .El +.Pp +Lastly, +.Fn swapoff +can fail if: +.Bl -tag -width Er +.It Bq Er EINVAL +The system is not currently swapping to +.Fa special . +.It Bq Er ENOMEM +Not enough virtual memory is available to safely disable +paging and swapping to the given device. +.El .Sh SEE ALSO .Xr config 8 , -.Xr swapon 8 -.Sh BUGS -There is no way to stop swapping on a disk so that the pack may be -dismounted. -.Pp -This call will be upgraded in future versions of the system. +.Xr swapon 8 , +.Xr sysctl 8 .Sh HISTORY The .Fn swapon function call appeared in .Bx 4.0 . +.Fn Swapoff +appeared in +.Fx 5.0 . Index: sbin/swapon/Makefile =================================================================== RCS file: /home/ncvs/src/sbin/swapon/Makefile,v retrieving revision 1.6 diff -u -r1.6 Makefile --- sbin/swapon/Makefile 2001/12/04 02:19:58 1.6 +++ sbin/swapon/Makefile 2002/10/07 13:55:33 @@ -3,5 +3,7 @@ PROG= swapon MAN= swapon.8 +LINKS= ${BINDIR}/swapon ${BINDIR}/swapoff +MLINKS= swapon.8 swapoff.8 .include Index: sbin/swapon/swapon.8 =================================================================== RCS file: /home/ncvs/src/sbin/swapon/swapon.8,v retrieving revision 1.20 diff -u -r1.20 swapon.8 --- sbin/swapon/swapon.8 2002/08/21 18:11:44 1.20 +++ sbin/swapon/swapon.8 2002/10/07 13:55:33 @@ -36,39 +36,46 @@ .Dt SWAPON 8 .Os .Sh NAME -.Nm swapon -.Nd "specify additional device for paging and swapping" +.Nm swapon , swapoff +.Nd "specify devices for paging and swapping" .Sh SYNOPSIS -.Nm +.Nm swap[on|off] .Fl a -.Nm +.Nm swap[on|off] .Ar special_file ... .Sh DESCRIPTION The -.Nm +.Nm swapon utility is used to specify additional devices on which paging and swapping are to take place. The system begins by swapping and paging on only a single device so that only one disk is required at bootstrap time. Calls to -.Nm +.Nm swapon normally occur in the system multi-user initialization file .Pa /etc/rc making all swap devices available, so that the paging and swapping activity is interleaved across several devices. .Pp +The +.Nm swapoff +utility disables paging and swapping on a device. +Calls to +.Nm swapoff +succeed only if disabling the device would leave enough +remaining virtual memory to accomodate all running programs. +.Pp Normally, the first form is used: .Bl -tag -width indent .It Fl a All devices marked as ``sw'' swap devices in .Pa /etc/fstab -are made available unless their ``noauto'' option is also set. +are added to or removed from the pool of available swap +unless their ``noauto'' option is also set. .El .Pp -The second form gives individual block devices as given -in the system swap configuration table. The call makes only this space -available to the system for swap allocation. +The second form is used to configure or disable individual devices. .Sh SEE ALSO .Xr swapon 2 , .Xr fstab 5 , @@ -85,12 +92,12 @@ .It Pa /etc/fstab ASCII file system description table .El -.Sh BUGS -There is no way to stop paging and swapping on a device. -It is therefore not possible to dismount swap devices which are -mounted during system operation. .Sh HISTORY The -.Nm +.Nm swapon utility appeared in .Bx 4.0 . +The +.Nm swapoff +utility appeared in +.Fx 5.0 . Index: sbin/swapon/swapon.c =================================================================== RCS file: /home/ncvs/src/sbin/swapon/swapon.c,v retrieving revision 1.12 diff -u -r1.12 swapon.c --- sbin/swapon/swapon.c 2002/03/21 13:20:48 1.12 +++ sbin/swapon/swapon.c 2002/10/07 13:55:33 @@ -53,15 +53,21 @@ #include #include -static void usage(void); -int add(char *name, int ignoreebusy); +int do_swapoff; +static void usage(const char *); +static int this_is_swapoff(const char *); +int twiddle(char *name, int ignoreebusy); + int main(int argc, char **argv) { struct fstab *fsp; int stat; int ch, doall; + char *pname = argv[0]; + + do_swapoff = this_is_swapoff(pname); doall = 0; while ((ch = getopt(argc, argv, "a")) != -1) @@ -71,7 +77,7 @@ break; case '?': default: - usage(); + usage(pname); } argv += optind; @@ -82,23 +88,24 @@ continue; if (strstr(fsp->fs_mntops, "noauto")) continue; - if (add(fsp->fs_spec, 1)) + if (twiddle(fsp->fs_spec, 1)) stat = 1; else - printf("swapon: adding %s as swap device\n", + printf("%s: %sing %s as swap device\n", + pname, do_swapoff ? "remov" : "add", fsp->fs_spec); } else if (!*argv) - usage(); + usage(pname); for (; *argv; ++argv) - stat |= add(*argv, 0); + stat |= twiddle(*argv, 0); exit(stat); } int -add(char *name, int ignoreebusy) +twiddle(char *name, int ignoreebusy) { - if (swapon(name) == -1) { + if ((do_swapoff ? swapoff(name) : swapon(name)) == -1) { switch (errno) { case EBUSY: if (!ignoreebusy) @@ -114,8 +121,23 @@ } static void -usage() +usage(const char *pname) { - fprintf(stderr, "usage: swapon [-a] [special_file ...]\n"); + fprintf(stderr, "usage: %s [-a] [special_file ...]\n", pname); exit(1); +} + +static int +this_is_swapoff(const char *s) +{ + const char *u; + + if ((u = strrchr(s, '/')) != NULL) + ++u; + else + u = s; + if (strcmp(u, "swapoff") == 0) + return 1; + else + return 0; } Index: sys/kern/init_sysent.c =================================================================== RCS file: /home/ncvs/src/sys/kern/init_sysent.c,v retrieving revision 1.135 diff -u -r1.135 init_sysent.c --- sys/kern/init_sysent.c 2002/10/02 16:48:15 1.135 +++ sys/kern/init_sysent.c 2002/10/07 13:55:50 @@ -2,8 +2,8 @@ * System call switch table. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/kern/init_sysent.c,v 1.135 2002/10/02 16:48:15 archie Exp $ - * created from FreeBSD: src/sys/kern/syscalls.master,v 1.124 2002/10/01 02:35:59 rwatson Exp + * $FreeBSD$ + * created from FreeBSD: src/sys/kern/syscalls.master,v 1.125 2002/10/02 16:48:15 archie Exp */ #include "opt_compat.h" @@ -443,4 +443,5 @@ { 0, (sy_call_t *)nosys }, /* 412 = extattr_set_link */ { 0, (sy_call_t *)nosys }, /* 413 = extattr_get_link */ { 0, (sy_call_t *)nosys }, /* 414 = extattr_delete_link */ + { SYF_MPSAFE | AS(swapoff_args), (sy_call_t *)swapoff }, /* 415 = swapoff */ }; Index: sys/kern/subr_blist.c =================================================================== RCS file: /home/ncvs/src/sys/kern/subr_blist.c,v retrieving revision 1.10 diff -u -r1.10 subr_blist.c --- sys/kern/subr_blist.c 2002/05/18 23:46:04 1.10 +++ sys/kern/subr_blist.c 2002/10/07 13:55:51 @@ -93,7 +93,7 @@ #include #include -#define malloc(a,b,c) malloc(a) +#define malloc(a,b,c) calloc(a, 1) #define free(a,b) free(a) typedef unsigned int u_daddr_t; @@ -116,6 +116,9 @@ daddr_t radix, int skip, daddr_t blk); static void blst_copy(blmeta_t *scan, daddr_t blk, daddr_t radix, daddr_t skip, blist_t dest, daddr_t count); +static int blst_leaf_fill(blmeta_t *scan, daddr_t blk, int count); +static int blst_meta_fill(blmeta_t *scan, daddr_t allocBlk, daddr_t count, + daddr_t radix, int skip, daddr_t blk); static daddr_t blst_radix_init(blmeta_t *scan, daddr_t radix, int skip, daddr_t count); #ifndef _KERNEL @@ -165,13 +168,14 @@ #if defined(BLIST_DEBUG) printf( - "BLIST representing %d blocks (%d MB of swap)" - ", requiring %dK of ram\n", - bl->bl_blocks, - bl->bl_blocks * 4 / 1024, - (bl->bl_rootblks * sizeof(blmeta_t) + 1023) / 1024 + "BLIST representing %lld blocks (%lld MB of swap)" + ", requiring %lldK of ram\n", + (long long)bl->bl_blocks, + (long long)bl->bl_blocks * 4 / 1024, + (long long)(bl->bl_rootblks * sizeof(blmeta_t) + 1023) / 1024 ); - printf("BLIST raw radix tree contains %d records\n", bl->bl_rootblks); + printf("BLIST raw radix tree contains %lld records\n", + (long long)bl->bl_rootblks); #endif blst_radix_init(bl->bl_root, bl->bl_radix, bl->bl_skip, blocks); @@ -226,6 +230,30 @@ } /* + * blist_fill() - mark a region in the block bitmap as off-limits + * to the allocator (i.e. allocate it), ignoring any + * existing allocations. Return the number of blocks + * actually filled that were free before the call. + */ + +int +blist_fill(blist_t bl, daddr_t blkno, daddr_t count) +{ + int filled; + + if (bl) { + if (bl->bl_radix == BLIST_BMAP_RADIX) + filled = blst_leaf_fill(bl->bl_root, blkno, count); + else + filled = blst_meta_fill(bl->bl_root, blkno, count, + bl->bl_radix, bl->bl_skip, 0); + bl->bl_free -= filled; + return filled; + } else + return 0; +} + +/* * blist_resize() - resize an existing radix tree to handle the * specified number of blocks. This will reallocate * the tree and transfer the previous bitmap to the new @@ -507,9 +535,9 @@ int next_skip = (skip >> BLIST_META_RADIX_SHIFT); #if 0 - printf("FREE (%x,%d) FROM (%x,%d)\n", - freeBlk, count, - blk, radix + printf("FREE (%llx,%lld) FROM (%llx,%lld)\n", + (long long)freeBlk, (long long)count, + (long long)blk, (long long)radix ); #endif @@ -679,6 +707,117 @@ } /* + * BLST_LEAF_FILL() - allocate specific blocks in leaf bitmap + * + * This routine allocates all blocks in the specified range + * regardless of any existing allocations in that range. Returns + * the number of blocks allocated by the call. + */ + +static int +blst_leaf_fill(blmeta_t *scan, daddr_t blk, int count) +{ + int n = blk & (BLIST_BMAP_RADIX - 1); + int nblks; + u_daddr_t mask, bitmap; + + mask = ((u_daddr_t)-1 << n) & + ((u_daddr_t)-1 >> (BLIST_BMAP_RADIX - count - n)); + + /* Count the number of blocks we're about to allocate */ + bitmap = scan->u.bmu_bitmap & mask; + for (nblks = 0; bitmap != 0; nblks++) + bitmap &= bitmap - 1; + + scan->u.bmu_bitmap &= ~mask; + return nblks; +} + +/* + * BLIST_META_FILL() - allocate specific blocks at a meta node + * + * This routine allocates the specified range of blocks, + * regardless of any existing allocations in the range. The + * range must be within the extent of this node. Returns the + * number of blocks allocated by the call. + */ +static int +blst_meta_fill( + blmeta_t *scan, + daddr_t allocBlk, + daddr_t count, + daddr_t radix, + int skip, + daddr_t blk +) { + int i; + int next_skip = (skip >> BLIST_META_RADIX_SHIFT); + int nblks = 0; + + if (count == radix || scan->u.bmu_avail == 0) { + /* + * ALL-ALLOCATED special case + */ + nblks = scan->u.bmu_avail; + scan->u.bmu_avail = 0; + scan->bm_bighint = count; + return nblks; + } + + if (scan->u.bmu_avail == radix) { + radix >>= BLIST_META_RADIX_SHIFT; + + /* + * ALL-FREE special case, initialize sublevel + */ + for (i = 1; i <= skip; i += next_skip) { + if (scan[i].bm_bighint == (daddr_t)-1) + break; + if (next_skip == 1) { + scan[i].u.bmu_bitmap = (u_daddr_t)-1; + scan[i].bm_bighint = BLIST_BMAP_RADIX; + } else { + scan[i].bm_bighint = radix; + scan[i].u.bmu_avail = radix; + } + } + } else { + radix >>= BLIST_META_RADIX_SHIFT; + } + + if (count > radix) + panic("blist_meta_fill: allocation too large"); + + i = (allocBlk - blk) / radix; + blk += i * radix; + i = i * next_skip + 1; + + while (i <= skip && blk < allocBlk + count) { + daddr_t v; + + v = blk + radix - allocBlk; + if (v > count) + v = count; + + if (scan->bm_bighint == (daddr_t)-1) + panic("blst_meta_fill: filling unexpected range"); + + if (next_skip == 1) { + nblks += blst_leaf_fill(&scan[i], allocBlk, v); + } else { + nblks += blst_meta_fill(&scan[i], allocBlk, v, + radix, next_skip - 1, blk); + } + count -= v; + allocBlk += v; + blk += radix; + i += next_skip; + } + scan->u.bmu_avail -= nblks; + return nblks; +} + +/* * BLST_RADIX_INIT() - initialize radix tree * * Initialize our meta structures and bitmaps and calculate the exact @@ -768,41 +907,41 @@ if (radix == BLIST_BMAP_RADIX) { printf( - "%*.*s(%04x,%d): bitmap %08x big=%d\n", + "%*.*s(%08llx,%lld): bitmap %08llx big=%lld\n", tab, tab, "", - blk, radix, - scan->u.bmu_bitmap, - scan->bm_bighint + (long long)blk, (long long)radix, + (long long)scan->u.bmu_bitmap, + (long long)scan->bm_bighint ); return; } if (scan->u.bmu_avail == 0) { printf( - "%*.*s(%04x,%d) ALL ALLOCATED\n", + "%*.*s(%08llx,%lld) ALL ALLOCATED\n", tab, tab, "", - blk, - radix + (long long)blk, + (long long)radix ); return; } if (scan->u.bmu_avail == radix) { printf( - "%*.*s(%04x,%d) ALL FREE\n", + "%*.*s(%08llx,%lld) ALL FREE\n", tab, tab, "", - blk, - radix + (long long)blk, + (long long)radix ); return; } printf( - "%*.*s(%04x,%d): subtree (%d/%d) big=%d {\n", + "%*.*s(%08llx,%lld): subtree (%lld/%lld) big=%lld {\n", tab, tab, "", - blk, radix, - scan->u.bmu_avail, - radix, - scan->bm_bighint + (long long)blk, (long long)radix, + (long long)scan->u.bmu_avail, + (long long)radix, + (long long)scan->bm_bighint ); radix >>= BLIST_META_RADIX_SHIFT; @@ -812,9 +951,9 @@ for (i = 1; i <= skip; i += next_skip) { if (scan[i].bm_bighint == (daddr_t)-1) { printf( - "%*.*s(%04x,%d): Terminator\n", + "%*.*s(%08llx,%lld): Terminator\n", tab, tab, "", - blk, radix + (long long)blk, (long long)radix ); lastState = 0; break; @@ -866,13 +1005,14 @@ daddr_t count = 0; - printf("%d/%d/%d> ", bl->bl_free, size, bl->bl_radix); + printf("%lld/%lld/%lld> ", (long long)bl->bl_free, + (long long)size, (long long)bl->bl_radix); fflush(stdout); if (fgets(buf, sizeof(buf), stdin) == NULL) break; switch(buf[0]) { case 'r': - if (sscanf(buf + 1, "%d", &count) == 1) { + if (sscanf(buf + 1, "%lld", &count) == 1) { blist_resize(&bl, count, 1); } else { printf("?\n"); @@ -881,26 +1021,37 @@ blist_print(bl); break; case 'a': - if (sscanf(buf + 1, "%d", &count) == 1) { + if (sscanf(buf + 1, "%lld", &count) == 1) { daddr_t blk = blist_alloc(bl, count); - printf(" R=%04x\n", blk); + printf(" R=%08llx\n", (long long)blk); } else { printf("?\n"); } break; case 'f': - if (sscanf(buf + 1, "%x %d", &da, &count) == 2) { + if (sscanf(buf + 1, "%llx %lld", + (long long *)&da, (long long *)&count) == 2) { blist_free(bl, da, count); } else { printf("?\n"); } break; + case 'l': + if (sscanf(buf + 1, "%llx %lld", + (long long *)&da, (long long *)&count) == 2) { + printf(" n=%d\n", + blist_fill(bl, da, count)); + } else { + printf("?\n"); + } + break; case '?': case 'h': puts( "p -print\n" "a %d -allocate\n" "f %x %d -free\n" + "l %x %d -fill\n" "r %d -resize\n" "h/? -help" ); Index: sys/kern/syscalls.c =================================================================== RCS file: /home/ncvs/src/sys/kern/syscalls.c,v retrieving revision 1.120 diff -u -r1.120 syscalls.c --- sys/kern/syscalls.c 2002/10/01 02:37:35 1.120 +++ sys/kern/syscalls.c 2002/10/07 13:55:51 @@ -2,8 +2,8 @@ * System call names. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/kern/syscalls.c,v 1.120 2002/10/01 02:37:35 rwatson Exp $ - * created from FreeBSD: src/sys/kern/syscalls.master,v 1.124 2002/10/01 02:35:59 rwatson Exp + * $FreeBSD$ + * created from FreeBSD: src/sys/kern/syscalls.master,v 1.125 2002/10/02 16:48:15 archie Exp */ char *syscallnames[] = { @@ -422,4 +422,5 @@ "#412", /* 412 = extattr_set_link */ "#413", /* 413 = extattr_get_link */ "#414", /* 414 = extattr_delete_link */ + "swapoff", /* 415 = swapoff */ }; Index: sys/kern/syscalls.master =================================================================== RCS file: /home/ncvs/src/sys/kern/syscalls.master,v retrieving revision 1.125 diff -u -r1.125 syscalls.master --- sys/kern/syscalls.master 2002/10/02 16:48:15 1.125 +++ sys/kern/syscalls.master 2002/10/07 13:55:52 @@ -590,3 +590,4 @@ 412 UNIMPL BSD extattr_set_link 413 UNIMPL BSD extattr_get_link 414 UNIMPL BSD extattr_delete_link +415 MSTD BSD { int swapoff(const char *name); } Index: sys/sys/blist.h =================================================================== RCS file: /home/ncvs/src/sys/sys/blist.h,v retrieving revision 1.4 diff -u -r1.4 blist.h --- sys/sys/blist.h 2002/05/18 09:38:20 1.4 +++ sys/sys/blist.h 2002/10/07 13:55:58 @@ -9,6 +9,7 @@ * (void) blist_destroy(blist) * blkno = blist_alloc(blist, count) * (void) blist_free(blist, blkno, count) + * nblks = blist_fill(blist, blkno, count) * (void) blist_resize(&blist, count, freeextra) * * @@ -78,6 +79,7 @@ extern void blist_destroy(blist_t blist); extern daddr_t blist_alloc(blist_t blist, daddr_t count); extern void blist_free(blist_t blist, daddr_t blkno, daddr_t count); +extern int blist_fill(blist_t bl, daddr_t blkno, daddr_t count); extern void blist_print(blist_t blist); extern void blist_resize(blist_t *pblist, daddr_t count, int freenew); Index: sys/sys/conf.h =================================================================== RCS file: /home/ncvs/src/sys/sys/conf.h,v retrieving revision 1.149 diff -u -r1.149 conf.h --- sys/sys/conf.h 2002/09/27 19:47:56 1.149 +++ sys/sys/conf.h 2002/10/07 13:55:59 @@ -267,6 +267,7 @@ }; #define SW_FREED 0x01 #define SW_SEQUENTIAL 0x02 +#define SW_CLOSING 0x04 #define sw_freed sw_flags /* XXX compat */ #ifdef _KERNEL Index: sys/sys/syscall.h =================================================================== RCS file: /home/ncvs/src/sys/sys/syscall.h,v retrieving revision 1.119 diff -u -r1.119 syscall.h --- sys/sys/syscall.h 2002/10/01 02:37:35 1.119 +++ sys/sys/syscall.h 2002/10/07 13:56:00 @@ -2,8 +2,8 @@ * System call numbers. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/sys/syscall.h,v 1.119 2002/10/01 02:37:35 rwatson Exp $ - * created from FreeBSD: src/sys/kern/syscalls.master,v 1.124 2002/10/01 02:35:59 rwatson Exp + * $FreeBSD$ + * created from FreeBSD: src/sys/kern/syscalls.master,v 1.125 2002/10/02 16:48:15 archie Exp */ #define SYS_syscall 0 @@ -317,4 +317,5 @@ #define SYS_ksem_unlink 406 #define SYS_ksem_getvalue 407 #define SYS_ksem_destroy 408 -#define SYS_MAXSYSCALL 415 +#define SYS_swapoff 415 +#define SYS_MAXSYSCALL 416 Index: sys/sys/syscall.mk =================================================================== RCS file: /home/ncvs/src/sys/sys/syscall.mk,v retrieving revision 1.74 diff -u -r1.74 syscall.mk --- sys/sys/syscall.mk 2002/10/01 02:37:35 1.74 +++ sys/sys/syscall.mk 2002/10/07 13:56:00 @@ -1,7 +1,7 @@ # FreeBSD system call names. # DO NOT EDIT-- this file is automatically generated. -# $FreeBSD: src/sys/sys/syscall.mk,v 1.74 2002/10/01 02:37:35 rwatson Exp $ -# created from FreeBSD: src/sys/kern/syscalls.master,v 1.124 2002/10/01 02:35:59 rwatson Exp +# $FreeBSD$ +# created from FreeBSD: src/sys/kern/syscalls.master,v 1.125 2002/10/02 16:48:15 archie Exp MIASM = \ syscall.o \ exit.o \ @@ -265,4 +265,5 @@ ksem_open.o \ ksem_unlink.o \ ksem_getvalue.o \ - ksem_destroy.o + ksem_destroy.o \ + swapoff.o Index: sys/sys/sysproto.h =================================================================== RCS file: /home/ncvs/src/sys/sys/sysproto.h,v retrieving revision 1.112 diff -u -r1.112 sysproto.h --- sys/sys/sysproto.h 2002/10/02 16:48:16 1.112 +++ sys/sys/sysproto.h 2002/10/07 13:56:03 @@ -2,8 +2,8 @@ * System call prototypes. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/sys/sysproto.h,v 1.112 2002/10/02 16:48:16 archie Exp $ - * created from FreeBSD: src/sys/kern/syscalls.master,v 1.124 2002/10/01 02:35:59 rwatson Exp + * $FreeBSD$ + * created from FreeBSD: src/sys/kern/syscalls.master,v 1.125 2002/10/02 16:48:15 archie Exp */ #ifndef _SYS_SYSPROTO_H_ @@ -1157,6 +1157,9 @@ struct ksem_destroy_args { char id_l_[PADL_(semid_t)]; semid_t id; char id_r_[PADR_(semid_t)]; }; +struct swapoff_args { + char name_l_[PADL_(const char *)]; const char * name; char name_r_[PADR_(const char *)]; +}; int nosys(struct thread *, struct nosys_args *); void sys_exit(struct thread *, struct sys_exit_args *); int fork(struct thread *, struct fork_args *); @@ -1419,6 +1422,7 @@ int ksem_unlink(struct thread *, struct ksem_unlink_args *); int ksem_getvalue(struct thread *, struct ksem_getvalue_args *); int ksem_destroy(struct thread *, struct ksem_destroy_args *); +int swapoff(struct thread *, struct swapoff_args *); #ifdef COMPAT_43 Index: sys/vm/swap_pager.c =================================================================== RCS file: /home/ncvs/src/sys/vm/swap_pager.c,v retrieving revision 1.180 diff -u -r1.180 swap_pager.c --- sys/vm/swap_pager.c 2002/09/28 17:15:32 1.180 +++ sys/vm/swap_pager.c 2002/10/07 13:56:05 @@ -197,6 +197,7 @@ static __inline void swp_sizecheck(void); static void swp_pager_sync_iodone(struct buf *bp); static void swp_pager_async_iodone(struct buf *bp); +static __inline int swp_pager_force_pagein(struct swblock *, int); /* * Swap bitmap functions @@ -207,6 +208,8 @@ /* * Metadata functions */ +static __inline struct swblock ** + swp_pager_hash(vm_object_t object, vm_pindex_t index); static void swp_pager_meta_build(vm_object_t, vm_pindex_t, daddr_t); static void swp_pager_meta_free(vm_object_t, vm_pindex_t, daddr_t); static void swp_pager_meta_free_all(vm_object_t); @@ -513,12 +516,22 @@ daddr_t blk; int npages; { + struct swdevt *sp = &swdevt[BLK2DEVIDX(blk)]; + GIANT_REQUIRED; + /* per-swap area stats */ + sp->sw_used -= npages; + + /* + * If we are attempting to stop swapping on this device, we + * don't want to mark any blocks free lest they be reused. + */ + if (sp->sw_flags & SW_CLOSING) + return; + blist_free(swapblist, blk, npages); vm_swap_size += npages; - /* per-swap area stats */ - swdevt[BLK2DEVIDX(blk)].sw_used -= npages; swp_sizecheck(); } @@ -1623,6 +1636,147 @@ ) ); splx(s); +} + +/* + * swap_pager_isswapped: + * + * Return 1 if at least one page in the given object is paged + * out to the given swap device. + */ +int swap_pager_isswapped(vm_object_t object, int devidx) { + daddr_t index = 0; + int bcount; + int i; + + for (bcount = 0; bcount < object->un_pager.swp.swp_bcount; bcount++) { + struct swblock **pswap; + struct swblock *swap; + + pswap = swp_pager_hash(object, index); + + if ((swap = *pswap) != NULL) { + for (i = 0; i < SWAP_META_PAGES; ++i) { + daddr_t v = swap->swb_pages[i]; + if (v != SWAPBLK_NONE && + BLK2DEVIDX(v) == devidx && + !vm_page_lookup(object, swap->swb_index+i)) + return 1; + } + } + + index += SWAP_META_PAGES; + if (index > 0x20000000) + panic("swap_pager_isswapped: failed to locate all swap meta blocks"); + } + return 0; +} + +/* + * swap_pager_swapoff: + * + * Page in all of the pages that have been paged out to the + * given device. The corresponding blocks in the bitmap must be + * marked as allocated and the device must be flagged SW_CLOSING. + * There may be no processes swapped out to the device. + * + * This routine may block. + */ +void +swap_pager_swapoff(int devidx) +{ + struct swblock **pswap; + struct swblock *swap; + daddr_t v; + int i, j, k; + int paged; + + GIANT_REQUIRED; + + for (i = 0; i <= swhash_mask; i++) { /* '<=' is correct here */ +restart: + pswap = &swhash[i]; + while ((swap = *pswap) != NULL) { + for (j = 0; j < SWAP_META_PAGES; j += paged) { + paged = 1; + v = swap->swb_pages[j]; + if (v == SWAPBLK_NONE || + BLK2DEVIDX(v) != devidx) + continue; + + paged = swp_pager_force_pagein(swap, j); + + swp_pager_freeswapspace(swap->swb_pages[j], + paged); + for (k = j; k < j + paged; k++) + swap->swb_pages[k] = SWAPBLK_NONE; + swap->swb_count -= paged; + if (swap->swb_count <= 0) { + *pswap = swap->swb_hnext; + --swap->swb_object->un_pager.swp.swp_bcount; + uma_zfree(swap_zone, swap); + } + + goto restart; + } + pswap = &swap->swb_hnext; + } + } +} + +/* + * SWP_PAGER_FORCE_PAGEIN() - force pages on a device to be paged in + * + * This routine dissociates the page at the given index within a + * swap block from its backing store, paging it in if necessary. + * If the page is paged in, it is placed in the inactive queue, + * since it had its backing store ripped out from under it. The + * swap metadata associated with the page is left intact. This + * function returns the number of pages that were dissociated + * from their swap backing. + * + * XXX This routine could be optimized to bring in adjacent pages + * on the device. (needs to be passed devidx as well) + */ +static __inline int +swp_pager_force_pagein(struct swblock *swap, int idx) +{ + vm_object_t object; + vm_page_t m; + vm_pindex_t pindex; + + object = swap->swb_object; + pindex = swap->swb_index + idx; + + if (object->type != OBJT_SWAP) + panic("swp_pager_force_pagein: object not backed by swap"); + + m = vm_page_grab(object, pindex, VM_ALLOC_NORMAL | VM_ALLOC_RETRY); + if (m->valid == VM_PAGE_BITS_ALL) { + /* + * The page is already in memory, but must be + * dirtied, since we're taking away its backing store. + */ + vm_page_lock_queues(); + vm_page_activate(m); + vm_page_dirty(m); + vm_page_wakeup(m); + vm_page_unlock_queues(); + return 1; + } + + vm_object_pip_add(object, 1); + if (swap_pager_getpages(object, &m, 1, 0) != VM_PAGER_OK) + panic("swap_pager_force_pagein: read from swap failed");/*XXX*/ + vm_object_pip_subtract(object, 1); + vm_page_dirty(m); + + vm_page_lock_queues(); + vm_page_dontneed(m); + vm_page_wakeup(m); + vm_page_unlock_queues(); + + return 1; } /************************************************************************ Index: sys/vm/swap_pager.h =================================================================== RCS file: /home/ncvs/src/sys/vm/swap_pager.h,v retrieving revision 1.34 diff -u -r1.34 swap_pager.h --- sys/vm/swap_pager.h 2002/09/05 14:04:34 1.34 +++ sys/vm/swap_pager.h 2002/10/07 13:56:05 @@ -83,9 +83,11 @@ extern int swap_pager_full; extern struct blist *swapblist; extern struct uma_zone *swap_zone; +extern int nswap_lowat, nswap_hiwat; void swap_pager_putpages(vm_object_t, vm_page_t *, int, boolean_t, int *); boolean_t swap_pager_haspage(vm_object_t object, vm_pindex_t pindex, int *before, int *after); +void swap_pager_swapoff(int devidx); int swap_pager_swp_alloc(vm_object_t, int); void swap_pager_copy(vm_object_t, vm_object_t, vm_pindex_t, int); Index: sys/vm/vm_glue.c =================================================================== RCS file: /home/ncvs/src/sys/vm/vm_glue.c,v retrieving revision 1.157 diff -u -r1.157 vm_glue.c --- sys/vm/vm_glue.c 2002/09/28 17:15:33 1.157 +++ sys/vm/vm_glue.c 2002/10/07 13:56:06 @@ -324,6 +324,35 @@ up = (vm_offset_t)p->p_uarea; pmap_qenter(up, ma, UAREA_PAGES); } + +/* + * Swap in the UAREAs of all processes swapped out to the given device. + */ +void +vm_proc_swapin_all(int devidx) +{ + struct proc *p; + +retry: + sx_slock(&allproc_lock); + FOREACH_PROC_IN_SYSTEM(p) { + PROC_LOCK(p); + mtx_lock_spin(&sched_lock); + + if (p->p_upages_obj != NULL && + swap_pager_isswapped(p->p_upages_obj, devidx)) { + sx_sunlock(&allproc_lock); + faultin(p); + mtx_unlock_spin(&sched_lock); + PROC_UNLOCK(p); + goto retry; + } + + mtx_unlock_spin(&sched_lock); + PROC_UNLOCK(p); + } + sx_sunlock(&allproc_lock); +} #endif /* Index: sys/vm/vm_pageout.h =================================================================== RCS file: /home/ncvs/src/sys/vm/vm_pageout.h,v retrieving revision 1.30 diff -u -r1.30 vm_pageout.h --- sys/vm/vm_pageout.h 2002/03/19 22:17:45 1.30 +++ sys/vm/vm_pageout.h 2002/10/07 13:56:06 @@ -104,6 +104,12 @@ extern void vm_wait(void); extern void vm_waitpfault(void); +/* XXX This is probably misplaced. */ +#ifndef NO_SWAPPING +void vm_proc_swapin_all(int); +int swap_pager_isswapped(vm_object_t, int); +#endif /* !NO_SWAPPING */ + #ifdef _KERNEL void vm_pageout_page(vm_page_t, vm_object_t); void vm_pageout_cluster(vm_page_t, vm_object_t); Index: sys/vm/vm_swap.c =================================================================== RCS file: /home/ncvs/src/sys/vm/vm_swap.c,v retrieving revision 1.122 diff -u -r1.122 vm_swap.c --- sys/vm/vm_swap.c 2002/09/25 01:24:17 1.122 +++ sys/vm/vm_swap.c 2002/10/07 13:56:10 @@ -35,6 +35,7 @@ */ #include "opt_swap.h" +#include "opt_vm.h" #include #include @@ -56,6 +57,7 @@ #include #include #include +#include #include #include @@ -163,11 +165,12 @@ /* * Create a special vnode op vector for swapdev_vp - we only use - * VOP_STRATEGY(), everything else returns an error. + * VOP_STRATEGY() and reclaim; everything else returns an error. */ vop_t **swapdev_vnodeop_p; static struct vnodeopv_entry_desc swapdev_vnodeop_entries[] = { { &vop_default_desc, (vop_t *) vop_defaultop }, + { &vop_reclaim_desc, (vop_t *) vop_null }, { &vop_strategy_desc, (vop_t *) swapdev_strategy }, { NULL, NULL } }; @@ -324,7 +327,7 @@ sp->sw_vp = vp; sp->sw_dev = dev2udev(dev); sp->sw_device = dev; - sp->sw_flags |= SW_FREED; + sp->sw_flags = SW_FREED; sp->sw_nblks = nblks; sp->sw_used = 0; @@ -350,7 +353,121 @@ vm_swap_size += blk; } + swap_pager_full = 0; + return (0); +} + +/* + * SYSCALL: swapoff(devname) + * + * Disable swapping on the given device. + */ +#ifndef _SYS_SYSPROTO_H_ +struct swapoff_args { + char *name; +}; +#endif + +/* + * MPSAFE + */ +/* ARGSUSED */ +int +swapoff(td, uap) + struct thread *td; + struct swapoff_args *uap; +{ + struct vnode *vp; + struct nameidata nd; + struct swdevt *sp; + swblk_t dvbase, vsbase; + u_long nblks, aligned_nblks, blk; + int error, index; + + mtx_lock(&Giant); + + error = suser(td); + if (error) + goto done; + + NDINIT(&nd, LOOKUP, FOLLOW, UIO_USERSPACE, uap->name, td); + error = namei(&nd); + if (error) + goto done; + NDFREE(&nd, NDF_ONLY_PNBUF); + vp = nd.ni_vp; + + for (sp = swdevt, index = 0 ; index < nswdev; index++, sp++) { + if (sp->sw_vp == vp) + goto found; + } + error = EINVAL; + goto done; +found: + nblks = sp->sw_nblks; + + /* + * We can turn off this swap device safely only if the + * available virtual memory in the system will fit the amount + * of data we will have to page back in, plus an epsilon so + * the system doesn't become critically low on swap space. + */ + if (cnt.v_free_count + cnt.v_cache_count + vm_swap_size < + sp->sw_used + nswap_lowat) { + error = ENOMEM; + goto done; + } + + /* + * Prevent further allocations on this device. + */ + sp->sw_flags |= SW_CLOSING; + for (dvbase = dmmax; dvbase < nblks; dvbase += dmmax) { + blk = min(nblks - dvbase, dmmax); + vsbase = index * dmmax + dvbase * nswdev; + vm_swap_size -= blist_fill(swapblist, vsbase, blk); + } + + /* + * Page in the contents of the device and close it. + */ +#ifndef NO_SWAPPING + vm_proc_swapin_all(index); +#endif /* !NO_SWAPPING */ + swap_pager_swapoff(index); + + if (sp->sw_used != 0) + panic("swapoff: failed to locate %d swap blocks", sp->sw_used); + + VOP_CLOSE(vp, FREAD | FWRITE, td->td_ucred, td); + vrele(vp); + sp->sw_vp = NULL; + + /* + * Resize the bitmap based on the new largest swap device, + * or free the bitmap if there are no more devices. + */ + for (sp = swdevt, nblks = 0; sp < swdevt + nswdev; sp++) { + if (sp->sw_vp == NULL) + continue; + nblks = max(nblks, sp->sw_nblks); + } + + aligned_nblks = (nblks + (dmmax - 1)) & ~(u_long)(dmmax - 1); + nswap = aligned_nblks * nswdev; + + if (nswap == 0) { + blist_destroy(swapblist); + swapblist = NULL; + vrele(swapdev_vp); + swapdev_vp = NULL; + } else + blist_resize(&swapblist, nswap, 0); + +done: + mtx_unlock(&Giant); + return (error); } static int To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 9: 9:53 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 350EE37B401 for ; Mon, 7 Oct 2002 09:09:45 -0700 (PDT) Received: from salmon.maths.tcd.ie (salmon.maths.tcd.ie [134.226.81.11]) by mx1.FreeBSD.org (Postfix) with SMTP id E5BF543E42 for ; Mon, 7 Oct 2002 09:09:41 -0700 (PDT) (envelope-from iedowse@maths.tcd.ie) Received: from walton.maths.tcd.ie by salmon.maths.tcd.ie with SMTP id ; 7 Oct 2002 17:09:39 +0100 (BST) To: hackers@freebsd.org Subject: gdb support for kernel modules Date: Mon, 07 Oct 2002 17:09:39 +0100 From: Ian Dowse Message-ID: <200210071709.aa25499@salmon.maths.tcd.ie> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG This is something I have been meaning to investigate for a while: when gdb encounters a userland executable that uses shared libraries it automatically adds the symbols from each library, so it seemed likely that gdb could be made do the same thing with kernel modules. I am aware of the existence of `gdbmods' etc, but it would be nicer to have the support built in to gdb. Anyway, below is a proof-of-concept patch that does the basics, but among other things, its logic for locating the kernel module files needs a lot of work - currently it just assumes /boot/kernel/, which is almost never what you actually want. It works for debugging vmcores and live /dev/mem access, but I don't know if it can work for remote debugging. Does anybody know gdb internals enough to comment on how this is done or suggest improvements? Ian # gdb -k kernel.debug /dev/mem ... This GDB was configured as "i386-undermydesk-freebsd"... panic messages: --- --- warning: skipping first file (kernel) Reading symbols from /boot/kernel/ufs.ko...done. Loaded symbols for /boot/kernel/ufs.ko Reading symbols from /boot/kernel/md.ko...done. Loaded symbols for /boot/kernel/md.ko Reading symbols from /boot/kernel/vinum.ko...done. Loaded symbols for /boot/kernel/vinum.ko #0 mi_switch () at ../../../kern/kern_synch.c:849 849 td->td_kse->ke_oncpu = PCPU_GET(cpuid); (kgdb) info sharedlibrary warning: skipping first file (kernel) From To Syms Read Shared Object Library 0xc1098dd0 0xc10bfc10 Yes /boot/kernel/ufs.ko 0xc11e24d0 0xc11e4270 Yes /boot/kernel/md.ko 0xc10cf940 0xc10ddc30 Yes /boot/kernel/vinum.ko (kgdb) proc 316 (kgdb) bt #0 mi_switch () at ../../../kern/kern_synch.c:849 #1 0xc01b7d14 in msleep (ident=0xc1292e00, mtx=0x0, priority=76, wmesg=0x0, timo=0) at ../../../kern/kern_synch.c:559 #2 0xc11e3052 in md_kthread (arg=0xc1292e00) at /usr/src/sys/dev/md/md.c:578 #3 0xc019d2e5 in fork_exit (callout=0xc11e2fd0 , arg=0x0, frame=0x0) at ../../../kern/kern_fork.c:853 (kgdb) Index: Makefile =================================================================== RCS file: /dump/FreeBSD-CVS/src/gnu/usr.bin/binutils/gdb/Makefile,v retrieving revision 1.61 diff -u -r1.61 Makefile --- Makefile 29 Jun 2002 03:16:10 -0000 1.61 +++ Makefile 7 Oct 2002 10:31:41 -0000 @@ -37,7 +37,7 @@ ui-file.c ui-out.c wrapper.c cli-out.c \ cli-cmds.c cli-cmds.h cli-decode.c cli-decode.h cli-script.c \ cli-script.h cli-setshow.c cli-setshow.h cli-utils.c cli-utils.h -XSRCS+= freebsd-uthread.c kvm-fbsd.c +XSRCS+= freebsd-uthread.c kvm-fbsd.c solib-fbsd-kld.c SRCS= init.c ${XSRCS} nm.h tm.h xm.h gdbversion.c xregex.h .if exists(${.CURDIR}/Makefile.${TARGET_ARCH}) Index: fbsd-kgdb.h =================================================================== RCS file: /dump/FreeBSD-CVS/src/gnu/usr.bin/binutils/gdb/fbsd-kgdb.h,v retrieving revision 1.3 diff -u -r1.3 fbsd-kgdb.h --- fbsd-kgdb.h 18 Sep 2002 16:20:49 -0000 1.3 +++ fbsd-kgdb.h 6 Oct 2002 23:32:14 -0000 @@ -7,6 +7,7 @@ extern int kernel_debugging; extern int kernel_writablecore; +extern struct target_so_ops kgdb_so_ops; #define ADDITIONAL_OPTIONS \ {"kernel", no_argument, &kernel_debugging, 1}, \ Index: kvm-fbsd.c =================================================================== RCS file: /dump/FreeBSD-CVS/src/gnu/usr.bin/binutils/gdb/kvm-fbsd.c,v retrieving revision 1.42 diff -u -r1.42 kvm-fbsd.c --- kvm-fbsd.c 18 Sep 2002 16:19:05 -0000 1.42 +++ kvm-fbsd.c 6 Oct 2002 23:41:56 -0000 @@ -56,6 +56,7 @@ #include "bfd.h" #include "target.h" #include "gdbcore.h" +#include "solist.h" static void kcore_files_info (struct target_ops *); @@ -72,6 +73,10 @@ static int xfer_umem (CORE_ADDR, char *, int, int); +#ifdef SOLIB_ADD +static int kcore_solib_add_stub (PTR); +#endif + static char *core_file; static kvm_t *core_kd; static struct pcb cur_pcb; @@ -209,6 +214,12 @@ inferior_ptid = null_ptid; /* Avoid confusion from thread stuff. */ + /* Clear out solib state while the bfd is still open. See + comments in clear_solib in solib.c. */ +#ifdef CLEAR_SOLIB + CLEAR_SOLIB (); +#endif + if (core_kd) { kvm_close (core_kd); @@ -305,7 +316,16 @@ printf ("---\n"); } - if (!ontop) + if (ontop) + { + /* Add symbols and section mappings for any kernel modules. */ +#ifdef SOLIB_ADD + current_target_so_ops = &kgdb_so_ops; + catch_errors (kcore_solib_add_stub, &from_tty, (char *) 0, + RETURN_MASK_ALL); +#endif + } + else { warning ("you won't be able to access this core file until you terminate\n" "your %s; do ``info files''", target_longname); @@ -651,6 +671,15 @@ if (set_context ((CORE_ADDR) val)) error ("invalid proc address"); } + +#ifdef SOLIB_ADD +static int +kcore_solib_add_stub (PTR from_ttyp) +{ + SOLIB_ADD (NULL, *(int *) from_ttyp, ¤t_target, auto_solib_add); + return 0; +} +#endif /* SOLIB_ADD */ void _initialize_kcorelow (void) Index: solib-fbsd-kld.c =================================================================== RCS file: solib-fbsd-kld.c diff -N solib-fbsd-kld.c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ solib-fbsd-kld.c 7 Oct 2002 10:39:48 -0000 @@ -0,0 +1,181 @@ +/* Handle FreeBSD kernel modules as shared libraries. + Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, + 2001 + Free Software Foundation, Inc. + + This file is part of GDB. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place - Suite 330, + Boston, MA 02111-1307, USA. */ + +#include +#include +#define _KERNEL +#include +#undef _KERNEL + +#include "defs.h" +#include "symtab.h" +#include "bfd.h" +#include "symfile.h" +#include "objfiles.h" +#include "gdbcore.h" +#include "target.h" +#include "inferior.h" + +#include "solist.h" + +struct lm_info + { + CORE_ADDR address; + }; + +static void +kgdb_relocate_section_addresses (struct so_list *so, + struct section_table *sec) +{ + sec->addr += so->lm_info->address; + sec->endaddr += so->lm_info->address; +} + +static int +kgdb_open_symbol_file_object (void *from_ttyp) +{ + warning ("kgdb_open_symbol_file_object called\n"); + return 0; +} + +static struct so_list * +kgdb_current_sos (void) +{ + linker_file_list_t linker_files; + struct linker_file lfile; + struct minimal_symbol *msymbol; + struct linker_file *lfilek; + struct so_list *head = NULL; + struct so_list **link_ptr = &head; + + CORE_ADDR lfiles_addr; + + msymbol = lookup_minimal_symbol ("linker_files", NULL, symfile_objfile); + if (msymbol == NULL || SYMBOL_VALUE_ADDRESS (msymbol) == 0) + { + warning ("failed to find linker_files symbol\n"); + return 0; + } + lfiles_addr = SYMBOL_VALUE_ADDRESS (msymbol); + if (target_read_memory (lfiles_addr, (char *)&linker_files, + sizeof (linker_files))) + { + warning ("failed to read linker_files data\n"); + return 0; + } + for (lfilek = TAILQ_FIRST (&linker_files); lfilek != NULL; + lfilek = TAILQ_NEXT (&lfile, link)) + { + struct so_list *new; + struct cleanup *old_chain; + char *buf; + int errcode; + + if (target_read_memory ((CORE_ADDR) lfilek, (char *) &lfile, + sizeof (lfile))) + { + warning ("failed to read linker file data at %p\n", lfilek); + return 0; + } + target_read_string ((CORE_ADDR) lfile.filename, &buf, + SO_NAME_MAX_PATH_SIZE - 1, &errcode); + if (errcode != 0) + { + warning ("cannot read linker file pathname: %s\n", + safe_strerror (errcode)); + return 0; + } + if (lfilek == TAILQ_FIRST (&linker_files)) /* XXX kernel always first? */ + { + warning ("skipping first file (%s)\n", buf); + xfree (buf); + continue; + } + + new = (struct so_list *) xmalloc (sizeof (struct so_list)); + old_chain = make_cleanup (xfree, new); + + memset (new, 0, sizeof (*new)); + + new->lm_info = xmalloc (sizeof (struct lm_info)); + make_cleanup (xfree, new->lm_info); + + new->lm_info->address = (CORE_ADDR) lfile.address; + + strncpy (new->so_original_name, buf, SO_NAME_MAX_PATH_SIZE - 1); + new->so_original_name[SO_NAME_MAX_PATH_SIZE - 1] = '\0'; + xfree (buf); + snprintf (new->so_name, SO_NAME_MAX_PATH_SIZE, "/boot/kernel/%s", + new->so_original_name); + + new->next = NULL; + *link_ptr = new; + link_ptr = &new->next; + + discard_cleanups (old_chain); + } + return head; +} + +static int +kgdb_in_dynsym_resolve_code (CORE_ADDR pc) +{ + warning ("kgdb_in_dynsym_resolve_code called\n"); + return 0; +} + +static void +kgdb_special_symbol_handling (void) +{ +} + +static void +kgdb_solib_create_inferior_hook (void) +{ + warning ("kgdb_solib_create_inferior_hook called\n"); +} + +static void +kgdb_clear_solib (void) +{ +} + +static void +kgdb_free_so (struct so_list *so) +{ + xfree (so->lm_info); +} + +struct target_so_ops kgdb_so_ops; + +void +_initialize_kgdb_solib (void) +{ + kgdb_so_ops.relocate_section_addresses = kgdb_relocate_section_addresses; + kgdb_so_ops.free_so = kgdb_free_so; + kgdb_so_ops.clear_solib = kgdb_clear_solib; + kgdb_so_ops.solib_create_inferior_hook = kgdb_solib_create_inferior_hook; + kgdb_so_ops.special_symbol_handling = kgdb_special_symbol_handling; + kgdb_so_ops.current_sos = kgdb_current_sos; + kgdb_so_ops.open_symbol_file_object = kgdb_open_symbol_file_object; + kgdb_so_ops.in_dynsym_resolve_code = kgdb_in_dynsym_resolve_code; +} To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 12:17:37 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9147737B401 for ; Mon, 7 Oct 2002 12:17:36 -0700 (PDT) Received: from srv2.resnet.ohio-state.edu (srv2.resnet.ohio-state.edu [164.107.3.56]) by mx1.FreeBSD.org (Postfix) with SMTP id BEB3D43E6A for ; Mon, 7 Oct 2002 12:17:35 -0700 (PDT) (envelope-from mistry.7@osu.edu) Received: (qmail 15385 invoked by uid 506); 7 Oct 2002 19:22:39 -0000 Received: from mistry.7@osu.edu by srv2.resnet.ohio-state.edu by uid 503 with qmail-scanner-1.14 ( Clear:. Processed in 0.018144 secs); 07 Oct 2002 19:22:39 -0000 Received: from rdrt-164-107-205-104.resnet.ohio-state.edu (HELO bigguy.am-productions.biz) (164.107.205.104) by srv2.resnet.ohio-state.edu with SMTP; 7 Oct 2002 19:22:39 -0000 Content-Type: text/plain; charset="us-ascii" From: Anish Mistry To: freebsd-hackers@freebsd.org Subject: Hercules Game Theatre XP CS4630 csa pcm driver Date: Mon, 7 Oct 2002 15:16:51 -0400 User-Agent: KMail/1.4.3 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200210071516.51446.mistry.7@osu.edu> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I've got a Hercules Game Theatre XP sound card. It has an external=20 breakout box and uses a CS4630 chipset. Just using the pcm device to pla= y=20 sound produces a lot of crackling and popping. This is because there are= =20 special drivers for Windows that control the output of the box. I've go= t=20 the whitepapers(registers,values,etc) for the CS4630, but I'm not sure wh= ere=20 to start to even write a special purpose driver/kernel module for this=20 device. What would be required to write a driver for this device? I've never = done=20 this before, but that's never stopped me before. What information do I n= eed=20 to get from Hercules about the card/box and is there anyone who would be=20 willing to help me out if even it's just to figure out what information t= hat=20 I need to get started. Thanks for any help, --=20 Anish Mistry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 13: 9:26 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3653237B401 for ; Mon, 7 Oct 2002 13:09:25 -0700 (PDT) Received: from mailgw2a.lmco.com (mailgw2a.lmco.com [192.91.147.7]) by mx1.FreeBSD.org (Postfix) with ESMTP id 79E8943E6E for ; Mon, 7 Oct 2002 13:09:24 -0700 (PDT) (envelope-from rick.norman@lmco.com) Received: from emss01g01.ems.lmco.com ([129.197.181.54]) by mailgw2a.lmco.com (8.11.6/8.11.6) with ESMTP id g97K9N903583 for ; Mon, 7 Oct 2002 16:09:23 -0400 (EDT) Received: from CONVERSION-DAEMON.lmco.com by lmco.com (PMDF V6.1-1 #40643) id <0H3M00601NYJNF@lmco.com> for freebsd-hackers@freebsd.org; Mon, 07 Oct 2002 13:08:43 -0700 (PDT) Received: from lmco.com ([129.197.20.43]) by lmco.com (PMDF V6.1-1 #40643) with ESMTP id <0H3M00073NYIPX@lmco.com> for freebsd-hackers@freebsd.org; Mon, 07 Oct 2002 13:08:42 -0700 (PDT) Date: Mon, 07 Oct 2002 13:02:43 -0700 From: rick norman Subject: route caching problems To: freebsd-hackers@freebsd.org Message-id: <3DA1E862.954BFE00@lmco.com> MIME-version: 1.0 X-Mailer: Mozilla 4.79 [en] (WinNT; U) Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 7BIT X-Accept-Language: en Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, I'm running 4.6 release on a pc that I have configured as a router. The problem occurs when an app on this router establishes a tcp connection to some other app several hops away. The route caching code adds a static host route to the forwarding table. This is fine as long as nothing changes, but as soon as a downstream router has an interface change or a route change, this static host route is no longer valid. The routing demons, in this case gated running ospf , update the routes, but the static route is still there causing the tcp stream to fail. What I think I need is some way to disable the caching 'optimizations' for locally terminated connections. Can someone suggest some options ? Thanks, Rick Norman To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 15:16:56 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C9D0337B406 for ; Mon, 7 Oct 2002 15:16:55 -0700 (PDT) Received: from hotmail.com (ool-4354b49d.dyn.optonline.net [67.84.180.157]) by mx1.FreeBSD.org (Postfix) with SMTP id B92CF43E6A; Mon, 7 Oct 2002 15:16:53 -0700 (PDT) (envelope-from jim223221a@hotmail.com) Reply-To: "Jim Davison" Message-ID: <000a58b26b3c$8477e6c4$4ce83ac6@xufvsb> From: "Jim Davison" To: users@FreeBSD.ORG Subject: Cheap Cigarettes Date: Mon, 07 Oct 2002 14:57:52 +0700 MiME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_NextPart_000_00E6_15B56D0E.A1351C20" X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: The Bat! (v1.52f) Business Importance: Normal Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG ------=_NextPart_000_00E6_15B56D0E.A1351C20 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: base64 Q2lnYXJldHRlcyBmcm9tICQxOS45OSBwZXIgY2FydG9uISENCg0KaHR0cDov L3d3dy5saWZlbGluZWRlYWxzLmNvbS9jaWdzL2luZGV4LnBocD8xNjINCjU5 OTJzSGhJMy0wMjhWSUd4bDE2 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 16:43:48 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 624F437B401 for ; Mon, 7 Oct 2002 16:43:47 -0700 (PDT) Received: from nic.upatras.gr (nic.upatras.gr [150.140.129.30]) by mx1.FreeBSD.org (Postfix) with SMTP id EB1E443E77 for ; Mon, 7 Oct 2002 16:43:45 -0700 (PDT) (envelope-from keramida@freebsd.org) Received: (qmail 16486 invoked from network); 7 Oct 2002 23:36:28 -0000 Received: from upnet-dialinpool-10.upatras.gr (HELO hades.hell.gr) (@150.140.128.244) by nic.upatras.gr with SMTP; 7 Oct 2002 23:36:28 -0000 Received: from hades.hell.gr (hades [127.0.0.1]) by hades.hell.gr (8.12.6/8.12.6) with ESMTP id g97Nga2I001591; Tue, 8 Oct 2002 02:42:37 +0300 (EEST) (envelope-from keramida@freebsd.org) Received: (from keramida@localhost) by hades.hell.gr (8.12.6/8.12.6/Submit) id g97NfkZY001581; Tue, 8 Oct 2002 02:41:46 +0300 (EEST) (envelope-from keramida@freebsd.org) Date: Tue, 8 Oct 2002 02:41:45 +0300 From: Giorgos Keramidas To: Ian Dowse Cc: hackers@freebsd.org Subject: Re: gdb support for kernel modules Message-ID: <20021007234145.GC1408@hades.hell.gr> References: <200210071709.aa25499@salmon.maths.tcd.ie> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200210071709.aa25499@salmon.maths.tcd.ie> X-PGP-Fingerprint: C1EB 0653 DB8B A557 3829 00F9 D60F 941A 3186 03B6 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 2002-10-07 17:09, Ian Dowse wrote: > > This is something I have been meaning to investigate for a while: [...] > Anyway, below is a proof-of-concept patch that does the basics, but > among other things, its logic for locating the kernel module files > needs a lot of work - currently it just assumes /boot/kernel/, > diff -N solib-fbsd-kld.c > --- /dev/null 1 Jan 1970 00:00:00 -0000 > +++ solib-fbsd-kld.c 7 Oct 2002 10:39:48 -0000 > + snprintf (new->so_name, SO_NAME_MAX_PATH_SIZE, "/boot/kernel/%s", > + new->so_original_name); I'm not really sure this would work for remote gdb sessions, but locally it's probably more correct to use sysctl and grab the value of kern.module_path or kern.bootfile instead of hardwiring `/boot/kernel/%s'. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 16:54:15 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2B95037B401 for ; Mon, 7 Oct 2002 16:54:13 -0700 (PDT) Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id A7A3A43E3B for ; Mon, 7 Oct 2002 16:54:11 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (localhost [127.0.0.1]) by apollo.backplane.com (8.12.5/8.12.4) with ESMTP id g97Nl4PQ049416; Mon, 7 Oct 2002 16:47:04 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.12.5/8.12.4/Submit) id g97Nl3Zo049415; Mon, 7 Oct 2002 16:47:03 -0700 (PDT) (envelope-from dillon) Date: Mon, 7 Oct 2002 16:47:03 -0700 (PDT) From: Matthew Dillon Message-Id: <200210072347.g97Nl3Zo049415@apollo.backplane.com> To: David Schultz Cc: Peter Wemm , Sean Kelly , hackers@FreeBSD.ORG Subject: Re: swapoff? References: <20020713071911.GA1558@HAL9000.wox.org> <20020713073404.9869A3811@overcee.wemm.org> <20020713115746.GA2162@HAL9000.wox.org> <200207131636.g6DGaoqh081285@apollo.backplane.com> <20021007153845.GA371@HAL9000.homeunix.com> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG :I'm resurrecting this thread because I finally got around to :finishing up the patches to implement swapoff. I would appreciate :some review of them, particularly to verify that I have done the :right thing WRT synchronization. I have not optimized it to do :read clustering, but I have ensured that such an optimization :could be made. Other than that, I don't know of any deficiencies. This is great, David. The code is about as clean as it's possible to make in a swapoff implementation. There are some minor inefficiencies.. some shortcuts that can be taken in the blist code for example, but I don't think we have to worry about them for this initial implementation. The SW_CLOSING test is an excellent solution to dealing with the swap bitmap when paging in from the dying swap area. The swap_pager_isswapped() function may not be doing a sufficient test: :+ pswap = swp_pager_hash(object, index); :+ :+ if ((swap = *pswap) != NULL) { :+ for (i = 0; i < SWAP_META_PAGES; ++i) { :+ daddr_t v = swap->swb_pages[i]; :+ if (v != SWAPBLK_NONE && :+ BLK2DEVIDX(v) == devidx && :+ !vm_page_lookup(object, swap->swb_index+i)) :+ return 1; :+ } :+ } It is quite possible for a VM page to be present but invalid, meaning that the swap is still valid. You could incorrectly return that the object is not swapped when in fact it is. BUT, since you only appear to be making this call on the process's UPAGES object, there may not be a problem. Perhapss the best thing to do is to not do the vm_page_lookup() call and instead just unconditionally faultin() the uarea if it looks like there might be a problem. You may need a master lock to ensure that only swapon() or swapoff() is 'in progress' at any given moment. The vm_page_grab() call below may block, I think: :+ :+ if (object->type != OBJT_SWAP) :+ panic("swp_pager_force_pagein: object not backed by swap"); :+ :+ m = vm_page_grab(object, pindex, VM_ALLOC_NORMAL | VM_ALLOC_RETRY); :+ if (m->valid == VM_PAGE_BITS_ALL) { :+ /* :+ * The page is already in memory, but must be :+ * dirtied, since we're taking away its backing store. :+ */ :+ vm_page_lock_queues(); :+ vm_page_activate(m); :+ vm_page_dirty(m); :+ vm_page_wakeup(m); :+ vm_page_unlock_queues(); :+ return 1; :+ } :+ :+ vm_object_pip_add(object, 1); I think you may want to do the pip_add before calling vm_page_grab(). -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 20:37:56 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 027CC37B401 for ; Mon, 7 Oct 2002 20:37:56 -0700 (PDT) Received: from yahoo.com (ool-435487f7.dyn.optonline.net [67.84.135.247]) by mx1.FreeBSD.org (Postfix) with SMTP id CD53243E8A; Mon, 7 Oct 2002 20:37:53 -0700 (PDT) (envelope-from mark3212asd22@yahoo.com) Reply-To: "Mark Lawson" Message-ID: <016c86e11e1c$3554c2a2$5bd37de1@ivpyxb> From: "Mark Lawson" To: users@FreeBSD.ORG Subject: Discount Cigarettes Date: Mon, 07 Oct 2002 16:07:33 +1100 MiME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_NextPart_000_00E2_01B87B1E.A2486D16" X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: eGroups Message Poster Importance: Normal Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG ------=_NextPart_000_00E2_01B87B1E.A2486D16 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: base64 Q2lnYXJldHRlcyBmcm9tICQxOS45OSBwZXIgY2FydG9uISENCg0KaHR0cDov L3d3dy5saWZlbGluZWRlYWxzLmNvbS9jaWdzL2luZGV4LnBocD8xNjINCjA2 NTh6TnphNi01MTJtZEtMODkxNGp0aW81LTI4N0xvc3E3NDY3WHhTSTktNjUz cG9jWTE3NzNMV0NxMi0xNzBzSWNjNGw2NQ== To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Mon Oct 7 21:47:27 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6439C37B401 for ; Mon, 7 Oct 2002 21:47:26 -0700 (PDT) Received: from rootlabs.com (root.org [67.118.192.226]) by mx1.FreeBSD.org (Postfix) with SMTP id 16E0943E88 for ; Mon, 7 Oct 2002 21:47:26 -0700 (PDT) (envelope-from nate@rootlabs.com) Received: (qmail 9301 invoked by uid 1000); 8 Oct 2002 04:47:28 -0000 Date: Mon, 7 Oct 2002 21:47:28 -0700 (PDT) From: Nate Lawson To: David Schultz Cc: hackers@FreeBSD.ORG Subject: Re: swapoff? In-Reply-To: <20021007153845.GA371@HAL9000.homeunix.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Nice, thanks for doing this. How about some more accurate names for the userland routines instead of "this_is_swapoff" and "twiddle"? -Nate To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 2:18:24 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8F87137B401 for ; Tue, 8 Oct 2002 02:18:22 -0700 (PDT) Received: from hotmail.com (f120.law3.hotmail.com [209.185.241.120]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4AD3B43E8A for ; Tue, 8 Oct 2002 02:18:22 -0700 (PDT) (envelope-from riaal@hotmail.com) Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC; Tue, 8 Oct 2002 02:18:22 -0700 Received: from 196.30.152.3 by lw3fd.law3.hotmail.msn.com with HTTP; Tue, 08 Oct 2002 09:18:21 GMT X-Originating-IP: [196.30.152.3] From: "Riaal Domingues" To: freebsd-hackers@freebsd.org Cc: pk@nanoteq.com Subject: Network connections keep dropping Date: Tue, 08 Oct 2002 09:18:21 +0000 Mime-Version: 1.0 Content-Type: text/plain; format=flowed Message-ID: X-OriginalArrivalTime: 08 Oct 2002 09:18:22.0215 (UTC) FILETIME=[A5EED170:01C26EAB] Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi there! I have a strange problem and I hope you guys can help me. We have several 4.6-RELEASE boxes running SSH, after connected for a while (varies between 5 min. and an +-40) the connection dies. The SSH on the server only writes out the following message: "fatal: Write failed : permission denied". I looked in the SSH source code, and the only file that generates an error like that is /usr/src/crypto/openssh/packet.c. The permissions denied (errno set by system) error is generated in an attempt to write to the "connection_out" socket. I then tried a connection to the servers using telnet, and exactly the same behaviour as with SSH !! So, it is not SSH related, we upgrade the server to 4.6.2-RELEASE but still the same thing, it looks like it may have something to do with the kernel or network sockets or something. I tried it on different hardware combinations as well with the same results. We use a plain installation with a vanilla SSH config, nothing unusual, the kernel is configured to use ipfirewall, striped from some SCSI devices, I386 I486 and that's it. A quick way to generate the error is to log on to the server, leave it for a while then add a firewall rule and delete it again, on deletion the connection to that server (using ssh) is immediately disconnected with the same error message from sshd as described above. This trick generates the problem about 99% of the time. I can't find anything in the mailing list of similar problems. Has anyone else experienced something like this? or can anybody please give me a hint what else I can do to try and find the problem. Cheers Peut Kotze ------------------------------------------------------- _________________________________________________________________ Chat with friends online, try MSN Messenger: http://messenger.msn.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 4:36:23 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3C8A337B401 for ; Tue, 8 Oct 2002 04:36:21 -0700 (PDT) Received: from HAL9000.homeunix.com (12-232-220-15.client.attbi.com [12.232.220.15]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7182843E65 for ; Tue, 8 Oct 2002 04:36:20 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Received: from HAL9000.homeunix.com (localhost [127.0.0.1]) by HAL9000.homeunix.com (8.12.6/8.12.5) with ESMTP id g98BaJBY000434; Tue, 8 Oct 2002 04:36:19 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Received: (from das@localhost) by HAL9000.homeunix.com (8.12.6/8.12.5/Submit) id g98BaE4n000433; Tue, 8 Oct 2002 04:36:14 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Date: Tue, 8 Oct 2002 04:36:14 -0700 From: David Schultz To: Matthew Dillon Cc: Peter Wemm , Sean Kelly , hackers@FreeBSD.ORG Subject: Re: swapoff? Message-ID: <20021008113614.GA319@HAL9000.homeunix.com> Mail-Followup-To: Matthew Dillon , Peter Wemm , Sean Kelly , hackers@FreeBSD.ORG References: <20020713071911.GA1558@HAL9000.wox.org> <20020713073404.9869A3811@overcee.wemm.org> <20020713115746.GA2162@HAL9000.wox.org> <200207131636.g6DGaoqh081285@apollo.backplane.com> <20021007153845.GA371@HAL9000.homeunix.com> <200210072347.g97Nl3Zo049415@apollo.backplane.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200210072347.g97Nl3Zo049415@apollo.backplane.com> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Rather than spamming the list with another 37K patch, I posted a revised version at http://csua.berkeley.edu/~das/swapoff.patch2 Thus spake Matthew Dillon : > The swap_pager_isswapped() function may not be doing > a sufficient test: [...] > It is quite possible for a VM page to be present but invalid, > meaning that the swap is still valid. You could incorrectly > return that the object is not swapped when in fact it is. > > BUT, since you only appear to be making this call on > the process's UPAGES object, there may not be a problem. > Perhapss the best thing to do is to not do the vm_page_lookup() > call and instead just unconditionally faultin() the uarea > if it looks like there might be a problem. I revised the patches to do as you suggested. It turns out that a couple of extra lines are needed, because when the scan over all processes restarts, pagein_all() will no longer automagically skip over processes it has already swapped in. It has to immediately free the swap metadata for the UPAGES object and dirty the associated pages (as opposed to letting swap_pager_swapoff do it); otherwise it will loop forever trying to swap in the same process. > You may need a master lock to ensure that only swapon() or > swapoff() is 'in progress' at any given moment. Added. (This was a deficiency in the original swapon() as well.) > The vm_page_grab() call below may block, I think: [...] > I think you may want to do the pip_add before calling vm_page_grab(). Yep, fixed. I also tweaked the calculation that determines whether there is enough virtual memory to remove the device, but it doesn't seem to detect when there is insufficient space. (I actually thought it was right the first time.) Can you see anything obviously wrong with my math? The code works fine in all of my tests, except that calling swapoff() when the system is under heavy paging load and has multiple swap devices sometimes leads to a few pages being missed by the scan. I think the problem is that some process allocates some swap and starts paging out just before the device is marked as off-limits. Am I missing a simple solution to this problem? (For now, I kludge around the issue by rescanning if there are still blocks remaining.) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 4:39:53 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6F78837B401 for ; Tue, 8 Oct 2002 04:39:52 -0700 (PDT) Received: from HAL9000.homeunix.com (12-232-220-15.client.attbi.com [12.232.220.15]) by mx1.FreeBSD.org (Postfix) with ESMTP id DEA2043E75 for ; Tue, 8 Oct 2002 04:39:51 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Received: from HAL9000.homeunix.com (localhost [127.0.0.1]) by HAL9000.homeunix.com (8.12.6/8.12.5) with ESMTP id g98BdlBY000445; Tue, 8 Oct 2002 04:39:47 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Received: (from das@localhost) by HAL9000.homeunix.com (8.12.6/8.12.5/Submit) id g98BdgfD000444; Tue, 8 Oct 2002 04:39:42 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Date: Tue, 8 Oct 2002 04:39:42 -0700 From: David Schultz To: Nate Lawson Cc: hackers@FreeBSD.ORG Subject: Re: swapoff? Message-ID: <20021008113942.GB319@HAL9000.homeunix.com> Mail-Followup-To: Nate Lawson , hackers@FreeBSD.ORG References: <20021007153845.GA371@HAL9000.homeunix.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Thus spake Nate Lawson : > Nice, thanks for doing this. How about some more accurate names for the > userland routines instead of "this_is_swapoff" and "twiddle"? Sure, suggest something and I'll change it. I shamelessly stole 'this_is_swapoff' from w / uptime, but you can blame me for 'twiddle'. The function was originally called 'add', I think, but now it adds or removes depending on whether it's being called as swapon or swapoff... To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 5:33:28 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8D77537B401 for ; Tue, 8 Oct 2002 05:33:27 -0700 (PDT) Received: from srv1.cosmo-project.de (srv1.cosmo-project.de [213.83.6.106]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5AF5E43E86 for ; Tue, 8 Oct 2002 05:33:26 -0700 (PDT) (envelope-from ticso@cicely8.cicely.de) Received: from cicely5.cicely.de (cicely5.cicely.de [IPv6:3ffe:400:8d0:301:200:92ff:fe9b:20e7]) by srv1.cosmo-project.de (8.12.5/8.12.5) with ESMTP id g98CXE6K000596 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=OK); Tue, 8 Oct 2002 14:33:22 +0200 (CEST) (envelope-from ticso@cicely8.cicely.de) Received: from cicely8.cicely.de (cicely8.cicely.de [10.1.1.10]) by cicely5.cicely.de (8.12.6/8.12.6) with ESMTP id g98CXDgK051381 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO); Tue, 8 Oct 2002 14:33:14 +0200 (CEST) (envelope-from ticso@cicely8.cicely.de) Received: from cicely8.cicely.de (localhost [127.0.0.1]) by cicely8.cicely.de (8.12.6/8.12.6) with ESMTP id g98CXClv016802; Tue, 8 Oct 2002 14:33:12 +0200 (CEST) (envelope-from ticso@cicely8.cicely.de) Received: (from ticso@localhost) by cicely8.cicely.de (8.12.6/8.12.6/Submit) id g98CXAxc016801; Tue, 8 Oct 2002 14:33:11 +0200 (CEST) Date: Tue, 8 Oct 2002 14:33:09 +0200 From: Bernd Walter To: Riaal Domingues Cc: freebsd-hackers@FreeBSD.ORG, pk@nanoteq.com Subject: Re: Network connections keep dropping Message-ID: <20021008123309.GC1837@cicely8.cicely.de> Reply-To: ticso@cicely.de References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Operating-System: FreeBSD cicely8.cicely.de 5.0-CURRENT i386 User-Agent: Mutt/1.5.1i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, Oct 08, 2002 at 09:18:21AM +0000, Riaal Domingues wrote: > I have a strange problem and I hope you guys can help me. > > We have several 4.6-RELEASE boxes running SSH, after connected for a > while (varies between 5 min. and an +-40) the connection dies. The SSH > on the server only writes out the following message: "fatal: Write > failed : permission denied". I looked in the SSH source code, and the > only file that generates an error like that is > /usr/src/crypto/openssh/packet.c. The permissions denied (errno set by > system) error is generated in an attempt to write to the > "connection_out" socket. The typical reason for directly seeing denies when accessing sockets is a deny by an ipfw rule. Check your ipfw dynamic rules carefully - they might timeout because of a configuration error. It's also possible, but I'm not shure, that an mbuf/mbufcluster shortage can produces such errors. Well there are some other reasons too, but most of them don't apply to your scenario or are unlikely. -- B.Walter COSMO-Project http://www.cosmo-project.de ticso@cicely.de Usergroup info@cosmo-project.de To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 6:37:54 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 798E137B401 for ; Tue, 8 Oct 2002 06:37:53 -0700 (PDT) Received: from duke.cs.duke.edu (duke.cs.duke.edu [152.3.140.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id CFF5843E4A for ; Tue, 8 Oct 2002 06:37:52 -0700 (PDT) (envelope-from gallatin@cs.duke.edu) Received: from grasshopper.cs.duke.edu (grasshopper.cs.duke.edu [152.3.145.30]) by duke.cs.duke.edu (8.9.3/8.9.3) with ESMTP id JAA29916; Tue, 8 Oct 2002 09:37:52 -0400 (EDT) Received: (from gallatin@localhost) by grasshopper.cs.duke.edu (8.11.6/8.9.1) id g98DbMK52337; Tue, 8 Oct 2002 09:37:22 -0400 (EDT) (envelope-from gallatin@cs.duke.edu) From: Andrew Gallatin MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15778.57234.386016.42431@grasshopper.cs.duke.edu> Date: Tue, 8 Oct 2002 09:37:22 -0400 (EDT) To: Ian Dowse Cc: hackers@freebsd.org Subject: Re: gdb support for kernel modules In-Reply-To: <20021007234145.GC1408@hades.hell.gr> References: <200210071709.aa25499@salmon.maths.tcd.ie> <20021007234145.GC1408@hades.hell.gr> X-Mailer: VM 6.75 under 21.1 (patch 12) "Channel Islands" XEmacs Lucid Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Giorgos Keramidas writes: > On 2002-10-07 17:09, Ian Dowse wrote: > > > > This is something I have been meaning to investigate for a while: [...] > > Anyway, below is a proof-of-concept patch that does the basics, but > > among other things, its logic for locating the kernel module files > > needs a lot of work - currently it just assumes /boot/kernel/, > > > diff -N solib-fbsd-kld.c > > --- /dev/null 1 Jan 1970 00:00:00 -0000 > > +++ solib-fbsd-kld.c 7 Oct 2002 10:39:48 -0000 > > > + snprintf (new->so_name, SO_NAME_MAX_PATH_SIZE, "/boot/kernel/%s", > > + new->so_original_name); > > I'm not really sure this would work for remote gdb sessions, but locally > it's probably more correct to use sysctl and grab the value of > kern.module_path or kern.bootfile instead of hardwiring `/boot/kernel/%s'. gdbmods does an ugly thing which is incredibly useful. It assumes that the modules you want to debug are sitting in your kernel build pool. So what it does is extract the build directory from the kernel (using strings), and runs a find rooted there for the module in question. But its a shell script, so it can get away with stuff like that ;) Perhaps we could embed the build directory somewhere the elf headers of each kernel module (including the kernel) so that kgdb could find the corresponding build file with symbols. Then your (very cool) solib-fbsd-kld.c could easily find the kernel and modules which match the kernel you're debugging.. Drew To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 8:58:17 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EA27637B401 for ; Tue, 8 Oct 2002 08:58:15 -0700 (PDT) Received: from salmon.maths.tcd.ie (salmon.maths.tcd.ie [134.226.81.11]) by mx1.FreeBSD.org (Postfix) with SMTP id 57E7E43E6A for ; Tue, 8 Oct 2002 08:58:14 -0700 (PDT) (envelope-from iedowse@maths.tcd.ie) Received: from walton.maths.tcd.ie by salmon.maths.tcd.ie with SMTP id ; 8 Oct 2002 16:58:12 +0100 (BST) To: Andrew Gallatin Cc: hackers@freebsd.org Subject: Re: gdb support for kernel modules In-Reply-To: Your message of "Tue, 08 Oct 2002 09:37:22 EDT." <15778.57234.386016.42431@grasshopper.cs.duke.edu> Date: Tue, 08 Oct 2002 16:58:12 +0100 From: Ian Dowse Message-ID: <200210081658.aa35776@salmon.maths.tcd.ie> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <15778.57234.386016.42431@grasshopper.cs.duke.edu>, Andrew Gallatin writes: >gdbmods does an ugly thing which is incredibly useful. It assumes >that the modules you want to debug are sitting in your kernel build >pool. So what it does is extract the build directory from the kernel >(using strings), and runs a find rooted there for the module in >question. But its a shell script, so it can get away with stuff like >that ;) Yes, I intend to attempt the same thing by extracting the path from version[] and using similar logic. It can probably use a list of likely locations and pick the first one where the module actually exists. GDB already has the `solib-absolute-prefix' and `solib-search-path' variables, but they are of limited use for kernel modules as the paths and module names you want for debugging are usually different to those that were actually loaded. >Perhaps we could embed the build directory somewhere the elf headers >of each kernel module (including the kernel) so that kgdb could find >the corresponding build file with symbols. Then your (very cool) >solib-fbsd-kld.c could easily find the kernel and modules which match >the kernel you're debugging.. True, even having the path as a variable inside the module should be sufficient I think. The other clever suggestion that was made to me was to maintain the standard r_debug* symbols in the kernel so that a virtually unmodified gdb could extract information about the loaded modules. Ian To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 10: 5:27 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D13DA37B401 for ; Tue, 8 Oct 2002 10:05:26 -0700 (PDT) Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7811F43E4A for ; Tue, 8 Oct 2002 10:05:26 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (localhost [127.0.0.1]) by apollo.backplane.com (8.12.5/8.12.4) with ESMTP id g98H5OPQ078651; Tue, 8 Oct 2002 10:05:24 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.12.5/8.12.4/Submit) id g98H5JWk078650; Tue, 8 Oct 2002 10:05:19 -0700 (PDT) (envelope-from dillon) Date: Tue, 8 Oct 2002 10:05:19 -0700 (PDT) From: Matthew Dillon Message-Id: <200210081705.g98H5JWk078650@apollo.backplane.com> To: David Schultz Cc: Peter Wemm , Sean Kelly , hackers@FreeBSD.ORG Subject: Re: swapoff? References: <20020713071911.GA1558@HAL9000.wox.org> <20020713073404.9869A3811@overcee.wemm.org> <20020713115746.GA2162@HAL9000.wox.org> <200207131636.g6DGaoqh081285@apollo.backplane.com> <20021007153845.GA371@HAL9000.homeunix.com> <200210072347.g97Nl3Zo049415@apollo.backplane.com> <20021008113614.GA319@HAL9000.homeunix.com> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG :The code works fine in all of my tests, except that calling :swapoff() when the system is under heavy paging load and has :multiple swap devices sometimes leads to a few pages being missed :by the scan. I think the problem is that some process allocates :some swap and starts paging out just before the device is marked :as off-limits. Am I missing a simple solution to this problem? :(For now, I kludge around the issue by rescanning if there are :still blocks remaining.) Hmm. Yes, I think the issue here is that you may be missing pages in objects which are undergoing I/O. You may need to wait for other paging on the object (the pip count) to go to zero. I will review that code more carefully in a little bit and give you a definitive answer. -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 10:18: 4 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5E21E37B404 for ; Tue, 8 Oct 2002 10:18:03 -0700 (PDT) Received: from lurza.secnetix.de (lurza.secnetix.de [212.66.1.130]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8762E43E42 for ; Tue, 8 Oct 2002 10:18:02 -0700 (PDT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (localhost [IPv6:::1]) by lurza.secnetix.de (8.12.5/8.12.5) with ESMTP id g98HHxmC051030 for ; Tue, 8 Oct 2002 19:18:00 +0200 (CEST) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.12.5/8.12.5/Submit) id g98HHxjp051029; Tue, 8 Oct 2002 19:17:59 +0200 (CEST) Date: Tue, 8 Oct 2002 19:17:59 +0200 (CEST) Message-Id: <200210081717.g98HHxjp051029@lurza.secnetix.de> From: Oliver Fromme To: freebsd-hackers@FreeBSD.ORG Subject: Mount option "nomtime"? X-Newsgroups: list.freebsd-hackers User-Agent: tin/1.5.4-20000523 ("1959") (UNIX) (FreeBSD/4.6-STABLE (i386)) MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, The mount(8) manpage doesn't mention it, so I assume that there is no such thing as a "nomtime" option (analogous to the "noatime" option) to prevent the mtimes of inodes from being updated for each write access. But maybe is there some other way to achieve that? For example, updating of mtimes is not neccessary on a file system that contains a news spool, or the content of a web cache, or similar transient data. Disabling those updates might prevent quite some superfluous overhead. I'm tempted to try implementing "nomtime" myself, but I would prefer hearing some opinions first before wasting time on something completely stupid. :-) Regards Oliver -- Oliver Fromme, secnetix GmbH & Co KG, Oettingenstr. 2, 80538 München Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. "All that we see or seem is just a dream within a dream" (E. A. Poe) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 10:45:49 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5DC8C37B401 for ; Tue, 8 Oct 2002 10:45:47 -0700 (PDT) Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id DC11F43E65 for ; Tue, 8 Oct 2002 10:45:46 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (localhost [127.0.0.1]) by apollo.backplane.com (8.12.5/8.12.4) with ESMTP id g98HjkPQ078884; Tue, 8 Oct 2002 10:45:46 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.12.5/8.12.4/Submit) id g98Hjkam078883; Tue, 8 Oct 2002 10:45:46 -0700 (PDT) (envelope-from dillon) Date: Tue, 8 Oct 2002 10:45:46 -0700 (PDT) From: Matthew Dillon Message-Id: <200210081745.g98Hjkam078883@apollo.backplane.com> To: David Schultz Cc: Peter Wemm , Sean Kelly , hackers@FreeBSD.ORG Subject: Re: swapoff? References: <20020713071911.GA1558@HAL9000.wox.org> <20020713073404.9869A3811@overcee.wemm.org> <20020713115746.GA2162@HAL9000.wox.org> <200207131636.g6DGaoqh081285@apollo.backplane.com> <20021007153845.GA371@HAL9000.homeunix.com> <200210072347.g97Nl3Zo049415@apollo.backplane.com> <20021008113614.GA319@HAL9000.homeunix.com> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG :... :detect when there is insufficient space. (I actually thought it :was right the first time.) Can you see anything obviously wrong :with my math? : :The code works fine in all of my tests, except that calling :swapoff() when the system is under heavy paging load and has :multiple swap devices sometimes leads to a few pages being missed :by the scan. I think the problem is that some process allocates :some swap and starts paging out just before the device is marked :as off-limits. Am I missing a simple solution to this problem? :(For now, I kludge around the issue by rescanning if there are :still blocks remaining.) Ok, I think the problem is in swap_pager_swapoff() and swp_pager_force_pagein(). Another process may be manipulating the swblock (or a prior swblock) while swp_pager_force_pagein() is blocked. In fact, the swap block can be ripped out from under swap_pager_swapoff() if swp_pager_force_pagein() blocks. i.e. the 'swap' structure may be invalid after you call swp_pager_force_pagein(). This is a sticky situation because both the VM object and the swblocks may be manipulated by other processes when you block. I think what you need to try to do is this (it's a mess, if you can think of a better solution definitely go another route!) while ((swap = *pswap) != NULL) { if (anything_is_swapped_to_the_device) { try_to_page_it_all_in (note that the swblock structure is invalid the moment you block, so swp_pager_force_pagein() should be given the whole range). /* fall through to retry */ } else if (the_related_object_pip_count_is_not_zero) { vm_object_pip_sleep(...) /* fall through to retry */ } else if (swap->swb_count <= 0) { free the swap block *pswap = swap->swb_hnext; } } -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 11:38:45 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 83AE537B401 for ; Tue, 8 Oct 2002 11:38:43 -0700 (PDT) Received: from maile.telia.com (maile.telia.com [194.22.190.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id 52F1443E75 for ; Tue, 8 Oct 2002 11:38:42 -0700 (PDT) (envelope-from erikt@midgard.homeip.net) Received: from d1o913.telia.com (d1o913.telia.com [195.252.44.241]) by maile.telia.com (8.12.5/8.12.5) with ESMTP id g98IcdaF011533 for ; Tue, 8 Oct 2002 20:38:39 +0200 (CEST) X-Original-Recipient: Received: from falcon.midgard.homeip.net (h76n3fls20o913.telia.com [213.67.148.76]) by d1o913.telia.com (8.8.8/8.8.8) with SMTP id UAA28326 for ; Tue, 8 Oct 2002 20:38:38 +0200 (CEST) Received: (qmail 65752 invoked by uid 1001); 8 Oct 2002 18:38:36 -0000 Date: Tue, 8 Oct 2002 20:38:36 +0200 From: Erik Trulsson To: Oliver Fromme Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Mount option "nomtime"? Message-ID: <20021008183835.GA65525@falcon.midgard.homeip.net> Mail-Followup-To: Oliver Fromme , freebsd-hackers@FreeBSD.ORG References: <200210081717.g98HHxjp051029@lurza.secnetix.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200210081717.g98HHxjp051029@lurza.secnetix.de> User-Agent: Mutt/1.5.1i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, Oct 08, 2002 at 07:17:59PM +0200, Oliver Fromme wrote: > Hi, > > The mount(8) manpage doesn't mention it, so I assume that > there is no such thing as a "nomtime" option (analogous > to the "noatime" option) to prevent the mtimes of inodes > from being updated for each write access. > > But maybe is there some other way to achieve that? > > For example, updating of mtimes is not neccessary on a > file system that contains a news spool, or the content of > a web cache, or similar transient data. Disabling those > updates might prevent quite some superfluous overhead. > > I'm tempted to try implementing "nomtime" myself, but I > would prefer hearing some opinions first before wasting > time on something completely stupid. :-) Since I suspect that most writes occur when you are first creating the file and that modifications in existing files are fairly uncommon I think any performance gains would be quite minor. Also since the most common file modification operation is probably to append data at the end of the file, rather than modify data in the middle of the file, the inode would still have to be changed to reflect the changed size of the file, it can't be very expensive to update the mtime at the same time. Also various sorts of file caches (like news spools or web caches) probably uses the mtime (and sometimes atime) to determine which files are oldest and therefore should be deleted first when diskspace is running low. Not updating the mtime on such files could lead to "interesting" results as the wrong files are flushed. Considering the above I think that a "nomtime" option would be much more likely to create problems than to solve any problems. -- Erik Trulsson ertr1013@student.uu.se To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 12: 8: 9 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 59ADE37B401 for ; Tue, 8 Oct 2002 12:08:07 -0700 (PDT) Received: from lurza.secnetix.de (lurza.secnetix.de [212.66.1.130]) by mx1.FreeBSD.org (Postfix) with ESMTP id 36ADE43E6E for ; Tue, 8 Oct 2002 12:08:06 -0700 (PDT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (localhost [IPv6:::1]) by lurza.secnetix.de (8.12.5/8.12.5) with ESMTP id g98J80mC055939 for ; Tue, 8 Oct 2002 21:08:01 +0200 (CEST) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.12.5/8.12.5/Submit) id g98J809u055938; Tue, 8 Oct 2002 21:08:00 +0200 (CEST) Date: Tue, 8 Oct 2002 21:08:00 +0200 (CEST) Message-Id: <200210081908.g98J809u055938@lurza.secnetix.de> From: Oliver Fromme To: freebsd-hackers@FreeBSD.ORG Subject: Re: Mount option "nomtime"? In-Reply-To: <20021008183835.GA65525@falcon.midgard.homeip.net> X-Newsgroups: list.freebsd-hackers User-Agent: tin/1.5.4-20000523 ("1959") (UNIX) (FreeBSD/4.6-STABLE (i386)) MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Erik Trulsson wrote: > On Tue, Oct 08, 2002 at 07:17:59PM +0200, Oliver Fromme wrote: > > [...] > > For example, updating of mtimes is not neccessary on a > > file system that contains a news spool, or the content of > > a web cache, or similar transient data. Disabling those > > updates might prevent quite some superfluous overhead. > > Since I suspect that most writes occur when you are first creating the > file and that modifications in existing files are fairly uncommon I > think any performance gains would be quite minor. I should have been more specific in my examples. Sorry. Think about INN with using cycbuffers (CNFS) when storing news articles (which is pretty standard on fullfeed news servers). Those cycbuffers are a bunch of large files. Their size never changes, but a lot of data is written to them all the time. The same goes for the overview data when using the so-called buffindexed storage. INN itself does not need the mtime information of the buffer files. Another example would be "oops", which is a very fast, lightweight web proxy. It uses cyclic buffer files to store the cached data, similar to INN's CNFS. I think in the above cases, a "nomtime" option would indeed save some unnecessary overhead. Of course, I agree that it won't buy you much in the case of "normal" file creation or appending to existing files. But that's not the kind of scenario I have in mind. Regards Oliver -- Oliver Fromme, secnetix GmbH & Co KG, Oettingenstr. 2, 80538 München Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. "All that we see or seem is just a dream within a dream" (E. A. Poe) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 12:59:34 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0956437B401 for ; Tue, 8 Oct 2002 12:59:33 -0700 (PDT) Received: from gw.catspoiler.org (217-ip-163.nccn.net [209.79.217.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 897D343E65 for ; Tue, 8 Oct 2002 12:59:32 -0700 (PDT) (envelope-from dl-freebsd@catspoiler.org) Received: from mousie.catspoiler.org (mousie.catspoiler.org [192.168.101.2]) by gw.catspoiler.org (8.12.5/8.12.5) with ESMTP id g98JxOvU036374; Tue, 8 Oct 2002 12:59:28 -0700 (PDT) (envelope-from dl-freebsd@catspoiler.org) Message-Id: <200210081959.g98JxOvU036374@gw.catspoiler.org> Date: Tue, 8 Oct 2002 12:59:24 -0700 (PDT) From: Don Lewis Subject: Re: Mount option "nomtime"? To: olli@secnetix.de Cc: freebsd-hackers@FreeBSD.ORG In-Reply-To: <200210081908.g98J809u055938@lurza.secnetix.de> MIME-Version: 1.0 Content-Type: TEXT/plain; charset=ISO-8859-1 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 8 Oct, Oliver Fromme wrote: > I should have been more specific in my examples. Sorry. > > Think about INN with using cycbuffers (CNFS) when storing > news articles (which is pretty standard on fullfeed news > servers). Those cycbuffers are a bunch of large files. > Their size never changes, but a lot of data is written to > them all the time. The same goes for the overview data > when using the so-called buffindexed storage. INN itself > does not need the mtime information of the buffer files. > > Another example would be "oops", which is a very fast, > lightweight web proxy. It uses cyclic buffer files to > store the cached data, similar to INN's CNFS. > > I think in the above cases, a "nomtime" option would indeed > save some unnecessary overhead. Probably not much, especially if you are using soft updates. The in-kernel copy of the inode will get updated on every write, but the on-disk copy will only get written when the soft updates timer for it goes off, which I think would be once every 10 seconds and is tunable. I don't think you'll see much reduction in load compared to all the other I/O that's going on. Noatime won't help much in your examples either. It only buys you a lot if the data is spread over a large number of files. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 13: 3:34 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3CFB837B401 for ; Tue, 8 Oct 2002 13:03:33 -0700 (PDT) Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id E500D43E3B for ; Tue, 8 Oct 2002 13:03:32 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (localhost [127.0.0.1]) by apollo.backplane.com (8.12.5/8.12.4) with ESMTP id g98K3TPQ084533; Tue, 8 Oct 2002 13:03:30 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.12.5/8.12.4/Submit) id g98K3Thx084532; Tue, 8 Oct 2002 13:03:29 -0700 (PDT) (envelope-from dillon) Date: Tue, 8 Oct 2002 13:03:29 -0700 (PDT) From: Matthew Dillon Message-Id: <200210082003.g98K3Thx084532@apollo.backplane.com> To: Don Lewis Cc: olli@secnetix.de, freebsd-hackers@FreeBSD.ORG Subject: Re: Mount option "nomtime"? References: <200210081959.g98JxOvU036374@gw.catspoiler.org> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG :.. :> :> Another example would be "oops", which is a very fast, :> lightweight web proxy. It uses cyclic buffer files to :> store the cached data, similar to INN's CNFS. :> :> I think in the above cases, a "nomtime" option would indeed :> save some unnecessary overhead. : :Probably not much, especially if you are using soft updates. The :in-kernel copy of the inode will get updated on every write, but the :on-disk copy will only get written when the soft updates timer for it :goes off, which I think would be once every 10 seconds and is tunable. I :don't think you'll see much reduction in load compared to all the other :I/O that's going on. atime/mtime/ctime updates will collect in the in-memory inode and only be written to disk when the filesystem sync occurs once every 30-60 seconds or so. This is how it works with or without softupdates. :Noatime won't help much in your examples either. It only buys you a lot :if the data is spread over a large number of files. -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 14:48:36 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DEF9137B401 for ; Tue, 8 Oct 2002 14:48:35 -0700 (PDT) Received: from lurza.secnetix.de (lurza.secnetix.de [212.66.1.130]) by mx1.FreeBSD.org (Postfix) with ESMTP id F08D843E4A for ; Tue, 8 Oct 2002 14:48:34 -0700 (PDT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (localhost [IPv6:::1]) by lurza.secnetix.de (8.12.5/8.12.5) with ESMTP id g98LmWmC062891 for ; Tue, 8 Oct 2002 23:48:32 +0200 (CEST) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.12.5/8.12.5/Submit) id g98LmWnS062890; Tue, 8 Oct 2002 23:48:32 +0200 (CEST) Date: Tue, 8 Oct 2002 23:48:32 +0200 (CEST) Message-Id: <200210082148.g98LmWnS062890@lurza.secnetix.de> From: Oliver Fromme To: freebsd-hackers@FreeBSD.ORG Subject: Re: Mount option "nomtime"? In-Reply-To: <200210082003.g98K3Thx084532@apollo.backplane.com> X-Newsgroups: list.freebsd-hackers User-Agent: tin/1.5.4-20000523 ("1959") (UNIX) (FreeBSD/4.6-STABLE (i386)) MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Matthew Dillon wrote: > > atime/mtime/ctime updates will collect in the in-memory inode > and only be written to disk when the filesystem sync occurs once > every 30-60 seconds or so. This is how it works with or without > softupdates. Is that also true for NFS mounts? (The reason why I'm asking: I am going to set up a new newsserver (INN) on a FreeBSD machine, where all data including the newsspool is stored on a NetApp Filer.) Regards Oliver -- Oliver Fromme, secnetix GmbH & Co KG, Oettingenstr. 2, 80538 München Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. "All that we see or seem is just a dream within a dream" (E. A. Poe) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 15: 3:35 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4C54637B401 for ; Tue, 8 Oct 2002 15:03:34 -0700 (PDT) Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 01B6943E77 for ; Tue, 8 Oct 2002 15:03:34 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (localhost [127.0.0.1]) by apollo.backplane.com (8.12.5/8.12.4) with ESMTP id g98M3XPQ085136; Tue, 8 Oct 2002 15:03:33 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.12.5/8.12.4/Submit) id g98M3XO2085135; Tue, 8 Oct 2002 15:03:33 -0700 (PDT) (envelope-from dillon) Date: Tue, 8 Oct 2002 15:03:33 -0700 (PDT) From: Matthew Dillon Message-Id: <200210082203.g98M3XO2085135@apollo.backplane.com> To: Oliver Fromme Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Mount option "nomtime"? References: <200210082148.g98LmWnS062890@lurza.secnetix.de> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG :Matthew Dillon wrote: : > : > atime/mtime/ctime updates will collect in the in-memory inode : > and only be written to disk when the filesystem sync occurs once : > every 30-60 seconds or so. This is how it works with or without : > softupdates. : :Is that also true for NFS mounts? : :(The reason why I'm asking: I am going to set up a new :newsserver (INN) on a FreeBSD machine, where all data :including the newsspool is stored on a NetApp Filer.) : :Regards : Oliver : :-- :Oliver Fromme, secnetix GmbH & Co KG, Oettingenstr. 2, 80538 München It is a function of the NFS server, not the NFS client. I would presume that a NetApp does the right thing. -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 15: 3:36 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E539137B404 for ; Tue, 8 Oct 2002 15:03:34 -0700 (PDT) Received: from orthanc.ab.ca (orthanc.ab.ca [216.123.203.186]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0AC4843E88 for ; Tue, 8 Oct 2002 15:03:34 -0700 (PDT) (envelope-from lyndon@orthanc.ab.ca) Received: from orthanc.ab.ca (localhost.orthanc.ab.ca [127.0.0.1]) by orthanc.ab.ca (8.12.6/8.12.6) with ESMTP id g98M3OGI010628; Tue, 8 Oct 2002 16:03:24 -0600 (MDT) (envelope-from lyndon@orthanc.ab.ca) Message-Id: <200210082203.g98M3OGI010628@orthanc.ab.ca> From: Lyndon Nerenberg Organization: The Frobozz Magic Homing Pigeon Company To: Oliver Fromme Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Mount option "nomtime"? In-reply-to: Your message of "Tue, 08 Oct 2002 23:48:32 +0200." <200210082148.g98LmWnS062890@lurza.secnetix.de> X-Mailer: mh-e 6.1+cvs; MH 6.8.4; Emacs 21.2 Date: Tue, 08 Oct 2002 16:03:24 -0600 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Oliver> (The reason why I'm asking: I am going to set up a new Oliver> newsserver (INN) on a FreeBSD machine, where all data Oliver> including the newsspool is stored on a NetApp Filer.) For local INN storage you can avoid the mtime issue simply by using raw disk partitions. For cycbufs, you don't need the filesystem -- just treat the raw disk as the file. By bypassing the filesystem you eliminate all of its overhead. The INN documentation describes how to set this up. You might want to try this before committing $$$$$$$$$$ to a netapp filer. --lyndon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Tue Oct 8 15:30:23 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6EFEF37B401 for ; Tue, 8 Oct 2002 15:30:22 -0700 (PDT) Received: from lurza.secnetix.de (lurza.secnetix.de [212.66.1.130]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7D06743E6A for ; Tue, 8 Oct 2002 15:30:21 -0700 (PDT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (localhost [IPv6:::1]) by lurza.secnetix.de (8.12.5/8.12.5) with ESMTP id g98MUKmC064560 for ; Wed, 9 Oct 2002 00:30:20 +0200 (CEST) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.12.5/8.12.5/Submit) id g98MUJ7D064559; Wed, 9 Oct 2002 00:30:19 +0200 (CEST) Date: Wed, 9 Oct 2002 00:30:19 +0200 (CEST) Message-Id: <200210082230.g98MUJ7D064559@lurza.secnetix.de> From: Oliver Fromme To: freebsd-hackers@FreeBSD.ORG Subject: Re: Mount option "nomtime"? In-Reply-To: <200210082203.g98M3OGI010628@orthanc.ab.ca> X-Newsgroups: list.freebsd-hackers User-Agent: tin/1.5.4-20000523 ("1959") (UNIX) (FreeBSD/4.6-STABLE (i386)) MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Lyndon Nerenberg wrote: > > Oliver> (The reason why I'm asking: I am going to set up a new > Oliver> newsserver (INN) on a FreeBSD machine, where all data > Oliver> including the newsspool is stored on a NetApp Filer.) > > For local INN storage you can avoid the mtime issue simply by using raw > disk partitions. For cycbufs, you don't need the filesystem -- just treat > the raw disk as the file. By bypassing the filesystem you eliminate all > of its overhead. The INN documentation describes how to set this up. You > might want to try this before committing $$$$$$$$$$ to a netapp filer. I know the INN documentation by heart. :-) Using local disks is not possible, because the machine does not have any local disks (except for a very small one for booting the OS). The NetApp Filer is already there and has a few hundreds of Gbytes of space free, so that it'll be. Both have gigabit ethernet, so that shouldn't be a problem. I'm very curious how it will perform. Regards Oliver -- Oliver Fromme, secnetix GmbH & Co KG, Oettingenstr. 2, 80538 München Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. "All that we see or seem is just a dream within a dream" (E. A. Poe) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 7:57: 2 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6044F37B61E for ; Wed, 9 Oct 2002 07:56:56 -0700 (PDT) Received: from qmail.anet.net.th (qmail.anet.net.th [203.148.255.86]) by mx1.FreeBSD.org (Postfix) with SMTP id 06BF243E7B for ; Wed, 9 Oct 2002 07:56:49 -0700 (PDT) (envelope-from MZ00080315@anet.net.th) Received: (qmail 57970 invoked by uid 0); 9 Oct 2002 14:56:38 -0000 Received: from unknown (HELO ME) (210.203.184.240) by qmail.anet.net.th with SMTP; 9 Oct 2002 14:56:38 -0000 From: MZ00080315@anet.net.th Subject:22:18:53 - ¢Íú¡Ç¹ mail ¢Í§¤Ø³ ªèÇ·ÓẺÊͺ¶ÒÁ ¢Íº¤Ø³ÁÒ¡¤èÐ - 22:18:53 X-Priority: 1 (Highest) Reply-To: MZ00080315@anet.net.th X-Mailer: Microsoft Outlook Express 5.00.2615.200 MIME-Version: 1.0 Content-type: multipart/mixed; boundary="#MYBOUNDARY#" Message-Id: <20021009145649.06BF243E7B@mx1.FreeBSD.org> Date: Wed, 9 Oct 2002 07:56:49 -0700 (PDT) To: undisclosed-recipients: ; Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --#MYBOUNDARY# Content-Type: text/plain; charset=ansi Content-Transfer-Encoding: 8bit ¨Ò¡ÃÒ¡ÒÃàÁ×ͧä·ÂÇѹ¹Õé ·ÓãË龺ÇèÒ ÁÕ¤¹·ÕèÁջѭËÒà¡ÕèÂǡѺ¡ÒÃÊØ¢ÀÒ¾à»ç¹¨Ó¹Ç¹ÁÒ¡ ẺÊͺ¶ÒÁ¹ÕéÍÒ¨ªèǤسä´é áµè¶éҤسà»ç¹¤¹·ÕèÁÕÊØ¢ÀÒ¾´ÕÍÂÙèáÅéÇ ¡çäÁè¨Óà»ç¹µéͧµÍºáººÊͺ¶ÒÁ¤èРẺÊͺ¶ÒÁ¡ÒôÙáÅÊØ¢ÀÒ¾ áÅÐäÅ¿ìÊäµÅì 1. »Ñ­ËÒÊØ¢ÀÒ¾¢Í§¤Ø³¤×Í /¹éÓ˹ѡÁÒ¡ µéͧ¡ÒÃÅ´ .......¡ÔâÅ/ ¤ÇÒÁ´Ñ¹ÊÙ§-µèÓ / àºÒËÇÒ¹ / ¤ÅÍàÃÊàµÍÃÍÅ - ä¤Ã¡ÃÕà«ÍÃìäŹì / Í×è¹ æ ............................................................................. 2. ã¹áµèÅÐÇѹ¤Ø³ÃѺ»Ãзҹ¤Ãº 3 Á×éÍËÃ×ÍäÁè / ãªè / äÁè ..................Á×éÍ / Çѹ 3. ¤èÒÍÒËÒÃáµèÅÐÁ×éÍ·Õè¤Ø³ÃѺ»Ãзҹ»ÃÐÁÒ³ÃÒ¤ÒÁ×éÍÅСÕèºÒ· / 20-25 ºÒ· / 30-40 / 50-60 / ÁÒ¡¡ÇèÒ 60 ............................................................................. 4. »Ñ¨¨ØºÑ¹¤Ø³´ÙáÅÊØ¢ÀÒ¾ÍÂèÒ§äà / ÍÍ¡¡ÓÅѧ¡ÒÂÊÁèÓàÊÁÍ / äÁèãÊèã¨ã¹¡ÒôÙáÅÊØ¢ÀÒ¾ / ·Ò¹ÍÒËÒÃàÊÃÔÁÂÕèËéÍ / Í×è¹ æ ............................................................................. 5. ¤Ø³à¤Â¤Çº¤ØÁ¹éÓ˹ѡÁÒ¡è͹ËÃ×ÍäÁè / à¤Â (ä´é¼Å-äÁèä´é¼Å) / äÁèà¤Â ............................................................................. 6. ¤Ø³¨ÃÔ§¨Ñ§¡Ñº¡Ò÷Õè¨ÐÁÕÃÙ»ÃèÒ§ áÅÐÊØ¢ÀÒ¾·Õè´ÕËÃ×ÍäÁè / ¨ÃÔ§¨Ñ§ / äÁè¨ÃÔ§¨Ñ§ ÊÓËÃѺ¼Ùé·Õè¨ÃÔ§¨Ñ§·Õè¨ÐÁÕÃÙ»ÃèÒ§ áÅÐÊØ¢ÀÒ¾·Õè´Õ àÃÒ¢Íá¹Ð¹Ó ¼ÅÔµÀѳ±ìâ»Ãá¡ÃÁÍÒËÒÃÊÙµÃÊÁ´ØÅÂì¨Ò¡ÊÁعä¾Ã¸ÃÃÁªÒµÔ ªèÇÂá¡é»Ñ­ËÒ¹éÓ˹ѡ ÊÑ´Êèǹ áÅÐÊØ¢ÀÒ¾ ·Õèµé¹à赯 ÍØ´Á´éÇÂÊÒÃÍÒËÒúÃÔÊØ·¸Ôì¤Ãº 5 ËÁÙè ·Ò¹á·¹Á×éÍÍÒËÒû¡µÔ 1 - 2 Á×é͵èÍÇѹ ä´éÃѺ¡ÒÃÃѺÃͧ¨Ò¡ ÍÂ. 54 »ÃÐà·È äÁèãªèÂÒÅ´¹éÓ˹ѡ äÁèµéͧʹÍÒËÒà äÁèÁռŢéÒ§à¤Õ§ ÃѺ»ÃСѹ¤ÇÒÁ¾Íã¨ÀÒÂã¹ 1 à´×͹ ´éÇÂÃкº¤×¹à§Ô¹ 100% ¤Ø³Ê¹ã¨·Õè¨Ð·ÃÒº¢éÍÁÙÅà¡ÕèÂǡѺâ»Ãá¡ÃÁâÀª¹Ò¡ÒôÙáÅÃÙ»ÃèÒ§ áÅÐÊØ¢ÀÒ¾ËÃ×ÍäÁè / ʹ㨠/ äÁèʹ㨠............................................................................. ¡Ã³Õ·Õèʹ㨠àÃÒ¨ÐÁÕà¨éÒ˹éÒ·ÕèµÔ´µèÍ¡ÅѺä»ËҤسÀÒÂã¹ 48 ªÁ. à¾×èÍãËéÃÒÂÅÐàÍÕ´áÅШѴÊè§àÍ¡ÊÒÿÃÕ ª×èÍ-¹ÒÁÊ¡ØÅ ...........................................ÍÒªÕ¾ ........................... ÍÒÂØ .......................... ÊèǹÊÙ§ ...........................¹éÓ˹ѡ ............... â·ÃÈѾ·ì ......................... àÇÅÒ·ÕèÊдǡ㹡ÒõԴµèÍ ..................... ·ÕèÍÂÙè ·Õè¨ÐãËé¨Ñ´Êè§àÍ¡ÊÒÃãËé¿ÃÕ .................... Please unsubscribe sent mail to MZ00080315@anet.net.th --#MYBOUNDARY#-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 9:17:49 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1D45337B401; Wed, 9 Oct 2002 09:17:48 -0700 (PDT) Received: from bulwark.switch.com (bulwark.switch.com [206.181.77.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8A27143E3B; Wed, 9 Oct 2002 09:17:46 -0700 (PDT) (envelope-from tnelson@switch.com) Received: from bulwark.switch.com (root@localhost) by bulwark.switch.com with ESMTP id g99FomDS016535; Wed, 9 Oct 2002 11:50:48 -0400 (EDT) Received: from isunix2.switch.com (isunix2.switch.com [199.234.168.6]) by bulwark.switch.com with ESMTP id g99Folkt016526; Wed, 9 Oct 2002 11:50:47 -0400 (EDT) Received: from exchptc1.switch.com ([199.234.168.10]) by isunix2.switch.com (PMDF V5.2-32 #37720) with ESMTP id <0H3Q0097P1CMPO@isunix2.switch.com>; Wed, 9 Oct 2002 11:50:46 -0400 (EDT) Received: by exchptc1.switch.com with Internet Mail Service (5.5.2653.19) id <4LCC1HLM>; Wed, 09 Oct 2002 11:50:46 -0400 Content-return: allowed Date: Wed, 09 Oct 2002 11:50:45 -0400 From: "Nelson, Trent ." Subject: FreeBSD usage in safety-critical environments To: "'hackers@freebsd.org'" Cc: "'questions@freebsd.org'" Message-id: <8F329FEDF58BD411BE5200508B10DA7607D71A10@exchptc1.switch.com> MIME-version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-type: text/plain; charset="iso-8859-1" Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG [Please include me directly as I'm not on the list] Hi, Has anyone had any experience with deploying FreeBSD in safety-critical environments? Has any work been done attempting to certify FreeBSD to any particular SIL? Is there any intention to do such a thing? If not FreeBSD, I'd be interested to hear if any has had exposure to other BSD flavors being used in safety-critical environments. I've just been shown a report at work that has been commissioned by the UK Health & Safety Executives and sponsored by the UK Ministry of Defense and Safety Regulation Group of the UK Civil Aviation Authority undertaking a preliminary assessment of Linux for safety-related systems. The report 'identifies' that it would be possible to certify Linux to SIL 1 and SIL 2 quite easily, and SIL 3 with a little work. I'd hate to think that this would be an arena where BSD couldn't compete. I'd also hate to think that the tendency for big players such as the MoD or DoD etc to lean towards Linux is based on the general Linux 'hype', rather than technical merit... Regards, Trent. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 10: 0: 2 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5CAF537B401; Wed, 9 Oct 2002 10:00:00 -0700 (PDT) Received: from ns1.ovis.net (ns1.ovis.net [207.0.147.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9EFDF43E77; Wed, 9 Oct 2002 09:59:58 -0700 (PDT) (envelope-from chromexa@ovis.net) Received: from ovis.net (s45.pm5.ovis.net [207.0.147.111]) by ns1.ovis.net (Postfix) with ESMTP id 3BADA3B43; Wed, 9 Oct 2002 12:59:19 -0400 (EDT) Message-ID: <3DA4625F.332C5D20@ovis.net> Date: Wed, 09 Oct 2002 13:07:43 -0400 From: Steve Kudlak Reply-To: chromexa@ovis.net X-Mailer: Mozilla 4.5 [en]C-CCK-MCD ezn/58/n (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: "Nelson, Trent ." Cc: "'hackers@freebsd.org'" , "'questions@freebsd.org'" Subject: Re: FreeBSD usage in safety-critical environments References: <8F329FEDF58BD411BE5200508B10DA7607D71A10@exchptc1.switch.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG "Nelson, Trent ." wrote: > [Please include me directly as I'm not on the list] > > Hi, > > Has anyone had any experience with deploying FreeBSD in > safety-critical environments? Has any work been done attempting to certify > FreeBSD to any particular SIL? Is there any intention to do such a thing? > > If not FreeBSD, I'd be interested to hear if any has had exposure to > other BSD flavors being used in safety-critical environments. > > I've just been shown a report at work that has been commissioned by > the UK Health & Safety Executives and sponsored by the UK Ministry of > Defense and Safety Regulation Group of the UK Civil Aviation Authority > undertaking a preliminary assessment of Linux for safety-related systems. > The report 'identifies' that it would be possible to certify Linux to SIL 1 > and SIL 2 quite easily, and SIL 3 with a little work. > > I'd hate to think that this would be an arena where BSD couldn't > compete. I'd also hate to think that the tendency for big players such as > the MoD or DoD etc to lean towards Linux is based on the general Linux > 'hype', rather than technical merit... > > Regards, > > Trent. > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message Well I don't know if this belongs on questions or hackers but the question has enough technical merit to be interesting. For example to what level has BSD been certified. I remember doing this consulting project and mucking with the "low grade" in my opinion C-2 security that Sun OSes had and finding bugs in things like FTP logging and the like. I now do other things so I don't worry about that. :) But it is an interesting issue. I wonder if we should move it to chat? Have Fun, Sends Steve To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 10: 8:59 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B003137B401 for ; Wed, 9 Oct 2002 10:08:56 -0700 (PDT) Received: from bulwark.switch.com (bulwark.switch.com [206.181.77.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0487043E75 for ; Wed, 9 Oct 2002 10:08:56 -0700 (PDT) (envelope-from tnelson@switch.com) Received: from bulwark.switch.com (root@localhost) by bulwark.switch.com with ESMTP id g99H8tqb028924 for ; Wed, 9 Oct 2002 13:08:55 -0400 (EDT) Received: from isunix2.switch.com (isunix2.switch.com [199.234.168.6]) by bulwark.switch.com with ESMTP id g99H8tkt028907 for ; Wed, 9 Oct 2002 13:08:55 -0400 (EDT) Received: from exchptc1.switch.com ([199.234.168.10]) by isunix2.switch.com (PMDF V5.2-32 #37720) with ESMTP id <0H3Q00AII4YTMK@isunix2.switch.com> for hackers@freebsd.org; Wed, 9 Oct 2002 13:08:53 -0400 (EDT) Received: by exchptc1.switch.com with Internet Mail Service (5.5.2653.19) id <4LCC121Y>; Wed, 09 Oct 2002 13:08:53 -0400 Content-return: allowed Date: Wed, 09 Oct 2002 13:08:46 -0400 From: "Nelson, Trent ." Subject: RE: FreeBSD usage in safety-critical environments To: "'chromexa@ovis.net'" , "Nelson, Trent ." Cc: "'hackers@freebsd.org'" Message-id: <8F329FEDF58BD411BE5200508B10DA7607D71A12@exchptc1.switch.com> MIME-version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-type: text/plain; charset="iso-8859-1" Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG [Taken off questions@] > -----Original Message----- > From: Steve Kudlak [mailto:chromexa@ovis.net] > Sent: Wednesday, October 09, 2002 6:08 PM > To: Nelson, Trent . > Cc: 'hackers@freebsd.org'; 'questions@freebsd.org' > Subject: Re: FreeBSD usage in safety-critical environments > > > > "Nelson, Trent ." wrote: > > > [Please include me directly as I'm not on the list] > > > > Hi, > > > > Has anyone had any experience with deploying FreeBSD in > > safety-critical environments? Has any work been done attempting to > certify > > FreeBSD to any particular SIL? Is there any intention to do such a > thing? > > > > If not FreeBSD, I'd be interested to hear if any has had > exposure to > > other BSD flavors being used in safety-critical environments. > > > > I've just been shown a report at work that has been commissioned > by > > the UK Health & Safety Executives and sponsored by the UK Ministry of > > Defense and Safety Regulation Group of the UK Civil Aviation Authority > > undertaking a preliminary assessment of Linux for safety-related > systems. > > The report 'identifies' that it would be possible to certify Linux to > SIL 1 > > and SIL 2 quite easily, and SIL 3 with a little work. > > > > I'd hate to think that this would be an arena where BSD couldn't > > compete. I'd also hate to think that the tendency for big players such > as > > the MoD or DoD etc to lean towards Linux is based on the general Linux > > 'hype', rather than technical merit... > > > > Regards, > > > > Trent. > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > with "unsubscribe freebsd-hackers" in the body of the message > > Well I don't know if this belongs on questions or hackers but the > question has enough technical merit to be interesting. For example > to what level has BSD been certified. I remember doing this consulting > project and mucking with the "low grade" in my opinion C-2 security > that Sun OSes had and finding bugs in things like FTP logging and > the like. I now do other things so I don't worry about that. :) But it > is an interesting issue. I wonder if we should move it to chat? If you're referring to security criteria (Trusted Computer Security Evaluation Criteria or ITSEC for Euro/UK), then no, FreeBSD doesn't currently provide any features C2/F-C2+ configuration (Access Control Lists, auditing, accountability, etc). This is being tackled by TrustedBSD though, which I'm sure Robert Watson can provide some more information on. Although they are inter-related, the safety integrity level of the system is what I was really querying. That tends to bring in a whole host of metrics such as error and exception handling, standard failure modes, MTBF, etc etc. > > Have Fun, > Sends Steve Regards, Trent. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 10:15:35 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9202437B401; Wed, 9 Oct 2002 10:15:33 -0700 (PDT) Received: from horkos.telenet-ops.be (horkos.telenet-ops.be [195.130.132.45]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1590343E4A; Wed, 9 Oct 2002 10:15:33 -0700 (PDT) (envelope-from Guido@VanHoecke.org) Received: from localhost (localhost.localdomain [127.0.0.1]) by horkos.telenet-ops.be (Postfix) with SMTP id C4DF884B27; Wed, 9 Oct 2002 19:15:31 +0200 (CEST) Received: from VanHoecke.org (D5E0E969.kabel.telenet.be [213.224.233.105]) by horkos.telenet-ops.be (Postfix) with ESMTP id 13CE384B21; Wed, 9 Oct 2002 19:15:29 +0200 (CEST) Message-ID: <3DA46430.6080206@VanHoecke.org> Date: Wed, 09 Oct 2002 19:15:28 +0200 From: Guido Van Hoecke User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2a) Gecko/20020910 X-Accept-Language: en-us, en MIME-Version: 1.0 To: stefan@beke.sk Cc: freebsd-hackers@freebsd.org, freebsd-questions@freebsd.org, Matthew Emmerton , freebsd-mobile@freebsd.org Subject: Re: i-buddie References: <20021009113837.A27354@creon.profinet.sk> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG i4o beke wrote: > Hi Guido. I've seen your question on freebsd-mobile, without answer. > I'd like to buy i-buddie, 3c or 4. So your problems with setup are > really interesting for me. > Is your sis network card working? Is it possible to > run XWin on i-buddie? Thank you for your answer. I am afraid I have had no luck with freebsd. My sis900 network card is recognized but fails with a 'MII without any PHY!', and 3 more devices are showing up as unknown: pci0 2.7 is a sis7012 audio driver pci0 5.0 is a conexant 56k modem pci0 7.0 ia a VIA OHCI Compliant IEEE1394 host controller Further more, XF86 as available in freebsd 4.6.2-RELEASE #0 does not recognize my lcd panel, so I can't run a desktop environment. I have not yet posted about the X problem, I wanted to have the sis900 network problem resolved first. FYI, I've installed mandrake 8.2 without a single hickup: all hardware recognized and configured properly in a very neat and smooth installation. Other distros which I've tried with less success are Red Hat 7.3, and Debian 3.0 I do like the iBuddy though! -- Guido Van Hoecke To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 10:21: 8 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 52BAC37B401 for ; Wed, 9 Oct 2002 10:21:07 -0700 (PDT) Received: from mail1.panix.com (mail1.panix.com [166.84.1.72]) by mx1.FreeBSD.org (Postfix) with ESMTP id A6B9543E3B for ; Wed, 9 Oct 2002 10:21:06 -0700 (PDT) (envelope-from float@firedrake.org) Received: from firedrake.org (narcissus.net [166.84.159.135]) by mail1.panix.com (Postfix) with ESMTP id 855E648A70; Wed, 9 Oct 2002 13:21:05 -0400 (EDT) Date: Wed, 9 Oct 2002 13:21:05 -0400 Subject: Re: [hackers] Writing a PCI ADSL Driver Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v546) Cc: David Gilbert , Neal Nelson , To: Taavi Talvik From: float@firedrake.org In-Reply-To: <20021007013551.S98477-100000@valu.uninet.ee> Message-Id: <7E1C6E6A-DBAB-11D6-B8A2-003065D4F4F2@firedrake.org> Content-Transfer-Encoding: 7bit X-Mailer: Apple Mail (2.546) Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sunday, October 6, 2002, at 06:48 PM, Taavi Talvik wrote: > > Problem with ADSL is that there are actually too many link layer > encapsualtions in use - PPPoE, PPPoA, plain rfc1348 (if i remember > rfc number correctly) etc. This RFC defines the format of two new Resource Records (RRs) for the Domain Name System (DNS), and reserves corresponding DNS type mnemonic and numerical codes. Nope, try again. :-) -- Ben You buttered your bread, now lie in it. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 10:39:24 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A23F837B401 for ; Wed, 9 Oct 2002 10:39:22 -0700 (PDT) Received: from dibbler.ne.client2.attbi.com (dibbler.ne.client2.attbi.com [24.61.41.247]) by mx1.FreeBSD.org (Postfix) with ESMTP id DF9C143E75 for ; Wed, 9 Oct 2002 10:39:21 -0700 (PDT) (envelope-from rodrigc@attbi.com) Received: from dibbler.ne.client2.attbi.com (localhost.ne.attbi.com [127.0.0.1]) by dibbler.ne.client2.attbi.com (8.12.6/8.12.5) with ESMTP id g99He2CK007874; Wed, 9 Oct 2002 13:40:02 -0400 (EDT) (envelope-from rodrigc@dibbler.ne.client2.attbi.com) Received: (from rodrigc@localhost) by dibbler.ne.client2.attbi.com (8.12.6/8.12.6/Submit) id g99He2te007873; Wed, 9 Oct 2002 13:40:02 -0400 (EDT) Date: Wed, 9 Oct 2002 13:40:01 -0400 From: Craig Rodrigues To: "Nelson, Trent ." Cc: "'chromexa@ovis.net'" , "'hackers@freebsd.org'" Subject: Re: FreeBSD usage in safety-critical environments Message-ID: <20021009134001.A7815@attbi.com> References: <8F329FEDF58BD411BE5200508B10DA7607D71A12@exchptc1.switch.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <8F329FEDF58BD411BE5200508B10DA7607D71A12@exchptc1.switch.com>; from tnelson@switch.com on Wed, Oct 09, 2002 at 01:08:46PM -0400 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, Oct 09, 2002 at 01:08:46PM -0400, Nelson, Trent . wrote: > > > The report 'identifies' that it would be possible to certify Linux to > > SIL 1 > > > and SIL 2 quite easily, and SIL 3 with a little work. I've seen this game before with other certification efforts, ie. U.S. Federal Aviation Administration's DO-178B for certification of software used in airborne systems and equipment. Certification is usually an expensive undertaking, so it usually requires a company with enough $$$ to jump through all the hoops of the certification process (ie. submitting to special tests, fixing the bugs, etc.). No one would go through this stuff unless there was an anticipated reward, ie. $$$. WindRiver has done this kind of stuff for VxWorks. Now, if the UK govt. is looking to certify Linux, what version and what vendor would they certify? Linux has a lot of buzz these days, and there are a number of vendors who are trying to pitch it in real-time and embedded systems markets, and many companies who are providing Linux-based services. I'm sure that any FreeBSD could be certified, but the questions would be: - which companies have the resources to submit to such an SIL certification and jump through all the hoops? - is there enough of a financial incentive to do so? - has the UK govt heard of BSD, and would they even care if someone wanted to certify it? Unfortunately marketing and mindshare plays a lot in these kinds of things. -- Craig Rodrigues http://www.gis.net/~craigr rodrigc@attbi.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 10:48:14 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7D38637B401 for ; Wed, 9 Oct 2002 10:48:13 -0700 (PDT) Received: from valu.uninet.ee (valu.uninet.ee [194.204.34.51]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9621A43E88 for ; Wed, 9 Oct 2002 10:48:12 -0700 (PDT) (envelope-from taavi@uninet.ee) Received: by valu.uninet.ee (Postfix, from userid 1002) id A1AD336420; Wed, 9 Oct 2002 20:48:10 +0300 (EEST) Received: from localhost (localhost [127.0.0.1]) by valu.uninet.ee (Postfix) with ESMTP id 9E6603261A; Wed, 9 Oct 2002 20:48:10 +0300 (EEST) Date: Wed, 9 Oct 2002 20:48:10 +0300 (EEST) From: Taavi Talvik To: float@firedrake.org Cc: David Gilbert , Neal Nelson , Subject: Re: [hackers] Writing a PCI ADSL Driver In-Reply-To: <7E1C6E6A-DBAB-11D6-B8A2-003065D4F4F2@firedrake.org> Message-ID: <20021009203358.W35437-100000@valu.uninet.ee> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, 9 Oct 2002 float@firedrake.org wrote: > On Sunday, October 6, 2002, at 06:48 PM, Taavi Talvik wrote: > > > > Problem with ADSL is that there are actually too many link layer > > encapsualtions in use - PPPoE, PPPoA, plain rfc1348 (if i remember > > rfc number correctly) etc. > > This RFC defines the format of two new Resource Records (RRs) for the > Domain Name System (DNS), and reserves corresponding DNS type > mnemonic and numerical codes. > > Nope, try again. :-) Ok, rfc1483 obsoleted by rfc2684. Still, the point holds - in xDSL services every imaginable encapsulation is used and usefull driver should provide netgraph hooks for constructing arbitrary upper layers. Especially nice would be autodetection of active ATM VC's, used encapsualtions and connecting appropriate netgraph hooks automagically. best regards, taavi To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 10:55:23 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E364237B401 for ; Wed, 9 Oct 2002 10:55:21 -0700 (PDT) Received: from ns1.ovis.net (ns1.ovis.net [207.0.147.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6A68743E65 for ; Wed, 9 Oct 2002 10:55:21 -0700 (PDT) (envelope-from chromexa@ovis.net) Received: from ovis.net (s45.pm5.ovis.net [207.0.147.111]) by ns1.ovis.net (Postfix) with ESMTP id 108F83B43; Wed, 9 Oct 2002 13:55:16 -0400 (EDT) Message-ID: <3DA46F74.461FEB85@ovis.net> Date: Wed, 09 Oct 2002 14:03:32 -0400 From: Steve Kudlak Reply-To: chromexa@ovis.net X-Mailer: Mozilla 4.5 [en]C-CCK-MCD ezn/58/n (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Craig Rodrigues Cc: "Nelson, Trent ." , "'hackers@freebsd.org'" Subject: Re: FreeBSD usage in safety-critical environments References: <8F329FEDF58BD411BE5200508B10DA7607D71A12@exchptc1.switch.com> <20021009134001.A7815@attbi.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Craig Rodrigues wrote: > On Wed, Oct 09, 2002 at 01:08:46PM -0400, Nelson, Trent . wrote: > > > > The report 'identifies' that it would be possible to certify Linux to > > > SIL 1 > > > > and SIL 2 quite easily, and SIL 3 with a little work. > > I've seen this game before with other certification efforts, > ie. U.S. Federal Aviation Administration's DO-178B for certification > of software used in airborne systems and equipment. > > Certification is usually an expensive undertaking, so it usually requires > a company with enough $$$ to jump through all the hoops > of the certification process (ie. submitting to special tests, fixing the > bugs, etc.). No one would go through this > stuff unless there was an anticipated reward, ie. $$$. > WindRiver has done this kind of stuff for VxWorks. > > Now, if the UK govt. is looking to certify Linux, what version and > what vendor would they certify? Linux has a lot of buzz these days, > and there are a number of vendors who are trying to pitch it in > real-time and embedded systems markets, and many companies who are > providing Linux-based services. > > I'm sure that any FreeBSD could be certified, but the questions would be: > - which companies have the resources to submit to such an SIL certification > and jump through all the hoops? > - is there enough of a financial incentive to do so? > - has the UK govt heard of BSD, and would they even care if someone wanted to > certify it? > > Unfortunately marketing and mindshare plays a lot in these kinds of things. > > -- > Craig Rodrigues > http://www.gis.net/~craigr > rodrigc@attbi.com Is there a place for *BSD security freaks to go and discuss systems? I get lots of security questions, usually these are broad level questions and nothing like the "government authority certification body" sorts of things. Usually they are the usual user questions that come to systems people. The folks that faint when they see me reading FreeBSD hackers and go: "How can you read that..." As an aside right now my big thing is convincing people in remote areas that *nix, FreeBSD et al provide a clear and better alternative to windows. Have Fun, Sends Steve To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 11: 3:59 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E613237B401 for ; Wed, 9 Oct 2002 11:03:57 -0700 (PDT) Received: from dibbler.ne.client2.attbi.com (dibbler.ne.client2.attbi.com [24.61.41.247]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3462743E4A for ; Wed, 9 Oct 2002 11:03:57 -0700 (PDT) (envelope-from rodrigc@attbi.com) Received: from dibbler.ne.client2.attbi.com (localhost.ne.attbi.com [127.0.0.1]) by dibbler.ne.client2.attbi.com (8.12.6/8.12.5) with ESMTP id g99I4bCK007985; Wed, 9 Oct 2002 14:04:38 -0400 (EDT) (envelope-from rodrigc@dibbler.ne.client2.attbi.com) Received: (from rodrigc@localhost) by dibbler.ne.client2.attbi.com (8.12.6/8.12.6/Submit) id g99I4ato007984; Wed, 9 Oct 2002 14:04:36 -0400 (EDT) Date: Wed, 9 Oct 2002 14:04:36 -0400 From: Craig Rodrigues To: Steve Kudlak Cc: "'hackers@freebsd.org'" Subject: Re: FreeBSD usage in safety-critical environments Message-ID: <20021009140436.A7948@attbi.com> References: <8F329FEDF58BD411BE5200508B10DA7607D71A12@exchptc1.switch.com> <20021009134001.A7815@attbi.com> <3DA46F74.461FEB85@ovis.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <3DA46F74.461FEB85@ovis.net>; from chromexa@ovis.net on Wed, Oct 09, 2002 at 02:03:32PM -0400 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, Oct 09, 2002 at 02:03:32PM -0400, Steve Kudlak wrote: > Is there a place for *BSD security freaks to go and discuss systems? > I get lots of security questions, usually these are broad level questions > and nothing like the "government authority certification body" sorts > of things. Usually they are the usual user questions that come to > systems people. The folks that faint when they see me reading > FreeBSD hackers and go: "How can you read that..." As an aside > right now my big thing is convincing people in remote areas that > *nix, FreeBSD et al provide a clear and better alternative to windows. Your question is a bit off-topic in terms of certification, although security is an important part of safety. See the list of FreeBSD mailing lists: http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/eresources.html#ERESOURCES-MAIL freebsd-security or freebsd-security-notifications might be appropriate for your needs. There is a lot of FreeBSD security-related work going on in the TrustedBSD project ( http://www.trustedbsd.org ). Another BSD project, OpenBSD ( http://www.openbsd.org ), has security and safety as its primary focus. -- Craig Rodrigues http://www.gis.net/~craigr rodrigc@attbi.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 12:27:30 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B0AA137B401; Wed, 9 Oct 2002 12:27:28 -0700 (PDT) Received: from flamingo.mail.pas.earthlink.net (flamingo.mail.pas.earthlink.net [207.217.120.232]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4B42343E6A; Wed, 9 Oct 2002 12:27:28 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0579.cvx22-bradley.dialup.earthlink.net ([209.179.200.69] helo=mindspring.com) by flamingo.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zMUP-0001Dx-00; Wed, 09 Oct 2002 12:27:26 -0700 Message-ID: <3DA482D6.F618F6C5@mindspring.com> Date: Wed, 09 Oct 2002 12:26:14 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: "Nelson, Trent ." Cc: "'hackers@freebsd.org'" , "'questions@freebsd.org'" Subject: Re: FreeBSD usage in safety-critical environments References: <8F329FEDF58BD411BE5200508B10DA7607D71A10@exchptc1.switch.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG "Nelson, Trent ." wrote: > Has anyone had any experience with deploying FreeBSD in > safety-critical environments? Has any work been done attempting to certify > FreeBSD to any particular SIL? Is there any intention to do such a thing? > > If not FreeBSD, I'd be interested to hear if any has had exposure to > other BSD flavors being used in safety-critical environments. Life support systems need to be designed from the ground up. > I've just been shown a report at work that has been commissioned by > the UK Health & Safety Executives and sponsored by the UK Ministry of > Defense and Safety Regulation Group of the UK Civil Aviation Authority > undertaking a preliminary assessment of Linux for safety-related systems. > The report 'identifies' that it would be possible to certify Linux to SIL 1 > and SIL 2 quite easily, and SIL 3 with a little work. Tell me where these systems will be deployed, so I avoid going there. Seriously. > I'd hate to think that this would be an arena where BSD couldn't > compete. I'd also hate to think that the tendency for big players such as > the MoD or DoD etc to lean towards Linux is based on the general Linux > 'hype', rather than technical merit... Life support systems require formal proofs of correctness for code; since neither Linux nor FreeBSD is formally correct, in total, you would need to be insane to deplaoy either of them as, for example, a part of an air traffic control system. The same goes for AIX, Solaris, Windows, VMS, and most other systems. The SIL 1/2 stuff, from my understanding, depends on fast reboot times and other things that are out of the control of the OS, and are more BIOS things anyway (external signal state changes during debvice probes, etc., causing actions in the hardware attached to the ports, etc.). The biggest cost factor in an life support deployment (IMO) is the liability insurance. By becoming your own vendor, you get to assume all of the liability. Not a good thing, from a risk analysis perspective. 8-(. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 12:37: 6 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B1FE437B401; Wed, 9 Oct 2002 12:37:05 -0700 (PDT) Received: from pintail.mail.pas.earthlink.net (pintail.mail.pas.earthlink.net [207.217.120.122]) by mx1.FreeBSD.org (Postfix) with ESMTP id 50B5A43E6A; Wed, 9 Oct 2002 12:37:05 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0579.cvx22-bradley.dialup.earthlink.net ([209.179.200.69] helo=mindspring.com) by pintail.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zMdh-000738-00; Wed, 09 Oct 2002 12:37:01 -0700 Message-ID: <3DA48516.A029DFCA@mindspring.com> Date: Wed, 09 Oct 2002 12:35:50 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: chromexa@ovis.net Cc: "Nelson, Trent ." , "'hackers@freebsd.org'" , "'questions@freebsd.org'" Subject: Re: Security certification (was FreeBSD usage in safety-critical environments) References: <8F329FEDF58BD411BE5200508B10DA7607D71A10@exchptc1.switch.com> <3DA4625F.332C5D20@ovis.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Steve Kudlak wrote: > Well I don't know if this belongs on questions or hackers but the > question has enough technical merit to be interesting. For example > to what level has BSD been certified. I remember doing this consulting > project and mucking with the "low grade" in my opinion C-2 security > that Sun OSes had and finding bugs in things like FTP logging and > the like. I now do other things so I don't worry about that. :) But it > is an interesting issue. I wonder if we should move it to chat? Such certification is a certification of both software and hardware. What this means is that if you certify an OS C-2 on a "Dell 1770S", it is *not* certified on a "Dell 1771S" or a "Dell 1770R". Sun can claim certification because they are a hardware vendor, with an OS sideline, as opposed to an OS vendor. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 12:50:17 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 86EFE37B401; Wed, 9 Oct 2002 12:49:59 -0700 (PDT) Received: from outmail-3.st1.spray.net (outmail-3.st1.spray.net [212.78.202.122]) by mx1.FreeBSD.org (Postfix) with ESMTP id CD41A43E42; Wed, 9 Oct 2002 12:49:58 -0700 (PDT) (envelope-from puledi1976@lycos.co.uk) Received: from lycos.co.uk (newwww-37.st1.spray.net [212.78.202.47]) by outmail-3.st1.spray.net (Postfix) with SMTP id C7351A06C; Wed, 9 Oct 2002 21:49:57 +0200 (DST) From: puledi mpezi To: puledi1976@lycos.co.uk Message-ID: <1034192996016884@lycos.co.uk> X-Mailer: Caramail - www.caramail.com X-Originating-IP: [216.139.169.27] Mime-Version: 1.0 Subject: contact me!! Date: Content-Type: multipart/mixed; boundary="=_NextPart_Caramail_0168841034192996_ID" Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG This message is in MIME format. Since your mail reader does not understand this format, some or all of this message may not be legible. --=_NextPart_Caramail_0168841034192996_ID Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit MR. PULEDI MPEZI. PACIFIC BANK OF SOUTH AFRICA, 9TH FLOOR, HEERENGRACHT TOWER, STANDARD BANK CENTER, CAPE TOWN, SOUTH AFRICA. I am Mr. Puledi Mpezi, Provincial Director Pacific Bank of South Africa, Johannesburg Branch. I have urgent and very confidential business proposition for you. On June 6, 1998, an American Oil consultant/contractor with the South Africa Mining Corporation, Mr. Charles Andason made a numbered time (Fixed) Deposit for twelve calendar months, valued at US$25,000,000.00 (Twenty- five Million Dollars) in my branch. Upon maturity, I sent a routine notification to his forwarding address but got no reply. After a month, we sent a reminder and finally we discovered from his contract employers, the South Africa Mining Corporation that Mr. Charles Andason died from an automobile accident. On further investigation, I found out that he died without making a WILL, and all attempts to trace his next of kin was fruitless. I therefore made further investigation and discovered that Mr. Charles Andason did not declare any kin or relations in all his official documents, including his Bank Deposit paperwork in my Bank. This sum of US$25,000,000.00 is still sitting in my Bank and the interest is being rolled over with the principal sum at the end of each year. No one will ever come forward to claim it. According to South Africa Law, at the expiration of 5 (five) years, the money will revert to the ownership of the South Africa Government if nobody applies to claim the fund. Consequently, my proposal is that I will like you to stand in as the next of kin to Mr. Charles Andason so that the fruits of this old man's labor will not get into the hands of some corrupt government officials. This is simple, I will like you to provide immediately your full names and address so that the Attorney will prepare the necessary documents and affidavits which will put you in place as the next of kin. We shall employ the service of two Attorneys for drafting and notarization of the WILL and to obtain the necessary documents and letter of probate/administration in your favor for the transfer. A bank account in any part of the world which you will provide will then facilitate the transfer of this money to you as the beneficiary/next of kin. The money will be paid into your account for us to share in the ratio of 60% for me and 40% for you. There is no risk at all as all the paperwork for this transaction will be done by the Attorney and my position as the Branch Manager guarantees the successful execution of this transaction. If you are interested, please reply immediately via the private email address below.. Upon your response, I shall then provide you with more details and relevant documents that will help you understand the transaction. Please observe utmost confidentiality, and rest assured that this transaction would be most profitable for both of us because I shall require your assistance to invest my share in your country. Sincerely Puledi Mpezi ______________________________________________________ Check out all the latest outrageous email attachments on the Outrageous Email Chart! - http://viral.lycos.co.uk --=_NextPart_Caramail_0168841034192996_ID-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 13:24:45 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5593537B401 for ; Wed, 9 Oct 2002 13:24:44 -0700 (PDT) Received: from yahoo.com (adsl-63-199-30-238.dsl.snfc21.pacbell.net [63.199.30.238]) by mx1.FreeBSD.org (Postfix) with SMTP id 6A94A43E7B; Wed, 9 Oct 2002 13:24:39 -0700 (PDT) (envelope-from Brad1123ghj@yahoo.com) Reply-To: "Brad Luqinski" Message-ID: <011e87e80b0d$1421d1d5$3ee88cd3@xvgblp> From: "Brad Luqinski" To: users@FreeBSD.ORG Subject: Cheap Smokes Date: Wed, 09 Oct 2002 23:19:28 -0300 MiME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_NextPart_000_00B6_33A88C0B.D0417A52" X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook, Build 10.0.2616 Importance: Normal Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG ------=_NextPart_000_00B6_33A88C0B.D0417A52 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: base64 Q2lnYXJldHRlcyBmcm9tICQxOS45OSBwZXIgY2FydG9uISENCg0KaHR0cDov L3d3dy5saWZlbGluZWRlYWxzLmNvbS9jaWdzL2luZGV4LnBocD8xNjINCjgz NDFvV3hMMy0zMDJ2ZXJ0Mjk0N2JiV24xLTUwOWZsMjk= To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 15: 2:28 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3DE6337B401; Wed, 9 Oct 2002 15:02:27 -0700 (PDT) Received: from boreas.isi.edu (boreas.isi.edu [128.9.160.161]) by mx1.FreeBSD.org (Postfix) with ESMTP id 75D8643E4A; Wed, 9 Oct 2002 15:02:26 -0700 (PDT) (envelope-from faber@ISI.EDU) Received: from pun.isi.edu (pun.isi.edu [128.9.160.150]) by boreas.isi.edu (8.11.6/8.11.2) with ESMTP id g99Lx2C12208; Wed, 9 Oct 2002 14:59:02 -0700 (PDT) Received: from pun.isi.edu (localhost [127.0.0.1]) by pun.isi.edu (8.12.6/8.12.6) with ESMTP id g99Lx1Pp085686; Wed, 9 Oct 2002 14:59:01 -0700 (PDT) (envelope-from faber@pun.isi.edu) Received: (from faber@localhost) by pun.isi.edu (8.12.6/8.12.6/Submit) id g99Lx1Kh085685; Wed, 9 Oct 2002 14:59:01 -0700 (PDT) Date: Wed, 9 Oct 2002 14:59:01 -0700 From: Ted Faber To: Terry Lambert Cc: "Nelson, Trent ." , "'hackers@freebsd.org'" , "'questions@freebsd.org'" Subject: Re: FreeBSD usage in safety-critical environments Message-ID: <20021009215900.GC93282@pun.isi.edu> References: <8F329FEDF58BD411BE5200508B10DA7607D71A10@exchptc1.switch.com> <3DA482D6.F618F6C5@mindspring.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="mvpLiMfbWzRoNl4x" Content-Disposition: inline In-Reply-To: <3DA482D6.F618F6C5@mindspring.com> User-Agent: Mutt/1.4i X-url: http://www.isi.edu/~faber Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --mvpLiMfbWzRoNl4x Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Oct 09, 2002 at 12:26:14PM -0700, Terry Lambert wrote: > Life support systems require formal proofs of correctness for code; > since neither Linux nor FreeBSD is formally correct, in total, you > would need to be insane to deplaoy either of them as, for example, > a part of an air traffic control system. I suspect that's a bad example, or that you mean an embedded aircraft control system. Ron Reisman and James Murphy gave a fine invited talk at USENIX 02 (http://www.usenix.org/events/usenix02/tech/#11am) about the growing number of UNIX components in the US ATC system. I reject the conclusion that the FAA is collectively insane for that reason. ---------------------------------------------------------------------- Ted Faber faber@isi.edu USC/ISI Computer Scientist http://www.isi.edu/~faber (310) 448-9190 PGP Keys: http://www.isi.edu/~faber/pubkeys.asc --mvpLiMfbWzRoNl4x Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (FreeBSD) iD8DBQE9pKakaUz3f+Zf+XsRApo2AJwMLYdFonRM4VfHSNZqePEF8Dny0ACfb6QJ 6u4wLjkoKK7+Hz8+XEP2+do= =wNh+ -----END PGP SIGNATURE----- --mvpLiMfbWzRoNl4x-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 19:22:30 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6BB3337B401; Wed, 9 Oct 2002 19:22:28 -0700 (PDT) Received: from dibbler.ne.client2.attbi.com (dibbler.ne.client2.attbi.com [24.61.41.247]) by mx1.FreeBSD.org (Postfix) with ESMTP id AB37E43E4A; Wed, 9 Oct 2002 19:22:27 -0700 (PDT) (envelope-from rodrigc@attbi.com) Received: from dibbler.ne.client2.attbi.com (localhost.ne.attbi.com [127.0.0.1]) by dibbler.ne.client2.attbi.com (8.12.6/8.12.5) with ESMTP id g9A2N8CK010097; Wed, 9 Oct 2002 22:23:08 -0400 (EDT) (envelope-from rodrigc@dibbler.ne.client2.attbi.com) Received: (from rodrigc@localhost) by dibbler.ne.client2.attbi.com (8.12.6/8.12.6/Submit) id g9A2N8Ed010096; Wed, 9 Oct 2002 22:23:08 -0400 (EDT) Date: Wed, 9 Oct 2002 22:23:07 -0400 From: Craig Rodrigues To: freebsd-standards@freebsd.org Cc: freebsd-hackers@freebsd.org Subject: Problem detecting POSIX symbolic constants Message-ID: <20021009222307.A9894@attbi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, Earlier this year on the FreeBSD hackers mailing list: http://docs.freebsd.org/cgi/getmsg.cgi?fetch=278142+0+/usr/local/www/db/text/2002/freebsd-hackers/20020317.freebsd-hackers I was advised by Terry Lambert to use: #ifdef _POSIX_REALTIME_SIGNALS to detect if sigqueue(), sigtimedwait, sigwaitinfo() were defined. I made this change to the FreeBSD configuration for ACE, a C++ library used for systems programming ( http://www.cs.wustl.edu/~schmidt/ACE.html ). The change I made worked fine in -STABLE. However, in -CURRENT, this test breaks, because _POSIX_REALTIME_SIGNALS is defined, but it is -1. According to the letter of the law: http://www.opengroup.org/onlinepubs/007904975/basedefs/xbd_chap02.html "The following symbolic constants shall either be undefined or defined with a value other than -1." So, this is legal way to implement these macros. It just breaks my code. :) Can I appeal to the freebsd-standards team to leave these macros undefined instead of defining them to -1? #ifdef/#ifndef is a pretty common way to detect if a feature is available on a system, especially when used in conjunction with something like autoconf. If that is not an option, then what is the correct way for me to write my code? Keep in mind that code in ACE must be very portable, and work on platforms which may not adhere 100% to the letter of the POSIX law. Unfortunately ACE does not use autoconf, so these configurations need to be hardcoded. Here is my code, from config-freebsd-pthread.h from ACE: 210 #include 211 #include 212 /* POSIX Realtime signals are not fully implemented in FreeBSD. 213 When they are implemented, then _POSIX_REALTIME_SIGNALS will be 214 defined, as specified in the POSIX standard. 215 Refer to e-mail thread on freebsd-hackers mailing list, March 2002. */ 216 #ifdef _POSIX_REALTIME_SIGNALS 217 # define ACE_HAS_AIO_CALLS 218 # ifndef SIGRTMIN 219 # define SIGRTMIN 32 220 # endif /* SIGRTMIN */ 221 # ifndef SIGRTMAX 222 # define SIGRTMAX (_SIG_MAXSIG - 1) 223 # endif /* SIGRTMAX */ 224 #endif /* _POSIX_REALTIME_SIGNALS */ Thanks. -- Craig Rodrigues http://www.gis.net/~craigr rodrigc@attbi.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 19:32:19 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A459B37B401; Wed, 9 Oct 2002 19:32:17 -0700 (PDT) Received: from harrier.mail.pas.earthlink.net (harrier.mail.pas.earthlink.net [207.217.120.12]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1F00E43E4A; Wed, 9 Oct 2002 19:32:17 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0018.cvx21-bradley.dialup.earthlink.net ([209.179.192.18] helo=mindspring.com) by harrier.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zT7V-0000q7-00; Wed, 09 Oct 2002 19:32:13 -0700 Message-ID: <3DA4E61C.DCC8F543@mindspring.com> Date: Wed, 09 Oct 2002 19:29:48 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Craig Rodrigues Cc: freebsd-standards@freebsd.org, freebsd-hackers@freebsd.org Subject: Re: Problem detecting POSIX symbolic constants References: <20021009222307.A9894@attbi.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Craig Rodrigues wrote: > #ifdef _POSIX_REALTIME_SIGNALS > According to the letter of the law: > http://www.opengroup.org/onlinepubs/007904975/basedefs/xbd_chap02.html > > "The following symbolic constants shall either be undefined or defined > with a value other than -1." > > So, this is legal way to implement these macros. It just breaks my code. :) Crap. I missed that. To be totally correct, you will need to: #ifdef _POSIX_REALTIME_SIGNALS #if (_POSIX_REALTIME_SIGNALS != -1) ... #endif #endif It's annoying, but doing this will ensure that there are no gaps through which some system other than FreeBSD might fall. > If that is not an option, then what is the correct way for me to write > my code? Keep in mind that code in ACE must be very portable, and work > on platforms which may not adhere 100% to the letter of the POSIX law. This argues for two tests, instead of one. Sorry. PS: There is probably a technicality for wehther or not the "#if" directive is supported, seperately from the value compare. PPS: Technically, it doesn't say that the defined value has to be an integer type, either... some people are just jerks. 8-(. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 20:20:18 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 842AA37B401; Wed, 9 Oct 2002 20:20:16 -0700 (PDT) Received: from dibbler.ne.client2.attbi.com (dibbler.ne.client2.attbi.com [24.61.41.247]) by mx1.FreeBSD.org (Postfix) with ESMTP id 726A543E4A; Wed, 9 Oct 2002 20:20:15 -0700 (PDT) (envelope-from rodrigc@attbi.com) Received: from dibbler.ne.client2.attbi.com (localhost.ne.attbi.com [127.0.0.1]) by dibbler.ne.client2.attbi.com (8.12.6/8.12.5) with ESMTP id g9A3KuCK010445; Wed, 9 Oct 2002 23:20:56 -0400 (EDT) (envelope-from rodrigc@dibbler.ne.client2.attbi.com) Received: (from rodrigc@localhost) by dibbler.ne.client2.attbi.com (8.12.6/8.12.6/Submit) id g9A3KuIh010444; Wed, 9 Oct 2002 23:20:56 -0400 (EDT) Date: Wed, 9 Oct 2002 23:20:56 -0400 From: Craig Rodrigues To: freebsd-standards@freebsd.org Cc: freebsd-hackers@freebsd.org Subject: Re: Problem detecting POSIX symbolic constants Message-ID: <20021009232056.A10429@attbi.com> References: <20021009222307.A9894@attbi.com> <3DA4E61C.DCC8F543@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <3DA4E61C.DCC8F543@mindspring.com>; from tlambert2@mindspring.com on Wed, Oct 09, 2002 at 07:29:48PM -0700 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, Oct 09, 2002 at 07:29:48PM -0700, Terry Lambert wrote: > To be totally correct, you will need to: > > #ifdef _POSIX_REALTIME_SIGNALS > #if (_POSIX_REALTIME_SIGNALS != -1) > > ... > > #endif > #endif > > It's annoying, but doing this will ensure that there are no > gaps through which some system other than FreeBSD might fall. Sigh. Why did the POSIX guys do this? :( BTW, I think that: #if defined(_POSIX_REALTIME_SIGNALS) && (_POSIX_REALTIME_SIGNALS != -1 ) should suffice, but I'll double-check with one of my portability gurus to see if that is OK for ACE. I have another request. Even though my preprocessor check was bogus, ACE still compiled, and I did not discover that there were any problems until link time, ie. I had a libACE.so library which could not link with anything because of unresolved symbols. This was very annoying. It would have been nicer if this could have been caught earlier in the compile stage. Since sigqueue(), sigwait(), sigwaitinfo() are not implemented in FreeBSD, is this patch OK? --- src/include/signal.h.orig Wed Oct 9 23:15:21 2002 +++ src/include/signal.h Wed Oct 9 23:15:31 2002 @@ -76,13 +76,6 @@ int sigwait(const sigset_t *, int *); #endif -#if __BSD_VISIBLE || __POSIX_VISIBLE >= 199506 || __XSI_VISIBLE >= 600 -int sigqueue(__pid_t, int, const union sigval); -int sigtimedwait(const sigset_t * __restrict, siginfo_t * __restrict, - const struct timespec * __restrict); -int sigwaitinfo(const sigset_t * __restrict, siginfo_t * __restrict); -#endif - #if __BSD_VISIBLE || __POSIX_VISIBLE >= 200112 || __XSI_VISIBLE int killpg(__pid_t, int); int sigaltstack(const stack_t * __restrict, stack_t * __restrict); At some point in the future when POSIX RT signals are implemented in FreeBSD (I'm not volunteering :), then _POSIX_REALTIME_SIGNALS can be defined to 200112L in unistd.h, and these three prototypes can be put back into . Is this OK? Thanks. -- Craig Rodrigues http://www.gis.net/~craigr rodrigc@attbi.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 21:22:57 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 79B0837B401; Wed, 9 Oct 2002 21:22:56 -0700 (PDT) Received: from mrv.tusur.ru (mrv.tusur.ru [212.192.120.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id A6CC443E3B; Wed, 9 Oct 2002 21:22:53 -0700 (PDT) (envelope-from mrv@mrv.tusur.ru) Received: from mrv.tusur.ru (localhost [127.0.0.1]) by mrv.tusur.ru (8.12.6/8.12.5) with ESMTP id g9A3EnCA009636; Thu, 10 Oct 2002 11:14:49 +0800 (KRAST) (envelope-from mrv@mrv.tusur.ru) Received: (from mrv@localhost) by mrv.tusur.ru (8.12.6/8.12.6/Submit) id g9A3Emfb009635; Thu, 10 Oct 2002 11:14:48 +0800 (KRAST) Date: Thu, 10 Oct 2002 11:14:48 +0800 From: "Roman V. Mashak" To: Steve Kudlak Cc: "Nelson, Trent ." , "'hackers@freebsd.org'" , "'questions@freebsd.org'" Subject: Re: FreeBSD usage in safety-critical environments Message-ID: <20021010031448.GA9612@mrv.tusur.ru> References: <8F329FEDF58BD411BE5200508B10DA7607D71A10@exchptc1.switch.com> <3DA4625F.332C5D20@ovis.net> Mime-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <3DA4625F.332C5D20@ovis.net> User-Agent: Mutt/1.3.99i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, Oct 09, 2002 at 01:07:43PM -0400, Steve Kudlak wrote: > project and mucking with the "low grade" in my opinion C-2 security > that Sun OSes had and finding bugs in things like FTP logging and > the like. I now do other things so I don't worry about that. :) But it > is an interesting issue. I wonder if we should move it to chat? Could you please pick up some URLs with description of all security levels (C-2 and so on) - how to get, who is going on it and so on. Thanks in advance. -- Best regards, Roman To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 22:14:21 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9774A37B401; Wed, 9 Oct 2002 22:14:20 -0700 (PDT) Received: from pintail.mail.pas.earthlink.net (pintail.mail.pas.earthlink.net [207.217.120.122]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3456E43E6A; Wed, 9 Oct 2002 22:14:20 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0137.cvx22-bradley.dialup.earthlink.net ([209.179.198.137] helo=mindspring.com) by pintail.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zVeF-0007LV-00; Wed, 09 Oct 2002 22:14:12 -0700 Message-ID: <3DA50C53.FA2B1619@mindspring.com> Date: Wed, 09 Oct 2002 22:12:51 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: "Roman V. Mashak" Cc: Steve Kudlak , "Nelson, Trent ." , "'hackers@freebsd.org'" , "'questions@freebsd.org'" Subject: Re: FreeBSD usage in safety-critical environments References: <8F329FEDF58BD411BE5200508B10DA7607D71A10@exchptc1.switch.com> <3DA4625F.332C5D20@ovis.net> <20021010031448.GA9612@mrv.tusur.ru> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG "Roman V. Mashak" wrote: > On Wed, Oct 09, 2002 at 01:07:43PM -0400, Steve Kudlak wrote: > > project and mucking with the "low grade" in my opinion C-2 security > > that Sun OSes had and finding bugs in things like FTP logging and > > the like. I now do other things so I don't worry about that. :) But it > > is an interesting issue. I wonder if we should move it to chat? > > Could you please pick up some URLs with description of all security levels > (C-2 and so on) - how to get, who is going on it and so on. > Thanks in advance. Here is the "Orange Book" (DoD TCSEC / DoD 5200.28-STD): http://www.radium.ncsc.mil/tpep/library/rainbow/5200.28-STD.html You "get it" by paying a certified testing laboratory a huge amount of money to test a particular hardware and software combination. See also: http://www.trustedbsd.org/ -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 22:27:52 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 77D3537B401 for ; Wed, 9 Oct 2002 22:27:51 -0700 (PDT) Received: from rs2s3.datacenter.cha.cantv.net (rs2s3-b.datacenter.cha.cantv.net [200.44.32.58]) by mx1.FreeBSD.org (Postfix) with ESMTP id 31FC743E77 for ; Wed, 9 Oct 2002 22:27:45 -0700 (PDT) (envelope-from info@bestamericaplace.com) Received: from AspEmail (dC8549086.dslam-01-4-9-01-1-01.cum.dsl.cantv.net [200.84.144.134]) by rs2s3.datacenter.cha.cantv.net (8.10.2/8.10.2/2.0) with SMTP id g9A5RDK19933 for ; Thu, 10 Oct 2002 01:27:13 -0400 Message-Id: <200210100527.g9A5RDK19933@rs2s3.datacenter.cha.cantv.net> From: "Bestamericaplace.com Consulting Co." To: hackers@freebsd.org Reply-To: info@bestamericaplace.com Subject: Oferta Especial --- Special Offer Date: Thu, 10 Oct 2002 01:15:24 -0400 MIME-Version: 1.0 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Si requiere de Un Sistema para Windows o Un Sitio Web Avanzado. Visitenos en http://www.bestamericaplace.com If you require a Website or a Application for Windows, visit us at http://www.bestamericaplace.com This e-mail is never sent unsolicited. If you want to be removed from our list please send a blank e-mail to remove@bestamericaplace.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 22:39:24 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AC56E37B401 for ; Wed, 9 Oct 2002 22:39:22 -0700 (PDT) Received: from dsl-64-128-185-9.telocity.com (dsl-64-128-185-9.telocity.com [64.128.185.9]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8F57E43E4A for ; Wed, 9 Oct 2002 22:39:21 -0700 (PDT) (envelope-from mjoyner@hq.dyns.cx) Received: (from root@localhost) by dsl-64-128-185-9.telocity.com (8.11.5/8.11.5) id g9A5c5N83440; Thu, 10 Oct 2002 01:38:05 -0400 (EDT) (envelope-from mjoyner@hq.dyns.cx) Received: from ip-34.internal (ip-34.internal [192.168.2.34]) by hq.dyns.cx (8.11.5/8.11.5av) with ESMTP id g9A5bwl83426; Thu, 10 Oct 2002 01:37:58 -0400 (EDT) (envelope-from mjoyner@hq.dyns.cx) Received: from hq.dyns.cx (localhost [127.0.0.1]) by ip-34.internal (8.12.6/8.12.6) with ESMTP id g9A5d8QO029698; Thu, 10 Oct 2002 01:39:09 -0400 (EDT) (envelope-from mjoyner@hq.dyns.cx) Message-ID: <3DA5127C.4010400@hq.dyns.cx> Disposition-Notification-To: Wolfieee Date: Thu, 10 Oct 2002 01:39:08 -0400 From: Wolfieee User-Agent: Mozilla/5.0 (X11; U; Linux i386; en-US; rv:1.1) Gecko/20020826 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Oliver Fromme , freebsd-hackers@freebsd.org Subject: Re: Mount option "nomtime"? References: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by AMaViS perl-11 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG what about vnconfiging some files on the netapp thing, this way the *bsd can see the vnconfig files as local raw disk partitions? Oliver Fromme wrote: > Lyndon Nerenberg wrote: > > > > Oliver> (The reason why I'm asking: I am going to set up a new > > Oliver> newsserver (INN) on a FreeBSD machine, where all data > > Oliver> including the newsspool is stored on a NetApp Filer.) > > > > For local INN storage you can avoid the mtime issue simply by using raw > > disk partitions. For cycbufs, you don't need the filesystem -- just treat > > the raw disk as the file. By bypassing the filesystem you eliminate all > > of its overhead. The INN documentation describes how to set this up. You > > might want to try this before committing $$$$$$$$$$ to a netapp filer. > > I know the INN documentation by heart. :-) > > Using local disks is not possible, because the machine does > not have any local disks (except for a very small one for > booting the OS). The NetApp Filer is already there and has > a few hundreds of Gbytes of space free, so that it'll be. > Both have gigabit ethernet, so that shouldn't be a problem. > > I'm very curious how it will perform. > > Regards > Oliver > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 22:49:23 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CDA1837B401; Wed, 9 Oct 2002 22:49:19 -0700 (PDT) Received: from khavrinen.lcs.mit.edu (khavrinen.lcs.mit.edu [18.24.4.193]) by mx1.FreeBSD.org (Postfix) with ESMTP id 83C4B43E4A; Wed, 9 Oct 2002 22:49:18 -0700 (PDT) (envelope-from wollman@khavrinen.lcs.mit.edu) Received: from khavrinen.lcs.mit.edu (localhost [IPv6:::1]) by khavrinen.lcs.mit.edu (8.12.3/8.12.5) with ESMTP id g9A5nGgQ060519 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=OK); Thu, 10 Oct 2002 01:49:16 -0400 (EDT) (envelope-from wollman@khavrinen.lcs.mit.edu) Received: (from wollman@localhost) by khavrinen.lcs.mit.edu (8.12.3/8.12.5/Submit) id g9A5nFLn060516; Thu, 10 Oct 2002 01:49:15 -0400 (EDT) (envelope-from wollman) Date: Thu, 10 Oct 2002 01:49:15 -0400 (EDT) From: Garrett Wollman Message-Id: <200210100549.g9A5nFLn060516@khavrinen.lcs.mit.edu> To: Craig Rodrigues Cc: freebsd-standards@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG Subject: Problem detecting POSIX symbolic constants In-Reply-To: <20021009222307.A9894@attbi.com> References: <20021009222307.A9894@attbi.com> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG < said: > I was advised by Terry Lambert to use: > #ifdef _POSIX_REALTIME_SIGNALS Terry was wrong. If _POSIX_REALTIME_SIGNALS is undefined, it means one of two things: - The RTS option is not supported, or - You can't tell whether or not the RTS option is supported. The section of XBD you quoted refers only to the two symbolic onstants listed in that bullet point: _POSIX_CHOWN_RESTRICTED and _POSIX_NO_TRUNC. Both of these represent options from older version of POSIX which are now mandatory (which is also true of the following bullet-point). This change was made in POSIX.1-2001 for alignment with the FIPS-151 standard. > The change I made worked fine in -STABLE. > However, in -CURRENT, this test breaks, because _POSIX_REALTIME_SIGNALS > is defined, but it is -1. POSIX.1-2001 requires that this constant be so defined if the option is not supported. See the section. > Can I appeal to the freebsd-standards team to leave these macros undefined > instead of defining them to -1? #ifdef/#ifndef is a pretty common way > to detect if a feature is available on a system, especially when used > in conjunction with something like autoconf. It's also wrong when used in conjunction with POSIX options. The correct test is as follows: If the option constant is not defined, you really have no idea whether the option is available or not. If the corresponding sysconf(3) key *is* defined, then you might be able to use sysconf(3) or getconf(1) to determine whether the option is supported. You will probably still need to check for the headers and functions manually, because the implementation is not being forthcoming and probably doesn't implement the function even if sysconf() claims it does. If the option constant is defined as -1, the option is guaranteed not to be supported, and the implementation provides neither the library functions nor the header files necessary to compile a program which makes use of the option. If the option constant is defined as a positive value, the option is guaranteed to be supported under all configurations of the system. The library functions and header files are supplied for use with the C compiler, c99(1) (or c89(1) for older POSIX standards). For some functions, additional library specifications must be provided on the c99 command line (see the standard for details). The precise valu of the option constant will tell you what version of the option is supported; for POSIX.1-2001, the option constant if positive must usually be defined to 200112L. If the option constant is defined but zero, the option may or may not be supported depending on run-time configuration. Library functions and header files are supplied as described in the previous case, but applications must call sysconf(3) with the appropriate key to determine at run time whether the option is supported on the system as currently configured. These rules have changed somewhat as the POSIX standards have evolved, but this is the current state of affairs as set out in 1003.1-2001. Hope this helps. -GAWollman To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Wed Oct 9 23: 1: 2 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3BE4D37B401 for ; Wed, 9 Oct 2002 23:01:01 -0700 (PDT) Received: from lurza.secnetix.de (lurza.secnetix.de [212.66.1.130]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5F97343E42 for ; Wed, 9 Oct 2002 23:01:00 -0700 (PDT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (localhost [IPv6:::1]) by lurza.secnetix.de (8.12.5/8.12.5) with ESMTP id g9A60xmC034085 for ; Thu, 10 Oct 2002 08:00:59 +0200 (CEST) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.12.5/8.12.5/Submit) id g9A60xiX034084; Thu, 10 Oct 2002 08:00:59 +0200 (CEST) Date: Thu, 10 Oct 2002 08:00:59 +0200 (CEST) Message-Id: <200210100600.g9A60xiX034084@lurza.secnetix.de> From: Oliver Fromme To: freebsd-hackers@FreeBSD.ORG Reply-To: freebsd-hackers@FreeBSD.ORG Subject: Re: Mount option "nomtime"? In-Reply-To: <3DA5127C.4010400@hq.dyns.cx> X-Newsgroups: list.freebsd-hackers User-Agent: tin/1.5.4-20000523 ("1959") (UNIX) (FreeBSD/4.6-STABLE (i386)) MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Wolfieee wrote: > what about vnconfiging some files on the netapp thing, this way the *bsd > can see the vnconfig files as local raw disk partitions? That wouldn't make a difference, because the NetApp Filer would still schedule mtime updates for evey write access to the file that has been vnconfiged on the client. From the point of view of the Filer, it is still just a file that someone is writing to. Regards Oliver -- Oliver Fromme, secnetix GmbH & Co KG, Oettingenstr. 2, 80538 München Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. "All that we see or seem is just a dream within a dream" (E. A. Poe) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 1: 9:28 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F383537B401; Thu, 10 Oct 2002 01:09:25 -0700 (PDT) Received: from snipe.mail.pas.earthlink.net (snipe.mail.pas.earthlink.net [207.217.120.62]) by mx1.FreeBSD.org (Postfix) with ESMTP id 81C4743EAC; Thu, 10 Oct 2002 01:09:25 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0055.cvx40-bradley.dialup.earthlink.net ([216.244.42.55] helo=mindspring.com) by snipe.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zYNL-0005Bj-00; Thu, 10 Oct 2002 01:08:55 -0700 Message-ID: <3DA5354F.9BB3E54B@mindspring.com> Date: Thu, 10 Oct 2002 01:07:43 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Garrett Wollman Cc: Craig Rodrigues , freebsd-standards@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG Subject: Re: Problem detecting POSIX symbolic constants References: <20021009222307.A9894@attbi.com> <200210100549.g9A5nFLn060516@khavrinen.lcs.mit.edu> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Garrett Wollman wrote: > < said: > > I was advised by Terry Lambert to use: > > #ifdef _POSIX_REALTIME_SIGNALS > > Terry was wrong. If _POSIX_REALTIME_SIGNALS is undefined, it means > one of two things: > > - The RTS option is not supported, or That's what I said in the orignal posting. He needed to protect his use of the covered functions with that. [ ... ] > POSIX.1-2001 requires that this constant be so defined if the option > is not supported. See the section. Is FreeBSD fully compliant with POSIX 1003.1-2001 compliant? > The correct test is as follows: > > If the option constant is not defined, you really have no idea whether > the option is available or not. If the corresponding sysconf(3) key > *is* defined, then you might be able to use sysconf(3) or getconf(1) > to determine whether the option is supported. You will probably still > need to check for the headers and functions manually, because the > implementation is not being forthcoming and probably doesn't implement > the function even if sysconf() claims it does. Manual checking is no good. The only way to do that without relying on a feature test macro in FreeBSD is to nm the library, and look for the function symbols, or try linking a stub program, and check the exit status. FreeBSD has the prototypes, but doesn't have the code implementing the functions, which is where the probem started. It's a lot easier to check the macro: you don't have to write scripts to have portable source code. > If the option constant is defined as -1, the option is guaranteed not > to be supported, and the implementation provides neither the library > functions nor the header files necessary to compile a program which > makes use of the option. > > If the option constant is defined as a positive value, the option is > guaranteed to be supported under all configurations of the system. So the test is: #ifdef _POSIX_REALTIME_SIGNALS #if _POSIX_REALTIME_SIGNALS > 0 ...or, if you want to assume all preprocessors support "#if": #if defined(_POSIX_REALTIME_SIGNALS) && (_POSIX_REALTIME_SIGNALS > 0) I think the first is safer, in that if "#if" is not supported, it being an undefined preprocessor directive would be non-fatal, being in an uncompiled "#ifdef" block... > If the option constant is defined but zero, the option may or may not > be supported depending on run-time configuration. Library functions > and header files are supplied as described in the previous case, but > applications must call sysconf(3) with the appropriate key to > determine at run time whether the option is supported on the system as > currently configured. Out of curiosity, where in the standard does it say this about zero? > These rules have changed somewhat as the POSIX standards have evolved, > but this is the current state of affairs as set out in 1003.1-2001. > > Hope this helps. Yes, it clarifies things a lot. I wish you'd spoken up when he was originally asking how to perform the feature test at compile time (the sysconf(3) stuff for runtime support is pretty useless, IMO... you would fall back to not using the interface, I think, rather than put in a whole alternate set of code for it, with a whole alternate set of runtime overhead, which might add a bunch of compares to a "feature exists" flag). My posting was based on the information present in FreeBSD source files at the time the question was asked (and it's worked well, until -current defined it to be -1, without being otherwise fully compliant with POSIX 1003.1-2001, Grrrrr...). Would you recommend "#if", even though it meant the code would be less portable? The ACE framework is supposed to be portable to a lot of systems, some of which are running older compliers or not GNU C++. I'm positive that the first couple of years of the Oregon C++ compiler preprocessor didn't support "#if", for example. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 2:28:20 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7AA0A37B401 for ; Thu, 10 Oct 2002 02:28:19 -0700 (PDT) Received: from valu.uninet.ee (valu.uninet.ee [194.204.34.51]) by mx1.FreeBSD.org (Postfix) with ESMTP id CDB4843EAA for ; Thu, 10 Oct 2002 02:28:18 -0700 (PDT) (envelope-from taavi@uninet.ee) Received: by valu.uninet.ee (Postfix, from userid 1002) id CAB6836420; Thu, 10 Oct 2002 12:28:13 +0300 (EEST) Received: from localhost (localhost [127.0.0.1]) by valu.uninet.ee (Postfix) with ESMTP id C93C83261A; Thu, 10 Oct 2002 12:28:13 +0300 (EEST) Date: Thu, 10 Oct 2002 12:28:13 +0300 (EEST) From: Taavi Talvik To: Bruce M Simpson Cc: float@firedrake.org, David Gilbert , Neal Nelson , Subject: Re: [hackers] Writing a PCI ADSL Driver In-Reply-To: <20021010084237.GC25634@spc.org> Message-ID: <20021010121046.Q58931-100000@valu.uninet.ee> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, 10 Oct 2002, Bruce M Simpson wrote: > I'm sure that if we drive the 3060 as a NATM interface, we can write generic > netgraph code to attach to a link layer ATM interface and examine inbound > ATM UNI cells for their VPI*VCI and act accordingly. > > This will certainly require ngatm and is a good testing ground for that code. eni3060 can be configured to receive all unknown VC's on separately handled receive descriptor. Another issue is how to cleanly separate xDSL chipset handling from ATM SAR handling. For example both eni3060/3061 and 3com HomeConnect have alcatel chipset but different ATM sar's (eni - lanai, 3com - idt). xDSL handling could be common to both as code dealing with alcatel chipset is same. Same thing about configuring modem for different linecodes (G.dmt, G.lite, ANSI, etc). I looked at miibus, but that is not generic enough to be used here. best regards, taavi To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 3:47: 8 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A5A5D37B401; Thu, 10 Oct 2002 03:47:05 -0700 (PDT) Received: from bulwark.switch.com (bulwark.switch.com [206.181.77.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6EBC643EAC; Thu, 10 Oct 2002 03:47:01 -0700 (PDT) (envelope-from tnelson@switch.com) Received: from bulwark.switch.com (root@localhost) by bulwark.switch.com with ESMTP id g9AAl0aR025952; Thu, 10 Oct 2002 06:47:00 -0400 (EDT) Received: from isunix2.switch.com (isunix2.switch.com [199.234.168.6]) by bulwark.switch.com with ESMTP id g9AAl0kt025941; Thu, 10 Oct 2002 06:47:00 -0400 (EDT) Received: from exchptc1.switch.com ([199.234.168.10]) by isunix2.switch.com (PMDF V5.2-32 #37720) with ESMTP id <0H3R00GIXHYBC1@isunix2.switch.com>; Thu, 10 Oct 2002 06:46:59 -0400 (EDT) Received: by exchptc1.switch.com with Internet Mail Service (5.5.2653.19) id <4LCC13MW>; Thu, 10 Oct 2002 06:48:04 -0400 Content-return: allowed Date: Thu, 10 Oct 2002 06:48:03 -0400 From: "Nelson, Trent ." Subject: RE: FreeBSD usage in safety-critical environments To: "'Ted Faber'" , Terry Lambert Cc: "Nelson, Trent ." , "'hackers@freebsd.org'" , "'questions@freebsd.org'" Message-id: <8F329FEDF58BD411BE5200508B10DA7607D71A15@exchptc1.switch.com> MIME-version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-type: text/plain; charset="iso-8859-1" Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > -----Original Message----- > From: Ted Faber [mailto:faber@ISI.EDU] > Sent: Wednesday, October 09, 2002 10:59 PM > To: Terry Lambert > Cc: Nelson, Trent .; 'hackers@freebsd.org'; 'questions@freebsd.org' > Subject: Re: FreeBSD usage in safety-critical environments > > On Wed, Oct 09, 2002 at 12:26:14PM -0700, Terry Lambert wrote: > > Life support systems require formal proofs of correctness for code; > > since neither Linux nor FreeBSD is formally correct, in total, you > > would need to be insane to deplaoy either of them as, for example, > > a part of an air traffic control system. > > I suspect that's a bad example, or that you mean an embedded aircraft > control system. Ron Reisman and James Murphy gave a fine invited talk > at USENIX 02 (http://www.usenix.org/events/usenix02/tech/#11am) about > the growing number of UNIX components in the US ATC system. I reject > the conclusion that the FAA is collectively insane for that reason. I'd have to concur. I'm working on a large rail engineering project in the UK that is implementing a two-phased deployment of a Railway Control Centre System. The first phase will be using a combination of Tru64 UNIX and Linux systems, with an investigation being taken place for the second phase to move completely to Linux. There is a huge difference between systems rated at SIL 1 and 2 (which is what ATC/rail CCS would fall under) and those rated at 3 and 4. I was not referring to life-support or life-critical systems, as these will almost certainly be a proprietary hardware/software package that has been certified and accredited to a high level of safety integrity. What I was referring to were systems running on UNIX that control and interface to these safety-critical systems. For railway, Control Centres may suggest an erroneous route that would result in two trains colliding (although such a system will be commissioned on the basis that it wouldn't allow such a route to be suggested), but the 'vital', safety-critical interlocking would prevent such a route being set. The resulting safety-integrity level for the Control Centre would be SIL 2. The analogy between ATCs & embedded aircraft control systems isn't as tight as there isn't a physical interface between the two (well, at least as far as I know). The deployment of FreeBSD, or any BSD variant, (or ANYTHING other than Linux) in environments such as this, is what I was originally getting at. Oh, and Terry, I think you'd be astonished if I informed you of how many rail control systems in the US and around the world use either Linux or some of the commercial variants such as Tru64 UNIX or Solaris. > Ted Faber faber@isi.edu > USC/ISI Computer Scientist http://www.isi.edu/~faber > (310) 448-9190 PGP Keys: http://www.isi.edu/~faber/pubkeys.asc Regards, Trent. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 3:57:48 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B61EA37B401; Thu, 10 Oct 2002 03:57:45 -0700 (PDT) Received: from newnet.co.uk (newnet.co.uk [212.87.80.12]) by mx1.FreeBSD.org (Postfix) with ESMTP id D2F5D43E77; Thu, 10 Oct 2002 03:57:43 -0700 (PDT) (envelope-from jamie@jamiesdomain.org.uk) Received: from BONG (perry-gw-nat1-eth1.router.trident-uk.co.uk [81.3.89.49]) by newnet.co.uk (8.12.3/8.12.3) with SMTP id g9AAvDtS002552; Thu, 10 Oct 2002 11:57:13 +0100 (BST) (envelope-from jamie@jamiesdomain.org.uk) Message-ID: <009d01c2704b$ac662a70$3264a8c0@BONG> Reply-To: "Jamie Heckford" From: "Jamie Heckford" To: "Nelson, Trent ." , "'Ted Faber'" , "Terry Lambert" Cc: "'hackers@freebsd.org'" , "'questions@freebsd.org'" References: <8F329FEDF58BD411BE5200508B10DA7607D71A15@exchptc1.switch.com> Subject: Re: FreeBSD usage in safety-critical environments Date: Thu, 10 Oct 2002 11:56:22 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1106 X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 X-Newnet-MailScanner: Found to be clean Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hardly reassuring from all the recent train crashes really :P ----- Original Message ----- From: "Nelson, Trent ." To: "'Ted Faber'" ; "Terry Lambert" Cc: "Nelson, Trent ." ; "'hackers@freebsd.org'" ; "'questions@freebsd.org'" Sent: Thursday, October 10, 2002 11:48 AM Subject: RE: FreeBSD usage in safety-critical environments > > > > -----Original Message----- > > From: Ted Faber [mailto:faber@ISI.EDU] > > Sent: Wednesday, October 09, 2002 10:59 PM > > To: Terry Lambert > > Cc: Nelson, Trent .; 'hackers@freebsd.org'; 'questions@freebsd.org' > > Subject: Re: FreeBSD usage in safety-critical environments > > > > On Wed, Oct 09, 2002 at 12:26:14PM -0700, Terry Lambert wrote: > > > Life support systems require formal proofs of correctness for code; > > > since neither Linux nor FreeBSD is formally correct, in total, you > > > would need to be insane to deplaoy either of them as, for example, > > > a part of an air traffic control system. > > > > I suspect that's a bad example, or that you mean an embedded aircraft > > control system. Ron Reisman and James Murphy gave a fine invited talk > > at USENIX 02 (http://www.usenix.org/events/usenix02/tech/#11am) about > > the growing number of UNIX components in the US ATC system. I reject > > the conclusion that the FAA is collectively insane for that reason. > > I'd have to concur. I'm working on a large rail engineering project > in the UK that is implementing a two-phased deployment of a Railway Control > Centre System. The first phase will be using a combination of Tru64 UNIX > and Linux systems, with an investigation being taken place for the second > phase to move completely to Linux. > > There is a huge difference between systems rated at SIL 1 and 2 > (which is what ATC/rail CCS would fall under) and those rated at 3 and 4. I > was not referring to life-support or life-critical systems, as these will > almost certainly be a proprietary hardware/software package that has been > certified and accredited to a high level of safety integrity. What I was > referring to were systems running on UNIX that control and interface to > these safety-critical systems. > > For railway, Control Centres may suggest an erroneous route that > would result in two trains colliding (although such a system will be > commissioned on the basis that it wouldn't allow such a route to be > suggested), but the 'vital', safety-critical interlocking would prevent such > a route being set. The resulting safety-integrity level for the Control > Centre would be SIL 2. The analogy between ATCs & embedded aircraft control > systems isn't as tight as there isn't a physical interface between the two > (well, at least as far as I know). > > The deployment of FreeBSD, or any BSD variant, (or ANYTHING other > than Linux) in environments such as this, is what I was originally getting > at. > > Oh, and Terry, I think you'd be astonished if I informed you of how > many rail control systems in the US and around the world use either Linux or > some of the commercial variants such as Tru64 UNIX or Solaris. > > > Ted Faber faber@isi.edu > > USC/ISI Computer Scientist http://www.isi.edu/~faber > > (310) 448-9190 PGP Keys: http://www.isi.edu/~faber/pubkeys.asc > > Regards, > > Trent. > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message > -- ____________________________________________________ Message scanned for viruses and dangerous content by and believed to be clean To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 4:21:58 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 22D9B37B401; Thu, 10 Oct 2002 04:21:55 -0700 (PDT) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id CF9F143E9E; Thu, 10 Oct 2002 04:21:53 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id VAA08746; Thu, 10 Oct 2002 21:21:47 +1000 Date: Thu, 10 Oct 2002 21:31:56 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Craig Rodrigues Cc: freebsd-standards@FreeBSD.ORG, Subject: Re: Problem detecting POSIX symbolic constants In-Reply-To: <20021009232056.A10429@attbi.com> Message-ID: <20021010205529.M8598-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, 9 Oct 2002, Craig Rodrigues wrote: > On Wed, Oct 09, 2002 at 07:29:48PM -0700, Terry Lambert wrote: > > To be totally correct, you will need to: > > > > #ifdef _POSIX_REALTIME_SIGNALS > > #if (_POSIX_REALTIME_SIGNALS != -1) > > > > ... > > > > #endif > > #endif > > > > It's annoying, but doing this will ensure that there are no > > gaps through which some system other than FreeBSD might fall. In Standard C, this is equivalent to the non-verbose version: #if _POSIX_REALTIME_SIGNALS != -1 ... #endif since if _POSIX_REALTIME_SIGNALS is not defined then it is equivalent to 0 in cpp expressions. The problem cases are if _POSIX_REALTIME_SIGNALS is defined to or , but these are not permitted in POSIX.1-2001. These cases were permitted for many feature test macros in POSIX.1-1990. > Sigh. Why did the POSIX guys do this? :( Perhaps because they wanted you to use sysconf() instead of these mistakes. Actually, they didn't do this. _POSIX_REALTIME_SIGNALS is specified to have value 0, -1 or 200xxxL (draft 7 says xxx; I think the final standard says 112). > BTW, I think that: > #if defined(_POSIX_REALTIME_SIGNALS) && (_POSIX_REALTIME_SIGNALS != -1 ) > > should suffice, but I'll double-check with one of my portability gurus > to see if that is OK for ACE. This is variant of the above verbose version. It requires slightly more modern compilers, so it might fail for some 20-year old pre-Standard C compilers instead of only for some 25-year old ones. > I have another request. Even though my preprocessor check was bogus, > ACE still compiled, and I did not discover that there were any problems > until link time, ie. I had a libACE.so library which could not > link with anything because of unresolved symbols. This was very annoying. > It would have been nicer if this could have been caught earlier in the > compile stage. > Since sigqueue(), sigwait(), sigwaitinfo() are not implemented in FreeBSD, > is this patch OK? > > --- src/include/signal.h.orig Wed Oct 9 23:15:21 2002 > +++ src/include/signal.h Wed Oct 9 23:15:31 2002 > @@ -76,13 +76,6 @@ > int sigwait(const sigset_t *, int *); > #endif > > -#if __BSD_VISIBLE || __POSIX_VISIBLE >= 199506 || __XSI_VISIBLE >= 600 > -int sigqueue(__pid_t, int, const union sigval); > -int sigtimedwait(const sigset_t * __restrict, siginfo_t * __restrict, > - const struct timespec * __restrict); > -int sigwaitinfo(const sigset_t * __restrict, siginfo_t * __restrict); > -#endif > - > #if __BSD_VISIBLE || __POSIX_VISIBLE >= 200112 || __XSI_VISIBLE > int killpg(__pid_t, int); > int sigaltstack(const stack_t * __restrict, stack_t * __restrict); > > At some point in the future when POSIX RT signals are implemented > in FreeBSD (I'm not volunteering :), then > _POSIX_REALTIME_SIGNALS can be defined to 200112L in unistd.h, and > these three prototypes can be put back into . > > Is this OK? I used a variant your patch for this in PR 35924 until recently when I noticed that it usually worked for the bogus reason that is not included, then _POSIX_REALTIME_SIGNALS is only defined accidentally (to whatever value). I now use just #if 0 and an XXX comment as a reminder to fix this someday: %%% Index: signal.h =================================================================== RCS file: /home/ncvs/src/include/signal.h,v retrieving revision 1.19 diff -u -2 -r1.19 signal.h --- signal.h 6 Oct 2002 21:54:08 -0000 1.19 +++ signal.h 7 Oct 2002 07:06:19 -0000 @@ -78,9 +79,18 @@ #if __BSD_VISIBLE || __POSIX_VISIBLE >= 199506 || __XSI_VISIBLE >= 600 +#if 0 +/* + * PR: 35924 + * XXX we don't actually have these. We set _POSIX_REALTIME_SIGNALS to + * -1 to show that we don't have them, but this symbol is not necessarily + * in scope (in the current implementation), so we can't use it here. + */ int sigqueue(__pid_t, int, const union sigval); +struct timespec; int sigtimedwait(const sigset_t * __restrict, siginfo_t * __restrict, const struct timespec * __restrict); int sigwaitinfo(const sigset_t * __restrict, siginfo_t * __restrict); #endif +#endif #if __BSD_VISIBLE || __POSIX_VISIBLE >= 200112 || __XSI_VISIBLE %%% The patch also moves the forward declaration of struct timespec near to the one place that it is used (related patches not included). This mainly makes it obvious that the messy visibility for it is the same as the one for the function that uses it. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 5: 3:36 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id ACA0A37B401; Thu, 10 Oct 2002 05:03:34 -0700 (PDT) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id 98DA543E8A; Thu, 10 Oct 2002 05:03:33 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id WAA12387; Thu, 10 Oct 2002 22:03:28 +1000 Date: Thu, 10 Oct 2002 22:13:37 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Craig Rodrigues Cc: freebsd-standards@FreeBSD.ORG, Subject: Re: Problem detecting POSIX symbolic constants In-Reply-To: <20021009222307.A9894@attbi.com> Message-ID: <20021010213351.X8598-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, 9 Oct 2002, Craig Rodrigues wrote: > Earlier this year on the FreeBSD hackers mailing list: > http://docs.freebsd.org/cgi/getmsg.cgi?fetch=278142+0+/usr/local/www/db/text/2002/freebsd-hackers/20020317.freebsd-hackers > > I was advised by Terry Lambert to use: > #ifdef _POSIX_REALTIME_SIGNALS > > to detect if sigqueue(), sigtimedwait, sigwaitinfo() were defined. > > I made this change to the FreeBSD configuration for ACE, a C++ > library used for systems programming ( http://www.cs.wustl.edu/~schmidt/ACE.html ). > > The change I made worked fine in -STABLE. > However, in -CURRENT, this test breaks, because _POSIX_REALTIME_SIGNALS > is defined, but it is -1. > > According to the letter of the law: > http://www.opengroup.org/onlinepubs/007904975/basedefs/xbd_chap02.html > > "The following symbolic constants shall either be undefined or defined > with a value other than -1." This law only covers 2 symbols (_POSIX_CHOWN_RESTRICTED and _POSIX_NO_TRUNC). _POSIX_REALTIME_SIGNALS is covered by more general and complicated laws. It may be undefined or defined to 0, -1 or 2001mumbleL. > So, this is legal way to implement these macros. It just breaks my code. :) > > Can I appeal to the freebsd-standards team to leave these macros undefined > instead of defining them to -1? #ifdef/#ifndef is a pretty common way > to detect if a feature is available on a system, especially when used > in conjunction with something like autoconf. No. If they were undefined (and _POSIX_VERSION is large enough), then their undefinedness means that applications must use sysconf() to determine if they work. Other cases are simpler: _POSIX_REALTIME_SIGNALS is defined to -1: This means that the interface is not supported. Applications shouldn't use it at either compile time, link time or runtime, since it might not exist in headers or libraries. _POSIX_REALTIME_SIGNALS is defined to 0: This means that the interface may work, and that it exists in headers and libraries, so applications may reference it in normal ways. It may fail at runtime; applications must use sysconf() to determine if it is actually _POSIX_REALTIME_SIGNALS is defined to 2001mumbleL: This means that the interface just works. sysconf() may be used to check that it works, but sysconf() must not fail. _POSIX_REALTIME_SIGNALS is undefined: Apparently the same as when it is defined to 0, except you cannot assume that anything related to it works until you call sysconf(), so you must not reference its interfaces statically, and must use a dll or something that references it. The dll is presumably available on systems that support it but not (except possibly a dummy version) on systems that don't support it. I think the case where the symbol is undefined should never be implemented in practice. It can be reduced to the case where the symbol is 0 using dynamic linkage with the complications for linkage not visible to the application. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 5: 8:15 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 07FE937B407 for ; Thu, 10 Oct 2002 05:08:12 -0700 (PDT) Received: from nic.upatras.gr (nic.upatras.gr [150.140.129.30]) by mx1.FreeBSD.org (Postfix) with SMTP id 2344843EA3 for ; Thu, 10 Oct 2002 05:08:10 -0700 (PDT) (envelope-from keramida@ceid.upatras.gr) Received: (qmail 4100 invoked from network); 10 Oct 2002 12:01:10 -0000 Received: from upnet-dialinpool-103.upnet.gr (HELO hades.hell.gr) (@150.140.128.151) by nic.upatras.gr with SMTP; 10 Oct 2002 12:01:10 -0000 Received: from hades.hell.gr (hades [127.0.0.1]) by hades.hell.gr (8.12.6/8.12.6) with ESMTP id g9AC894w041390; Thu, 10 Oct 2002 15:08:11 +0300 (EEST) (envelope-from keramida@ceid.upatras.gr) Received: (from keramida@localhost) by hades.hell.gr (8.12.6/8.12.6/Submit) id g9ABOZjf036551; Thu, 10 Oct 2002 14:24:35 +0300 (EEST) (envelope-from keramida@ceid.upatras.gr) Date: Thu, 10 Oct 2002 14:24:34 +0300 From: Giorgos Keramidas To: Terry Lambert Cc: Garrett Wollman , Craig Rodrigues , freebsd-standards@freebsd.org, freebsd-hackers@freebsd.org Subject: Re: Problem detecting POSIX symbolic constants Message-ID: <20021010112434.GS21391@hades.hell.gr> References: <20021009222307.A9894@attbi.com> <200210100549.g9A5nFLn060516@khavrinen.lcs.mit.edu> <3DA5354F.9BB3E54B@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3DA5354F.9BB3E54B@mindspring.com> X-PGP-Fingerprint: C1EB 0653 DB8B A557 3829 00F9 D60F 941A 3186 03B6 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 2002-10-10 01:07, Terry Lambert wrote: > > So the test is: > > #ifdef _POSIX_REALTIME_SIGNALS > #if _POSIX_REALTIME_SIGNALS > 0 > > ...or, if you want to assume all preprocessors support "#if": > > #if defined(_POSIX_REALTIME_SIGNALS) && (_POSIX_REALTIME_SIGNALS > 0) > > I think the first is safer, in that if "#if" is not supported, it > being an undefined preprocessor directive would be non-fatal, > being in an uncompiled "#ifdef" block... Well, almost. There is one exception. A compiler that doesn't support #if but happens to run in an environment that has _POSIX_REALTIME_SIGNALS defined and equal to -1. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 6:30:28 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2F48237B407 for ; Thu, 10 Oct 2002 06:30:23 -0700 (PDT) Received: from mail.speakeasy.net (mail16.speakeasy.net [216.254.0.216]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9112D43EAC for ; Thu, 10 Oct 2002 06:30:20 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: (qmail 20062 invoked from network); 10 Oct 2002 13:30:20 -0000 Received: from unknown (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) by mail16.speakeasy.net (qmail-ldap-1.03) with DES-CBC3-SHA encrypted SMTP for ; 10 Oct 2002 13:30:20 -0000 Received: from laptop.baldwin.cx (laptop.baldwin.cx [192.168.0.4]) by server.baldwin.cx (8.12.6/8.12.6) with ESMTP id g9ADUIn5014559; Thu, 10 Oct 2002 09:30:18 -0400 (EDT) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.5.2 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <3DA46430.6080206@VanHoecke.org> Date: Thu, 10 Oct 2002 09:30:22 -0400 (EDT) From: John Baldwin To: Guido Van Hoecke Subject: Re: i-buddie Cc: freebsd-mobile@freebsd.org, Matthew Emmerton , freebsd-questions@freebsd.org, freebsd-hackers@freebsd.org, stefan@beke.sk Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 09-Oct-2002 Guido Van Hoecke wrote: > i4o beke wrote: >> Hi Guido. I've seen your question on freebsd-mobile, without answer. >> I'd like to buy i-buddie, 3c or 4. So your problems with setup are >> really interesting for me. >> Is your sis network card working? Is it possible to >> run XWin on i-buddie? Thank you for your answer. > > I am afraid I have had no luck with freebsd. My sis900 network card is > recognized but fails with a 'MII without any PHY!', and 3 more devices > are showing up as unknown: That I can't help you with, sorry. > pci0 2.7 is a sis7012 audio driver Sound isn't configured in teh default kernel. Try doing a 'kldload snd_driver' and seeing if pcm0 attaches to it. > pci0 5.0 is a conexant 56k modem Probably a win modem. There are some ports that might work with this. > pci0 7.0 ia a VIA OHCI Compliant IEEE1394 host controller This is firewire. Only supported in -current. > Further more, XF86 as available in freebsd 4.6.2-RELEASE #0 does not > recognize my lcd panel, so I can't run a desktop environment. Sometimes X has to be futzed with to work right. I had to add bogus horizontal and vertical refresh rates for X to work right on my laptop. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 7:58:11 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 31CEB37B40A; Thu, 10 Oct 2002 07:58:01 -0700 (PDT) Received: from dibbler.ne.client2.attbi.com (dibbler.ne.client2.attbi.com [24.61.41.247]) by mx1.FreeBSD.org (Postfix) with ESMTP id 921A34433D; Thu, 10 Oct 2002 07:55:28 -0700 (PDT) (envelope-from rodrigc@attbi.com) Received: from dibbler.ne.client2.attbi.com (localhost.ne.attbi.com [127.0.0.1]) by dibbler.ne.client2.attbi.com (8.12.6/8.12.5) with ESMTP id g9AEtWCK012415; Thu, 10 Oct 2002 10:55:32 -0400 (EDT) (envelope-from rodrigc@dibbler.ne.client2.attbi.com) Received: (from rodrigc@localhost) by dibbler.ne.client2.attbi.com (8.12.6/8.12.6/Submit) id g9AEtVHC012414; Thu, 10 Oct 2002 10:55:31 -0400 (EDT) Date: Thu, 10 Oct 2002 10:55:31 -0400 From: Craig Rodrigues To: freebsd-standards@freebsd.org Cc: freebsd-hackers@freebsd.org Subject: Re: Problem detecting POSIX symbolic constants Message-ID: <20021010105531.A12354@attbi.com> References: <20021009232056.A10429@attbi.com> <20021010205529.M8598-100000@gamplex.bde.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <20021010205529.M8598-100000@gamplex.bde.org>; from bde@zeta.org.au on Thu, Oct 10, 2002 at 09:31:56PM +1000 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Oct 10, 2002 at 09:31:56PM +1000, Bruce Evans wrote: > Perhaps because they wanted you to use sysconf() instead of these mistakes. Well in the case of ACE, it is a C++ library that is compiled on platforms which may or may not have sysconf() (ie. Windows), so using sysconf() is not practical in this case. Checking a feature macro is much easier. > > This is variant of the above verbose version. It requires slightly more > modern compilers, so it might fail for some 20-year old pre-Standard C > compilers instead of only for some 25-year old ones. ACE makes some pretty aggressive use of C++ features, so luckily compliance with 20-25 year old compilers is not a requirement. :) Support for gcc 2.7.2 and 2.8 compilers was dropped recently. It will be really exciting to use ACE on FreeBSD 5.x since gcc 3.2.1 has some fairly good support for modern C++ features. > I used a variant your patch for this in PR 35924 until recently when Wow, I forgot that I filed 35924! :) Thanks for reminding me. > I noticed that it usually worked for the bogus reason that > is not included, then _POSIX_REALTIME_SIGNALS is only defined accidentally > (to whatever value). I now use just #if 0 and an XXX comment as a > reminder to fix this someday: > > %%% > Index: signal.h > =================================================================== > RCS file: /home/ncvs/src/include/signal.h,v > retrieving revision 1.19 > diff -u -2 -r1.19 signal.h > --- signal.h 6 Oct 2002 21:54:08 -0000 1.19 > +++ signal.h 7 Oct 2002 07:06:19 -0000 > @@ -78,9 +79,18 @@ > > #if __BSD_VISIBLE || __POSIX_VISIBLE >= 199506 || __XSI_VISIBLE >= 600 > +#if 0 > +/* > + * PR: 35924 > + * XXX we don't actually have these. We set _POSIX_REALTIME_SIGNALS to > + * -1 to show that we don't have them, but this symbol is not necessarily > + * in scope (in the current implementation), so we can't use it here. > + */ > int sigqueue(__pid_t, int, const union sigval); > +struct timespec; > int sigtimedwait(const sigset_t * __restrict, siginfo_t * __restrict, > const struct timespec * __restrict); > int sigwaitinfo(const sigset_t * __restrict, siginfo_t * __restrict); > #endif > +#endif > > #if __BSD_VISIBLE || __POSIX_VISIBLE >= 200112 || __XSI_VISIBLE > %%% > > The patch also moves the forward declaration of struct timespec near to > the one place that it is used (related patches not included). This > mainly makes it obvious that the messy visibility for it is the same > as the one for the function that uses it. This patch works for me. I think it is just as easy to just remove cruft from the header file entirely, but since your patch effectively does the same thing and has informative comments, that is fine. If your patch (or some equivalent variant) is committed, then I think PR 35924 can be closed. Something needs to be done about these prototypes. Thanks. -- Craig Rodrigues http://www.gis.net/~craigr rodrigc@attbi.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 9: 5:56 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C7C2537B401 for ; Thu, 10 Oct 2002 09:05:54 -0700 (PDT) Received: from ns1.ovis.net (ns1.ovis.net [207.0.147.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4609943E77 for ; Thu, 10 Oct 2002 09:05:54 -0700 (PDT) (envelope-from chromexa@ovis.net) Received: from ovis.net (s43.pm5.ovis.net [207.0.147.109]) by ns1.ovis.net (Postfix) with ESMTP id C00DE3B43; Thu, 10 Oct 2002 12:05:45 -0400 (EDT) Message-ID: <3DA5A764.68AA7199@ovis.net> Date: Thu, 10 Oct 2002 12:14:28 -0400 From: Steve Kudlak Reply-To: chromexa@ovis.net X-Mailer: Mozilla 4.5 [en]C-CCK-MCD ezn/58/n (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: "Roman V. Mashak" , "'hackers@freebsd.org'" , "Nelson, Trent ." Subject: C-2(Security) blues and the like Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG It has been a long time since I dealt with those arcane security matters. At least they are obscure and arcane to most people. Many consider me to be babbling when I go on about these things. If I start saying "rainbow books" (the NSA's security books are in different colors) many people assume that I am crazy.:) Most of the stuff I did involved C-2 security and all the logging and authentication stuff. An assumption seems to have been made that "logging in" via ftp was the same as logging in via tty or machine. This is not so. The ftp code "establishes a user" the login code gets the user a shell and all that. For awhile in some OSes with C-2 security if one was going to mount a dictionary attack on some user or ever root, ftp would have been away to go. It would allow one a large amount of attacks with logging. One would definitely get more than 3 attempts to "login". It was a way around C-2 security and was in my opinion a pretty serious compromise. Logging ftp "logins" and ftp use were proposed fixes. I just had to find the problems not fix them. Hmmm...maybe I will post this to BSD hackers and if someone says it is off topic I will shut up. Perhaps I should as this info is kind of old. But the important to watch for these little back door tricks. Note I have not as of late read the FreeBSD ftp code. Perhaps I should. Have Fun, Sends Steve To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 9:45:26 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D5E2837B401 for ; Thu, 10 Oct 2002 09:45:24 -0700 (PDT) Received: from scribble.fsn.hu (scribble.fsn.hu [193.224.40.95]) by mx1.FreeBSD.org (Postfix) with SMTP id 0590243EB3 for ; Thu, 10 Oct 2002 09:45:21 -0700 (PDT) (envelope-from bra@fsn.hu) Received: (qmail 27187 invoked by uid 1000); 10 Oct 2002 16:45:22 -0000 Received: from localhost (sendmail-bs@127.0.0.1) by localhost with SMTP; 10 Oct 2002 16:45:22 -0000 Date: Thu, 10 Oct 2002 18:45:22 +0200 (CEST) From: Attila Nagy To: hackers@freebsd.org Subject: Sharing a SCSI bus between some computers Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hello, Due to the lack of enough "networking power" I started to think about alternatives. I would like to ask your thoughts on the following setup: +----------+ +----------+ +----------+ + BOX1 +-------+ SCSI BOX +------+ BOX2 + +----------+ +----++----+ +----------+ || +----++----+ + BOX3 + +----------+ BOX[1-3] would be a PC with a SCSI adapter. SCSI BOX is an external SCSI RAID array. The line between the boxes is a single SCSI cable, on which the devices access the bus (it would be a correct chain, with a terminator on each end). The question is: what will happen if BOX3 mounts the filesystem from the SCSI BOX RW and BOX[1-2] mount it RO? In the case BOX[1-2] it is only necessary to read from the array, nothing more. I've seen a similar setup on Sun hardware, where the disk array was used by two computers. RW/RO, as in this case. Does anybody have experiences regarding this? Is it possible/necessary to hack some kind of locking into the SCSI driver? The adapters are made by Adaptec (aic7xxx). Thanks, ----------[ Free Software ISOs - http://www.fsn.hu/?f=download ]---------- Attila Nagy e-mail: Attila.Nagy@fsn.hu Free Software Network (FSN.HU) phone @work: +361 210 1415 (194) cell.: +3630 306 6758 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 10:28:39 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1EE9137B401 for ; Thu, 10 Oct 2002 10:28:38 -0700 (PDT) Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7CF9943EA9 for ; Thu, 10 Oct 2002 10:28:36 -0700 (PDT) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.12.6/8.12.5) id g9AHSa37027306; Thu, 10 Oct 2002 12:28:36 -0500 (CDT) (envelope-from dan) Date: Thu, 10 Oct 2002 12:28:35 -0500 From: Dan Nelson To: Attila Nagy Cc: hackers@FreeBSD.ORG Subject: Re: Sharing a SCSI bus between some computers Message-ID: <20021010172835.GA24603@dan.emsphone.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-OS: FreeBSD 5.0-CURRENT X-message-flag: Outlook Error User-Agent: Mutt/1.5.1i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In the last episode (Oct 10), Attila Nagy said: > Due to the lack of enough "networking power" I started to think about > alternatives. > [ snip pic of SCSI RAID with 3 servers hanging off it ] > > The question is: what will happen if BOX3 mounts the filesystem from > the SCSI BOX RW and BOX[1-2] mount it RO? > > In the case BOX[1-2] it is only necessary to read from the array, > nothing more. As long as BOX3 never writes data, you're okay. The problem is that BOX1/2 don't know when BOX3 has invalidated their cached data by writing to the disk. What you want is a shared-storage filesystem, and there is no such thing for FreeBSD. Considering you can get a gigabit ethernet NIC for under $50 and a D-Link 4-port gigabit switch for $300, you might just want to plug the RAID into BOX3, and have BOX1/2 NFS-mount it. -- Dan Nelson dnelson@allantgroup.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 10:35:42 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B558D37B401 for ; Thu, 10 Oct 2002 10:35:41 -0700 (PDT) Received: from kali.avantgo.com (shadow.avantgo.com [64.157.226.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id 75C5A43E9C for ; Thu, 10 Oct 2002 10:35:41 -0700 (PDT) (envelope-from scott@avantgo.com) Received: from river.avantgo.com ([10.11.30.114]) by kali.avantgo.com with Microsoft SMTPSVC(5.0.2195.3779); Thu, 10 Oct 2002 10:35:36 -0700 Date: Thu, 10 Oct 2002 10:35:31 -0700 (PDT) From: Scott Hess To: freebsd-hackers@FreeBSD.ORG Subject: Re: Mount option "nomtime"? In-Reply-To: <200210100600.g9A60xiX034084@lurza.secnetix.de> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-OriginalArrivalTime: 10 Oct 2002 17:35:36.0407 (UTC) FILETIME=[7152BE70:01C27083] Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, 10 Oct 2002, Oliver Fromme wrote: > Wolfieee wrote: > > what about vnconfiging some files on the netapp thing, this way the > > *bsd can see the vnconfig files as local raw disk partitions? > > That wouldn't make a difference, because the NetApp Filer would still > schedule mtime updates for evey write access to the file that has been > vnconfiged on the client. Probably talking through my hat, here, but doesn't NetApp use a LFS (log-structured file system) variant? It's been a couple years since we got ours, but at the time I reviewed it for use as a central database filesystem. I'm pretty sure it used an LFS, partially because of the sweet RAID-write semantics - basically, you never have to read-modify-write to deal with the parity update, you simply generate an entire chunk worth of data in NVRAM, and write it all at once, with parity. In any case, assuming that I got the analysis right, that means the mtime update should be essentially free, since it's already going to be writing a new inode for the file to capture any new blocks written. http://www.netapp.com/tech_library/3001.html#I4, also note the Ousterhout reference in the bibliography. An even stronger indicator is at http://www.netapp.com/tech_library/3002.html#I35. Later, scott To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 11:50:13 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 41E2737B401 for ; Thu, 10 Oct 2002 11:50:12 -0700 (PDT) Received: from mailhost.nxad.com (lan.ext.nxad.com [66.250.180.254]) by mx1.FreeBSD.org (Postfix) with ESMTP id F093243EB3 for ; Thu, 10 Oct 2002 11:50:11 -0700 (PDT) (envelope-from sean@nxad.com) Received: from perrin.int.nxad.com (perrin.int.nxad.com [192.168.1.251]) by mailhost.nxad.com (Postfix) with ESMTP id 34F20212F00 for ; Thu, 10 Oct 2002 11:50:11 -0700 (PDT) Received: by perrin.int.nxad.com (Postfix, from userid 1001) id C23EE20F01; Thu, 10 Oct 2002 11:50:10 -0700 (PDT) Date: Thu, 10 Oct 2002 11:50:10 -0700 From: Sean Chittenden To: hackers@freebsd.org Subject: Porting work on sigcontext from linux to BSD... Message-ID: <20021010185010.GZ56492@perrin.int.nxad.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4i X-PGP-Key: finger seanc@FreeBSD.org X-PGP-Fingerprint: 6CEB 1B06 BFD3 70F6 95BE 7E4D 8E85 2E0A 5F5B 3ECB X-Web-Homepage: http://sean.chittenden.org/ Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I'm by no means a kernel guy and don't really pretend to be one, but I'm certainly willing to learn given some simple docs. I'm trying to port the bigforth forth compiler to FreeBSD and am having a miserable time doing so because bigforth isn't written in a very generic way. That said, I'm having some impedance issues when trying to simply map lenux's sigcontext struct (asm/sigcontext.h) to FreeBSD's sigcontext struct (machine/signal.h). Specifically, I'm stumped on what esp_at_signal is for and what the equiv of BSD's is. It's not sc_esp since that maps over nicely. Any help or files that I could look at that'd give me some clue as to what it is that I'm playing with and how to use/map this data structure? On a related, but different note, is there any value in having the data members of sigcontext be unsigned long vs just ints? So far as I can tell they're just wasting space, but I could be very wrong. -sc -- Sean Chittenden To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 12:25:45 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 92C3B37B401; Thu, 10 Oct 2002 12:25:44 -0700 (PDT) Received: from conure.mail.pas.earthlink.net (conure.mail.pas.earthlink.net [207.217.120.54]) by mx1.FreeBSD.org (Postfix) with ESMTP id E746143EB3; Thu, 10 Oct 2002 12:25:43 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0397.cvx21-bradley.dialup.earthlink.net ([209.179.193.142] helo=mindspring.com) by conure.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17ziw5-0005MH-00; Thu, 10 Oct 2002 12:25:30 -0700 Message-ID: <3DA5D3E2.B09326DD@mindspring.com> Date: Thu, 10 Oct 2002 12:24:18 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: "Nelson, Trent ." Cc: 'Ted Faber' , "'hackers@freebsd.org'" , "'questions@freebsd.org'" Subject: Re: FreeBSD usage in safety-critical environments References: <8F329FEDF58BD411BE5200508B10DA7607D71A15@exchptc1.switch.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG "Nelson, Trent ." wrote: > Oh, and Terry, I think you'd be astonished if I informed you of how > many rail control systems in the US and around the world use either Linux or > some of the commercial variants such as Tru64 UNIX or Solaris. I rather think they run Solaris. Earlier in my career (late 1980's), I worked on the system that was used for the console for the G.E. Medical Systems NMR's (now called MRI). I also worked on the control system for a blood-gas analyzer. I guess things are different in the U.K.. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 12:28:45 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 49CD737B401; Thu, 10 Oct 2002 12:28:44 -0700 (PDT) Received: from conure.mail.pas.earthlink.net (conure.mail.pas.earthlink.net [207.217.120.54]) by mx1.FreeBSD.org (Postfix) with ESMTP id F1E1143E4A; Thu, 10 Oct 2002 12:28:43 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0397.cvx21-bradley.dialup.earthlink.net ([209.179.193.142] helo=mindspring.com) by conure.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17ziyR-0001f6-00; Thu, 10 Oct 2002 12:27:55 -0700 Message-ID: <3DA5D473.21A43EDD@mindspring.com> Date: Thu, 10 Oct 2002 12:26:43 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Giorgos Keramidas Cc: Garrett Wollman , Craig Rodrigues , freebsd-standards@freebsd.org, freebsd-hackers@freebsd.org Subject: Re: Problem detecting POSIX symbolic constants References: <20021009222307.A9894@attbi.com> <200210100549.g9A5nFLn060516@khavrinen.lcs.mit.edu> <3DA5354F.9BB3E54B@mindspring.com> <20021010112434.GS21391@hades.hell.gr> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Giorgos Keramidas wrote: > > I think the first is safer, in that if "#if" is not supported, it > > being an undefined preprocessor directive would be non-fatal, > > being in an uncompiled "#ifdef" block... > > Well, almost. There is one exception. A compiler that doesn't support > #if but happens to run in an environment that has _POSIX_REALTIME_SIGNALS > defined and equal to -1. You can always wrap the whole thing with a POSIX test, which would dictate the preprocessor support, as well, I think. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 12:33:35 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 14F2D37B401; Thu, 10 Oct 2002 12:33:34 -0700 (PDT) Received: from conure.mail.pas.earthlink.net (conure.mail.pas.earthlink.net [207.217.120.54]) by mx1.FreeBSD.org (Postfix) with ESMTP id A638C43E97; Thu, 10 Oct 2002 12:33:33 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0397.cvx21-bradley.dialup.earthlink.net ([209.179.193.142] helo=mindspring.com) by conure.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zj3k-00034J-00; Thu, 10 Oct 2002 12:33:25 -0700 Message-ID: <3DA5D5BD.1DAFF031@mindspring.com> Date: Thu, 10 Oct 2002 12:32:13 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Bruce Evans Cc: Craig Rodrigues , freebsd-standards@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG Subject: Re: Problem detecting POSIX symbolic constants References: <20021010205529.M8598-100000@gamplex.bde.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bruce Evans wrote: > In Standard C, this is equivalent to the non-verbose version: > > #if _POSIX_REALTIME_SIGNALS != -1 > ... > #endif > > since if _POSIX_REALTIME_SIGNALS is not defined then it is equivalent to > 0 in cpp expressions. The problem cases are if _POSIX_REALTIME_SIGNALS > is defined to or , but these are not permitted in > POSIX.1-2001. These cases were permitted for many feature test macros > in POSIX.1-1990. I know it's not fashionable to write code that's portable to compilers other than GCC, but even if FreeBSD is going to ignore portability for it's own source code, it's probably unreasonable to expect ACE to ignore portability for theirs. > > Sigh. Why did the POSIX guys do this? :( > > Perhaps because they wanted you to use sysconf() instead of these mistakes. > Actually, they didn't do this. _POSIX_REALTIME_SIGNALS is specified to > have value 0, -1 or 200xxxL (draft 7 says xxx; I think the final standard > says 112). This can't be the case; specifically, the sysconf() test will only work at runtime, which means that the symbols had to be there and resolvable at link time. Unless you know some preprocessor directive to access the "sysconf" space? > > BTW, I think that: > > #if defined(_POSIX_REALTIME_SIGNALS) && (_POSIX_REALTIME_SIGNALS != -1 ) > > > > should suffice, but I'll double-check with one of my portability gurus > > to see if that is OK for ACE. > > This is variant of the above verbose version. It requires slightly more > modern compilers, so it might fail for some 20-year old pre-Standard C > compilers instead of only for some 25-year old ones. Uh, the 1990 standard, which allowed "#if" is only 12 years old. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 12:39:59 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EDFAE37B401; Thu, 10 Oct 2002 12:39:57 -0700 (PDT) Received: from conure.mail.pas.earthlink.net (conure.mail.pas.earthlink.net [207.217.120.54]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7DA6D43E9E; Thu, 10 Oct 2002 12:39:57 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0397.cvx21-bradley.dialup.earthlink.net ([209.179.193.142] helo=mindspring.com) by conure.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zjA0-00067e-00; Thu, 10 Oct 2002 12:39:53 -0700 Message-ID: <3DA5D741.FB59AE1B@mindspring.com> Date: Thu, 10 Oct 2002 12:38:41 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Bruce Evans Cc: Craig Rodrigues , freebsd-standards@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG Subject: Re: Problem detecting POSIX symbolic constants References: <20021010213351.X8598-100000@gamplex.bde.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bruce Evans wrote: > _POSIX_REALTIME_SIGNALS is defined to 0: > This means that the interface may work, and that it exists in headers and > libraries, so applications may reference it in normal ways. It may fail > at runtime; applications must use sysconf() to determine if it is actually Alternately, they can say "Screw you, OS designer!" and use it as if it were "-1", so that they don't have to add all sorts of runtime garbage to their programs, with multiple alternate code paths, etc.. Makes for much more readable code. > _POSIX_REALTIME_SIGNALS is undefined: > Apparently the same as when it is defined to 0, except you cannot assume > that anything related to it works until you call sysconf(), so you must > not reference its interfaces statically, and must use a dll or something > that references it. The dll is presumably available on systems that > support it but not (except possibly a dummy version) on systems that > don't support it. > > I think the case where the symbol is undefined should never be implemented > in practice. It can be reduced to the case where the symbol is 0 using > dynamic linkage with the complications for linkage not visible to the > application. I think you will have to go back in time, for this to happen. As things stand today, there are systems where it's undefined that were implemented before the symbol was a twinkle in some feature-test weenie on the POSIX committee's eye. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 13: 8: 6 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 76CC137B401 for ; Thu, 10 Oct 2002 13:08:05 -0700 (PDT) Received: from swan.mail.pas.earthlink.net (swan.mail.pas.earthlink.net [207.217.120.123]) by mx1.FreeBSD.org (Postfix) with ESMTP id F16A343EB7 for ; Thu, 10 Oct 2002 13:08:04 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0397.cvx21-bradley.dialup.earthlink.net ([209.179.193.142] helo=mindspring.com) by swan.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zjbE-0002sP-00; Thu, 10 Oct 2002 13:08:00 -0700 Message-ID: <3DA5DDD8.3864BDCB@mindspring.com> Date: Thu, 10 Oct 2002 13:06:48 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Scott Hess Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Mount option "nomtime"? References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Scott Hess wrote: > > That wouldn't make a difference, because the NetApp Filer would still > > schedule mtime updates for evey write access to the file that has been > > vnconfiged on the client. > > Probably talking through my hat, here, but doesn't NetApp use a LFS > (log-structured file system) variant? Almost. It's called WAFL, for "Write Anywhere File Layout". > In any case, assuming that I got the analysis right, that means the mtime > update should be essentially free, since it's already going to be writing > a new inode for the file to capture any new blocks written. Nope. The cost is not free. > http://www.netapp.com/tech_library/3001.html#I4, also note the Ousterhout > reference in the bibliography. An even stronger indicator is at > http://www.netapp.com/tech_library/3002.html#I35. Heh. You need to read your own references. 8-). -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 14:31:39 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0B71237B401 for ; Thu, 10 Oct 2002 14:31:38 -0700 (PDT) Received: from mail1.informationwave.net (dipole.informationwave.net [199.74.235.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id B6F1443EB7 for ; Thu, 10 Oct 2002 14:31:37 -0700 (PDT) (envelope-from abe@informationwave.net) Received: by mail1.informationwave.net (Postfix, from userid 1007) id BC9A04F917; Thu, 10 Oct 2002 17:29:54 -0400 (EDT) Date: Thu, 10 Oct 2002 17:29:54 -0400 From: abe To: hackers@freebsd.org Subject: fatal trap 12 kernel panic Message-ID: <20021010212954.GA67855@dipole.informationwave.net> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="qDbXVdCdHGoSgWSk" Content-Disposition: inline User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --qDbXVdCdHGoSgWSk Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi, I've written to the questions list recently with regard to a panic that keeps occuring and perhaps my message was not formatted as well as it could have been. In more testing it seems that the minute the ipfw rules are loaded (which previously worked without issue), the machine panics. Any network connectivity attempted afterwards results in a panic. This includes ping, telnet, smtp, etc. When the machine panics, it drops into the debugger and displays the following: Stopped at add_dyn_rule+0172: movl 0(%edx,%ebx,4)x%eax I am including the entire 'trace' output from the debugger, but have also tried to produce a core to get a backtrace via gdb however it doesn't seem to be dumping a core. savecore="YES" as well as dumpdir and dumpdev are set properly in rc.conf, yet nothing is produced and the system claims no dumpdev is set. If anyone has any experience with this issue, as I believe it to be with ipfw due to lengthy testing on 4 different machines now (was 3 before), please feel free to email me and clue me in. Thanks a lot. Regards, Abe --qDbXVdCdHGoSgWSk Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="trace.txt" add_dyn_rule(c0424894,0,c1258e00) at add_dyn_rule+0x172 install_state(c1258e00) at install_state+0x179 ip_fw_chk(cc88cda4,14,c1153000,cc88cdaa,cc88cdac) at ip_fw_chk+0x8d8 ip_output(c0e63800,0,cbafad7c,0,0) at ip_output+0x530 udp_output(cbafad40,c0e63800,0,0,cb69ba40) at udp_output+0x238 udp_send(cbac8980,0,c0e63800,0,0) at udp_send+0x20 sosend(cbac8980,0,cc88cecc,c0e63800,0) at sosend+0x5df sendit(cb69ba40,5,cc88cf0c,0,bfbfeb2b) at sendit+0x253 sendto(cb69ba40,cc88cf80,1b,bfbff400,0) at sendto+0x4e syscall2(2f,2f,2f,0,bfbff400) at syscall2+0x1f5 Xint0x80_syscall() at Xint0x80_syscall+0x25 --qDbXVdCdHGoSgWSk-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 14:32:37 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1BDEA37B401 for ; Thu, 10 Oct 2002 14:32:37 -0700 (PDT) Received: from relay03.cablecom.net (relay03.cablecom.net [62.2.33.103]) by mx1.FreeBSD.org (Postfix) with ESMTP id 33AD343EC5 for ; Thu, 10 Oct 2002 14:32:36 -0700 (PDT) (envelope-from hanspeter_roth@hotmail.com) Received: from localhost.there (dclient80-218-74-198.hispeed.ch [80.218.74.198]) by relay03.cablecom.net (8.12.5/8.12.5/SOL/AWF/MXRELAY/20020820) with ESMTP id g9ALWYMO086275 for ; Thu, 10 Oct 2002 23:32:34 +0200 (CEST) (envelope-from hanspeter_roth@hotmail.com) Received: (from idefix@localhost) by localhost.there (8.11.3nb1/8.11.3) id g9ALWh304279 for freebsd-hackers@FreeBSD.ORG; Thu, 10 Oct 2002 23:32:43 +0200 (CEST) Date: Thu, 10 Oct 2002 23:32:43 +0200 From: Hanspeter Roth To: freebsd-hackers@FreeBSD.ORG Subject: Sil 0648/0649/0680 supporting DMA for ATAPI? Message-ID: <20021010233242.A4251@gicco.cablecom.ch> Reply-To: freebsd-hackers@FreeBSD.ORG Mail-Followup-To: freebsd-hackers@FreeBSD.ORG References: <000001c26c6b$f7bacc30$da8ea392@zeus> <200210051305.g95D5rUx020852@spider.deepcore.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <200210051305.g95D5rUx020852@spider.deepcore.dk>; from sos@spider.deepcore.dk on Sat, Oct 05, 2002 at 03:05:53PM +0200 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Oct 05 at 15:05, Soeren Schmidt spoke: > Too late, I've already added support for the Sil 0680 chip in both > -current and -stable. BTW it was not supported before that (not even Does any of the Sil 0648/0649/0680 support DMA for ATAPI devices, particularly for Plextor CD-R PX-W4012A? -Hanspeter To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 14:41:39 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BD30737B443 for ; Thu, 10 Oct 2002 14:41:36 -0700 (PDT) Received: from avocet.mail.pas.earthlink.net (avocet.mail.pas.earthlink.net [207.217.120.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 51D8843ED8 for ; Thu, 10 Oct 2002 14:41:36 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0397.cvx21-bradley.dialup.earthlink.net ([209.179.193.142] helo=mindspring.com) by avocet.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zl3l-0004kH-00; Thu, 10 Oct 2002 14:41:33 -0700 Message-ID: <3DA5F3BC.CD0154CF@mindspring.com> Date: Thu, 10 Oct 2002 14:40:12 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: abe Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic References: <20021010212954.GA67855@dipole.informationwave.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG abe wrote: > I've written to the questions list recently with regard to a > panic that keeps occuring and perhaps my message was not formatted > as well as it could have been. In more testing it seems that the > minute the ipfw rules are loaded (which previously worked without > issue), the machine panics. Any network connectivity attempted > afterwards results in a panic. This includes ping, telnet, smtp, > etc. When the machine panics, it drops into the debugger and > displays the following: > > Stopped at add_dyn_rule+0172: movl 0(%edx,%ebx,4)x%eax Sounds like you rebuilt your kernel, but did not rebuild your kernel modules, and now you are loading an old module into a new kernel. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 14:45:59 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6E09437B401 for ; Thu, 10 Oct 2002 14:45:57 -0700 (PDT) Received: from mail1.informationwave.net (dipole.informationwave.net [199.74.235.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0BD8343EDE for ; Thu, 10 Oct 2002 14:45:57 -0700 (PDT) (envelope-from abe@informationwave.net) Received: by mail1.informationwave.net (Postfix, from userid 1007) id A31394F917; Thu, 10 Oct 2002 17:44:13 -0400 (EDT) Date: Thu, 10 Oct 2002 17:44:13 -0400 From: abe To: Luigi Rizzo Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic Message-ID: <20021010214413.GA71656@dipole.informationwave.net> References: <20021010212954.GA67855@dipole.informationwave.net> <20021010143948.B65814@carp.icir.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20021010143948.B65814@carp.icir.org> User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi Luigi, Pardon, been a hectic week. Heh. I've tried this on fresh installs of 4.5-rel, 4.5-rel-p20, 4.6.2-p2, and 4.7-RC. On Thu, Oct 10, 2002 at 02:39:48PM -0700, Luigi Rizzo wrote: > what freebsd version are you using, are you using compiled-in ipfw or > a module ? > > cheers > luigi > > On Thu, Oct 10, 2002 at 05:29:54PM -0400, abe wrote: > > Hi, > > > > I've written to the questions list recently with regard to a panic that keeps occuring > > and perhaps my message was not formatted as well as it could have been. In more testing > > it seems that the minute the ipfw rules are loaded (which previously worked without issue), > > the machine panics. Any network connectivity attempted afterwards results in a panic. > > This includes ping, telnet, smtp, etc. When the machine panics, it drops into the debugger > > and displays the following: > > > > Stopped at add_dyn_rule+0172: movl 0(%edx,%ebx,4)x%eax > > > > I am including the entire 'trace' output from the debugger, but have also tried to > > produce a core to get a backtrace via gdb however it doesn't seem to be dumping a core. > > savecore="YES" as well as dumpdir and dumpdev are set properly in rc.conf, yet nothing > > is produced and the system claims no dumpdev is set. > > > > If anyone has any experience with this issue, as I believe it to be with ipfw due to > > lengthy testing on 4 different machines now (was 3 before), please feel free to email me > > and clue me in. Thanks a lot. > > > > Regards, > > > > Abe > > > > > add_dyn_rule(c0424894,0,c1258e00) at add_dyn_rule+0x172 > > install_state(c1258e00) at install_state+0x179 > > ip_fw_chk(cc88cda4,14,c1153000,cc88cdaa,cc88cdac) at ip_fw_chk+0x8d8 > > ip_output(c0e63800,0,cbafad7c,0,0) at ip_output+0x530 > > udp_output(cbafad40,c0e63800,0,0,cb69ba40) at udp_output+0x238 > > udp_send(cbac8980,0,c0e63800,0,0) at udp_send+0x20 > > sosend(cbac8980,0,cc88cecc,c0e63800,0) at sosend+0x5df > > sendit(cb69ba40,5,cc88cf0c,0,bfbfeb2b) at sendit+0x253 > > sendto(cb69ba40,cc88cf80,1b,bfbff400,0) at sendto+0x4e > > syscall2(2f,2f,2f,0,bfbff400) at syscall2+0x1f5 > > Xint0x80_syscall() at Xint0x80_syscall+0x25 > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 14:47: 2 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B47D337B401 for ; Thu, 10 Oct 2002 14:47:01 -0700 (PDT) Received: from mail1.informationwave.net (dipole.informationwave.net [199.74.235.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4A78343EE1 for ; Thu, 10 Oct 2002 14:47:01 -0700 (PDT) (envelope-from abe@informationwave.net) Received: by mail1.informationwave.net (Postfix, from userid 1007) id 822294F917; Thu, 10 Oct 2002 17:45:18 -0400 (EDT) Date: Thu, 10 Oct 2002 17:45:18 -0400 From: abe To: Terry Lambert Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic Message-ID: <20021010214518.GB71656@dipole.informationwave.net> References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3DA5F3BC.CD0154CF@mindspring.com> User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi Terry, This started out as a sudden panic on a machine that was in a datacenter for more than 8 months without issue. Then I installed on fresh machines, compiled in ipfw support, and also tried this as a module. The result is the same regardless. Regards, Abe On Thu, Oct 10, 2002 at 02:40:12PM -0700, Terry Lambert wrote: > abe wrote: > > I've written to the questions list recently with regard to a > > panic that keeps occuring and perhaps my message was not formatted > > as well as it could have been. In more testing it seems that the > > minute the ipfw rules are loaded (which previously worked without > > issue), the machine panics. Any network connectivity attempted > > afterwards results in a panic. This includes ping, telnet, smtp, > > etc. When the machine panics, it drops into the debugger and > > displays the following: > > > > Stopped at add_dyn_rule+0172: movl 0(%edx,%ebx,4)x%eax > > Sounds like you rebuilt your kernel, but did not rebuild your > kernel modules, and now you are loading an old module into a > new kernel. > > -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 14:47:30 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DFAAF37B401 for ; Thu, 10 Oct 2002 14:47:26 -0700 (PDT) Received: from hotmail.com (f26.sea1.hotmail.com [207.68.163.26]) by mx1.FreeBSD.org (Postfix) with ESMTP id 72FEF43E91 for ; Thu, 10 Oct 2002 14:47:25 -0700 (PDT) (envelope-from firstolasto@hotmail.com) Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC; Thu, 10 Oct 2002 14:47:25 -0700 Received: from 12.235.232.75 by sea1fd.sea1.hotmail.msn.com with HTTP; Thu, 10 Oct 2002 21:47:24 GMT X-Originating-IP: [12.235.232.75] From: "Firsto Lasto" To: mark@grondar.za Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: PRNG not seeded - error in non-root ssh inside 4.6.2 jails... Date: Thu, 10 Oct 2002 14:47:24 -0700 Mime-Version: 1.0 Content-Type: text/plain; format=flowed Message-ID: X-OriginalArrivalTime: 10 Oct 2002 21:47:25.0166 (UTC) FILETIME=[9ED868E0:01C270A6] Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Do you mean recompile SSL using urandom instead of random ? Would it be the exact same effect if I simply changed my /dev/random to major/minor 2,4 instead of 2,3 ? It seems like that would be much easier... > > > Ok, I am not sure how I can do that though - I cannot successfully run > > `rndcontrol -s X` inside a jail. > > > > On the other hand, I already have: > > > > rand_irqs="9 10 11 13 14" > > > > In my rc.conf on the underlying host machine, and have done several >boots > > with that in place. So presumably I should be seeded just fine, but if >I am > > not, I cannot change that in the jail because it seems I cannot set that >(I > > assume it is a sysctl issue). > > > > Willing to try whatever you can think of next :) > >Hokay. Can you grovel around inside OpenSSL (src/crypto/openssl/...) and >find where the random device is read? If it is /dev/random, then change >that to /dev/urandom. > >See how that works. > >M > > > > > I can't seed it by banging on the keyboard - it is a headless server >in > > >a > > > > rack thousands of miles from me :) > > > > > > > > Perhaps there is another way to do it ? > > > > > >Yes. > > > > > >You need to find sources of entropy in interrupts. Look at a > > >dmesg, and note which IRQ's your network device(s) and mass > > >storage controller(s) (both SCSI and ATA). Use any other > > >irq's that aren't too busy and may be somewhat random. > > >Staring at a 'systat 2 -vmstat' screen (right hand side) > > >may give some clues. > > > > > >Then use rndcontrol(8) to set up the seeding. There is a knob > > >in rc.conf to make this setting survive the next reboot. > > > > > >M > > > > > > > >Date: Thu, 03 Oct 2002 21:54:30 +0100 > > > > > > > > > > > Sorry, here is the rest: > > > > > > > > > > > > Here is the output of the `dd` command using urandom: > > > > > > > > > > > > dd if=/dev/urandom of=/dev/stdout bs=512 count=1 | hexdump -C > > > > > > 1+0 records in > > > > > > 1+0 records out > > > > > > 00000000 a0 69 1a 7c 8f 32 e5 21 ae 7a 33 14 68 0b 8e a6 > > > > > > |.i.|.2.!.z3.h...| > > > > > > > > > >... etc. Looking good. > > > > > > > > > > > $ ls -l /dev/*rand* > > > > > > crw-r--r-- 1 root wheel 2, 3 Sep 3 21:46 /dev/random > > > > > > crw-r--r-- 1 root wheel 2, 4 Sep 3 21:46 /dev/urandom > > > > > > > > > >Also good. > > > > > > > > > > > > > So then, as root I ran: `chmod 0666 /dev/stdout` and then I >ran > > >your > > > > > > >`dd` > > > > > > > > command and got: > > > > > > > > > > > > > > > > $ dd if=/dev/random of=/dev/stdout bs=512 count=1 | hexdump >-C > > > > > > > > 0+0 records in > > > > > > > > 0+0 records out > > > > > > > > 0 bytes transferred in 0.000036 secs (0 bytes/sec) > > > > > > > > > >Can you try a few of these while furiously abusing your keyboard? > > > > >I'm trying to see if /dev/random can be persuaded to give _any_ > > > > >aoutput at all. > > > > > > > > > >Maybe do it on a vty instead of in X. > > > > > > > > > >M > > > > >-- > > > > >o Mark Murray > > > > >\_ > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > _________________________________________________________________ > > > > Chat with friends online, try MSN Messenger: >http://messenger.msn.com > > > > > > >-- > > >o Mark Murray > > >\_ > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > _________________________________________________________________ > > Send and receive Hotmail on your mobile device: http://mobile.msn.com > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > with "unsubscribe freebsd-hackers" in the body of the message >-- >o Mark Murray >\_ >O.\_ Warning: this .sig is umop ap!sdn _________________________________________________________________ Send and receive Hotmail on your mobile device: http://mobile.msn.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 15: 6: 6 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5176937B401 for ; Thu, 10 Oct 2002 15:06:05 -0700 (PDT) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id A58B843EB1 for ; Thu, 10 Oct 2002 15:06:04 -0700 (PDT) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.12.4/8.12.4) with SMTP id g9AM5YOo039642; Thu, 10 Oct 2002 18:05:34 -0400 (EDT) (envelope-from robert@fledge.watson.org) Date: Thu, 10 Oct 2002 18:05:34 -0400 (EDT) From: Robert Watson X-Sender: robert@fledge.watson.org To: "Nelson, Trent ." Cc: "'chromexa@ovis.net'" , "'hackers@freebsd.org'" Subject: RE: FreeBSD usage in safety-critical environments In-Reply-To: <8F329FEDF58BD411BE5200508B10DA7607D71A12@exchptc1.switch.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, 9 Oct 2002, Nelson, Trent . wrote: > If you're referring to security criteria (Trusted Computer > Security Evaluation Criteria or ITSEC for Euro/UK), then no, FreeBSD > doesn't currently provide any features C2/F-C2+ configuration (Access > Control Lists, auditing, accountability, etc). This is being tackled by > TrustedBSD though, which I'm sure Robert Watson can provide some more > information on. We're actually close to feature completeness on the CAPP (Common Acess Protection Profile), which is logically equivilent to the old C2 TCSEC evaluation except expressed in the parlance of the Common Criteria, for 5.0. For example, we now have support for access control lists--we also have a number of features required for LSPP, which requires information labeling and mandatory protections. We don't current have an audit implementation, but I'm working to resolve that issue as soon as possible. The only big thing missing from the picture is actually someone who wants to bring FreeBSD to market with an evaluation--someone who's willing to go the distance on the evaluation process (paperwork, testing, etc). My goals for FreeBSD 6.0 include feature completeness on CAPP (C2) and LSPP (B1). > Although they are inter-related, the safety integrity level of > the system is what I was really querying. That tends to bring in a > whole host of metrics such as error and exception handling, standard > failure modes, MTBF, etc etc. Agreed. There are some similar notions, but they're not the same. I'm happy to take on the security feature issue, but I'm not qualified on the safety/reliability side. Anecdotately, FreeBSD has excellent up-time and strong failure tolerance, but you need something more than that in a formal sense. Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Network Associates Laboratories To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 15: 9:26 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E074937B404; Thu, 10 Oct 2002 15:09:24 -0700 (PDT) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id DFB4043ED1; Thu, 10 Oct 2002 15:09:23 -0700 (PDT) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.12.4/8.12.4) with SMTP id g9AM8sOo039668; Thu, 10 Oct 2002 18:08:54 -0400 (EDT) (envelope-from robert@fledge.watson.org) Date: Thu, 10 Oct 2002 18:08:54 -0400 (EDT) From: Robert Watson X-Sender: robert@fledge.watson.org To: Terry Lambert Cc: "Roman V. Mashak" , Steve Kudlak , "Nelson, Trent ." , "'hackers@freebsd.org'" , "'questions@freebsd.org'" Subject: Re: FreeBSD usage in safety-critical environments In-Reply-To: <3DA50C53.FA2B1619@mindspring.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, 9 Oct 2002, Terry Lambert wrote: > "Roman V. Mashak" wrote: > > On Wed, Oct 09, 2002 at 01:07:43PM -0400, Steve Kudlak wrote: > > > project and mucking with the "low grade" in my opinion C-2 security > > > that Sun OSes had and finding bugs in things like FTP logging and > > > the like. I now do other things so I don't worry about that. :) But it > > > is an interesting issue. I wonder if we should move it to chat? > > > > Could you please pick up some URLs with description of all security levels > > (C-2 and so on) - how to get, who is going on it and so on. > > Thanks in advance. > > Here is the "Orange Book" (DoD TCSEC / DoD 5200.28-STD): > > http://www.radium.ncsc.mil/tpep/library/rainbow/5200.28-STD.html > > You "get it" by paying a certified testing laboratory a huge amount of > money to test a particular hardware and software combination. Systems are no longer being evaluated to TCSEC. The new world order is based on a "Common Criteria" or language for expression protection profiles (PPs) in terms of a feature set, and then an assurance level (EAL-1 ... EAL-4 or higher). The logical equvilents to TCSEC C2 and B1, as mentioned in an earlier message I sent out, are the CAPP and LSPP protection profiles at EAL-4. In order to get your foot in the door, you really need at least EAL-3 / CAPP. There are lots of other protection profiles provided by NSA, NIST, and other international organizations. This is a logically seperate issue from the safety critical concern, although in many real world situations, you'd want both aspects. Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Network Associates Laboratories To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 15:10:52 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7D6CB37B401 for ; Thu, 10 Oct 2002 15:10:51 -0700 (PDT) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9E94D43EBE for ; Thu, 10 Oct 2002 15:10:50 -0700 (PDT) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.12.4/8.12.4) with SMTP id g9AMALOo039752; Thu, 10 Oct 2002 18:10:21 -0400 (EDT) (envelope-from robert@fledge.watson.org) Date: Thu, 10 Oct 2002 18:10:21 -0400 (EDT) From: Robert Watson X-Sender: robert@fledge.watson.org To: Steve Kudlak Cc: "Roman V. Mashak" , "'hackers@freebsd.org'" , "Nelson, Trent ." Subject: Re: C-2(Security) blues and the like In-Reply-To: <3DA5A764.68AA7199@ovis.net> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, 10 Oct 2002, Steve Kudlak wrote: > It has been a long time since I dealt with those arcane security > matters. At least they are obscure and arcane to most people. Many > consider me to be babbling when I go on about these things. If I start > saying "rainbow books" (the NSA's security books are in different > colors) many people assume that I am crazy.:) > > Most of the stuff I did involved C-2 security and all the logging and > authentication stuff. An assumption seems to have been made that > "logging in" via ftp was the same as logging in via tty or machine. This > is not so. The ftp code "establishes a user" the login code gets the > user a shell and all that. For awhile in some OSes with C-2 security if > one was going to mount a dictionary attack on some user or ever root, > ftp would have been away to go. It would allow one a large amount of > attacks with logging. One would definitely get more than 3 attempts to > "login". It was a way around C-2 security and was in my opinion a > pretty serious compromise. Logging ftp "logins" and ftp use were > proposed fixes. I just had to find the problems not fix them. > > Hmmm...maybe I will post this to BSD hackers and if someone says it is > off topic I will shut up. Perhaps I should as this info is kind of old. > But the important to watch for these little back door tricks. Note I > have not as of late read the FreeBSD ftp code. Perhaps I should. This would be on topic for trustedbsd-discuss@TrustedBSD.org, but you should go review current language, documents, and specifications, or you'll cover a lot of previously covered ground. The first thing you are probably interested in is the Common Criteria description, which I believe is available from ISO. Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Network Associates Laboratories To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 15:20:41 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 84CE337B401 for ; Thu, 10 Oct 2002 15:20:39 -0700 (PDT) Received: from albatross.prod.itd.earthlink.net (albatross.mail.pas.earthlink.net [207.217.120.120]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0D23E43EA9 for ; Thu, 10 Oct 2002 15:20:39 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0397.cvx21-bradley.dialup.earthlink.net ([209.179.193.142] helo=mindspring.com) by albatross.prod.itd.earthlink.net with esmtp (Exim 3.33 #1) id 17zlfU-00019B-00; Thu, 10 Oct 2002 15:20:33 -0700 Message-ID: <3DA5FCD2.B23CD912@mindspring.com> Date: Thu, 10 Oct 2002 15:18:58 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: abe Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> <20021010214518.GB71656@dipole.informationwave.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG abe wrote: > This started out as a sudden panic on a machine that was in a > datacenter for more than 8 months without issue. Then I installed > on fresh machines, compiled in ipfw support, and also tried this as > a module. The result is the same regardless. You have a traceback; do you have a system dump? [ ... ] > > > Stopped at add_dyn_rule+0172: movl 0(%edx,%ebx,4)x%eax Knowing the line of C code involved would be much more useful. Are you suddenly running an application that you did not formerly run? The creation of a dynamic rule as a result of a ip_output() call to ip_fw_chk() to install_state() to add_dyn_rule() implies that the flow ID passed down to add_dyn_rule() with the value of dyn_type == DYN_KEEP_STATE is valid. One possibility that occurs to me is that you end up with a parent count going over 65535 (it's a u_int16_t). When it is counted yet again, it goes to 0, then again, to 1. Then the next reference deletion causes it to go 1->0, at which point, the parent is deleted, even though it's still referenced. If this is the case, you can work around it by ensuring that a dynamic limit of 65534 or less is set. Another workaround would be to change the "count" member of the "struct ipfw_dyn_rule" to b a u_int32_t, and recompile everything. Without knowing the source code involved, you are unlikely to get an answer that's more than a guess. 8-(. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 15:27:30 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BCBA437B401 for ; Thu, 10 Oct 2002 15:27:28 -0700 (PDT) Received: from mail1.informationwave.net (dipole.informationwave.net [199.74.235.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1315B43EB3 for ; Thu, 10 Oct 2002 15:27:28 -0700 (PDT) (envelope-from abe@informationwave.net) Received: by mail1.informationwave.net (Postfix, from userid 1007) id 585C74F917; Thu, 10 Oct 2002 18:25:45 -0400 (EDT) Date: Thu, 10 Oct 2002 18:25:45 -0400 From: abe To: Terry Lambert Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic Message-ID: <20021010222545.GA82461@dipole.informationwave.net> References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> <20021010214518.GB71656@dipole.informationwave.net> <3DA5FCD2.B23CD912@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3DA5FCD2.B23CD912@mindspring.com> User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Oct 10, 2002 at 03:18:58PM -0700, Terry Lambert wrote: > abe wrote: > > This started out as a sudden panic on a machine that was in a > > datacenter for more than 8 months without issue. Then I installed > > on fresh machines, compiled in ipfw support, and also tried this as > > a module. The result is the same regardless. > > You have a traceback; do you have a system dump? Sorry Terry, unfortunately it wouldn't produce a system dump unless I was not taking the proper steps to produce one. Any URL that would point this out to me or any suggestion? > > [ ... ] > > > > Stopped at add_dyn_rule+0172: movl 0(%edx,%ebx,4)x%eax > > > Knowing the line of C code involved would be much more useful. > > Are you suddenly running an application that you did not formerly > run? The creation of a dynamic rule as a result of a ip_output() > call to ip_fw_chk() to install_state() to add_dyn_rule() implies > that the flow ID passed down to add_dyn_rule() with the value of > dyn_type == DYN_KEEP_STATE is valid. This is a vanilla installation with pretty much all inet services disabled. > > One possibility that occurs to me is that you end up with a > parent count going over 65535 (it's a u_int16_t). When it is > counted yet again, it goes to 0, then again, to 1. Then the > next reference deletion causes it to go 1->0, at which point, > the parent is deleted, even though it's still referenced. > > If this is the case, you can work around it by ensuring that a > dynamic limit of 65534 or less is set. > > Another workaround would be to change the "count" member of the > "struct ipfw_dyn_rule" to b a u_int32_t, and recompile everything. > > > Without knowing the source code involved, you are unlikely to get > an answer that's more than a guess. 8-(. Hell, it's more than I've gotten thus far. Much appreciation. Regards, Abe > > -- Terry > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 15:31: 4 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 95FD037B401; Thu, 10 Oct 2002 15:31:03 -0700 (PDT) Received: from albatross.prod.itd.earthlink.net (albatross.mail.pas.earthlink.net [207.217.120.120]) by mx1.FreeBSD.org (Postfix) with ESMTP id 32A0D43EB2; Thu, 10 Oct 2002 15:31:03 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0397.cvx21-bradley.dialup.earthlink.net ([209.179.193.142] helo=mindspring.com) by albatross.prod.itd.earthlink.net with esmtp (Exim 3.33 #1) id 17zlpd-0000ZJ-00; Thu, 10 Oct 2002 15:31:01 -0700 Message-ID: <3DA5FF43.D9786031@mindspring.com> Date: Thu, 10 Oct 2002 15:29:23 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Robert Watson Cc: Steve Kudlak , "Roman V. Mashak" , "'hackers@freebsd.org'" , "Nelson, Trent ." Subject: Re: C-2(Security) blues and the like References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Robert Watson wrote: > The first thing you are > probably interested in is the Common Criteria description, which I believe > is available from ISO. ...which answers the "how do I get it?" followup question that naturally comes from the CAPP/LSPP profile references for the various EAL levels: "You pay ISO through the nose for it". Are ISO standards still on the order of US$9 per single-sided page? I just got my copies of the ECMA standards on CDROM (for free...). -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 15:35: 3 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EC7B737B401 for ; Thu, 10 Oct 2002 15:35:01 -0700 (PDT) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id F384243EC2 for ; Thu, 10 Oct 2002 15:35:00 -0700 (PDT) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.12.4/8.12.4) with SMTP id g9AMYUOo040334; Thu, 10 Oct 2002 18:34:30 -0400 (EDT) (envelope-from robert@fledge.watson.org) Date: Thu, 10 Oct 2002 18:34:30 -0400 (EDT) From: Robert Watson X-Sender: robert@fledge.watson.org To: Terry Lambert Cc: Steve Kudlak , "Roman V. Mashak" , "'hackers@freebsd.org'" , "Nelson, Trent ." Subject: Re: C-2(Security) blues and the like In-Reply-To: <3DA5FF43.D9786031@mindspring.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, 10 Oct 2002, Terry Lambert wrote: > Robert Watson wrote: > > The first thing you are > > probably interested in is the Common Criteria description, which I believe > > is available from ISO. > > ...which answers the "how do I get it?" followup question that naturally > comes from the CAPP/LSPP profile references for the various EAL levels: > "You pay ISO through the nose for it". > > Are ISO standards still on the order of US$9 per single-sided page? I > just got my copies of the ECMA standards on CDROM (for free...). Actually, I believe that the CC should be available for free on the web somewhere. Unfortunately, I forget where. Last time I got it, it was a free PDF download. The CAPP and LSPP documents should be on www.nsa.gov somewhere, or off the radium web page. Another good acronym to google is NIAP. At this point, to be used in .mil, an operating system has to either be evaluated, or "in evaluation", or have a special exemption. Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Network Associates Laboratories To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 15:52:45 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8393337B401 for ; Thu, 10 Oct 2002 15:52:42 -0700 (PDT) Received: from flamingo.mail.pas.earthlink.net (flamingo.mail.pas.earthlink.net [207.217.120.232]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1206843ECD for ; Thu, 10 Oct 2002 15:52:42 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0397.cvx21-bradley.dialup.earthlink.net ([209.179.193.142] helo=mindspring.com) by flamingo.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zmAV-00035w-00; Thu, 10 Oct 2002 15:52:35 -0700 Message-ID: <3DA60447.4C66C85@mindspring.com> Date: Thu, 10 Oct 2002 15:50:47 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: abe Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> <20021010214518.GB71656@dipole.informationwave.net> <3DA5FCD2.B23CD912@mindspring.com> <20021010222545.GA82461@dipole.informationwave.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG abe wrote: > > You have a traceback; do you have a system dump? > > Sorry Terry, unfortunately it wouldn't produce a system dump unless > I was not taking the proper steps to produce one. Any URL that would > point this out to me or any suggestion? Poul changed this code. I haven't been able to get a correct dump locally since then. It would really depend on the *exact* version of FreeBSD you are running. You might want to look in the handbook, if you have a good version. The normal way on older versions was to add: dumpdev="/dev/ad0s3b" ...or whatever device your swap normally lives on... to your /etc/rc.conf. It's required to be the size of physical memory plus 64K (at a minimum). See "man dumpon". > > Knowing the line of C code involved would be much more useful. > > > > Are you suddenly running an application that you did not formerly > > run? The creation of a dynamic rule as a result of a ip_output() > > call to ip_fw_chk() to install_state() to add_dyn_rule() implies > > that the flow ID passed down to add_dyn_rule() with the value of > > dyn_type == DYN_KEEP_STATE is valid. > > This is a vanilla installation with pretty much all inet services > disabled. You are doing something UDP. It may be that some idiot has configured your machine as their DNS forwarder. This can happen if you leave your DNS server open for forwarding requests. > > One possibility that occurs to me is that you end up with a > > parent count going over 65535 (it's a u_int16_t). When it is > > counted yet again, it goes to 0, then again, to 1. Then the > > next reference deletion causes it to go 1->0, at which point, > > the parent is deleted, even though it's still referenced. > > > > If this is the case, you can work around it by ensuring that a > > dynamic limit of 65534 or less is set. > > > > Another workaround would be to change the "count" member of the > > "struct ipfw_dyn_rule" to b a u_int32_t, and recompile everything. > > > > > > Without knowing the source code involved, you are unlikely to get > > an answer that's more than a guess. 8-(. > > Hell, it's more than I've gotten thus far. Much appreciation. No problem. Thinking a bit more: You should be able to find out the C code at assembly code offset 0x172, assuming you created your kernel with "config -g", and you compiled the ipfw statically into the kernel, instead of loading it as a module. Assuming this is the case, to do that, go to the directory you compiled the kernel in, and run: gdb -k kernel.debug list *add_dyn_rule+0x172 ...don't forget to insert the 'x': it's a hex number. The kernel debugger leaves out the 'x' "To Be A Pain In Terry's Ass, For No Good Reason"(tm) ...you'll notice that it didn't leave it out of the traceback itself. You will likely need to back the number up to get a clean listing of the source line that caused the fault. Yeah, statically compiling in the IPFW is annoying, particularly since you will have to play "swap the kernel" to get a kernel up without IPFW, and this will be a pain, if the panic is immediate. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 15:54: 3 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D21D137B401; Thu, 10 Oct 2002 15:54:01 -0700 (PDT) Received: from dibbler.ne.client2.attbi.com (dibbler.ne.client2.attbi.com [24.61.41.247]) by mx1.FreeBSD.org (Postfix) with ESMTP id F333D43ED8; Thu, 10 Oct 2002 15:54:00 -0700 (PDT) (envelope-from rodrigc@attbi.com) Received: from dibbler.ne.client2.attbi.com (localhost.ne.attbi.com [127.0.0.1]) by dibbler.ne.client2.attbi.com (8.12.6/8.12.5) with ESMTP id g9AMsgCK014279; Thu, 10 Oct 2002 18:54:42 -0400 (EDT) (envelope-from rodrigc@dibbler.ne.client2.attbi.com) Received: (from rodrigc@localhost) by dibbler.ne.client2.attbi.com (8.12.6/8.12.6/Submit) id g9AMsfCV014278; Thu, 10 Oct 2002 18:54:41 -0400 (EDT) Date: Thu, 10 Oct 2002 18:54:41 -0400 From: Craig Rodrigues To: Robert Watson Cc: Terry Lambert , Steve Kudlak , "Roman V. Mashak" , "'hackers@freebsd.org'" , "Nelson, Trent ." Subject: Re: C-2(Security) blues and the like Message-ID: <20021010185441.A14243@attbi.com> References: <3DA5FF43.D9786031@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: ; from rwatson@FreeBSD.ORG on Thu, Oct 10, 2002 at 06:34:30PM -0400 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Oct 10, 2002 at 06:34:30PM -0400, Robert Watson wrote: > > Are ISO standards still on the order of US$9 per single-sided page? I > > just got my copies of the ECMA standards on CDROM (for free...). You can get ISO 15408 (Common Criteria) from ANSI: http://webstore.ansi.org/ansidocstore/find.asp?find_spec=15408 3 PDF files for $18 each, for a total of $54. Paper copies cost more. > Actually, I believe that the CC should be available for free on the web > somewhere. Unfortunately, I forget where. Last time I got it, it was a > free PDF download. A quick google search of "Common Criteria" yields: http://csrc.nist.gov/cc/ccv20/ccv2list.htm It has PDF files for download which are not the same as the ISO standard, but are supposed to be "aligned with ISO 15408". -- Craig Rodrigues http://www.gis.net/~craigr rodrigc@attbi.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 15:58:24 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9940337B401; Thu, 10 Oct 2002 15:58:23 -0700 (PDT) Received: from flamingo.mail.pas.earthlink.net (flamingo.mail.pas.earthlink.net [207.217.120.232]) by mx1.FreeBSD.org (Postfix) with ESMTP id CF23743EC2; Thu, 10 Oct 2002 15:58:22 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0397.cvx21-bradley.dialup.earthlink.net ([209.179.193.142] helo=mindspring.com) by flamingo.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zmG1-0003LX-00; Thu, 10 Oct 2002 15:58:18 -0700 Message-ID: <3DA6059A.C248EF9F@mindspring.com> Date: Thu, 10 Oct 2002 15:56:26 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Craig Rodrigues Cc: Robert Watson , Steve Kudlak , "Roman V. Mashak" , "'hackers@freebsd.org'" , "Nelson, Trent ." Subject: Re: C-2(Security) blues and the like References: <3DA5FF43.D9786031@mindspring.com> <20021010185441.A14243@attbi.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Craig Rodrigues wrote: > On Thu, Oct 10, 2002 at 06:34:30PM -0400, Robert Watson wrote: [ ... where to get security standards ... ] Cool. You guys are a wealth of information.. Robert: any chance of this finding its way into a docs secion on the TrustedBSD.org web site? -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 16: 8:38 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7C3AA37B401; Thu, 10 Oct 2002 16:08:36 -0700 (PDT) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 915AC43EB7; Thu, 10 Oct 2002 16:08:35 -0700 (PDT) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.12.4/8.12.4) with SMTP id g9AN83Oo040566; Thu, 10 Oct 2002 19:08:04 -0400 (EDT) (envelope-from robert@fledge.watson.org) Date: Thu, 10 Oct 2002 19:08:03 -0400 (EDT) From: Robert Watson X-Sender: robert@fledge.watson.org To: Terry Lambert Cc: Craig Rodrigues , Steve Kudlak , "Roman V. Mashak" , "'hackers@freebsd.org'" , "Nelson, Trent ." , chris@FreeBSD.ORG Subject: Re: C-2(Security) blues and the like In-Reply-To: <3DA6059A.C248EF9F@mindspring.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, 10 Oct 2002, Terry Lambert wrote: > Craig Rodrigues wrote: > > On Thu, Oct 10, 2002 at 06:34:30PM -0400, Robert Watson wrote: > [ ... where to get security standards ... ] > > Cool. You guys are a wealth of information.. > > Robert: any chance of this finding its way into a docs secion on the > TrustedBSD.org web site? Yeah, I was thinking that myself. At one point were were going to stick up a bibliography, but I never quite got around to it. I've CC'd Chris Costello in this e-mail--he's been doing TrustedBSD docs work, and can probably help put something together. At the very least we'd want to have references to: CC, both at ISO, NIST, etc Various relevant protection profiles, including (historically) the Orange Book, but more recently CAPP, LSPP, and the boatload of other profiles floating around (they exist for secure routers, etc, etc). Links to the MAC documentation in the developer's handbook. Any other papers people think are relevant. Also, we have a recent Design + Implementation paper submitted to the DISCEX III conference, I'm going to see if I can't get that up on the web page. BTW, my earlier comments still stand -- I think we have a grasp on the feature sets for most of these profiles, but what we don't have is an organization willing to carry through on the evaluation process. For grins, it probably costs between USD 500k and USD 1.5m. CC/CAPP and CC/LSPP are a bit less focussed on the dual hardware/software configuration, but you do still have to update the certification at each new release (not very hard for a branch like -STABLE). The goal of having such a certification would be to get in the door with DoD, better with the banking community, etc. Right now, as I mentioned previously, if your OS product isn't already in evaluation, DoD needs special exemptions to use the software, apparently. If we could find a vendor interested in selling FreeBSD distribution/support to some bit of DoD, I could probably help raise funding for missing components. Not enough to cover all of the evaluation -- that would require substantial private investment, but certainly enough to do supporting infrastructure and assurance stuff. Probably the best thing to do is find a bit of DoD already using FreeBSD and being forced to switch off by NIAP requirements, and connect them with a FreeBSD vendor willing to do some of the work (for a fee). FWIW, I'm aware of several products based on FreeBSD that are either in evaluation, or have been evaluted. Most of the time it's in the context of an embedded network product, so the differences are pretty substantial, though. If we did find appropriate sponsorship and a home for the project, we could probably get FreeBSD to EAL3/CAPP by 2003Q3. Being "in evaluation", as mentioned, would be enough to keep making sales. Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Network Associates Laboratories To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 16:26: 3 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 460FE37B401 for ; Thu, 10 Oct 2002 16:26:00 -0700 (PDT) Received: from mail1.informationwave.net (dipole.informationwave.net [199.74.235.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9A11243EA9 for ; Thu, 10 Oct 2002 16:25:59 -0700 (PDT) (envelope-from abe@informationwave.net) Received: by mail1.informationwave.net (Postfix, from userid 1007) id EF8A04F917; Thu, 10 Oct 2002 19:24:16 -0400 (EDT) Date: Thu, 10 Oct 2002 19:24:16 -0400 From: abe To: Terry Lambert Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic Message-ID: <20021010232416.GA97757@dipole.informationwave.net> References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> <20021010214518.GB71656@dipole.informationwave.net> <3DA5FCD2.B23CD912@mindspring.com> <20021010222545.GA82461@dipole.informationwave.net> <3DA60447.4C66C85@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3DA60447.4C66C85@mindspring.com> User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Oct 10, 2002 at 03:50:47PM -0700, Terry Lambert wrote: > abe wrote: > > > You have a traceback; do you have a system dump? > > > > Sorry Terry, unfortunately it wouldn't produce a system dump unless > > I was not taking the proper steps to produce one. Any URL that would > > point this out to me or any suggestion? > > Poul changed this code. I haven't been able to get a correct dump > locally since then. It would really depend on the *exact* version > of FreeBSD you are running. You might want to look in the handbook, > if you have a good version. > > The normal way on older versions was to add: > > dumpdev="/dev/ad0s3b" > > ...or whatever device your swap normally lives on... to your > /etc/rc.conf. It's required to be the size of physical memory > plus 64K (at a minimum). See "man dumpon". Tried that, no luck. savecore still complained about no dumpdev. 4.5-release I'd imagine is the exact version... > > > > > Knowing the line of C code involved would be much more useful. > > > > > > Are you suddenly running an application that you did not formerly > > > run? The creation of a dynamic rule as a result of a ip_output() > > > call to ip_fw_chk() to install_state() to add_dyn_rule() implies > > > that the flow ID passed down to add_dyn_rule() with the value of > > > dyn_type == DYN_KEEP_STATE is valid. > > > > This is a vanilla installation with pretty much all inet services > > disabled. > > You are doing something UDP. It may be that some idiot has > configured your machine as their DNS forwarder. This can > happen if you leave your DNS server open for forwarding requests. Using at the moment comcast's nameservers, and an IP issued via DHCP from them. > > > > > One possibility that occurs to me is that you end up with a > > > parent count going over 65535 (it's a u_int16_t). When it is > > > counted yet again, it goes to 0, then again, to 1. Then the > > > next reference deletion causes it to go 1->0, at which point, > > > the parent is deleted, even though it's still referenced. > > > > > > If this is the case, you can work around it by ensuring that a > > > dynamic limit of 65534 or less is set. > > > > > > Another workaround would be to change the "count" member of the > > > "struct ipfw_dyn_rule" to b a u_int32_t, and recompile everything. > > > > > > > > > Without knowing the source code involved, you are unlikely to get > > > an answer that's more than a guess. 8-(. > > > > Hell, it's more than I've gotten thus far. Much appreciation. > > No problem. > > Thinking a bit more: > > You should be able to find out the C code at assembly code offset > 0x172, assuming you created your kernel with "config -g", and you > compiled the ipfw statically into the kernel, instead of loading > it as a module. > > Assuming this is the case, to do that, go to the directory you > compiled the kernel in, and run: > > gdb -k kernel.debug > list *add_dyn_rule+0x172 (kgdb) list *add_dyn_rule+0x172 No source file for address 0xc021e5d6 (kgdb) > > ...don't forget to insert the 'x': it's a hex number. The kernel > debugger leaves out the 'x' "To Be A Pain In Terry's Ass, For No > Good Reason"(tm) ...you'll notice that it didn't leave it out of the > traceback itself. > > You will likely need to back the number up to get a clean listing > of the source line that caused the fault. > > Yeah, statically compiling in the IPFW is annoying, particularly > since you will have to play "swap the kernel" to get a kernel up > without IPFW, and this will be a pain, if the panic is immediate. > > -- Terry Regards, Abe To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 16:32:40 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B799F37B401 for ; Thu, 10 Oct 2002 16:32:39 -0700 (PDT) Received: from tartarus.telenet-ops.be (tartarus.telenet-ops.be [195.130.132.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id 42DFD43EB2 for ; Thu, 10 Oct 2002 16:32:39 -0700 (PDT) (envelope-from Guido@VanHoecke.org) Received: from localhost (localhost.localdomain [127.0.0.1]) by tartarus.telenet-ops.be (Postfix) with SMTP id 3A618DC459 for ; Fri, 11 Oct 2002 01:32:38 +0200 (CEST) Received: from VanHoecke.org (D5E0E969.kabel.telenet.be [213.224.233.105]) by tartarus.telenet-ops.be (Postfix) with ESMTP id E0500DC3F8 for ; Fri, 11 Oct 2002 01:32:37 +0200 (CEST) Message-ID: <3DA60E15.2090800@VanHoecke.org> Date: Fri, 11 Oct 2002 01:32:37 +0200 From: Guido Van Hoecke User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.1) Gecko/20020826 X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-hackers Subject: sis900 problem persists in 4.7 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG My sis900 network card is behaves in 4.7 as it did in 4.6.2: it still complains 'MII without any PHY!' The least i can say is that this is utterly frustrating... -- Guido Van Hoecke To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 16:41: 2 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9C81737B401 for ; Thu, 10 Oct 2002 16:41:01 -0700 (PDT) Received: from tartarus.telenet-ops.be (tartarus.telenet-ops.be [195.130.132.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2A6CF43EA3 for ; Thu, 10 Oct 2002 16:41:01 -0700 (PDT) (envelope-from Guido@VanHoecke.org) Received: from localhost (localhost.localdomain [127.0.0.1]) by tartarus.telenet-ops.be (Postfix) with SMTP id 678C0DC530 for ; Fri, 11 Oct 2002 01:41:00 +0200 (CEST) Received: from VanHoecke.org (D5E0E969.kabel.telenet.be [213.224.233.105]) by tartarus.telenet-ops.be (Postfix) with ESMTP id 44677DC43D for ; Fri, 11 Oct 2002 01:41:00 +0200 (CEST) Message-ID: <3DA6100C.8080303@VanHoecke.org> Date: Fri, 11 Oct 2002 01:41:00 +0200 From: Guido Van Hoecke User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.1) Gecko/20020826 X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-hackers Subject: 4.7 messed up my mandrake-lilo config Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I installed 4.7 in a free partition on a machine that has a Lilo configuration to boot either Win2K or Mandrake 8.2. After installing the FreeBsd Boot Manager, I get following options: F1 ?? F2 Linux F3 ?? F4 FreeBSD F4 works and F1 boots into Win2K. F2 and F3 beep at me but do not boot anything. Please tell me how I can correct this and boot mandrake linux from this menu. At least until FreeBSD knows how to handle my SIS900 network card, I do need Mandrake!!! -- Guido Van Hoecke To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 16:41:29 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0810C37B401 for ; Thu, 10 Oct 2002 16:41:27 -0700 (PDT) Received: from srv2.resnet.ohio-state.edu (srv2.resnet.ohio-state.edu [164.107.3.56]) by mx1.FreeBSD.org (Postfix) with SMTP id 23D5E43EAF for ; Thu, 10 Oct 2002 16:41:27 -0700 (PDT) (envelope-from mistry.7@osu.edu) Received: (qmail 7697 invoked by uid 506); 10 Oct 2002 23:46:56 -0000 Received: from mistry.7@osu.edu by srv2.resnet.ohio-state.edu by uid 503 with qmail-scanner-1.14 ( Clear:. Processed in 0.034759 secs); 10 Oct 2002 23:46:56 -0000 Received: from rdrt-164-107-205-104.resnet.ohio-state.edu (HELO bigguy.am-productions.biz) (164.107.205.104) by srv2.resnet.ohio-state.edu with SMTP; 10 Oct 2002 23:46:56 -0000 Content-Type: text/plain; charset="us-ascii" From: Anish Mistry To: freebsd-hackers@freebsd.org Subject: csa kernel module access Date: Thu, 10 Oct 2002 19:41:05 -0400 User-Agent: KMail/1.4.3 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200210101941.05839.mistry.7@osu.edu> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG =09What would be the best way to read/write from a device that shows up o= n boot,=20 but there is no device node for it? =09Basically what I am trying to do is to be able to send to commands to = the csa=20 device so that I can control the breakout box for my GameTheatre XP so I=20 don't get cracking and popping since it isn't outputting the sound throug= h=20 the device correctly with just pcm. I have looked at the=20 /usr/share/examples/kld made a few modifications to make it create my own= =20 device node. =09How should I access the csa device so that I can have my module send=20 commands? --- relevent dmesg output --- csa0: mem=20 0xdd000000-0xdd0fffff,0xdd102000-0xdd102fff irq 5 at device 10.0 on pci0 csa: card is Hercules Game Theatre XP pcm1: on csa0 Thanks, --=20 Anish Mistry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 18:50:31 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 23C3537B404 for ; Thu, 10 Oct 2002 18:50:30 -0700 (PDT) Received: from mail.empirequest.com (www.empirequest.com [216.126.10.210]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2F81543EAA for ; Thu, 10 Oct 2002 18:50:29 -0700 (PDT) (envelope-from spinlock_lists@empirequest.com) Received: (qmail 13460 invoked by uid 89); 11 Oct 2002 01:50:29 -0000 Received: from unknown (HELO twothousand) (spinlock?lists@empirequest.com@192.168.0.2) by www.empirequest.com with SMTP; 11 Oct 2002 01:50:29 -0000 Message-ID: <000d01c270c8$937a2160$0200a8c0@twothousand> From: "Andrei Cojocaru" To: Subject: Question about light-weight mutex (kind of) Date: Thu, 10 Oct 2002 19:50:28 -0600 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hello, I have a question, please include me in the reply specifically because I'm not subscribed to the mailing list. Thanks I want a thread to spin atomically on a value until it's equal to 1(i.e. it's waiting for an event), how do I do that? I have no idea.. I want this to be fast, not have to use a mutex each time to protect the value I have an idea of how to do it using atomic assembly statements but I don't want to use assmebly, I want to know if FreeBSD has built-in stuff for this. Please help thanks. This is required because I'm building R/W locks for a transaction system I'm working on, and I need a way for a thread waiting on a lock to be notified when a lock is gotten (and without having the thread block [that's why I want it to spin]). Any hints would be appreciated thanks, once again. ---- Andrei Cojocaru spinlock_lists@empirequest.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 19:12: 7 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E219E37B401 for ; Thu, 10 Oct 2002 19:12:05 -0700 (PDT) Received: from avocet.mail.pas.earthlink.net (avocet.mail.pas.earthlink.net [207.217.120.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7A7EC43EBE for ; Thu, 10 Oct 2002 19:12:05 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0099.cvx21-bradley.dialup.earthlink.net ([209.179.192.99] helo=mindspring.com) by avocet.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zpHX-0003Mb-00; Thu, 10 Oct 2002 19:12:04 -0700 Message-ID: <3DA6332C.CDC30B95@mindspring.com> Date: Thu, 10 Oct 2002 19:10:52 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: abe Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> <20021010214518.GB71656@dipole.informationwave.net> <3DA5FCD2.B23CD912@mindspring.com> <20021010222545.GA82461@dipole.informationwave.net> <3DA60447.4C66C85@mindspring.com> <20021010232416.GA97757@dipole.informationwave.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG abe wrote: > On Thu, Oct 10, 2002 at 03:50:47PM -0700, Terry Lambert wrote: > > You should be able to find out the C code at assembly code offset > > 0x172, assuming you created your kernel with "config -g", and you ******* > > compiled the ipfw statically into the kernel, instead of loading **************************************************************** > > it as a module. ************** > > > > Assuming this is the case, to do that, go to the directory you > > compiled the kernel in, and run: > > > > gdb -k kernel.debug > > list *add_dyn_rule+0x172 > > (kgdb) list *add_dyn_rule+0x172 > No source file for address 0xc021e5d6 > (kgdb) Not to be emphatic, or anything, but IPFW has to be static. There is voodoo you can use to make it know about loaded modules, but I'll be damned if I know what it is (again, I refer you to the handbook). 8-). -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 19:14: 7 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 63A4E37B401 for ; Thu, 10 Oct 2002 19:14:06 -0700 (PDT) Received: from avocet.mail.pas.earthlink.net (avocet.mail.pas.earthlink.net [207.217.120.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2413543EB7 for ; Thu, 10 Oct 2002 19:14:06 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0099.cvx21-bradley.dialup.earthlink.net ([209.179.192.99] helo=mindspring.com) by avocet.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zpJU-0005wr-00; Thu, 10 Oct 2002 19:14:04 -0700 Message-ID: <3DA633A4.CEFA07D4@mindspring.com> Date: Thu, 10 Oct 2002 19:12:52 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Anish Mistry Cc: freebsd-hackers@freebsd.org Subject: Re: csa kernel module access References: <200210101941.05839.mistry.7@osu.edu> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Anish Mistry wrote: > What would be the best way to read/write from a device that shows up on boot, > but there is no device node for it? I'll go out on a limb here and say "Create a device node for it". -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 19:21:28 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6F91C37B401 for ; Thu, 10 Oct 2002 19:21:27 -0700 (PDT) Received: from mail1.informationwave.net (dipole.informationwave.net [199.74.235.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id 11A3943E42 for ; Thu, 10 Oct 2002 19:21:27 -0700 (PDT) (envelope-from abe@informationwave.net) Received: by mail1.informationwave.net (Postfix, from userid 1007) id 13E994F921; Thu, 10 Oct 2002 22:19:45 -0400 (EDT) Date: Thu, 10 Oct 2002 22:19:45 -0400 From: abe To: Terry Lambert Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic Message-ID: <20021011021945.GA46517@dipole.informationwave.net> References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> <20021010214518.GB71656@dipole.informationwave.net> <3DA5FCD2.B23CD912@mindspring.com> <20021010222545.GA82461@dipole.informationwave.net> <3DA60447.4C66C85@mindspring.com> <20021010232416.GA97757@dipole.informationwave.net> <3DA6332C.CDC30B95@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3DA6332C.CDC30B95@mindspring.com> User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Oct 10, 2002 at 07:10:52PM -0700, Terry Lambert wrote: > abe wrote: > > On Thu, Oct 10, 2002 at 03:50:47PM -0700, Terry Lambert wrote: > > > You should be able to find out the C code at assembly code offset > > > 0x172, assuming you created your kernel with "config -g", and you > ******* > > > compiled the ipfw statically into the kernel, instead of loading > **************************************************************** > > > it as a module. > ************** > > > > > > Assuming this is the case, to do that, go to the directory you > > > compiled the kernel in, and run: > > > > > > gdb -k kernel.debug > > > list *add_dyn_rule+0x172 > > > > (kgdb) list *add_dyn_rule+0x172 > > No source file for address 0xc021e5d6 > > (kgdb) > > Not to be emphatic, or anything, but IPFW has to be static. I thought it was "static" considering I compiled the kernel with support for it as opposed to loading the module? Regards, Abe To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 20: 2: 8 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C2D7937B404 for ; Thu, 10 Oct 2002 20:02:07 -0700 (PDT) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id 796C143E8A for ; Thu, 10 Oct 2002 20:02:07 -0700 (PDT) (envelope-from billf@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1098) id 437EBAE163; Thu, 10 Oct 2002 20:02:07 -0700 (PDT) Date: Thu, 10 Oct 2002 20:02:07 -0700 From: Bill Fumerola To: Terry Lambert Cc: abe , hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic Message-ID: <20021011030207.GN80284@elvis.mu.org> References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> <20021010214518.GB71656@dipole.informationwave.net> <3DA5FCD2.B23CD912@mindspring.com> <20021010222545.GA82461@dipole.informationwave.net> <3DA60447.4C66C85@mindspring.com> <20021010232416.GA97757@dipole.informationwave.net> <3DA6332C.CDC30B95@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3DA6332C.CDC30B95@mindspring.com> User-Agent: Mutt/1.4i X-Operating-System: FreeBSD 4.7-MUORG-20020910 i386 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Oct 10, 2002 at 07:10:52PM -0700, Terry Lambert wrote: > Not to be emphatic, or anything, but IPFW has to be static. There > is voodoo you can use to make it know about loaded modules, but I'll > be damned if I know what it is (again, I refer you to the handbook). > 8-). nope. ipfw doesn't have to be static. ipfw+ipdivert has to be static. up until a while ago, ipfw+dummynet and ipfw+bridge had to be static, but that was fixed and MFC'd. ipfw by itself (which includes the dynamic rules) can be static or kldload'd. -- - bill fumerola / fumerola@yahoo-inc.com / billf@FreeBSD.org / billf@mu.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 20:12:58 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5C47837B401 for ; Thu, 10 Oct 2002 20:12:57 -0700 (PDT) Received: from mail1.informationwave.net (dipole.informationwave.net [199.74.235.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id DDD5A43EA9 for ; Thu, 10 Oct 2002 20:12:56 -0700 (PDT) (envelope-from abe@informationwave.net) Received: by mail1.informationwave.net (Postfix, from userid 1007) id BF32F4F921; Thu, 10 Oct 2002 23:11:14 -0400 (EDT) Date: Thu, 10 Oct 2002 23:11:14 -0400 From: abe To: Bill Fumerola Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic Message-ID: <20021011031114.GA60607@dipole.informationwave.net> References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> <20021010214518.GB71656@dipole.informationwave.net> <3DA5FCD2.B23CD912@mindspring.com> <20021010222545.GA82461@dipole.informationwave.net> <3DA60447.4C66C85@mindspring.com> <20021010232416.GA97757@dipole.informationwave.net> <3DA6332C.CDC30B95@mindspring.com> <20021011030207.GN80284@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20021011030207.GN80284@elvis.mu.org> User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bill, Any hint as to what seems to be going on here and maybe a clue to a possible solution? Regards, Abe On Thu, Oct 10, 2002 at 08:02:07PM -0700, Bill Fumerola wrote: > On Thu, Oct 10, 2002 at 07:10:52PM -0700, Terry Lambert wrote: > > > Not to be emphatic, or anything, but IPFW has to be static. There > > is voodoo you can use to make it know about loaded modules, but I'll > > be damned if I know what it is (again, I refer you to the handbook). > > 8-). > > nope. ipfw doesn't have to be static. ipfw+ipdivert has to be static. > up until a while ago, ipfw+dummynet and ipfw+bridge had to be static, > but that was fixed and MFC'd. ipfw by itself (which includes the dynamic > rules) can be static or kldload'd. > > -- > - bill fumerola / fumerola@yahoo-inc.com / billf@FreeBSD.org / billf@mu.org > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 21:48:19 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D0C3A37B401 for ; Thu, 10 Oct 2002 21:48:17 -0700 (PDT) Received: from mail1.informationwave.net (dipole.informationwave.net [199.74.235.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8532443E77 for ; Thu, 10 Oct 2002 21:48:17 -0700 (PDT) (envelope-from abe@informationwave.net) Received: by mail1.informationwave.net (Postfix, from userid 1007) id 767B64F921; Fri, 11 Oct 2002 00:46:36 -0400 (EDT) Date: Fri, 11 Oct 2002 00:46:36 -0400 From: abe To: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic Message-ID: <20021011044636.GA84506@dipole.informationwave.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hello folks, Recently I have been corresponding with several from this list and questions@ with regard to an odd issue with ipfw and my machine panicing after any network communication was attempted after loading some IPFW rules. Some evidence of the panics can be found at: http://dipole.informationwave.net/~abe/fbsd.jpg http://dipole.informationwave.net/~abe/crash.mpg http://dipole.informationwave.net/~abe/trace.txt Unfortunately, feedback sent while in good intentions did not help. However, in further tinkering with this issue I believe I've come to a conclusion. I run a rather high-traffic server so I had initially increased net.inet.ip.fw.dyn_buckets to 500, from the default 256 as people were complaining that they were getting connection refusals. At the time of the complaints, it seemed the max dyn_buckets limit had been reached. In attempt to remedy this as I said above I increased it. After this week of going through many hardware tests and so forth trying multiple machines with the same rules and numerous fresh installations, tonight I set the default net.inet.ip.fw.dyn_buckets back to 256 and no issues. So then on a chance, I increased the value to 512. After this, I attempted to reproduce the panic with the same procedure I had taken before making this change. No panics post-change. I'm going to be keeping a close eye on this server and hoping that it was as simple an issue as that, and if not of course pursue the answer until it is found. If anyone has any comments or thoughts on this, please feel free to contact me on or off the list. Regards, Abe To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 21:50:15 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 57C5B37B401 for ; Thu, 10 Oct 2002 21:50:14 -0700 (PDT) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1C30643EAF for ; Thu, 10 Oct 2002 21:50:14 -0700 (PDT) (envelope-from billf@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1098) id E63C8AE211; Thu, 10 Oct 2002 21:50:13 -0700 (PDT) Date: Thu, 10 Oct 2002 21:50:13 -0700 From: Bill Fumerola To: abe Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic Message-ID: <20021011045013.GO80284@elvis.mu.org> References: <20021011044636.GA84506@dipole.informationwave.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20021011044636.GA84506@dipole.informationwave.net> User-Agent: Mutt/1.4i X-Operating-System: FreeBSD 4.7-MUORG-20020910 i386 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Oct 11, 2002 at 12:46:36AM -0400, abe wrote: > Unfortunately, feedback sent while in good intentions did not help. However, in further > tinkering with this issue I believe I've come to a conclusion. I run a rather high-traffic > server so I had initially increased net.inet.ip.fw.dyn_buckets to 500, from the default 256 > as people were complaining that they were getting connection refusals. At the time of the > complaints, it seemed the max dyn_buckets limit had been reached. In attempt to remedy this > as I said above I increased it. After this week of going through many hardware tests and so > forth trying multiple machines with the same rules and numerous fresh installations, > tonight I set the default net.inet.ip.fw.dyn_buckets back to 256 and no issues. So then on a chance, > I increased the value to 512. After this, I attempted to reproduce the panic with the same > procedure I had taken before making this change. No panics post-change. static u_int32_t dyn_buckets = 256; /* must be power of 2 */ -- - bill fumerola / fumerola@yahoo-inc.com / billf@FreeBSD.org / billf@mu.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 21:51:38 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5158B37B401 for ; Thu, 10 Oct 2002 21:51:37 -0700 (PDT) Received: from mail1.informationwave.net (dipole.informationwave.net [199.74.235.3]) by mx1.FreeBSD.org (Postfix) with ESMTP id F36E643E97 for ; Thu, 10 Oct 2002 21:51:36 -0700 (PDT) (envelope-from abe@informationwave.net) Received: by mail1.informationwave.net (Postfix, from userid 1007) id 3D2294F921; Fri, 11 Oct 2002 00:49:56 -0400 (EDT) Date: Fri, 11 Oct 2002 00:49:56 -0400 From: abe To: Bill Fumerola Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic Message-ID: <20021011044956.GA87029@dipole.informationwave.net> References: <20021011044636.GA84506@dipole.informationwave.net> <20021011045013.GO80284@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20021011045013.GO80284@elvis.mu.org> User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Oct 10, 2002 at 09:50:13PM -0700, Bill Fumerola wrote: > On Fri, Oct 11, 2002 at 12:46:36AM -0400, abe wrote: > > > Unfortunately, feedback sent while in good intentions did not help. However, in further > > tinkering with this issue I believe I've come to a conclusion. I run a rather high-traffic > > server so I had initially increased net.inet.ip.fw.dyn_buckets to 500, from the default 256 > > as people were complaining that they were getting connection refusals. At the time of the > > complaints, it seemed the max dyn_buckets limit had been reached. In attempt to remedy this > > as I said above I increased it. After this week of going through many hardware tests and so > > forth trying multiple machines with the same rules and numerous fresh installations, > > tonight I set the default net.inet.ip.fw.dyn_buckets back to 256 and no issues. So then on a chance, > > I increased the value to 512. After this, I attempted to reproduce the panic with the same > > procedure I had taken before making this change. No panics post-change. > > static u_int32_t dyn_buckets = 256; /* must be power of 2 */ Well another issue solved, need thicker glasses it appears. Thanks much Bill. Funny thing is, it's been running without issue for almost a year now. Interesting. Regards, Abe > > -- > - bill fumerola / fumerola@yahoo-inc.com / billf@FreeBSD.org / billf@mu.org > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 21:53:59 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BFFB537B401 for ; Thu, 10 Oct 2002 21:53:57 -0700 (PDT) Received: from sbtx.tmn.ru (sbtx.tmn.ru [212.76.160.49]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9F2C743E9E for ; Thu, 10 Oct 2002 21:53:56 -0700 (PDT) (envelope-from serg@sbtx.tmn.ru) Received: from sv.tech.sibitex.tmn.ru (sv.tech.sibitex.tmn.ru [212.76.160.59]) by sbtx.tmn.ru (8.12.3/8.12.3) with ESMTP id g9B4rrPk077785; Fri, 11 Oct 2002 10:53:54 +0600 (YEKST) (envelope-from serg@sbtx.tmn.ru) Received: from sv.tech.sibitex.tmn.ru (localhost [127.0.0.1]) by sv.tech.sibitex.tmn.ru (8.12.6/8.12.6) with ESMTP id g9B4rq48009008; Fri, 11 Oct 2002 10:53:52 +0600 (YEKST) (envelope-from serg@sv.tech.sibitex.tmn.ru) Received: (from serg@localhost) by sv.tech.sibitex.tmn.ru (8.12.6/8.12.6/Submit) id g9B4rpbl008928; Fri, 11 Oct 2002 10:53:51 +0600 (YEKST) Date: Fri, 11 Oct 2002 10:53:51 +0600 From: "Sergey N. Voronkov" To: Guido Van Hoecke Cc: freebsd-hackers Subject: Re: 4.7 messed up my mandrake-lilo config Message-ID: <20021011045351.GA80995@sv.tech.sibitex.tmn.ru> References: <3DA6100C.8080303@VanHoecke.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3DA6100C.8080303@VanHoecke.org> User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Oct 11, 2002 at 01:41:00AM +0200, Guido Van Hoecke wrote: > I installed 4.7 in a free partition on a machine that has a Lilo > configuration to boot either Win2K or Mandrake 8.2. > > After installing the FreeBsd Boot Manager, I get following options: > > F1 ?? > F2 Linux > F3 ?? > F4 FreeBSD > > F4 works and F1 boots into Win2K. > F2 and F3 beep at me but do not boot anything. > > Please tell me how I can correct this and boot mandrake linux from this > menu. At least until FreeBSD knows how to handle my SIS900 network card, > I do need Mandrake!!! Do NOT install FreeBSD bootmanager into MBR unless you have LILO installed into partition (hda2(1?) in your situation)! Now you can repare Mandrake booting using Linux fixit disk. Reinstall LILO and all will be just fine. To learn more, please see Chapter 9 of the FAQ. Best Regards, Serg N. Voronkov, Sibitex JSC, Tyumen, Russia To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 22:21:10 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7688937B401 for ; Thu, 10 Oct 2002 22:21:09 -0700 (PDT) Received: from hawk.mail.pas.earthlink.net (hawk.mail.pas.earthlink.net [207.217.120.22]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0CE6743EAF for ; Thu, 10 Oct 2002 22:21:09 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0520.cvx40-bradley.dialup.earthlink.net ([216.244.44.10] helo=mindspring.com) by hawk.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zsEP-00079Q-00; Thu, 10 Oct 2002 22:21:02 -0700 Message-ID: <3DA65F77.C812618C@mindspring.com> Date: Thu, 10 Oct 2002 22:19:51 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Bill Fumerola Cc: abe , hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> <20021010214518.GB71656@dipole.informationwave.net> <3DA5FCD2.B23CD912@mindspring.com> <20021010222545.GA82461@dipole.informationwave.net> <3DA60447.4C66C85@mindspring.com> <20021010232416.GA97757@dipole.informationwave.net> <3DA6332C.CDC30B95@mindspring.com> <20021011030207.GN80284@elvis.mu.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bill Fumerola wrote: > On Thu, Oct 10, 2002 at 07:10:52PM -0700, Terry Lambert wrote: > > Not to be emphatic, or anything, but IPFW has to be static. There > > is voodoo you can use to make it know about loaded modules, but I'll > > be damned if I know what it is (again, I refer you to the handbook). > > 8-). > > nope. ipfw doesn't have to be static. ipfw+ipdivert has to be static. > up until a while ago, ipfw+dummynet and ipfw+bridge had to be static, > but that was fixed and MFC'd. ipfw by itself (which includes the dynamic > rules) can be static or kldload'd. It has to be static to be abe to get source code from a dump address inside the code, which varies, when it's a module, so you can't decode it from the kernel and the module itself, without knowing where the module loaded. It's doesn't "have to be static" for operational reasons; that's not what I'm claiming. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 22:34:32 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 34F2437B404 for ; Thu, 10 Oct 2002 22:34:31 -0700 (PDT) Received: from hawk.mail.pas.earthlink.net (hawk.mail.pas.earthlink.net [207.217.120.22]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8576643EAC for ; Thu, 10 Oct 2002 22:34:30 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0520.cvx40-bradley.dialup.earthlink.net ([216.244.44.10] helo=mindspring.com) by hawk.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17zsRR-0003x9-00; Thu, 10 Oct 2002 22:34:29 -0700 Message-ID: <3DA6629E.E51A869D@mindspring.com> Date: Thu, 10 Oct 2002 22:33:18 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: abe Cc: hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic References: <20021010212954.GA67855@dipole.informationwave.net> <3DA5F3BC.CD0154CF@mindspring.com> <20021010214518.GB71656@dipole.informationwave.net> <3DA5FCD2.B23CD912@mindspring.com> <20021010222545.GA82461@dipole.informationwave.net> <3DA60447.4C66C85@mindspring.com> <20021010232416.GA97757@dipole.informationwave.net> <3DA6332C.CDC30B95@mindspring.com> <20021011021945.GA46517@dipole.informationwave.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG abe wrote: > > > > gdb -k kernel.debug > > > > list *add_dyn_rule+0x172 > > > > > > (kgdb) list *add_dyn_rule+0x172 > > > No source file for address 0xc021e5d6 > > > (kgdb) > > > > Not to be emphatic, or anything, but IPFW has to be static. > > I thought it was "static" considering I compiled the kernel with support > for it as opposed to loading the module? You didn't; or you would have got GDB output that looked like: ------------------------------------------------------------------------ gdb -k kernel.debug GNU gdb 4.18 Copyright 1998 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i386-unknown-freebsd"... (kgdb) list *add_dyn_rule+0x172 0xc0262e6a is in lookup_dyn_parent (../../netinet/ip_fw2.c:928). 923 ipfw_dyn_rule *q; 924 int i; 925 926 if (ipfw_dyn_v) { 927 i = hash_packet( pkt ); 928 for (q = ipfw_dyn_v[i] ; q != NULL ; q=q->next) 929 if (q->dyn_type == O_LIMIT_PARENT && 930 rule== q->rule && 931 pkt->proto == q->id.proto && 932 pkt->src_ip == q->id.src_ip && (kgdb) ------------------------------------------------------------------------ Note: this is for my code; for your code, the code the offset may end up on a different source line. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Thu Oct 10 23:48:40 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 02EAF37B406; Thu, 10 Oct 2002 23:48:39 -0700 (PDT) Received: from bulwark.switch.com (bulwark.switch.com [206.181.77.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2210E43ED1; Thu, 10 Oct 2002 23:48:38 -0700 (PDT) (envelope-from tnelson@switch.com) Received: from bulwark.switch.com (root@localhost) by bulwark.switch.com with ESMTP id g9B6maxw026799; Fri, 11 Oct 2002 02:48:36 -0400 (EDT) Received: from isunix2.switch.com (isunix2.switch.com [199.234.168.6]) by bulwark.switch.com with ESMTP id g9B6makt026787; Fri, 11 Oct 2002 02:48:36 -0400 (EDT) Received: from exchptc1.switch.com ([199.234.168.10]) by isunix2.switch.com (PMDF V5.2-32 #37720) with ESMTP id <0H3T0005V1KZGM@isunix2.switch.com>; Fri, 11 Oct 2002 02:48:35 -0400 (EDT) Received: by exchptc1.switch.com with Internet Mail Service (5.5.2653.19) id <4LCC1YCY>; Fri, 11 Oct 2002 02:48:35 -0400 Content-return: allowed Date: Fri, 11 Oct 2002 02:48:34 -0400 From: "Nelson, Trent ." Subject: RE: C-2(Security) blues and the like To: "'Craig Rodrigues'" , Robert Watson Cc: Terry Lambert , Steve Kudlak , "Roman V. Mashak" , "'hackers@freebsd.org'" , "Nelson, Trent ." Message-id: <8F329FEDF58BD411BE5200508B10DA7607D71A1A@exchptc1.switch.com> MIME-version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-type: text/plain; charset="iso-8859-1" Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Additionally, take a look at: http://www.cesg.gov.uk/assurance/iacs/itsec/documents/formal-docs/index.htm Trent. > -----Original Message----- > From: Craig Rodrigues [mailto:rodrigc@attbi.com] > Sent: Thursday, October 10, 2002 11:55 PM > To: Robert Watson > Cc: Terry Lambert; Steve Kudlak; Roman V. Mashak; 'hackers@freebsd.org'; > Nelson, Trent . > Subject: Re: C-2(Security) blues and the like > > On Thu, Oct 10, 2002 at 06:34:30PM -0400, Robert Watson wrote: > > > Are ISO standards still on the order of US$9 per single-sided page? I > > > just got my copies of the ECMA standards on CDROM (for free...). > > You can get ISO 15408 (Common Criteria) from ANSI: > http://webstore.ansi.org/ansidocstore/find.asp?find_spec=15408 > > 3 PDF files for $18 each, for a total of $54. > Paper copies cost more. > > > Actually, I believe that the CC should be available for free on the web > > somewhere. Unfortunately, I forget where. Last time I got it, it was a > > free PDF download. > > A quick google search of "Common Criteria" yields: > http://csrc.nist.gov/cc/ccv20/ccv2list.htm > > It has PDF files for download which are not the same as the ISO standard, > but are supposed to be "aligned with ISO 15408". > > -- > Craig Rodrigues > http://www.gis.net/~craigr > rodrigc@attbi.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 0: 0:38 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0666937B401 for ; Fri, 11 Oct 2002 00:00:28 -0700 (PDT) Received: from carp.icir.org (carp.icir.org [192.150.187.71]) by mx1.FreeBSD.org (Postfix) with ESMTP id AC3FB43EAC for ; Fri, 11 Oct 2002 00:00:27 -0700 (PDT) (envelope-from rizzo@carp.icir.org) Received: from carp.icir.org (localhost [127.0.0.1]) by carp.icir.org (8.12.3/8.12.3) with ESMTP id g9B70RO2069731; Fri, 11 Oct 2002 00:00:27 -0700 (PDT) (envelope-from rizzo@carp.icir.org) Received: (from rizzo@localhost) by carp.icir.org (8.12.3/8.12.3/Submit) id g9B70REj069730; Fri, 11 Oct 2002 00:00:27 -0700 (PDT) (envelope-from rizzo) Date: Fri, 11 Oct 2002 00:00:27 -0700 From: Luigi Rizzo To: abe Cc: hackers@FreeBSD.ORG Subject: Re: fatal trap 12 kernel panic Message-ID: <20021011000027.A69671@carp.icir.org> References: <20021011044636.GA84506@dipole.informationwave.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <20021011044636.GA84506@dipole.informationwave.net>; from abe@informationwave.net on Fri, Oct 11, 2002 at 12:46:36AM -0400 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Oct 11, 2002 at 12:46:36AM -0400, abe wrote: ... > Unfortunately, feedback sent while in good intentions did not help. However, in further > tinkering with this issue I believe I've come to a conclusion. I run a rather high-traffic > server so I had initially increased net.inet.ip.fw.dyn_buckets to 500, from the default 256 ah... i think the bucket size has to be a power of two (and I thought the kernel would check that the value is correct, but i might have missed something). In your reports you said this was a very basic install and did not mention you changed parameters. Keep in mind for next time, when you mail a problem report, include all details you can. BTW you never run out of buckets, you can run out of entries, but that is a different sysctl variable. cheers luigi To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 0: 1:44 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D813C37B401 for ; Fri, 11 Oct 2002 00:01:43 -0700 (PDT) Received: from spider.deepcore.dk (cpe.atm2-0-56339.0x50c6aa0a.abnxx2.customer.tele.dk [80.198.170.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id DD06C43EC2 for ; Fri, 11 Oct 2002 00:01:36 -0700 (PDT) (envelope-from sos@spider.deepcore.dk) Received: (from sos@localhost) by spider.deepcore.dk (8.12.5/8.12.6) id g9B71WTo031300 for freebsd-hackers@FreeBSD.ORG; Fri, 11 Oct 2002 09:01:32 +0200 (CEST) (envelope-from sos) From: Soeren Schmidt Message-Id: <200210110701.g9B71WTo031300@spider.deepcore.dk> Subject: Re: Sil 0648/0649/0680 supporting DMA for ATAPI? In-Reply-To: <20021010233242.A4251@gicco.cablecom.ch> To: freebsd-hackers@FreeBSD.ORG Date: Fri, 11 Oct 2002 09:01:32 +0200 (CEST) X-Mailer: ELM [version 2.4ME+ PL98b (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=ISO-8859-1 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG It seems Hanspeter Roth wrote: > On Oct 05 at 15:05, Soeren Schmidt spoke: > > > Too late, I've already added support for the Sil 0680 chip in both > > -current and -stable. BTW it was not supported before that (not even > > Does any of the Sil 0648/0649/0680 support DMA for ATAPI devices, > particularly for Plextor CD-R PX-W4012A? The Sil 680 does support ATAPI DMA, I'll need to dig out the older CMD64[89] to be able to give a definite answer on those.. -Søren To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 0: 3:34 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0D0D537B401 for ; Fri, 11 Oct 2002 00:03:31 -0700 (PDT) Received: from flamingo.mail.pas.earthlink.net (flamingo.mail.pas.earthlink.net [207.217.120.232]) by mx1.FreeBSD.org (Postfix) with ESMTP id 92E8B43EC2 for ; Fri, 11 Oct 2002 00:03:30 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0520.cvx40-bradley.dialup.earthlink.net ([216.244.44.10] helo=mindspring.com) by flamingo.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17ztpX-0002LP-00; Fri, 11 Oct 2002 00:03:28 -0700 Message-ID: <3DA67778.3312A104@mindspring.com> Date: Fri, 11 Oct 2002 00:02:16 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: abe Cc: Bill Fumerola , hackers@freebsd.org Subject: Re: fatal trap 12 kernel panic References: <20021011044636.GA84506@dipole.informationwave.net> <20021011045013.GO80284@elvis.mu.org> <20021011044956.GA87029@dipole.informationwave.net> Content-Type: multipart/mixed; boundary="------------F3BB264D75970FAB27878B65" Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG This is a multi-part message in MIME format. --------------F3BB264D75970FAB27878B65 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit abe wrote: > On Thu, Oct 10, 2002 at 09:50:13PM -0700, Bill Fumerola wrote: > > On Fri, Oct 11, 2002 at 12:46:36AM -0400, abe wrote: > > static u_int32_t dyn_buckets = 256; /* must be power of 2 */ > > Well another issue solved, need thicker glasses it appears. Thanks much > Bill. Funny thing is, it's been running without issue for almost a year > now. Interesting. Try setting it back to 500, and see if you can get a crash. The value of dyn_buckets is seperate from the curr_dyn_buckets in both netinet/ipfw.c and netinet/ipfw2.c. In theory, the value is checked for a power of 2 value before it is used, and that's used to resize. If it isn't a power of 2, then it gets reset to back to curr_dyn_buckets. There is a window in the resize in netinet/ipfw2.c that could cause a probem (the old array is freed before the new array has been successfully allocated -- order of operation bug, IMO). But there should not be an issue with the size being changed... particularly on ip_output() called from send() called from user space. There's also a problem with initial sizing, and a problem if the initial allocation fails, and a couple other problems. I have attached a patch which fixes these problems. Note: This patch may not fix your "500" problem... the correct way to fix that is probably to have the sysctl for dyn_buckets use a set procedure, which refuses the set if it's not a power of 2 and/or rounds it up to the next power of 2 < 65536. -- Terry --------------F3BB264D75970FAB27878B65 Content-Type: text/plain; charset=us-ascii; name="ipfw.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="ipfw.diff" Index: ip_fw.c =================================================================== RCS file: /cvs/src/sys/netinet/ip_fw.c,v retrieving revision 1.188 diff -u -r1.188 ip_fw.c --- ip_fw.c 22 Jun 2002 11:51:02 -0000 1.188 +++ ip_fw.c 11 Oct 2002 03:01:38 -0000 @@ -862,23 +862,40 @@ struct ipfw_dyn_rule *r ; int i ; + + /* new allocation or reallocation */ if (ipfw_dyn_v == NULL || (dyn_count == 0 && dyn_buckets != curr_dyn_buckets)) { - /* try reallocation, make sure we have a power of 2 */ + /* make sure we have a power of 2 */ u_int32_t i = dyn_buckets ; while ( i > 0 && (i & 1) == 0 ) i >>= 1 ; if (i != 1) /* not a power of 2 */ dyn_buckets = curr_dyn_buckets ; /* reset */ - else { - curr_dyn_buckets = dyn_buckets ; - if (ipfw_dyn_v != NULL) - free(ipfw_dyn_v, M_IPFW); - ipfw_dyn_v = malloc(curr_dyn_buckets * sizeof r, + + /* new allocation or reallocation; avoid the realloction on reset */ + if (ipfw_dyn_v == NULL || + (dyn_count == 0 && dyn_buckets != curr_dyn_buckets)) { + ipfw_dyn_rule **new_ipfw_dyn_v; + + /* + * try the allocation; if it's a reallocation, and the malloc + * fails, keep the old area and reset, instead. + */ + new_ipfw_dyn_v = malloc(dyn_buckets * sizeof r, M_IPFW, M_DONTWAIT | M_ZERO); - if (ipfw_dyn_v == NULL) - return NULL; /* failed ! */ + if (new_ipfw_dyn_v != NULL) { + if (ipfw_dyn_v != NULL) + free(ipfw_dyn_v, M_IPFW); + ipfw_dyn_v = new_ipfw_dyn_v; + curr_dyn_buckets = dyn_buckets ; + } else { + dyn_buckets = curr_dyn_buckets ; /* reset */ + } } + + if (ipfw_dyn_v == NULL) + return NULL; /* failed ! */ } i = hash_packet(id); --------------F3BB264D75970FAB27878B65-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 0: 9:43 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 70C1B37B401 for ; Fri, 11 Oct 2002 00:09:42 -0700 (PDT) Received: from flamingo.mail.pas.earthlink.net (flamingo.mail.pas.earthlink.net [207.217.120.232]) by mx1.FreeBSD.org (Postfix) with ESMTP id D4CB643E7B for ; Fri, 11 Oct 2002 00:09:41 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0520.cvx40-bradley.dialup.earthlink.net ([216.244.44.10] helo=mindspring.com) by flamingo.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17ztvX-0006Ba-00; Fri, 11 Oct 2002 00:09:39 -0700 Message-ID: <3DA678EC.9C756D88@mindspring.com> Date: Fri, 11 Oct 2002 00:08:28 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Luigi Rizzo Cc: abe , hackers@FreeBSD.ORG Subject: Re: fatal trap 12 kernel panic References: <20021011044636.GA84506@dipole.informationwave.net> <20021011000027.A69671@carp.icir.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Luigi Rizzo wrote: > On Fri, Oct 11, 2002 at 12:46:36AM -0400, abe wrote: > ... > > Unfortunately, feedback sent while in good intentions did not > > help. However, in further tinkering with this issue I believe I've > > come to a conclusion. I run a rather high-traffic server so I had > > initially increased net.inet.ip.fw.dyn_buckets to 500, from the > > default 256 > > ah... i think the bucket size has to be a power of two (and I thought > the kernel would check that the value is correct, but i might have missed > something). It does check. There's a bug in the allocation code, though, where if it fails the allocation, it can take something that was working, and make it non-working. It can also fail the initial allocation, and drop into the rest of the code, if the value is changed before the startup. See my last posting for a patch for these. I still think the problem is related to the number of requests on a particular UDP socket from too many sources: the failure is in the UDP send path for dynamic rule insertion, which imlies that it's a UDP response. Probably, you could use this to get a packet in that you shouldn't be able to get in, BTW, by abusing a response from an allowed request to make an illegal request (I'm not that into the ipfw code, though). -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 0:10:25 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 259D537B401 for ; Fri, 11 Oct 2002 00:10:22 -0700 (PDT) Received: from storm.FreeBSD.org.uk (storm.FreeBSD.org.uk [194.242.157.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5FC4C43EC2 for ; Fri, 11 Oct 2002 00:10:21 -0700 (PDT) (envelope-from mark@grimreaper.grondar.org) Received: from storm.FreeBSD.org.uk (uucp@localhost [127.0.0.1]) by storm.FreeBSD.org.uk (8.12.6/8.12.6) with ESMTP id g9B7AKW1013817; Fri, 11 Oct 2002 08:10:20 +0100 (BST) (envelope-from mark@grimreaper.grondar.org) Received: (from uucp@localhost) by storm.FreeBSD.org.uk (8.12.6/8.12.6/Submit) with UUCP id g9B7AKb2013816; Fri, 11 Oct 2002 08:10:20 +0100 (BST) Received: from grimreaper.grondar.org (localhost [127.0.0.1]) by grimreaper.grondar.org (8.12.6/8.12.5) with ESMTP id g9B78b01061654; Fri, 11 Oct 2002 08:08:37 +0100 (BST) (envelope-from mark@grimreaper.grondar.org) Message-Id: <200210110708.g9B78b01061654@grimreaper.grondar.org> To: "Firsto Lasto" Cc: mark@grondar.za, freebsd-hackers@FreeBSD.ORG Subject: Re: PRNG not seeded - error in non-root ssh inside 4.6.2 jails... References: In-Reply-To: ; from "Firsto Lasto" "Thu, 10 Oct 2002 14:47:24 PDT." Date: Fri, 11 Oct 2002 08:08:37 +0100 From: Mark Murray Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > > Do you mean recompile SSL using urandom instead of random ? Yes. > Would it be the exact same effect if I simply changed my /dev/random to > major/minor 2,4 instead of 2,3 ? Yes. That would work. > It seems like that would be much easier... Indeed! M > > > Ok, I am not sure how I can do that though - I cannot successfully run > > > `rndcontrol -s X` inside a jail. > > > > > > On the other hand, I already have: > > > > > > rand_irqs="9 10 11 13 14" > > > > > > In my rc.conf on the underlying host machine, and have done several > >boots > > > with that in place. So presumably I should be seeded just fine, but if > >I am > > > not, I cannot change that in the jail because it seems I cannot set that > >(I > > > assume it is a sysctl issue). > > > > > > Willing to try whatever you can think of next :) > > > >Hokay. Can you grovel around inside OpenSSL (src/crypto/openssl/...) and > >find where the random device is read? If it is /dev/random, then change > >that to /dev/urandom. > > > >See how that works. > > > >M > > > > > > > I can't seed it by banging on the keyboard - it is a headless server > >in > > > >a > > > > > rack thousands of miles from me :) > > > > > > > > > > Perhaps there is another way to do it ? > > > > > > > >Yes. > > > > > > > >You need to find sources of entropy in interrupts. Look at a > > > >dmesg, and note which IRQ's your network device(s) and mass > > > >storage controller(s) (both SCSI and ATA). Use any other > > > >irq's that aren't too busy and may be somewhat random. > > > >Staring at a 'systat 2 -vmstat' screen (right hand side) > > > >may give some clues. > > > > > > > >Then use rndcontrol(8) to set up the seeding. There is a knob > > > >in rc.conf to make this setting survive the next reboot. > > > > > > > >M > > > > > > > > > >Date: Thu, 03 Oct 2002 21:54:30 +0100 > > > > > > > > > > > > > Sorry, here is the rest: > > > > > > > > > > > > > > Here is the output of the `dd` command using urandom: > > > > > > > > > > > > > > dd if=/dev/urandom of=/dev/stdout bs=512 count=1 | hexdump -C > > > > > > > 1+0 records in > > > > > > > 1+0 records out > > > > > > > 00000000 a0 69 1a 7c 8f 32 e5 21 ae 7a 33 14 68 0b 8e a6 > > > > > > > |.i.|.2.!.z3.h...| > > > > > > > > > > > >... etc. Looking good. > > > > > > > > > > > > > $ ls -l /dev/*rand* > > > > > > > crw-r--r-- 1 root wheel 2, 3 Sep 3 21:46 /dev/random > > > > > > > crw-r--r-- 1 root wheel 2, 4 Sep 3 21:46 /dev/urandom > > > > > > > > > > > >Also good. > > > > > > > > > > > > > > > So then, as root I ran: `chmod 0666 /dev/stdout` and then I > >ran > > > >your > > > > > > > >`dd` > > > > > > > > > command and got: > > > > > > > > > > > > > > > > > > $ dd if=/dev/random of=/dev/stdout bs=512 count=1 | hexdump > >-C > > > > > > > > > 0+0 records in > > > > > > > > > 0+0 records out > > > > > > > > > 0 bytes transferred in 0.000036 secs (0 bytes/sec) > > > > > > > > > > > >Can you try a few of these while furiously abusing your keyboard? > > > > > >I'm trying to see if /dev/random can be persuaded to give _any_ > > > > > >aoutput at all. > > > > > > > > > > > >Maybe do it on a vty instead of in X. > > > > > > > > > > > >M > > > > > >-- > > > > > >o Mark Murray > > > > > >\_ > > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > > > > > > _________________________________________________________________ > > > > > Chat with friends online, try MSN Messenger: > >http://messenger.msn.com > > > > > > > > >-- > > > >o Mark Murray > > > >\_ > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > _________________________________________________________________ > > > Send and receive Hotmail on your mobile device: http://mobile.msn.com > > > > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > > with "unsubscribe freebsd-hackers" in the body of the message > >-- > >o Mark Murray > >\_ > >O.\_ Warning: this .sig is umop ap!sdn > > > > > _________________________________________________________________ > Send and receive Hotmail on your mobile device: http://mobile.msn.com > -- o Mark Murray \_ O.\_ Warning: this .sig is umop ap!sdn To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 1:13: 0 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CB09337B401 for ; Fri, 11 Oct 2002 01:12:55 -0700 (PDT) Received: from hotmail.com (f99.sea1.hotmail.com [207.68.163.99]) by mx1.FreeBSD.org (Postfix) with ESMTP id 60DFF43EB3 for ; Fri, 11 Oct 2002 01:12:55 -0700 (PDT) (envelope-from firstolasto@hotmail.com) Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC; Fri, 11 Oct 2002 01:12:55 -0700 Received: from 12.235.232.75 by sea1fd.sea1.hotmail.msn.com with HTTP; Fri, 11 Oct 2002 08:12:54 GMT X-Originating-IP: [12.235.232.75] From: "Firsto Lasto" To: mark@grondar.za Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: PRNG not seeded - error in non-root ssh inside 4.6.2 jails... Date: Fri, 11 Oct 2002 01:12:54 -0700 Mime-Version: 1.0 Content-Type: text/plain; format=flowed Message-ID: X-OriginalArrivalTime: 11 Oct 2002 08:12:55.0064 (UTC) FILETIME=[00686180:01C270FE] Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Ok, I did this, and got the exact same results - first it says that PRNG is not seeded, and then I chmod 0666 /dev/urandom and then it tells me "host key verification failed". So, just in case I also did the opposite - I left random alone and set urandom to 2,3 so it behaves like random ... and this was interesting, when I did this, it told me PRNG not seeded no matter what I set the permissions to - so at no point did I progress to "host key verification failed". Hope this helps - I hate to think that the single most used userland application does not function inside of jail (which is the case, it seems, at least in 4.6.2) > > > > > Do you mean recompile SSL using urandom instead of random ? > >Yes. > > > Would it be the exact same effect if I simply changed my /dev/random to > > major/minor 2,4 instead of 2,3 ? > >Yes. That would work. > > > It seems like that would be much easier... > >Indeed! > >M > > > > > Ok, I am not sure how I can do that though - I cannot successfully >run > > > > `rndcontrol -s X` inside a jail. > > > > > > > > On the other hand, I already have: > > > > > > > > rand_irqs="9 10 11 13 14" > > > > > > > > In my rc.conf on the underlying host machine, and have done several > > >boots > > > > with that in place. So presumably I should be seeded just fine, but >if > > >I am > > > > not, I cannot change that in the jail because it seems I cannot set >that > > >(I > > > > assume it is a sysctl issue). > > > > > > > > Willing to try whatever you can think of next :) > > > > > >Hokay. Can you grovel around inside OpenSSL (src/crypto/openssl/...) >and > > >find where the random device is read? If it is /dev/random, then change > > >that to /dev/urandom. > > > > > >See how that works. > > > > > >M > > > > > > > > > I can't seed it by banging on the keyboard - it is a headless >server > > >in > > > > >a > > > > > > rack thousands of miles from me :) > > > > > > > > > > > > Perhaps there is another way to do it ? > > > > > > > > > >Yes. > > > > > > > > > >You need to find sources of entropy in interrupts. Look at a > > > > >dmesg, and note which IRQ's your network device(s) and mass > > > > >storage controller(s) (both SCSI and ATA). Use any other > > > > >irq's that aren't too busy and may be somewhat random. > > > > >Staring at a 'systat 2 -vmstat' screen (right hand side) > > > > >may give some clues. > > > > > > > > > >Then use rndcontrol(8) to set up the seeding. There is a knob > > > > >in rc.conf to make this setting survive the next reboot. > > > > > > > > > >M > > > > > > > > > > > >Date: Thu, 03 Oct 2002 21:54:30 +0100 > > > > > > > > > > > > > > > Sorry, here is the rest: > > > > > > > > > > > > > > > > Here is the output of the `dd` command using urandom: > > > > > > > > > > > > > > > > dd if=/dev/urandom of=/dev/stdout bs=512 count=1 | hexdump >-C > > > > > > > > 1+0 records in > > > > > > > > 1+0 records out > > > > > > > > 00000000 a0 69 1a 7c 8f 32 e5 21 ae 7a 33 14 68 0b 8e a6 > > > > > > > > |.i.|.2.!.z3.h...| > > > > > > > > > > > > > >... etc. Looking good. > > > > > > > > > > > > > > > $ ls -l /dev/*rand* > > > > > > > > crw-r--r-- 1 root wheel 2, 3 Sep 3 21:46 /dev/random > > > > > > > > crw-r--r-- 1 root wheel 2, 4 Sep 3 21:46 >/dev/urandom > > > > > > > > > > > > > >Also good. > > > > > > > > > > > > > > > > > So then, as root I ran: `chmod 0666 /dev/stdout` and >then I > > >ran > > > > >your > > > > > > > > >`dd` > > > > > > > > > > command and got: > > > > > > > > > > > > > > > > > > > > $ dd if=/dev/random of=/dev/stdout bs=512 count=1 | >hexdump > > >-C > > > > > > > > > > 0+0 records in > > > > > > > > > > 0+0 records out > > > > > > > > > > 0 bytes transferred in 0.000036 secs (0 bytes/sec) > > > > > > > > > > > > > >Can you try a few of these while furiously abusing your >keyboard? > > > > > > >I'm trying to see if /dev/random can be persuaded to give _any_ > > > > > > >aoutput at all. > > > > > > > > > > > > > >Maybe do it on a vty instead of in X. > > > > > > > > > > > > > >M > > > > > > >-- > > > > > > >o Mark Murray > > > > > > >\_ > > > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >_________________________________________________________________ > > > > > > Chat with friends online, try MSN Messenger: > > >http://messenger.msn.com > > > > > > > > > > >-- > > > > >o Mark Murray > > > > >\_ > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > _________________________________________________________________ > > > > Send and receive Hotmail on your mobile device: >http://mobile.msn.com > > > > > > > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > > > with "unsubscribe freebsd-hackers" in the body of the message > > >-- > > >o Mark Murray > > >\_ > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > _________________________________________________________________ > > Send and receive Hotmail on your mobile device: http://mobile.msn.com > > >-- >o Mark Murray >\_ >O.\_ Warning: this .sig is umop ap!sdn _________________________________________________________________ MSN Photos is the easiest way to share and print your photos: http://photos.msn.com/support/worldwide.aspx To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 1:20:17 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EF38937B401 for ; Fri, 11 Oct 2002 01:20:12 -0700 (PDT) Received: from storm.FreeBSD.org.uk (storm.FreeBSD.org.uk [194.242.157.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2A8C443E7B for ; Fri, 11 Oct 2002 01:20:12 -0700 (PDT) (envelope-from mark@grimreaper.grondar.org) Received: from storm.FreeBSD.org.uk (uucp@localhost [127.0.0.1]) by storm.FreeBSD.org.uk (8.12.6/8.12.6) with ESMTP id g9B8KBW1072791; Fri, 11 Oct 2002 09:20:11 +0100 (BST) (envelope-from mark@grimreaper.grondar.org) Received: (from uucp@localhost) by storm.FreeBSD.org.uk (8.12.6/8.12.6/Submit) with UUCP id g9B8KBvd072790; Fri, 11 Oct 2002 09:20:11 +0100 (BST) Received: from grimreaper.grondar.org (localhost [127.0.0.1]) by grimreaper.grondar.org (8.12.6/8.12.5) with ESMTP id g9B8Ie01062513; Fri, 11 Oct 2002 09:18:40 +0100 (BST) (envelope-from mark@grimreaper.grondar.org) Message-Id: <200210110818.g9B8Ie01062513@grimreaper.grondar.org> To: "Firsto Lasto" Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: PRNG not seeded - error in non-root ssh inside 4.6.2 jails... References: In-Reply-To: ; from "Firsto Lasto" "Fri, 11 Oct 2002 01:12:54 PDT." Date: Fri, 11 Oct 2002 09:18:40 +0100 From: Mark Murray Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > Ok, I did this, and got the exact same results - first it says that PRNG is > not seeded, and then I chmod 0666 /dev/urandom and then it tells me "host > key verification failed". I hope you mean /dev/random? M > > So, just in case I also did the opposite - I left random alone and set > urandom to 2,3 so it behaves like random ... and this was interesting, when > I did this, it told me PRNG not seeded no matter what I set the permissions > to - so at no point did I progress to "host key verification failed". > > Hope this helps - I hate to think that the single most used userland > application does not function inside of jail (which is the case, it seems, > at least in 4.6.2) > > > > > > > > > Do you mean recompile SSL using urandom instead of random ? > > > >Yes. > > > > > Would it be the exact same effect if I simply changed my /dev/random to > > > major/minor 2,4 instead of 2,3 ? > > > >Yes. That would work. > > > > > It seems like that would be much easier... > > > >Indeed! > > > >M > > > > > > > Ok, I am not sure how I can do that though - I cannot successfully > >run > > > > > `rndcontrol -s X` inside a jail. > > > > > > > > > > On the other hand, I already have: > > > > > > > > > > rand_irqs="9 10 11 13 14" > > > > > > > > > > In my rc.conf on the underlying host machine, and have done several > > > >boots > > > > > with that in place. So presumably I should be seeded just fine, but > >if > > > >I am > > > > > not, I cannot change that in the jail because it seems I cannot set > >that > > > >(I > > > > > assume it is a sysctl issue). > > > > > > > > > > Willing to try whatever you can think of next :) > > > > > > > >Hokay. Can you grovel around inside OpenSSL (src/crypto/openssl/...) > >and > > > >find where the random device is read? If it is /dev/random, then change > > > >that to /dev/urandom. > > > > > > > >See how that works. > > > > > > > >M > > > > > > > > > > > I can't seed it by banging on the keyboard - it is a headless > >server > > > >in > > > > > >a > > > > > > > rack thousands of miles from me :) > > > > > > > > > > > > > > Perhaps there is another way to do it ? > > > > > > > > > > > >Yes. > > > > > > > > > > > >You need to find sources of entropy in interrupts. Look at a > > > > > >dmesg, and note which IRQ's your network device(s) and mass > > > > > >storage controller(s) (both SCSI and ATA). Use any other > > > > > >irq's that aren't too busy and may be somewhat random. > > > > > >Staring at a 'systat 2 -vmstat' screen (right hand side) > > > > > >may give some clues. > > > > > > > > > > > >Then use rndcontrol(8) to set up the seeding. There is a knob > > > > > >in rc.conf to make this setting survive the next reboot. > > > > > > > > > > > >M > > > > > > > > > > > > > >Date: Thu, 03 Oct 2002 21:54:30 +0100 > > > > > > > > > > > > > > > > > Sorry, here is the rest: > > > > > > > > > > > > > > > > > > Here is the output of the `dd` command using urandom: > > > > > > > > > > > > > > > > > > dd if=/dev/urandom of=/dev/stdout bs=512 count=1 | hexdump > >-C > > > > > > > > > 1+0 records in > > > > > > > > > 1+0 records out > > > > > > > > > 00000000 a0 69 1a 7c 8f 32 e5 21 ae 7a 33 14 68 0b 8e a6 > > > > > > > > > |.i.|.2.!.z3.h...| > > > > > > > > > > > > > > > >... etc. Looking good. > > > > > > > > > > > > > > > > > $ ls -l /dev/*rand* > > > > > > > > > crw-r--r-- 1 root wheel 2, 3 Sep 3 21:46 /dev/random > > > > > > > > > crw-r--r-- 1 root wheel 2, 4 Sep 3 21:46 > >/dev/urandom > > > > > > > > > > > > > > > >Also good. > > > > > > > > > > > > > > > > > > > So then, as root I ran: `chmod 0666 /dev/stdout` and > >then I > > > >ran > > > > > >your > > > > > > > > > >`dd` > > > > > > > > > > > command and got: > > > > > > > > > > > > > > > > > > > > > > $ dd if=/dev/random of=/dev/stdout bs=512 count=1 | > >hexdump > > > >-C > > > > > > > > > > > 0+0 records in > > > > > > > > > > > 0+0 records out > > > > > > > > > > > 0 bytes transferred in 0.000036 secs (0 bytes/sec) > > > > > > > > > > > > > > > >Can you try a few of these while furiously abusing your > >keyboard? > > > > > > > >I'm trying to see if /dev/random can be persuaded to give _any_ > > > > > > > >aoutput at all. > > > > > > > > > > > > > > > >Maybe do it on a vty instead of in X. > > > > > > > > > > > > > > > >M > > > > > > > >-- > > > > > > > >o Mark Murray > > > > > > > >\_ > > > > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >_________________________________________________________________ > > > > > > > Chat with friends online, try MSN Messenger: > > > >http://messenger.msn.com > > > > > > > > > > > > >-- > > > > > >o Mark Murray > > > > > >\_ > > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > > > > > > _________________________________________________________________ > > > > > Send and receive Hotmail on your mobile device: > >http://mobile.msn.com > > > > > > > > > > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > > > > with "unsubscribe freebsd-hackers" in the body of the message > > > >-- > > > >o Mark Murray > > > >\_ > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > _________________________________________________________________ > > > Send and receive Hotmail on your mobile device: http://mobile.msn.com > > > > >-- > >o Mark Murray > >\_ > >O.\_ Warning: this .sig is umop ap!sdn > > > > _________________________________________________________________ > MSN Photos is the easiest way to share and print your photos: > http://photos.msn.com/support/worldwide.aspx > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message -- o Mark Murray \_ O.\_ Warning: this .sig is umop ap!sdn To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 1:34:54 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 229DC37B401; Fri, 11 Oct 2002 01:34:52 -0700 (PDT) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9AF3843E65; Fri, 11 Oct 2002 01:34:50 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id SAA10239; Fri, 11 Oct 2002 18:34:42 +1000 Date: Fri, 11 Oct 2002 18:44:53 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Terry Lambert Cc: Craig Rodrigues , , Subject: Re: Problem detecting POSIX symbolic constants In-Reply-To: <3DA5D5BD.1DAFF031@mindspring.com> Message-ID: <20021011183032.D12170-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, 10 Oct 2002, Terry Lambert wrote: > Bruce Evans wrote: > > In Standard C, this is equivalent to the non-verbose version: > > > > #if _POSIX_REALTIME_SIGNALS != -1 > > ... > > #endif > > > > since if _POSIX_REALTIME_SIGNALS is not defined then it is equivalent to > > 0 in cpp expressions. The problem cases are if _POSIX_REALTIME_SIGNALS > > is defined to or , but these are not permitted in > > POSIX.1-2001. These cases were permitted for many feature test macros > > in POSIX.1-1990. > > I know it's not fashionable to write code that's portable to > compilers other than GCC, but even if FreeBSD is going to ignore > portability for it's own source code, it's probably unreasonable > to expect ACE to ignore portability for theirs. Undefined symbols being 0 in cpp in expressions was in early C compilers if not the original one. Consult your archives for a posting 10-15 years or so ago by dmr in comp.std.c about him checking this in his archives. > > > Sigh. Why did the POSIX guys do this? :( > > > > Perhaps because they wanted you to use sysconf() instead of these mistakes. > > Actually, they didn't do this. _POSIX_REALTIME_SIGNALS is specified to > > have value 0, -1 or 200xxxL (draft 7 says xxx; I think the final standard > > says 112). > > This can't be the case; specifically, the sysconf() test will > only work at runtime, which means that the symbols had to be > there and resolvable at link time. Symbols can be resolved at runtime using dlopen(), etc. They would only actually be available on systems where sysconf() says that they are. > > > BTW, I think that: > > > #if defined(_POSIX_REALTIME_SIGNALS) && (_POSIX_REALTIME_SIGNALS != -1 ) > > > > > > should suffice, but I'll double-check with one of my portability gurus > > > to see if that is OK for ACE. > > > > This is variant of the above verbose version. It requires slightly more > > modern compilers, so it might fail for some 20-year old pre-Standard C > > compilers instead of only for some 25-year old ones. > > Uh, the 1990 standard, which allowed "#if" is only 12 years old. #if is in K&R1 (1978). Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 1:43:34 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 921CD37B401; Fri, 11 Oct 2002 01:43:32 -0700 (PDT) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6DE1343EB3; Fri, 11 Oct 2002 01:43:31 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id SAA11085; Fri, 11 Oct 2002 18:43:23 +1000 Date: Fri, 11 Oct 2002 18:53:35 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Terry Lambert Cc: Craig Rodrigues , , Subject: Re: Problem detecting POSIX symbolic constants In-Reply-To: <3DA5D741.FB59AE1B@mindspring.com> Message-ID: <20021011184643.U12170-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, 10 Oct 2002, Terry Lambert wrote: > Bruce Evans wrote: > > _POSIX_REALTIME_SIGNALS is undefined: > > Apparently the same as when it is defined to 0, except you cannot assume > > that anything related to it works until you call sysconf(), so you must > > not reference its interfaces statically, and must use a dll or something > > that references it. The dll is presumably available on systems that > > support it but not (except possibly a dummy version) on systems that > > don't support it. > > > > I think the case where the symbol is undefined should never be implemented > > in practice. It can be reduced to the case where the symbol is 0 using > > dynamic linkage with the complications for linkage not visible to the > > application. > > I think you will have to go back in time, for this to happen. As > things stand today, there are systems where it's undefined that > were implemented before the symbol was a twinkle in some feature-test > weenie on the POSIX committee's eye. _POSIX_REALTIME_SIGNALS is only valid in versions of POSIX that support it. Applications must also conditionalize on _POSIX_VERSION if they want to check for features that are not in all versions. Runtime configuration only lets us go forward in time. An application might use POSIX realtime features if they are available and magically start working better (without recompiling anything in the application) when the OS and/or library implementors get around to implementing the features. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 2:11:16 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 045B837B401 for ; Fri, 11 Oct 2002 02:11:15 -0700 (PDT) Received: from scribble.fsn.hu (scribble.fsn.hu [193.224.40.95]) by mx1.FreeBSD.org (Postfix) with SMTP id 2F09143EB7 for ; Fri, 11 Oct 2002 02:11:12 -0700 (PDT) (envelope-from bra@fsn.hu) Received: (qmail 6526 invoked by uid 1000); 11 Oct 2002 09:11:11 -0000 Received: from localhost (sendmail-bs@127.0.0.1) by localhost with SMTP; 11 Oct 2002 09:11:11 -0000 Date: Fri, 11 Oct 2002 11:11:11 +0200 (CEST) From: Attila Nagy To: Dan Nelson Cc: hackers@FreeBSD.ORG Subject: Re: Sharing a SCSI bus between some computers In-Reply-To: <20021010172835.GA24603@dan.emsphone.com> Message-ID: References: <20021010172835.GA24603@dan.emsphone.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hello, > As long as BOX3 never writes data, you're okay. If this would be the scenario, all boxes would mount the FS RO :) > The problem is that BOX1/2 don't know when BOX3 has invalidated their > cached data by writing to the disk. What problems could that cause? I don't mind if BOX[1-2] reads a file and the file disappears in the middle of the transfer, if those boxes can recognize it and will not read other portions of the hard disk. In short: if they won't offer corrupt data to the clients. > What you want is a shared-storage filesystem, and there is no such thing > for FreeBSD. BTW, is it possible to do it with common SCSI storage, or it would need some sophisticated solution, like fibre channel? > Considering you can get a gigabit ethernet NIC for under $50 and a > D-Link 4-port gigabit switch for $300, you might just want to plug the > RAID into BOX3, and have BOX1/2 NFS-mount it. Oh I know this :) Actually, this is exactly what I have. But because the machines (box1-3) aren't as powerful at all, I would like to get the maximum out of them. ----------[ Free Software ISOs - http://www.fsn.hu/?f=download ]---------- Attila Nagy e-mail: Attila.Nagy@fsn.hu Free Software Network (FSN.HU) phone @work: +361 210 1415 (194) cell.: +3630 306 6758 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 2:27:52 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9777037B401 for ; Fri, 11 Oct 2002 02:27:51 -0700 (PDT) Received: from horkos.telenet-ops.be (horkos.telenet-ops.be [195.130.132.45]) by mx1.FreeBSD.org (Postfix) with ESMTP id 20A3D43EAC for ; Fri, 11 Oct 2002 02:27:51 -0700 (PDT) (envelope-from Guido@VanHoecke.org) Received: from localhost (localhost.localdomain [127.0.0.1]) by horkos.telenet-ops.be (Postfix) with SMTP id D8AB283FF7; Fri, 11 Oct 2002 11:27:49 +0200 (CEST) Received: from VanHoecke.org (D5E0E969.kabel.telenet.be [213.224.233.105]) by horkos.telenet-ops.be (Postfix) with ESMTP id 2410383DAE; Fri, 11 Oct 2002 11:27:49 +0200 (CEST) Message-ID: <3DA69995.70309@VanHoecke.org> Date: Fri, 11 Oct 2002 11:27:49 +0200 From: Guido Van Hoecke User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2a) Gecko/20020910 X-Accept-Language: en-us, en MIME-Version: 1.0 To: "Sergey N. Voronkov" Cc: freebsd-hackers Subject: Re: 4.7 messed up my mandrake-lilo config References: <3DA6100C.8080303@VanHoecke.org> <20021011045351.GA80995@sv.tech.sibitex.tmn.ru> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Sergey N. Voronkov wrote: > On Fri, Oct 11, 2002 at 01:41:00AM +0200, Guido Van Hoecke wrote: >>Please tell me how I can correct this and boot mandrake linux from this >>menu. At least until FreeBSD knows how to handle my SIS900 network card, >>I do need Mandrake!!! > Now you can repare Mandrake booting using Linux fixit disk. Reinstall LILO > and all will be just fine. > > To learn more, please see Chapter 9 of the FAQ. Read, learned a lot and fixed my lilo. Thanks! -- Guido Van Hoecke To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 2:37:36 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B916137B401 for ; Fri, 11 Oct 2002 02:37:35 -0700 (PDT) Received: from relay03.cablecom.net (relay03.cablecom.net [62.2.33.103]) by mx1.FreeBSD.org (Postfix) with ESMTP id BF1CF43EB1 for ; Fri, 11 Oct 2002 02:37:34 -0700 (PDT) (envelope-from hanspeter_roth@hotmail.com) Received: from localhost.cablecom.ch (dclient80-218-74-198.hispeed.ch [80.218.74.198]) by relay03.cablecom.net (8.12.5/8.12.5/SOL/AWF/MXRELAY/20020820) with ESMTP id g9B9bWMO034907 for ; Fri, 11 Oct 2002 11:37:32 +0200 (CEST) (envelope-from hanspeter_roth@hotmail.com) Received: from gicco.local.fake (localhost [127.0.0.1]) by localhost.cablecom.ch (8.12.3/8.12.3/Debian -4) with ESMTP id g9B9bWH2001726 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=FAIL) for ; Fri, 11 Oct 2002 11:37:33 +0200 Received: (from idefix@localhost) by gicco.local.fake (8.12.3/8.12.3/Debian -4) id g9B9bVkX001724 for freebsd-hackers@FreeBSD.ORG; Fri, 11 Oct 2002 11:37:31 +0200 X-Authentication-Warning: gicco.local.fake: idefix set sender to hanspeter_roth@hotmail.com using -f Date: Fri, 11 Oct 2002 11:37:31 +0200 From: Hanspeter Roth To: freebsd-hackers@FreeBSD.ORG Subject: Re: Sil 0648/0649/0680 supporting DMA for ATAPI? Message-ID: <20021011093731.GA1714@gicco.cablecom.ch> Reply-To: freebsd-hackers@FreeBSD.ORG Mail-Followup-To: freebsd-hackers@FreeBSD.ORG References: <20021010233242.A4251@gicco.cablecom.ch> <200210110701.g9B71WTo031300@spider.deepcore.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200210110701.g9B71WTo031300@spider.deepcore.dk> User-Agent: Mutt/1.3.28i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Oct 11 at 09:01, Soeren Schmidt spoke: > The Sil 680 does support ATAPI DMA, I'll need to dig out the older Great! > CMD64[89] to be able to give a definite answer on those.. Ok. Don't bother about the older once. The SiI 680 is probably easier to acquire anyway. Thanks. -Hanspeter To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 2:39: 4 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8DC9D37B401 for ; Fri, 11 Oct 2002 02:39:03 -0700 (PDT) Received: from scribble.fsn.hu (scribble.fsn.hu [193.224.40.95]) by mx1.FreeBSD.org (Postfix) with SMTP id 0112543E9E for ; Fri, 11 Oct 2002 02:39:01 -0700 (PDT) (envelope-from bra@fsn.hu) Received: (qmail 7761 invoked by uid 1000); 11 Oct 2002 09:39:02 -0000 Received: from localhost (sendmail-bs@127.0.0.1) by localhost with SMTP; 11 Oct 2002 09:39:02 -0000 Date: Fri, 11 Oct 2002 11:39:02 +0200 (CEST) From: Attila Nagy To: Bruce M Simpson Cc: Dan Nelson , Subject: Re: Sharing a SCSI bus between some computers In-Reply-To: <20021011081814.GD25634@spc.org> Message-ID: References: <20021010172835.GA24603@dan.emsphone.com> <20021011081814.GD25634@spc.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hello, > I believe that SGI's xfs is capable of handling shared-storage setups... After Dan's mail I would think that only some kind of signalling would needed to accomplish the task of one RW and multiple RO machines using the same SCSI storage. This could be done in the hardware and in the software. All I could get on this topic is the problem of multiple RW machines, for which the Linux-specific GFS[1] used the SCSI locking feature of the individual devices and then implemented some kind of external locking, other distributed filesystems did similar methods. How difficult would be to implement this, either into the recently announced GEOM or some other layers? Thanks, [1]: http://www.sistina.com/products_gfs.htm ----------[ Free Software ISOs - http://www.fsn.hu/?f=download ]---------- Attila Nagy e-mail: Attila.Nagy@fsn.hu Free Software Network (FSN.HU) phone @work: +361 210 1415 (194) cell.: +3630 306 6758 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 3:29: 2 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 80A8B37B401 for ; Fri, 11 Oct 2002 03:29:01 -0700 (PDT) Received: from relay01.cablecom.net (relay01.cablecom.net [62.2.33.101]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9B05343E91 for ; Fri, 11 Oct 2002 03:29:00 -0700 (PDT) (envelope-from hanspeter_roth@hotmail.com) Received: from snoopy.cablecom.ch (dclient80-218-74-198.hispeed.ch [80.218.74.198]) by relay01.cablecom.net (8.12.5/8.12.5/SOL/AWF/MXRELAY/20020820) with ESMTP id g9BASwZ2035999 for ; Fri, 11 Oct 2002 12:28:59 +0200 (CEST) (envelope-from hanspeter_roth@hotmail.com) Received: (from idefix@localhost) by snoopy.cablecom.ch (8.11.6/8.11.6) id g9BASwm01054 for freebsd-hackers@FreeBSD.ORG; Fri, 11 Oct 2002 12:28:58 +0200 (CEST) (envelope-from hanspeter_roth@hotmail.com) Date: Fri, 11 Oct 2002 12:28:58 +0200 From: Hanspeter Roth To: freebsd-hackers@FreeBSD.ORG Subject: Re: Sil 0648/0649/0680 supporting DMA for ATAPI? Message-ID: <20021011122858.A991@gicco.cablecom.ch> Reply-To: freebsd-hackers@FreeBSD.ORG Mail-Followup-To: freebsd-hackers@FreeBSD.ORG References: <20021010233242.A4251@gicco.cablecom.ch> <200210110701.g9B71WTo031300@spider.deepcore.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <200210110701.g9B71WTo031300@spider.deepcore.dk>; from sos@spider.deepcore.dk on Fri, Oct 11, 2002 at 09:01:32AM +0200 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Oct 11 at 09:01, Soeren Schmidt spoke: > The Sil 680 does support ATAPI DMA, I'll need to dig out the older Would this also cover Dawicontrol Ultra DMA 133 RAID which is claimed to be built upon SiI 0680? http://www.dawicontrol.com/english/html/raid133.htm -Hanspeter To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 3:32:29 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AD6A137B401 for ; Fri, 11 Oct 2002 03:32:28 -0700 (PDT) Received: from spider.deepcore.dk (cpe.atm2-0-56339.0x50c6aa0a.abnxx2.customer.tele.dk [80.198.170.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id B15B743EB2 for ; Fri, 11 Oct 2002 03:32:24 -0700 (PDT) (envelope-from sos@spider.deepcore.dk) Received: (from sos@localhost) by spider.deepcore.dk (8.12.5/8.12.6) id g9BAWJ1i064505 for freebsd-hackers@FreeBSD.ORG; Fri, 11 Oct 2002 12:32:19 +0200 (CEST) (envelope-from sos) From: Soeren Schmidt Message-Id: <200210111032.g9BAWJ1i064505@spider.deepcore.dk> Subject: Re: Sil 0648/0649/0680 supporting DMA for ATAPI? In-Reply-To: <20021011122858.A991@gicco.cablecom.ch> To: freebsd-hackers@FreeBSD.ORG Date: Fri, 11 Oct 2002 12:32:18 +0200 (CEST) X-Mailer: ELM [version 2.4ME+ PL98b (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=ISO-8859-1 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG It seems Hanspeter Roth wrote: > On Oct 11 at 09:01, Soeren Schmidt spoke: > > > The Sil 680 does support ATAPI DMA, I'll need to dig out the older > > Would this also cover Dawicontrol Ultra DMA 133 RAID which is > claimed to be built upon SiI 0680? Yes, if its a Sil 0680 chip then it'll work, the one I've got is a Sunix SNX 3700, its a feature of the chip not the card (unless the maker really screwed up something).... -Søren To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 4: 2: 1 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 95CD037B401; Fri, 11 Oct 2002 04:01:59 -0700 (PDT) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id 750F143EB1; Fri, 11 Oct 2002 04:01:58 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id VAA26228; Fri, 11 Oct 2002 21:01:48 +1000 Date: Fri, 11 Oct 2002 21:12:00 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Craig Rodrigues Cc: freebsd-standards@FreeBSD.ORG, Subject: Re: Problem detecting POSIX symbolic constants In-Reply-To: <20021010105531.A12354@attbi.com> Message-ID: <20021011210139.H12589-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, 10 Oct 2002, Craig Rodrigues wrote: > On Thu, Oct 10, 2002 at 09:31:56PM +1000, Bruce Evans wrote: > > Perhaps because they wanted you to use sysconf() instead of these mistakes. > > Well in the case of ACE, it is a C++ library that is compiled on > platforms which may or may not have sysconf() (ie. Windows), so using sysconf() is > not practical in this case. Checking a feature macro is much easier. How can new POSIX interfaces and new POSIX feature test macros work on systems that don't have ancient POSIX interfaces like sysconf(). As may have been clarified in other meesages in this thread, you need a new version of POSIX even to interpret _POSIX_REALTIME_SIGNALS. It is in POSIX.1-1996 and perhaps in earlier versions of POSIX (not including at least the 1990 one), so it is meaningless unless _POSIX_VERSION > 199mumble. > > I used a variant your patch for this in PR 35924 until recently when > > ... > This patch works for me. I think it is just as easy to just remove cruft from > the header file entirely, but since your patch effectively does the same > thing and has informative comments, that is fine. I slightly prefer to ifdef them, since an implementation is planned. > If your patch (or some equivalent variant) is committed, then I think > PR 35924 can be closed. Something needs to be done about these prototypes. OK, I will clean up the patch and commit it. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 4: 5:25 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7198637B401 for ; Fri, 11 Oct 2002 04:05:23 -0700 (PDT) Received: from south.nanolink.com (south.nanolink.com [217.75.134.10]) by mx1.FreeBSD.org (Postfix) with SMTP id 1629043EAF for ; Fri, 11 Oct 2002 04:05:22 -0700 (PDT) (envelope-from roam@ringlet.net) Received: (qmail 85175 invoked by uid 85); 11 Oct 2002 11:16:07 -0000 Received: from office.sbnd.net (HELO straylight.ringlet.net) (217.75.140.130) by south.nanolink.com with SMTP; 11 Oct 2002 11:16:06 -0000 Received: (qmail 5537 invoked by uid 1000); 11 Oct 2002 11:05:08 -0000 Date: Fri, 11 Oct 2002 14:05:08 +0300 From: Peter Pentchev To: Andrei Cojocaru Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Question about light-weight mutex (kind of) Message-ID: <20021011110508.GR376@straylight.oblivion.bg> Mail-Followup-To: Andrei Cojocaru , freebsd-hackers@FreeBSD.ORG References: <000d01c270c8$937a2160$0200a8c0@twothousand> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="kb0TSCuX821Ar6UT" Content-Disposition: inline In-Reply-To: <000d01c270c8$937a2160$0200a8c0@twothousand> User-Agent: Mutt/1.5.1i X-Virus-Scanned: by Nik's Monitoring Daemon (AMaViS perl-11d ) Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --kb0TSCuX821Ar6UT Content-Type: text/plain; charset=windows-1251 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Oct 10, 2002 at 07:50:28PM -0600, Andrei Cojocaru wrote: > Hello, >=20 > I have a question, please include me in the reply specifically because I'm > not subscribed to the mailing list. Thanks >=20 > I want a thread to spin atomically on a value until it's equal to 1(i.e. > it's waiting for an event), how do I do that? I have no idea.. I want this > to be fast, not have to use a mutex each time to protect the value > I have an idea of how to do it using atomic assembly statements but I don= 't > want to use assmebly, I want to know if FreeBSD has built-in stuff for th= is. >=20 > Please help thanks. >=20 > This is required because I'm building R/W locks for a transaction system = I'm > working on, and I need a way for a thread waiting on a lock to be notified > when a lock is gotten (and without having the thread block [that's why I > want it to spin]). Any hints would be appreciated thanks, once again. Would pthread_rwlock_tryrdlock(3) and pthread_rwlock_tryrdlock(3), combined with an usleep() or something, do the trick? G'luck, Peter --=20 Peter Pentchev roam@ringlet.net roam@FreeBSD.org PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553 Hey, out there - is it *you* reading me, or is it someone else? --kb0TSCuX821Ar6UT Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.0 (FreeBSD) iD8DBQE9prBj7Ri2jRYZRVMRAmt+AKC/oJo9741nSXyOH2sYqH14Qs/6igCgmjWA sksrumvN/IPLw0zhDKJ4s+o= =g1Ol -----END PGP SIGNATURE----- --kb0TSCuX821Ar6UT-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 4: 6:50 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 28F1837B401 for ; Fri, 11 Oct 2002 04:06:48 -0700 (PDT) Received: from south.nanolink.com (south.nanolink.com [217.75.134.10]) by mx1.FreeBSD.org (Postfix) with SMTP id EC5E943E97 for ; Fri, 11 Oct 2002 04:06:46 -0700 (PDT) (envelope-from roam@ringlet.net) Received: (qmail 85204 invoked by uid 85); 11 Oct 2002 11:17:38 -0000 Received: from office.sbnd.net (HELO straylight.ringlet.net) (217.75.140.130) by south.nanolink.com with SMTP; 11 Oct 2002 11:17:36 -0000 Received: (qmail 5599 invoked by uid 1000); 11 Oct 2002 11:06:40 -0000 Date: Fri, 11 Oct 2002 14:06:40 +0300 From: Peter Pentchev To: Andrei Cojocaru Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Question about light-weight mutex (kind of) Message-ID: <20021011110640.GS376@straylight.oblivion.bg> Mail-Followup-To: Andrei Cojocaru , freebsd-hackers@FreeBSD.ORG References: <000d01c270c8$937a2160$0200a8c0@twothousand> <20021011110508.GR376@straylight.oblivion.bg> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="gJgGjUUWrnN4mpen" Content-Disposition: inline In-Reply-To: <20021011110508.GR376@straylight.oblivion.bg> User-Agent: Mutt/1.5.1i X-Virus-Scanned: by Nik's Monitoring Daemon (AMaViS perl-11d ) Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --gJgGjUUWrnN4mpen Content-Type: text/plain; charset=windows-1251 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Oct 11, 2002 at 02:05:08PM +0300, Peter Pentchev wrote: > On Thu, Oct 10, 2002 at 07:50:28PM -0600, Andrei Cojocaru wrote: > > Hello, > >=20 > > I have a question, please include me in the reply specifically because = I'm > > not subscribed to the mailing list. Thanks > >=20 > > I want a thread to spin atomically on a value until it's equal to 1(i.e. > > it's waiting for an event), how do I do that? I have no idea.. I want t= his > > to be fast, not have to use a mutex each time to protect the value > > I have an idea of how to do it using atomic assembly statements but I d= on't > > want to use assmebly, I want to know if FreeBSD has built-in stuff for = this. > >=20 > > Please help thanks. > >=20 > > This is required because I'm building R/W locks for a transaction syste= m I'm > > working on, and I need a way for a thread waiting on a lock to be notif= ied > > when a lock is gotten (and without having the thread block [that's why I > > want it to spin]). Any hints would be appreciated thanks, once again. >=20 > Would pthread_rwlock_tryrdlock(3) and pthread_rwlock_tryrdlock(3), > combined with an usleep() or something, do the trick? Of course, the second one was meant to be pthread_rwlock_trywrlock(3)... G'luck, Peter --=20 Peter Pentchev roam@ringlet.net roam@FreeBSD.org PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553 Hey, out there - is it *you* reading me, or is it someone else? --gJgGjUUWrnN4mpen Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.0 (FreeBSD) iD8DBQE9prDA7Ri2jRYZRVMRAhuQAJ9K48926OOnfaLkdk+Bk/1AMh8XCgCfaBW1 GbOjBY+grYyUxL9PfF4xgIU= =xkYo -----END PGP SIGNATURE----- --gJgGjUUWrnN4mpen-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 6: 2: 7 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CCA3D37B401 for ; Fri, 11 Oct 2002 06:02:05 -0700 (PDT) Received: from HAL9000.homeunix.com (12-232-220-15.client.attbi.com [12.232.220.15]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1835843EAF for ; Fri, 11 Oct 2002 06:02:05 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Received: from HAL9000.homeunix.com (localhost [127.0.0.1]) by HAL9000.homeunix.com (8.12.6/8.12.5) with ESMTP id g9BD23BY016890; Fri, 11 Oct 2002 06:02:03 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Received: (from das@localhost) by HAL9000.homeunix.com (8.12.6/8.12.5/Submit) id g9BD1tGc016889; Fri, 11 Oct 2002 06:01:55 -0700 (PDT) (envelope-from dschultz@uclink.Berkeley.EDU) Date: Fri, 11 Oct 2002 06:01:55 -0700 From: David Schultz To: Matthew Dillon Cc: Peter Wemm , Sean Kelly , hackers@FreeBSD.ORG Subject: Re: swapoff? Message-ID: <20021011130154.GA16549@HAL9000.homeunix.com> Mail-Followup-To: Matthew Dillon , Peter Wemm , Sean Kelly , hackers@FreeBSD.ORG References: <20020713071911.GA1558@HAL9000.wox.org> <20020713073404.9869A3811@overcee.wemm.org> <20020713115746.GA2162@HAL9000.wox.org> <200207131636.g6DGaoqh081285@apollo.backplane.com> <20021007153845.GA371@HAL9000.homeunix.com> <200210072347.g97Nl3Zo049415@apollo.backplane.com> <20021008113614.GA319@HAL9000.homeunix.com> <200210081745.g98Hjkam078883@apollo.backplane.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200210081745.g98Hjkam078883@apollo.backplane.com> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Thus spake Matthew Dillon : > This is a sticky situation because both the VM object and the > swblocks may be manipulated by other processes when you block. I > think what you need to try to do is this (it's a mess, if you can think > of a better solution definitely go another route!) > > while ((swap = *pswap) != NULL) { > if (anything_is_swapped_to_the_device) { > try_to_page_it_all_in > (note that the swblock structure is invalid the moment you > block, so swp_pager_force_pagein() should be given > the whole range). > /* fall through to retry */ > } else if (the_related_object_pip_count_is_not_zero) { > vm_object_pip_sleep(...) > /* fall through to retry */ > } else if (swap->swb_count <= 0) { > free the swap block > *pswap = swap->swb_hnext; > } > } Thanks, your solution looks pretty good. I guess as part of the try_to_page_it_all_in, I'll want to call swap_pager_unswapped() on each page. Now I really wish I had noticed swap_pager_unswapped() earlier; it would have made my job much easier! I'm worried that vm_proc_swapin_all() has a similar race with the swapout daemon. Presently I assume that my references to the UPAGES object and the associated pages remain valid after the faultin(), and that I can use swap_pager_freeswapspace() to free the correct metadata, instead of calling swap_pager_unswapped() on each page. Should just hold the process lock until the metadata are freed? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 6: 7:51 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A910537B401 for ; Fri, 11 Oct 2002 06:07:46 -0700 (PDT) Received: from yahoo.com (6532244hfc109.tampabay.rr.com [65.32.244.109]) by mx1.FreeBSD.org (Postfix) with SMTP id 1D1E143E88 for ; Fri, 11 Oct 2002 06:07:41 -0700 (PDT) (envelope-from MarketingProducts1010@yahoo.com) From: [] To: Reply-To: Subject: Subject: Lists: Publicity - Libraries - Bookstores - Custom - Film Producers - Publishers - Art Galleries - Record Stores (more) Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-Id: <20021011130741.1D1E143E88@mx1.FreeBSD.org> Date: Fri, 11 Oct 2002 06:07:41 -0700 (PDT) Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG UNLIMITED USE LISTS . . .DOWNLOAD WITHIN MINUTES. -------------------------------------------------------------- NEW LISTS: PBS STATIONS, UK MEDIA, POLITICAL MEDIA, NEW AGE MEDIA, UK LIBRARIES, SCIENTIFIC JOURNALS, FILM & TV PRODUCERS, ART PUBLISHERS, LITERARY AGENTS, MENS MEDIA. -------------------------------------------------------------- IF WE DO NOT HAVE THE LIST YOU NEED, WE WILL COMPILE A CUSTOM LIST ACCORDING TO YOUR SPECIFICATIONS -------------------------------------------------------------- Call to place your order or for more information. US & CANADA TOLL-FREE NUMBER: 888 330 4919 (24/7) If you would like more information via email, please write us at sendlistinfo@netscape.net - Thank you. -------------------------------------------------------------- LIBRARIES LISTS INCLUDE: Name, Address, phone, fax and email address (when available). AVAILABLE FORMATS: Excel Spreadsheet & Text Database 1,200 U.S. Public Libraries WITH EMAIL ADDRESSES - $109 1,200 U.S. Public Libraries - $89 1,000 U.S. University Libraries WITH EMAIL ADDRESSES - $89 1,000 U.S. University Libraries - $69 400+ Community College Libraries WITH EMAIL ADDRESSES - $59 400+ Community College Libraries - $49 1,093 U.S. K-12 Private School Libraries WITH EMAIL ADDRESSES - $109 1,093 U.S. K-12 Private School Libraries - $89 200 U.K. Public Libraries WITH EMAIL ADDRESSES - $49 200 U.K. Public Libraries - $39 250 U.K. University Libraries WITH EMAIL ADDRESSES - $49 250 U.K. University Libraries - $39 528 Australian Public Libraries WITH EMAIL ADDRESSES - $79 528 Australian Public Libraries - $69 279 Australian College & Univ. Libraries WITH EMAIL ADDRESSES - $49 279 Australian College & Univ. Libraries - $39 200 Canadian Libraries WITH EMAIL ADDRESSES - $49 200 Canadian Libraries - $39 100 New Zealand Libraries WITH EMAIL ADDRESSES - $39 100 New Zealand Libraries - $29 1,000 U.S. Medical Libraries - $79 313 U.S. Law Libraries - $49 193 U.S. Religious Libraries - $39 ---------------------------------------------- BOOKSTORES LIST INCLUDES: Name, Address, phone, fax and email address (when available). AVAILABLE FORMATS: Excel Spreadsheets & Text Databases 1,900+ Independent Bookstores WITH EMAIL ADDRESSES - $149 1,900+ Independent Bookstores - $129 1,900+ College Bookstores WITH EMAIL ADDRESSES - $149 1,900+ College Bookstores - $129 3,000+ Christian Bookstores WITH EMAIL ADDRESSES - $169 3,000+ Christian Bookstores - $149 2,200+ Chain Bookstores - $129 575+ Book Distributors & Chain HQs - WITH EMAIL ADDRESSES - $59 575+ Book Distributors & Chain HQs - $ 49 675 Canadian General Bookstores WITH EMAIL ADDRESSES - $69 675 Canadian General Bookstores - $59 175 Canadian University Bookstores - WITH EMAIL ADDRESSES - $39 175 Canadian University Bookstores - $29 550+ New Age Bookstores - WITH EMAIL ADDRESSES - $59 550+ New Age Bookstores - $49 125 African-American Bookstores - $29 You will be able to download your lists WITHIN MINUTES. ----------------------------------------------- MEDIA LISTS LISTS INCLUDE: Contact Name, Title/Position, Company, Address, Phone, Fax and Email Address (when available) AVAILABLE FORMATS: Excel Spreadsheet and Microsoft Word PBS Stations (800+ Contacts) - $99 Scientific Journals (500 Contacts) - $99 UK Media List (500 Contacts) - $99 Political Media List (1,100+ Contacts) - $149 Canadian National Media (590+ Contacts) - $99 New Age Media (250+ Contacts) - $99 Mens Interest Media (400 Contacts) - $99 Womens Interest Media (1,350+ Contacts) - $149 Teen Interest Media (216 Contacts) - $99 Eclectic Newsweeklies (575+ Contacts) - $99 College Radio Stations (520+ Contacts) - $99 Local TV News (North Region) (840+ Contacts) - $99 Local TV News (Midwest Region) (870+ Contacts) - $99 Local TV News (West Region) (890+ Contacts) - $99 Local TV News (South Region) (1,100+ Contacts) - $129 Local TV News (All Regions) (3,700+ Contacts) - $249 Drive Time Radio - Top 50 Markets (300+ Contacts) - $69 Australian National Media List (360+ Contacts) - $99 Drive Time Radio - Top 100 Markets (600 Contacts) - $99 Newspapers - Top 100 Papers (1,100+ Contacts) - $99 National Media List (1000+ Contacts) - $99 Sex & Relationships Media List (402 Contacts) - $99 Music Industry Media List (1,142 Contacts) - $149 Fashion & Beauty List (1,400 Contacts) - $149 Motion Picture, Film & Video (695 Contacts) - $99 National Public Radio (265 Contacts) - $99 Sports Media List (427 Contacts) - $99 African American Media List (1500 Contacts) - $149 Environmental Media List (763 Contacts) - $99 Gay and Lesbian Media List (260 Contacts) - $99 Book Industry Media List (502 Contacts) - $99 Christian Media List (370 Contacts) - $99 Family & Parenting Media List (789 Contacts) - $99 College Newspaper Contacts (1,400+ Contacts) - $99 ------------------------------------------------- TV & FILM PRODUCERS, DIRECTORS, DEVELOPMENT EXECS, (MORE) 3,000+ Contacts - $299 (Entire List) 800+ Producers Only - $99 650+ Development, Creative & Acquisitions Contacts Only - $89 Lists Include: Contact Name, Title, Company, Address, Phone and Fax Number Available Formats: Excel Spreadsheet and Text Database PUBLISHING COMPANY CONTACTS 1,700+ U.S. Publishing Contacts - $149 300 Art Publishing Contacts - $49 List Includes: Contact Name, Title, Company, Address, Phone, Number, Fax Number and Email Address (when available) Available Formats: Excel Spreadsheet and Text Database LITERARY AGENTS 300+ Contacts - $59 List Includes: Contact Name, Title, Company, Address, Phone, Number, Fax Number and Email Address (when available) Available Formats: Excel Spreadsheet and Text Database MUSIC AGENTS/MANAGERS 150+ Contacts - $39 List Includes: Contact Name, Title, Company, Address, Phone, Fax Number and Email Address (when available) Available Formats: Excel Spreadsheet and Text Database VIDEO STORE LISTS 1573 Independent Video Stores (West) - $79 2556 Independent Video Stores (Midwest) - $99 2037 Independent Video Stores (East) - $99 2987 Independent Video Stores (South) - $129 9150 Independent Video Stores (National)- $299 Lists Include: Store Name, Address and Phone Number Available Formats: Excel Spreadsheet and Text Database MUSIC STORE LISTS 997 Independent Music Stores (Midwest) - $79 1215 Independent Music Stores (South) - $89 1444 Independent Music Stores (East) - $89 1355 Independent Music Stores (West) - $89 5008 Independent Music Stores (National)- $249 Lists Include: Store Name, Address and Phone Number Available Formats: Excel Spreadsheet and Text Database ART GALLERY LISTS US National List WITH EMAIL ADDRESSES: $169 (1090 Galleries) US National List: $149 (1090 Galleries) Southern US: $39 (140 Galleries) Central US: $39 (150 Galleries) Western US: $69 (272 Galleries) Eastern US: $89 (530 Galleries) United Kingdom: $69 (230 Galleries) Canada: $49 (165 Galleries) Australia: $29 (50 Galleries) Lists Include: Gallery Name, Address, Phone Number and Fax Number Available Formats: Excel Spreadsheet and Text Database OUR GUARANTEE: We will gladly refund postage (up to 34 cents per item) for any undeliverable addresses over 5% of the total list. We will also correct the undeliverable contacts and issue you an updated list. ------------------------ You will be able to download your lists WITHIN MINUTES. Call to place your order or for more information. US & CANADA TOLL-FREE NUMBER: 888 330 4919 (24/7) If you would like more information via email, please write us at sendlistinfo@netscape.net - Thank you. ------------------------------------------------------------------- To be removed from any future mailings, please send a message with your email address in the subject line to PublicityRemoval@netscape.net. Requests will be processed within 48 hours at that address only. Apologies for any inconvience. Thank you. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 6:16:56 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3564D37B401 for ; Fri, 11 Oct 2002 06:16:54 -0700 (PDT) Received: from mail.empirequest.com (www.empirequest.com [216.126.10.210]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7002343E9E for ; Fri, 11 Oct 2002 06:16:53 -0700 (PDT) (envelope-from spinlock_lists@empirequest.com) Received: (qmail 26609 invoked by uid 89); 11 Oct 2002 13:16:53 -0000 Received: from unknown (HELO fivehundred) (spinlock?lists@empirequest.com@192.168.0.3) by www.empirequest.com with SMTP; 11 Oct 2002 13:16:53 -0000 Message-ID: <004e01c27128$77828c30$0300a8c0@fivehundred> From: "Andrei Cojocaru" To: "Peter Pentchev" Cc: References: <000d01c270c8$937a2160$0200a8c0@twothousand> <20021011110508.GR376@straylight.oblivion.bg> <20021011110640.GS376@straylight.oblivion.bg> Subject: Re: Question about light-weight mutex (kind of) Date: Fri, 11 Oct 2002 07:16:53 -0600 MIME-Version: 1.0 Content-Type: text/plain; charset="windows-1251" Content-Transfer-Encoding: quoted-printable X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Ah, no. I am writing my own R/W lock because I need the ability to offload them = to disk. I think condition variables should be fast enough for what I'm = looking for. Any ideas? ----- Original Message -----=20 From: "Peter Pentchev" To: "Andrei Cojocaru" Cc: Sent: Friday, October 11, 2002 05:06 Subject: Re: Question about light-weight mutex (kind of) On Fri, Oct 11, 2002 at 02:05:08PM +0300, Peter Pentchev wrote: > On Thu, Oct 10, 2002 at 07:50:28PM -0600, Andrei Cojocaru wrote: > > Hello, > >=20 > > I have a question, please include me in the reply specifically = because I'm > > not subscribed to the mailing list. Thanks > >=20 > > I want a thread to spin atomically on a value until it's equal to = 1(i.e. > > it's waiting for an event), how do I do that? I have no idea.. I = want this > > to be fast, not have to use a mutex each time to protect the value > > I have an idea of how to do it using atomic assembly statements but = I don't > > want to use assmebly, I want to know if FreeBSD has built-in stuff = for this. > >=20 > > Please help thanks. > >=20 > > This is required because I'm building R/W locks for a transaction = system I'm > > working on, and I need a way for a thread waiting on a lock to be = notified > > when a lock is gotten (and without having the thread block [that's = why I > > want it to spin]). Any hints would be appreciated thanks, once = again. >=20 > Would pthread_rwlock_tryrdlock(3) and pthread_rwlock_tryrdlock(3), > combined with an usleep() or something, do the trick? Of course, the second one was meant to be pthread_rwlock_trywrlock(3)... G'luck, Peter --=20 Peter Pentchev roam@ringlet.net roam@FreeBSD.org PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553 Hey, out there - is it *you* reading me, or is it someone else? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 10: 6:19 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 37E4B37B404 for ; Fri, 11 Oct 2002 10:06:18 -0700 (PDT) Received: from TMA-1.brad-x.com (static-b2-191.highspeed.eol.ca [64.56.236.191]) by mx1.FreeBSD.org (Postfix) with ESMTP id BC85043EA9 for ; Fri, 11 Oct 2002 10:06:16 -0700 (PDT) (envelope-from brad@brad-x.com) Received: from brad-x.com (Discovery.brad-x.com [201.64.15.21]) by TMA-1.brad-x.com (Postfix) with ESMTP id 0798D22104A; Fri, 11 Oct 2002 13:06:16 -0400 (EDT) Message-ID: <3DA70535.5060300@brad-x.com> Date: Fri, 11 Oct 2002 13:07:01 -0400 From: Brad Laue User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.0.1) Gecko/20021002 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Guido Van Hoecke Cc: freebsd-hackers Subject: Re: sis900 problem persists in 4.7 References: <3DA60E15.2090800@VanHoecke.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Guido Van Hoecke wrote: > My sis900 network card is behaves in 4.7 as it did in 4.6.2: > it still complains 'MII without any PHY!' The least i can say is that > this is utterly frustrating... Have a look at this PR and test the patch provided by the followups out. If it works for you, post a followup to it and some information as to its functionality to the list. http://www.freebsd.org/cgi/query-pr.cgi?pr=30836 Cheers, Brad -- // -- http://www.BRAD-X.com/ -- // To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 11:14:39 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7B3A437B404 for ; Fri, 11 Oct 2002 11:14:38 -0700 (PDT) Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1807A43E9E for ; Fri, 11 Oct 2002 11:14:38 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (localhost [127.0.0.1]) by apollo.backplane.com (8.12.5/8.12.4) with ESMTP id g9BIEbPQ040689; Fri, 11 Oct 2002 11:14:37 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.12.5/8.12.4/Submit) id g9BIEbah040688; Fri, 11 Oct 2002 11:14:37 -0700 (PDT) (envelope-from dillon) Date: Fri, 11 Oct 2002 11:14:37 -0700 (PDT) From: Matthew Dillon Message-Id: <200210111814.g9BIEbah040688@apollo.backplane.com> To: David Schultz Cc: Peter Wemm , Sean Kelly , hackers@FreeBSD.ORG Subject: Re: swapoff? References: <20020713071911.GA1558@HAL9000.wox.org> <20020713073404.9869A3811@overcee.wemm.org> <20020713115746.GA2162@HAL9000.wox.org> <200207131636.g6DGaoqh081285@apollo.backplane.com> <20021007153845.GA371@HAL9000.homeunix.com> <200210072347.g97Nl3Zo049415@apollo.backplane.com> <20021008113614.GA319@HAL9000.homeunix.com> <200210081745.g98Hjkam078883@apollo.backplane.com> <20021011130154.GA16549@HAL9000.homeunix.com> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG : :Thanks, your solution looks pretty good. I guess as part of the :try_to_page_it_all_in, I'll want to call swap_pager_unswapped() on :each page. Now I really wish I had noticed swap_pager_unswapped() :earlier; it would have made my job much easier! As long as you properly check and dirty the page you can get rid of the backing swap. :I'm worried that vm_proc_swapin_all() has a similar race with the :swapout daemon. Presently I assume that my references to the :UPAGES object and the associated pages remain valid after the :faultin(), and that I can use swap_pager_freeswapspace() to free :the correct metadata, instead of calling swap_pager_unswapped() on :each page. Should just hold the process lock until the metadata :are freed? Hmm. Well, the proc lock is not held during vm_proc_swapin() (but the PS_SWAPPINGIN flag is set). The proc lock is held during vm_proc_swapout(). In your vm_proc_swapin_all() you seem to be doing the right thing in regards to the mutexes and retry, and you have already marked the device is SW_CLOSING so if something does get in there and try to swap the process back in it shouldn't allocate swap you are trying to free. I think you may be ok. -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 12:47: 2 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9BADF37B401; Fri, 11 Oct 2002 12:46:59 -0700 (PDT) Received: from hawk.mail.pas.earthlink.net (hawk.mail.pas.earthlink.net [207.217.120.22]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3511843E8A; Fri, 11 Oct 2002 12:46:59 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0005.cvx21-bradley.dialup.earthlink.net ([209.179.192.5] helo=mindspring.com) by hawk.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 1805k7-0007DY-00; Fri, 11 Oct 2002 12:46:39 -0700 Message-ID: <3DA72A53.9D2D61E5@mindspring.com> Date: Fri, 11 Oct 2002 12:45:23 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Bruce Evans Cc: Craig Rodrigues , freebsd-standards@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG Subject: Re: Problem detecting POSIX symbolic constants References: <20021011183032.D12170-100000@gamplex.bde.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bruce Evans wrote: > > I know it's not fashionable to write code that's portable to > > compilers other than GCC, but even if FreeBSD is going to ignore > > portability for it's own source code, it's probably unreasonable > > to expect ACE to ignore portability for theirs. > > Undefined symbols being 0 in cpp in expressions was in early C compilers > if not the original one. Consult your archives for a posting 10-15 years > or so ago by dmr in comp.std.c about him checking this in his archives. You mean "in preprocessor expressions", of course. > > This can't be the case; specifically, the sysconf() test will > > only work at runtime, which means that the symbols had to be > > there and resolvable at link time. > > Symbols can be resolved at runtime using dlopen(), etc. They would only > actually be available on systems where sysconf() says that they are. You can't depend on people using the standard C library via dlopen, as opposed to, uh, "linking". If you are depending on this, then you don't need sysconf: if the symbol isn't in the library, that's an equally valid indicator, so if the symbol lookup fail on a library open on Windows, which does not have sysconf at all (for example), it would have to be treated as equivalent. In UNIX, the symbol would have to be there, because the preferred linking technology *says* it has to be there for the link to succeed, if the symbol is referenced. Again, it's a *lot* easier for the programmers to say "screw this!", and blow off the runtime code morphing. > > Uh, the 1990 standard, which allowed "#if" is only 12 years old. > > #if is in K&R1 (1978). According to my first edition "The C Programming Language": 12.3 Conditional compilation A compiler control line of the form #if constant-expression checks whether the constant expression (see section 15) evaluates to non-zero. ... 15 Constant expressions In several places C requires expressions which evaluate to a constant: after case, as array bounds, and in initializers. In the first two cases, the expression can involve only integer constants, character constants, and sizeof expressions, possibly connected by the binary operators + - * / % & | ^ << >> == != < > <= >= or by the unary operators - ~ or by the ternary operator ?: ...no "&&" or "||"... sorry. Also, "defined()" is not defined. I think you will find that "&&" and "||" in #if statements are later extensions. The value of undefined macros in preprocessor expressions being assumed to be zero is also not documented in the book. I would have to imagine that they were not considered constant expressions. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 12:51:10 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C678437B401; Fri, 11 Oct 2002 12:51:08 -0700 (PDT) Received: from hawk.mail.pas.earthlink.net (hawk.mail.pas.earthlink.net [207.217.120.22]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8043A43E8A; Fri, 11 Oct 2002 12:51:08 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0005.cvx21-bradley.dialup.earthlink.net ([209.179.192.5] helo=mindspring.com) by hawk.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 1805oP-0005ox-00; Fri, 11 Oct 2002 12:51:05 -0700 Message-ID: <3DA72B5D.97C8E6A8@mindspring.com> Date: Fri, 11 Oct 2002 12:49:49 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Bruce Evans Cc: Craig Rodrigues , freebsd-standards@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG Subject: Re: Problem detecting POSIX symbolic constants References: <20021011184643.U12170-100000@gamplex.bde.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bruce Evans wrote: > _POSIX_REALTIME_SIGNALS is only valid in versions of POSIX that support > it. Applications must also conditionalize on _POSIX_VERSION if they > want to check for features that are not in all versions. Yeah; I mentioned that I was afraid of this... > Runtime configuration only lets us go forward in time. An application > might use POSIX realtime features if they are available and magically > start working better (without recompiling anything in the application) > when the OS and/or library implementors get around to implementing the > features. Don't get me wrong; I understand why the feature is defined; I just don't think that any sane programmer is going to write two sets of runtime variant code, when they can write one set of compile time variant, but runtime invariant, code. The POSIX committee would do us all a favor if, instead of doing things like this, they concentrated on standardizing shared memory, distributed file locking, and the ability to free up ranges of blocks in the middle of files (as examples). -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 12:57: 4 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BE6E037B401 for ; Fri, 11 Oct 2002 12:56:58 -0700 (PDT) Received: from hotmail.com (f174.sea1.hotmail.com [207.68.163.174]) by mx1.FreeBSD.org (Postfix) with ESMTP id B5A0B43EA3 for ; Fri, 11 Oct 2002 12:56:57 -0700 (PDT) (envelope-from firstolasto@hotmail.com) Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC; Fri, 11 Oct 2002 12:56:57 -0700 Received: from 12.235.232.75 by sea1fd.sea1.hotmail.msn.com with HTTP; Fri, 11 Oct 2002 19:56:57 GMT X-Originating-IP: [12.235.232.75] From: "Firsto Lasto" To: mark@grondar.za Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: PRNG not seeded - error in non-root ssh inside 4.6.2 jails... Date: Fri, 11 Oct 2002 12:56:57 -0700 Mime-Version: 1.0 Content-Type: text/plain; format=flowed Message-ID: X-OriginalArrivalTime: 11 Oct 2002 19:56:57.0571 (UTC) FILETIME=[5AE76B30:01C27160] Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG No, /dev/urandom was already 666, and I just noticed that random was not, so I chmodded random 0666 and then the error changed from PRNG not seeded to "host key verification failed". I think there is some useful information in this last round of troubleshooting I did - the fact that the behavior was the same when I made random 2,4, but the behavior was different when I made urandom 2,3. Or perhaps it is not useful at all ? > > > Ok, I did this, and got the exact same results - first it says that PRNG >is > > not seeded, and then I chmod 0666 /dev/urandom and then it tells me >"host > > key verification failed". > >I hope you mean /dev/random? > >M > > > > > So, just in case I also did the opposite - I left random alone and set > > urandom to 2,3 so it behaves like random ... and this was interesting, >when > > I did this, it told me PRNG not seeded no matter what I set the >permissions > > to - so at no point did I progress to "host key verification failed". > > > > Hope this helps - I hate to think that the single most used userland > > application does not function inside of jail (which is the case, it >seems, > > at least in 4.6.2) > > > > > > > > > > > > > Do you mean recompile SSL using urandom instead of random ? > > > > > >Yes. > > > > > > > Would it be the exact same effect if I simply changed my /dev/random >to > > > > major/minor 2,4 instead of 2,3 ? > > > > > >Yes. That would work. > > > > > > > It seems like that would be much easier... > > > > > >Indeed! > > > > > >M > > > > > > > > > Ok, I am not sure how I can do that though - I cannot >successfully > > >run > > > > > > `rndcontrol -s X` inside a jail. > > > > > > > > > > > > On the other hand, I already have: > > > > > > > > > > > > rand_irqs="9 10 11 13 14" > > > > > > > > > > > > In my rc.conf on the underlying host machine, and have done >several > > > > >boots > > > > > > with that in place. So presumably I should be seeded just fine, >but > > >if > > > > >I am > > > > > > not, I cannot change that in the jail because it seems I cannot >set > > >that > > > > >(I > > > > > > assume it is a sysctl issue). > > > > > > > > > > > > Willing to try whatever you can think of next :) > > > > > > > > > >Hokay. Can you grovel around inside OpenSSL >(src/crypto/openssl/...) > > >and > > > > >find where the random device is read? If it is /dev/random, then >change > > > > >that to /dev/urandom. > > > > > > > > > >See how that works. > > > > > > > > > >M > > > > > > > > > > > > > I can't seed it by banging on the keyboard - it is a >headless > > >server > > > > >in > > > > > > >a > > > > > > > > rack thousands of miles from me :) > > > > > > > > > > > > > > > > Perhaps there is another way to do it ? > > > > > > > > > > > > > >Yes. > > > > > > > > > > > > > >You need to find sources of entropy in interrupts. Look at a > > > > > > >dmesg, and note which IRQ's your network device(s) and mass > > > > > > >storage controller(s) (both SCSI and ATA). Use any other > > > > > > >irq's that aren't too busy and may be somewhat random. > > > > > > >Staring at a 'systat 2 -vmstat' screen (right hand side) > > > > > > >may give some clues. > > > > > > > > > > > > > >Then use rndcontrol(8) to set up the seeding. There is a knob > > > > > > >in rc.conf to make this setting survive the next reboot. > > > > > > > > > > > > > >M > > > > > > > > > > > > > > > >Date: Thu, 03 Oct 2002 21:54:30 +0100 > > > > > > > > > > > > > > > > > > > Sorry, here is the rest: > > > > > > > > > > > > > > > > > > > > Here is the output of the `dd` command using urandom: > > > > > > > > > > > > > > > > > > > > dd if=/dev/urandom of=/dev/stdout bs=512 count=1 | >hexdump > > >-C > > > > > > > > > > 1+0 records in > > > > > > > > > > 1+0 records out > > > > > > > > > > 00000000 a0 69 1a 7c 8f 32 e5 21 ae 7a 33 14 68 0b 8e >a6 > > > > > > > > > > |.i.|.2.!.z3.h...| > > > > > > > > > > > > > > > > > >... etc. Looking good. > > > > > > > > > > > > > > > > > > > $ ls -l /dev/*rand* > > > > > > > > > > crw-r--r-- 1 root wheel 2, 3 Sep 3 21:46 >/dev/random > > > > > > > > > > crw-r--r-- 1 root wheel 2, 4 Sep 3 21:46 > > >/dev/urandom > > > > > > > > > > > > > > > > > >Also good. > > > > > > > > > > > > > > > > > > > > > So then, as root I ran: `chmod 0666 /dev/stdout` and > > >then I > > > > >ran > > > > > > >your > > > > > > > > > > >`dd` > > > > > > > > > > > > command and got: > > > > > > > > > > > > > > > > > > > > > > > > $ dd if=/dev/random of=/dev/stdout bs=512 count=1 | > > >hexdump > > > > >-C > > > > > > > > > > > > 0+0 records in > > > > > > > > > > > > 0+0 records out > > > > > > > > > > > > 0 bytes transferred in 0.000036 secs (0 bytes/sec) > > > > > > > > > > > > > > > > > >Can you try a few of these while furiously abusing your > > >keyboard? > > > > > > > > >I'm trying to see if /dev/random can be persuaded to give >_any_ > > > > > > > > >aoutput at all. > > > > > > > > > > > > > > > > > >Maybe do it on a vty instead of in X. > > > > > > > > > > > > > > > > > >M > > > > > > > > >-- > > > > > > > > >o Mark Murray > > > > > > > > >\_ > > > > > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >_________________________________________________________________ > > > > > > > > Chat with friends online, try MSN Messenger: > > > > >http://messenger.msn.com > > > > > > > > > > > > > > >-- > > > > > > >o Mark Murray > > > > > > >\_ > > > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >_________________________________________________________________ > > > > > > Send and receive Hotmail on your mobile device: > > >http://mobile.msn.com > > > > > > > > > > > > > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > > > > > with "unsubscribe freebsd-hackers" in the body of the message > > > > >-- > > > > >o Mark Murray > > > > >\_ > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > _________________________________________________________________ > > > > Send and receive Hotmail on your mobile device: >http://mobile.msn.com > > > > > > >-- > > >o Mark Murray > > >\_ > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > _________________________________________________________________ > > MSN Photos is the easiest way to share and print your photos: > > http://photos.msn.com/support/worldwide.aspx > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > with "unsubscribe freebsd-hackers" in the body of the message >-- >o Mark Murray >\_ >O.\_ Warning: this .sig is umop ap!sdn _________________________________________________________________ MSN Photos is the easiest way to share and print your photos: http://photos.msn.com/support/worldwide.aspx To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 13:10:16 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5A2F937B401 for ; Fri, 11 Oct 2002 13:10:10 -0700 (PDT) Received: from storm.FreeBSD.org.uk (storm.FreeBSD.org.uk [194.242.157.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7D12F43E88 for ; Fri, 11 Oct 2002 13:10:09 -0700 (PDT) (envelope-from mark@grimreaper.grondar.org) Received: from storm.FreeBSD.org.uk (uucp@localhost [127.0.0.1]) by storm.FreeBSD.org.uk (8.12.6/8.12.6) with ESMTP id g9BKA8W1056984; Fri, 11 Oct 2002 21:10:08 +0100 (BST) (envelope-from mark@grimreaper.grondar.org) Received: (from uucp@localhost) by storm.FreeBSD.org.uk (8.12.6/8.12.6/Submit) with UUCP id g9BKA7Xt056983; Fri, 11 Oct 2002 21:10:08 +0100 (BST) Received: from grimreaper.grondar.org (localhost [127.0.0.1]) by grimreaper.grondar.org (8.12.6/8.12.5) with ESMTP id g9BK9f01070788; Fri, 11 Oct 2002 21:09:41 +0100 (BST) (envelope-from mark@grimreaper.grondar.org) Message-Id: <200210112009.g9BK9f01070788@grimreaper.grondar.org> To: "Firsto Lasto" Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: PRNG not seeded - error in non-root ssh inside 4.6.2 jails... References: In-Reply-To: ; from "Firsto Lasto" "Fri, 11 Oct 2002 12:56:57 PDT." Date: Fri, 11 Oct 2002 21:09:41 +0100 From: Mark Murray Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > No, /dev/urandom was already 666, and I just noticed that random was not, so > I chmodded random 0666 and then the error changed from PRNG not seeded to > "host key verification failed". > > I think there is some useful information in this last round of > troubleshooting I did - the fact that the behavior was the same when I made > random 2,4, but the behavior was different when I made urandom 2,3. Sort of. Without logs and verified states, its hard to know what is finger problems and what is real. Starting from the top. Unmodified system. What are the permissions of /dev/*random? Please give the output of ls -al /dev/*random If they are unreadable, correct. What are the pleb-user outputs of dd if=/dev/random of=/dev/stdout count=1 bs=16 | hexdump -C dd if=/dev/urandom of=/dev/stdout count=1 bs=16 | hexdump -C Go through all combinations of 2,3 and 2,4 for both devices (so four combinations) and do the same. At each point, test the OpenSSL PRNG. Log everything. Send that back, please. M > > Or perhaps it is not useful at all ? > > > > > > > Ok, I did this, and got the exact same results - first it says that PRNG > >is > > > not seeded, and then I chmod 0666 /dev/urandom and then it tells me > >"host > > > key verification failed". > > > >I hope you mean /dev/random? > > > >M > > > > > > > > So, just in case I also did the opposite - I left random alone and set > > > urandom to 2,3 so it behaves like random ... and this was interesting, > >when > > > I did this, it told me PRNG not seeded no matter what I set the > >permissions > > > to - so at no point did I progress to "host key verification failed". > > > > > > Hope this helps - I hate to think that the single most used userland > > > application does not function inside of jail (which is the case, it > >seems, > > > at least in 4.6.2) > > > > > > > > > > > > > > > > > Do you mean recompile SSL using urandom instead of random ? > > > > > > > >Yes. > > > > > > > > > Would it be the exact same effect if I simply changed my /dev/random > >to > > > > > major/minor 2,4 instead of 2,3 ? > > > > > > > >Yes. That would work. > > > > > > > > > It seems like that would be much easier... > > > > > > > >Indeed! > > > > > > > >M > > > > > > > > > > > Ok, I am not sure how I can do that though - I cannot > >successfully > > > >run > > > > > > > `rndcontrol -s X` inside a jail. > > > > > > > > > > > > > > On the other hand, I already have: > > > > > > > > > > > > > > rand_irqs="9 10 11 13 14" > > > > > > > > > > > > > > In my rc.conf on the underlying host machine, and have done > >several > > > > > >boots > > > > > > > with that in place. So presumably I should be seeded just fine, > >but > > > >if > > > > > >I am > > > > > > > not, I cannot change that in the jail because it seems I cannot > >set > > > >that > > > > > >(I > > > > > > > assume it is a sysctl issue). > > > > > > > > > > > > > > Willing to try whatever you can think of next :) > > > > > > > > > > > >Hokay. Can you grovel around inside OpenSSL > >(src/crypto/openssl/...) > > > >and > > > > > >find where the random device is read? If it is /dev/random, then > >change > > > > > >that to /dev/urandom. > > > > > > > > > > > >See how that works. > > > > > > > > > > > >M > > > > > > > > > > > > > > > I can't seed it by banging on the keyboard - it is a > >headless > > > >server > > > > > >in > > > > > > > >a > > > > > > > > > rack thousands of miles from me :) > > > > > > > > > > > > > > > > > > Perhaps there is another way to do it ? > > > > > > > > > > > > > > > >Yes. > > > > > > > > > > > > > > > >You need to find sources of entropy in interrupts. Look at a > > > > > > > >dmesg, and note which IRQ's your network device(s) and mass > > > > > > > >storage controller(s) (both SCSI and ATA). Use any other > > > > > > > >irq's that aren't too busy and may be somewhat random. > > > > > > > >Staring at a 'systat 2 -vmstat' screen (right hand side) > > > > > > > >may give some clues. > > > > > > > > > > > > > > > >Then use rndcontrol(8) to set up the seeding. There is a knob > > > > > > > >in rc.conf to make this setting survive the next reboot. > > > > > > > > > > > > > > > >M > > > > > > > > > > > > > > > > > >Date: Thu, 03 Oct 2002 21:54:30 +0100 > > > > > > > > > > > > > > > > > > > > > Sorry, here is the rest: > > > > > > > > > > > > > > > > > > > > > > Here is the output of the `dd` command using urandom: > > > > > > > > > > > > > > > > > > > > > > dd if=/dev/urandom of=/dev/stdout bs=512 count=1 | > >hexdump > > > >-C > > > > > > > > > > > 1+0 records in > > > > > > > > > > > 1+0 records out > > > > > > > > > > > 00000000 a0 69 1a 7c 8f 32 e5 21 ae 7a 33 14 68 0b 8e > >a6 > > > > > > > > > > > |.i.|.2.!.z3.h...| > > > > > > > > > > > > > > > > > > > >... etc. Looking good. > > > > > > > > > > > > > > > > > > > > > $ ls -l /dev/*rand* > > > > > > > > > > > crw-r--r-- 1 root wheel 2, 3 Sep 3 21:46 > >/dev/random > > > > > > > > > > > crw-r--r-- 1 root wheel 2, 4 Sep 3 21:46 > > > >/dev/urandom > > > > > > > > > > > > > > > > > > > >Also good. > > > > > > > > > > > > > > > > > > > > > > > So then, as root I ran: `chmod 0666 /dev/stdout` and > > > >then I > > > > > >ran > > > > > > > >your > > > > > > > > > > > >`dd` > > > > > > > > > > > > > command and got: > > > > > > > > > > > > > > > > > > > > > > > > > > $ dd if=/dev/random of=/dev/stdout bs=512 count=1 | > > > >hexdump > > > > > >-C > > > > > > > > > > > > > 0+0 records in > > > > > > > > > > > > > 0+0 records out > > > > > > > > > > > > > 0 bytes transferred in 0.000036 secs (0 bytes/sec) > > > > > > > > > > > > > > > > > > > >Can you try a few of these while furiously abusing your > > > >keyboard? > > > > > > > > > >I'm trying to see if /dev/random can be persuaded to give > >_any_ > > > > > > > > > >aoutput at all. > > > > > > > > > > > > > > > > > > > >Maybe do it on a vty instead of in X. > > > > > > > > > > > > > > > > > > > >M > > > > > > > > > >-- > > > > > > > > > >o Mark Murray > > > > > > > > > >\_ > > > > > > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >_________________________________________________________________ > > > > > > > > > Chat with friends online, try MSN Messenger: > > > > > >http://messenger.msn.com > > > > > > > > > > > > > > > > >-- > > > > > > > >o Mark Murray > > > > > > > >\_ > > > > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >_________________________________________________________________ > > > > > > > Send and receive Hotmail on your mobile device: > > > >http://mobile.msn.com > > > > > > > > > > > > > > > > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > > > > > > with "unsubscribe freebsd-hackers" in the body of the message > > > > > >-- > > > > > >o Mark Murray > > > > > >\_ > > > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > > > > > > > > > > > > _________________________________________________________________ > > > > > Send and receive Hotmail on your mobile device: > >http://mobile.msn.com > > > > > > > > >-- > > > >o Mark Murray > > > >\_ > > > >O.\_ Warning: this .sig is umop ap!sdn > > > > > > > > > > > > > > _________________________________________________________________ > > > MSN Photos is the easiest way to share and print your photos: > > > http://photos.msn.com/support/worldwide.aspx > > > > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > > with "unsubscribe freebsd-hackers" in the body of the message > >-- > >o Mark Murray > >\_ > >O.\_ Warning: this .sig is umop ap!sdn > > > > > _________________________________________________________________ > MSN Photos is the easiest way to share and print your photos: > http://photos.msn.com/support/worldwide.aspx > -- o Mark Murray \_ O.\_ Warning: this .sig is umop ap!sdn To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Fri Oct 11 15:49:26 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2DEAC37B401; Fri, 11 Oct 2002 15:49:25 -0700 (PDT) Received: from tartarus.telenet-ops.be (tartarus.telenet-ops.be [195.130.132.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2DF5043E7B; Fri, 11 Oct 2002 15:49:24 -0700 (PDT) (envelope-from Guido@VanHoecke.org) Received: from localhost (localhost.localdomain [127.0.0.1]) by tartarus.telenet-ops.be (Postfix) with SMTP id 0C135DBD92; Sat, 12 Oct 2002 00:49:23 +0200 (CEST) Received: from VanHoecke.org (D5E0E969.kabel.telenet.be [213.224.233.105]) by tartarus.telenet-ops.be (Postfix) with ESMTP id 68C05DBB49; Sat, 12 Oct 2002 00:49:22 +0200 (CEST) Message-ID: <3DA75572.5020907@VanHoecke.org> Date: Sat, 12 Oct 2002 00:49:22 +0200 From: Guido Van Hoecke User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2a) Gecko/20020910 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Brad Laue Cc: freebsd-hackers , wpaul@freebsd.org Subject: Re: sis900 problem persists in 4.7 References: <3DA60E15.2090800@VanHoecke.org> <3DA70535.5060300@brad-x.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Brad Laue wrote: > Guido Van Hoecke wrote: > >> My sis900 network card is behaves in 4.7 as it did in 4.6.2: >> it still complains 'MII without any PHY!' The least i can say is that >> this is utterly frustrating... > > > Have a look at this PR and test the patch provided by the followups out. > If it works for you, post a followup to it and some information as to > its functionality to the list. > > http://www.freebsd.org/cgi/query-pr.cgi?pr=30836 You'll have to help me a bit. 1) When I read this PR, it is not clear to me which of the suggested patches have to be applied. 2) Is there a procedure / tool to extract the diffs from the pr. I know I'll have to use the patch program to apply them. But I do hope that there is somewhere a short description of the way to proceed. I've been browsing the manual and the developers handbook, but didn't find what I was looking for. 3) Is it ok if I apply these patches to my freshly installed 4.7-RELEASE kernel sources? Not having IP connectivity kind of complicates things a bit ;-) -- Guido Van Hoecke To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sat Oct 12 0:39:26 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5B66537B401; Sat, 12 Oct 2002 00:39:18 -0700 (PDT) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id 42DAC43E8A; Sat, 12 Oct 2002 00:39:17 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id RAA07511; Sat, 12 Oct 2002 17:39:09 +1000 Date: Sat, 12 Oct 2002 17:49:24 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Terry Lambert Cc: Craig Rodrigues , , Subject: Re: Problem detecting POSIX symbolic constants In-Reply-To: <3DA72A53.9D2D61E5@mindspring.com> Message-ID: <20021012171803.F15910-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 11 Oct 2002, Terry Lambert wrote: > Bruce Evans wrote: > > > I know it's not fashionable to write code that's portable to > > > compilers other than GCC, but even if FreeBSD is going to ignore > > > portability for it's own source code, it's probably unreasonable > > > to expect ACE to ignore portability for theirs. > > > > Undefined symbols being 0 in cpp in expressions was in early C compilers > > if not the original one. Consult your archives for a posting 10-15 years > > or so ago by dmr in comp.std.c about him checking this in his archives. > > You mean "in preprocessor expressions", of course. Oop. I meant only one "in" in "being 0 in cpp in [sic] expressions". > > > This can't be the case; specifically, the sysconf() test will > > > only work at runtime, which means that the symbols had to be > > > there and resolvable at link time. > > > > Symbols can be resolved at runtime using dlopen(), etc. They would only > > actually be available on systems where sysconf() says that they are. > > You can't depend on people using the standard C library via dlopen, > as opposed to, uh, "linking". Yes, a more careful reading of POSIX shows that if _POSIX_REALTIME_SIGNAL_ is undefined, then the (compile-time) system makes no claims as to the feature being either supported or unsupported. (Systems should leave it undefined it they are clueless about it.) The feature may still work at runtime, but the compile-time system makes no claims that it will or won't. Applications would have to do something magic to use it at runtime if it turns out to be present at runtime. It could easily be present at runtime because you update the OS. > > > Uh, the 1990 standard, which allowed "#if" is only 12 years old. > > > > #if is in K&R1 (1978). > > According to my first edition "The C Programming Language": > > 12.3 Conditional compilation > A compiler control line of the form > > #if constant-expression > > checks whether the constant expression (see section 15) > evaluates to non-zero. > > ... > > 15 Constant expressions > In several places C requires expressions which evaluate > to a constant: after case, as array bounds, and in initializers. > In the first two cases, the expression can involve only integer > constants, character constants, and sizeof expressions, possibly > connected by the binary operators > > + - * / % & | ^ << >> == != < > <= >= > > or by the unary operators > > - ~ > > or by the ternary operator > > ?: > > ...no "&&" or "||"... sorry. Also, "defined()" is not defined. > > I think you will find that "&&" and "||" in #if statements are > later extensions. > > The value of undefined macros in preprocessor expressions being > assumed to be zero is also not documented in the book. I would > have to imagine that they were not considered constant expressions. This book has lots of bugs (mostly from being too informal and/or omitting necessary details). Note that section 15 doesn't even mention "&&" and "||" working in non-cpp constant expressions. But they cetainly worked in expressions, and expressions with only constants in them are (informally) constant expessions. I think you are right that defined() didn't exist then. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sat Oct 12 1:47:30 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 25DC337B401; Sat, 12 Oct 2002 01:47:29 -0700 (PDT) Received: from pintail.mail.pas.earthlink.net (pintail.mail.pas.earthlink.net [207.217.120.122]) by mx1.FreeBSD.org (Postfix) with ESMTP id BB8D743EA3; Sat, 12 Oct 2002 01:47:28 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0112.cvx22-bradley.dialup.earthlink.net ([209.179.198.112] helo=mindspring.com) by pintail.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 180Hva-0006a1-00; Sat, 12 Oct 2002 01:47:18 -0700 Message-ID: <3DA7E0F4.5988CA77@mindspring.com> Date: Sat, 12 Oct 2002 01:44:36 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Bruce Evans Cc: Craig Rodrigues , freebsd-standards@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG Subject: Re: Problem detecting POSIX symbolic constants References: <20021012171803.F15910-100000@gamplex.bde.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bruce Evans wrote: > This book has lots of bugs (mostly from being too informal and/or > omitting necessary details). Note that section 15 doesn't even mention > "&&" and "||" working in non-cpp constant expressions. But they > cetainly worked in expressions, and expressions with only constants > in them are (informally) constant expessions. I think you are right > that defined() didn't exist then. McCarthy operators are strange. I think that there wasn't an expectation that there would be an evaluation indirection, though you could build one with multiple terenary "?:" expressions. I think the lack of "||" and "&&" mostly had to do with the fact that there was conditional evaluation of the RHS of the operator, based on the result of the LHS. With just an "&" or an "|", you actually need a much less complicated state machine to evaluate a constant expression. With the "||"/"&&", you almost have to do an edge associative operation, which implies a much more complex state machine for the preprocessor, I think. So my guess as to why it's now supported is that the cpp we use today is actually derived from the compiler code itself (and in many compilers, like MSVC++, it's integrated into the compiler completely, and only available seperately as an afterthought)... it being supported is more or less a side effect. In any case, ACE has to be a lot more protable than, say, "ls". Though I'd personally like "ls" to be portable enough that every UNIX just compiled up the FreeBSD version of its own (the best way to establish a standard -- see TCP), it's OK for FreeBSD specific code to be less portable than code ported to FreeBSD. ...now if we only knew what "_POSIX_VERSION > mumble" needed for "mumble"... 8-). -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sat Oct 12 6:59:34 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CE4BA37B401 for ; Sat, 12 Oct 2002 06:59:31 -0700 (PDT) Received: from bcn.dyndns.org (207-172-89-64.c3-0.bth-ubr7.lnh-bth.md.cable.rcn.com [207.172.89.64]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6451A43E65 for ; Sat, 12 Oct 2002 06:59:27 -0700 (PDT) (envelope-from shiao@terra.es) Received: from bcn.dyndns.org (www@bcn.dyndns.org [IPv6:::1]) by bcn.dyndns.org (8.12.2/8.12.2) with ESMTP id g9CAVOJf002262 for ; Sat, 12 Oct 2002 06:31:24 -0400 (EDT) Received: (from www@localhost) by bcn.dyndns.org (8.12.2/8.12.2/Submit) id g9CAVNZb018180 for hackers@freebsd.org; Sat, 12 Oct 2002 06:31:23 -0400 (EDT) X-Authentication-Warning: bcn.dyndns.org: www set sender to shiao@terra.es using -f Received: from 10.1.111.3 ( [10.1.111.3]) as user shiao@localhost by bcn.dyndns.org with HTTP; Sat, 12 Oct 2002 06:31:23 -0400 Message-ID: <1034418683.3da7f9fb445ce@bcn.dyndns.org> Date: Sat, 12 Oct 2002 06:31:23 -0400 From: Shiao Yeh To: hackers@freebsd.org Subject: Help saving 4.7 kernel dump to disk MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit User-Agent: Internet Messaging Program (IMP) 3.1 X-Originating-IP: 10.1.111.3 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, I tied to save the kernel core dump following Michael Lucas instructions, but it only works when the kernel is already loaded. I am experiencing kernel trap during kernel boot, and the show disk/device and ddb> call setdumpdev (0xf000b444) does not work for me. What else can I try to save the kernel dump while booting? I haven't seen anything in LINT regarding dump(s). I was running 4.6-Stable fine, but 4.7-STABLE kernel panic on a Sony Vaio. Please let me know if there is anything else I can try. Follows the dmesg Copyright (c) 1992-2002 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD 4.7-STABLE #8: Sat Oct 12 01:26:29 EDT 2002 root@harry2.bcn.dyndns.org:/usr/obj/usr/src/sys/GENERIC Timecounter "i8254" frequency 1193182 Hz CPU: Pentium III/Pentium III Xeon/Celeron (745.25-MHz 686-class CPU) Origin = "GenuineIntel" Id = 0x686 Stepping = 6 Features=0x383f9ff real memory = 333971456 (326144K bytes) avail memory = 319266816 (311784K bytes) Preloaded elf kernel "kernel" at 0xc051e000. Pentium Pro MTRR support enabled md0: Malloc disk Using $PIR table, 9 entries at 0xc00fdf30 npx0: on motherboard npx0: INT 16 interface pcib0: on motherboard pci0: on pcib0 pci0: at 2.0 irq 9 pcib1: at device 30.0 on pci0 pci1: on pcib1 pci1: (vendor=0x104c, dev=0x8021) at 0.0 irq 9 pcic0: irq 0 at device 2.0 on pci1 pcic0: PCI Memory allocated: 0x88000000 pcic0: Polling mode pccard0: on pcic0 fxp0: port 0x3000-0x303f mem 0xf4104000-0xf4104fff irq 9 at device 8.0 on pci1 fxp0: Ethernet address 08:00:46:16:ac:a5 inphy0: on miibus0 inphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto isab0: at device 31.0 on pci0 isa0: on isab0 atapci0: port 0x1800-0x180f at device 31.1 on pci0 ata0: at 0x1f0 irq 14 on atapci0 ata1: at 0x170 irq 15 on atapci0 uhci0: port 0x1820-0x183f irq 9 at device 31.2 on pci0 usb0: on uhci0 usb0: USB revision 1.0 uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub0: 2 ports with 2 removable, self powered pci0: (vendor=0x8086, dev=0x2443) at 31.3 irq 9 uhci1: port 0x1840-0x185f irq 9 at device 31.4 on pci0 usb1: on uhci1 usb1: USB revision 1.0 uhub1: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub1: 2 ports with 2 removable, self powered umass0: Sony USB Memory Stick Slot, rev 1.10/1.80, addr 2 pci0: (vendor=0x8086, dev=0x2445) at 31.5 irq 9 pci0: (vendor=0x8086, dev=0x2446) at 31.6 irq 9 eisa0: Fatal trap 12: page fault while in kernel mode fault virtual address = 0x0 fault code = supervisor read, page not present instruction pointer = 0x8:0xc037d480 stack pointer = 0x10:0xc0540f1c frame pointer = 0x10:0xc0540f24 code segment = base 0x0, limit 0xfffff, type 0x1b = DPL 0, pres 1, def32 1, gran 1 processor eflags = interrupt enabled, resume, IOPL = 0 current process = 0 (swapper) interrupt mask = net tty bio cam no such device 'ad' no such device 'd' panic: from debugger Fatal trap 3: breakpoint instruction fault while in kernel mode instruction pointer = 0x8:0xc0371df4 stack pointer = 0x10:0xc0540d30 frame pointer = 0x10:0xc0540d38 code segment = base 0x0, limit 0xfffff, type 0x1b = DPL 0, pres 1, def32 1, gran 1 processor eflags = interrupt enabled, IOPL = 0 current process = 0 (swapper) interrupt mask = net tty bio cam panic: from debugger Uptime: 0s Automatic reboot in 15 seconds - press a key on the console to abort --> Press a key on the console to reboot, --> or switch off the system now. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sat Oct 12 7:13:46 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5C97A37B401; Sat, 12 Oct 2002 07:13:45 -0700 (PDT) Received: from chiark.greenend.org.uk (chiark.greenend.org.uk [212.135.138.206]) by mx1.FreeBSD.org (Postfix) with ESMTP id 182E343E7B; Sat, 12 Oct 2002 07:13:44 -0700 (PDT) (envelope-from fanf@chiark.greenend.org.uk) Received: from fanf by chiark.greenend.org.uk with local (Exim 3.12 #1) id 180N1N-0007BV-00 (Debian); Sat, 12 Oct 2002 15:13:37 +0100 Date: Sat, 12 Oct 2002 15:13:36 +0100 From: Tony Finch To: Terry Lambert Cc: Bruce Evans , Craig Rodrigues , freebsd-standards@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG Subject: Re: Problem detecting POSIX symbolic constants Message-ID: <20021012151336.A24868@chiark.greenend.org.uk> References: <20021012171803.F15910-100000@gamplex.bde.org> <3DA7E0F4.5988CA77@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <3DA7E0F4.5988CA77@mindspring.com>; from tlambert2@mindspring.com on Sat, Oct 12, 2002 at 01:44:36AM -0700 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sat, Oct 12, 2002 at 01:44:36AM -0700, Terry Lambert wrote: > > I think the lack of "||" and "&&" mostly had to do with the fact > that there was conditional evaluation of the RHS of the operator, > based on the result of the LHS. > > With just an "&" or an "|", you actually need a much less complicated > state machine to evaluate a constant expression. With the "||"/"&&", > you almost have to do an edge associative operation, which implies a > much more complex state machine for the preprocessor, I think. No -- the short-circuiting behaviour of && and || only matters if you can have side-effects, which you can't in the preprocessor, so there is no need to implement it (unifdef doesn't). Tony. -- f.a.n.finch http://dotat.at/ THAMES DOVER: SOUTHEASTERLY VEERING NORTHWESTERLY 4 OR 5, OCCASIONALLY 6, BECOMING VARIABLE 3. RAIN OR SHOWERS. MODERATE OR GOOD. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sat Oct 12 11: 8:58 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A930637B401 for ; Sat, 12 Oct 2002 11:08:57 -0700 (PDT) Received: from exchange.corp.cre8.com (ns.cre8.com [216.135.81.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1861243EC2 for ; Sat, 12 Oct 2002 11:08:57 -0700 (PDT) (envelope-from sullrich@CRE8.COM) Received: by exchange.corp.cre8.com with Internet Mail Service (5.5.2653.19) id <4G1J2C8L>; Sat, 12 Oct 2002 14:15:49 -0400 Message-ID: <2F6DCE1EFAB3BC418B5C324F13934C9601D23845@exchange.corp.cre8.com> From: Scott Ullrich To: "'hackers@freebsd.org'" Subject: DistCC Date: Sat, 12 Oct 2002 14:15:49 -0400 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Greetings, Hackers-- Have any of you played around with DistCC (DistCC is a program to distribute compilation of C or C++ code across several machines on a network). I am hoping to improve my buildworld farm at home. With a dual AMD MP 1800, I can build world in 26 minutes but I am hoping to add a few more machines to the mix and try to get this down to 10 minutes (or less). I have a 3Ware Escalade 7810 and can get around 70 Mbytes a sec read/write so disk throughput hopefully will not be an issue. So with the above said, have any of you actually setup a build farm using DistCC and successfully built a FreeBSD world? Thanks in advance, -Scott To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sat Oct 12 13:21:31 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4103937B401; Sat, 12 Oct 2002 13:21:30 -0700 (PDT) Received: from hawk.mail.pas.earthlink.net (hawk.mail.pas.earthlink.net [207.217.120.22]) by mx1.FreeBSD.org (Postfix) with ESMTP id D393743EAC; Sat, 12 Oct 2002 13:21:29 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0083.cvx21-bradley.dialup.earthlink.net ([209.179.192.83] helo=mindspring.com) by hawk.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 180Sl8-0000KU-00; Sat, 12 Oct 2002 13:21:15 -0700 Message-ID: <3DA883F2.33E84C@mindspring.com> Date: Sat, 12 Oct 2002 13:20:03 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Tony Finch Cc: Bruce Evans , Craig Rodrigues , freebsd-standards@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG Subject: Re: Problem detecting POSIX symbolic constants References: <20021012171803.F15910-100000@gamplex.bde.org> <3DA7E0F4.5988CA77@mindspring.com> <20021012151336.A24868@chiark.greenend.org.uk> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Tony Finch wrote: > > With just an "&" or an "|", you actually need a much less complicated > > state machine to evaluate a constant expression. With the "||"/"&&", > > you almost have to do an edge associative operation, which implies a > > much more complex state machine for the preprocessor, I think. > > No -- the short-circuiting behaviour of && and || only matters if > you can have side-effects, which you can't in the preprocessor, > so there is no need to implement it (unifdef doesn't). Consider: #if _DEFINED_SUPPORTED && defined(SOMETHING) -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sat Oct 12 14:23:14 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BA70837B401 for ; Sat, 12 Oct 2002 14:23:12 -0700 (PDT) Received: from server2.wojo.com (server2.wojo.com [198.77.29.100]) by mx1.FreeBSD.org (Postfix) with ESMTP id 650C743E9C for ; Sat, 12 Oct 2002 14:23:12 -0700 (PDT) (envelope-from robertw@wojo.com) Received: by server2.wojo.com (Postfix, from userid 502) id 09CB884; Sat, 12 Oct 2002 17:23:11 -0400 (EDT) Received: from moe.wojo.net (ip44.dialup.iflint.net [198.173.220.44]) by server2.wojo.com (Postfix) with ESMTP id 6E38A96 for ; Sat, 12 Oct 2002 17:23:07 -0400 (EDT) Subject: RE: DistCC MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: quoted-printable Date: Sat, 12 Oct 2002 17:22:56 -0400 Message-ID: X-MS-Has-Attach: X-MimeOLE: Produced By Microsoft Exchange V6.0.6249.0 X-MS-TNEF-Correlator: Thread-Topic: DistCC content-class: urn:content-classes:message Thread-Index: AcJyGqNyvgQEo68CQESFbi2z/XIWyQAGg3hQ From: "Robert S. Wojciechowski Jr." To: X-Spam-Status: No, hits=-106.0 required=6.0 tests=USER_IN_WHITELIST,USER_IN_WHITELIST_TO version=2.50-cvs X-Spam-Level: X-Sanitizer: Anomy Sanitizer Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Scott, Although I can't try it right now, I was going to give this a spin in about a week or so on buildworlds. I have a few servers that are 733MHz PIIIs running on mirrored RAID 7200RPM drives (3ware as well) and would love to speed up the buildworld time from 58 minutes. A friend will also have his server in the rack and could speed it up even more, which would be VERY nice! --Robert -----Original Message----- From: Scott Ullrich [mailto:sullrich@CRE8.COM]=20 Sent: Saturday, October 12, 2002 2:16 PM To: 'hackers@freebsd.org' Subject: DistCC Greetings, Hackers-- Have any of you played around with DistCC (DistCC is a program to distribute compilation of C or C++ code across several machines on a network). I am hoping to improve my buildworld farm at home. With a dual AMD MP 1800, I can build world in 26 minutes but I am hoping to add a few more machines to the mix and try to get this down to 10 minutes (or less). I have a 3Ware Escalade 7810 and can get around 70 Mbytes a sec read/write so disk throughput hopefully will not be an issue. So with the above said, have any of you actually setup a build farm using DistCC and successfully built a FreeBSD world? Thanks in advance, -Scott To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message From owner-freebsd-hackers Sat Oct 12 17:24:38 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7013237B401 for ; Sat, 12 Oct 2002 17:24:37 -0700 (PDT) Received: from pepcross.com (pc-80-192-15-110-az.blueyonder.co.uk [80.192.15.110]) by mx1.FreeBSD.org (Postfix) with ESMTP id 32F8143EA9 for ; Sat, 12 Oct 2002 17:24:36 -0700 (PDT) (envelope-from steve@pepcross.com) Received: (from steve@localhost) by pepcross.com (8.11.6/8.11.6) id g9D0OKE00957 for freebsd-hackers@freebsd.org; Sun, 13 Oct 2002 01:24:20 +0100 (BST) (envelope-from steve) Date: Sun, 13 Oct 2002 01:24:20 +0100 From: Stephen Roome To: freebsd-hackers@freebsd.org Subject: Strange: syscons SC_PIXEL_MODE and userconfig interactions Message-ID: <20021013012420.A931@dylan.home> Mail-Followup-To: Stephen Roome , freebsd-hackers@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG So far I think that this is the weirdest problem I've had with any FreeBSD box. I've just recompiled a kernel for this laptop (old Compaq Armada 1550) which is a P133 with 16Mb of RAM. (Stop laughing you at the back!) This is running 4.7-RELEASE. Anyway, it's a reasonably cut down kernel which was all working fine until I added options SC_PIXEL_MODE to the kernel. (This is because the 100x37 VESA_800x600 mode is nicer than 80x25) Now it hangs straight after finding sbc/pcm devices and right before where it would normally find the hard disk (ad0). The kernel IS NOT compiled with any userconfig stuff at all, however if I boot from either BTX with -c or the loader with boot -c then it boots up fine. I'm typing this in 100x37 mode on this very laptop after two sucessful boots through the -c madness. Without the -c it just hangs. I'd include an output for debugging but I can't get any easily (no spare serial leads). I can compile a kernel with the debugger and try and find out a little more about where it's hanging but there is someone about who has the faintest idea what is going on without me trying to boot a debugging kernel on this slightly ageing machine then that would be a better start. (ctrl-alt-escape does at least tell me that there is no debugger in the kernel, but I know it's not really getting much further because pccardd and perhaps init and whatnot are not starting up and a power-off doesn't result in anything telling me I'd not unmounted.. So I don't think it got that far.) (I almost posted this to -questions, so feel free to flame me for asking something that's prolly been round the lists before but which I didn't find.) Many thanks in advance, Steve Roome (not subscribed to the list so please CC me) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message