From owner-freebsd-atm@FreeBSD.ORG Wed Jun 22 13:41:20 2005 Return-Path: X-Original-To: freebsd-atm@freebsd.org Delivered-To: freebsd-atm@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 19C9316A41C; Wed, 22 Jun 2005 13:41:20 +0000 (GMT) (envelope-from heiner@bilch.com) Received: from ns2.bilch.com (ns2.bilch.com [213.217.66.130]) by mx1.FreeBSD.org (Postfix) with ESMTP id 23FFD43D55; Wed, 22 Jun 2005 13:41:16 +0000 (GMT) (envelope-from heiner@bilch.com) Received: from [10.0.0.1] (sieben.schlaf.bilch.com [10.0.0.1]) by ns2.bilch.com (8.13.4/8.13.4) with ESMTP id j5MDfEn7064220; Wed, 22 Jun 2005 15:41:15 +0200 (CEST) (envelope-from heiner@bilch.com) Message-ID: <42B96A91.9030508@bilch.com> Date: Wed, 22 Jun 2005 15:41:37 +0200 From: Heiner Strauss User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.8) Gecko/20050601 X-Accept-Language: de, de-ch, de-at, en-us, en, fr-fr, zh-tw MIME-Version: 1.0 To: Harti Brandt References: <42B805F6.9050804@bilch.com> <20050621153222.U20063@beagle.kn.op.dlr.de> <42B87C41.50108@bilch.com> <20050622100548.G70536@beagle.kn.op.dlr.de> In-Reply-To: <20050622100548.G70536@beagle.kn.op.dlr.de> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-atm@freebsd.org Subject: Re: Switched virtual connection X-BeenThere: freebsd-atm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: ATM for FreeBSD! List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Jun 2005 13:41:20 -0000 Harti Brandt wrote: > On Tue, 21 Jun 2005, Heiner Strauss wrote: > > HS>Harti Brandt wrote: > HS>> On Tue, 21 Jun 2005, Heiner Strauss wrote: > HS>> > HS>> Hi, > HS>> > HS>> HS>Im trying to set up a SVC directly to an atm edge switch (3Com SS II > HS>> with an > HS>> HS>ATM uplink modul). The host has FreeBSD 5.4 and a ForeRunner 155HE card. > HS>> I > HS>> HS>have 2 Questions: > HS>> HS> > HS>> HS>1. Which of the 3 ATM implementations do I have to use ? > HS>> > HS>> You should use the HARP stack (that is netatm) plus the hatm driver (that > HS>> needs options atm) and the if_harp driver. Something like: > HS>> > HS>> natm_interfaces="hatm0" > HS>> > HS>> plus HARP configuration. See also rc.d/atm[123]. > HS>> > HS>> HS>2. Do I need ATMARPD ? > HS>> > HS>> You should google around for HARP. There is somewhere documentation on the > HS>> net. I think, that atmarpd is only needed if you want to synchronize > HS>> several atmarp daemons. > HS>> > HS>> HS>3. Are there examples for SVCs in netgraph/natm/HARP ? > HS>> > HS>> There is some documentation in /usr/share/examples/atm. For the rc.conf > HS>> variables you should refer to the rc files. > HS>> > HS> > HS>Ok. I did some homework. I have now : > HS> > HS>$ atm show int > HS>Interface Sigmgr State > HS>hatm0 UNI 3.0 INIT > HS> ATM address = 0x47.0005.80.ffe100.0000.0000.0000.0020482e1367.00 > HS> Network interfaces: fa0 > HS> > HS>There is now an UNI 3.0 signal manager and an ATM address. When I plug in the > HS>fiber the machine panics: > HS> > HS>Fatal trap 12: page fault while in kernel mode > HS>fault virtual address = 0x0 > HS>fault code = supervisor write, page not present > HS>... > HS>processor eflags = interrupt enabled, resume, IOPL=0 > HS>current process = 26 (swi1: net) > HS>trap number = 12 > HS>panic: page fault > HS>Uptime 29s > HS>Cannot dump.... > HS> > HS>I have this in my kernel: > HS> > HS>options ADAPTIVE_GIANT # Giant mutex is adaptive. > HS> > HS>options NATM > HS>options ATM_CORE #core ATM protocol family > HS>options ATM_IP #IP over ATM support > HS>#options ATM_SIGPVC #SIGPVC signalling manager > HS>#options ATM_SPANS #SPANS signalling manager > HS>options ATM_UNI #UNI signalling manager > HS> > HS># ATM > HS>device hatm > HS>device utopia > HS>device atm > HS>device harp > HS> > HS>What do I have to do know ? > > You can remove options NATM (but this has nothing to do with the panic). > Can you please compile in DDB so that we get a stack trace? Also do you > run current? If yes, you should fetch the patches I have committed today. > I have outcommented "options NATM". Here is the stack trace: air# hatm0: carrier detected Fatal trap 12: page fault while in kernel mode fault virtual address = 0x0 fault code = supervisor write, page not present instruction pointer = 0x8:0xc18f9000 stack pointer = 0x10:0xcbd20bb8 frame pointer = 0x10:0xcbd20bc0 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 = 26 (swi1: net) [thread pid 26 tid 100020 ] Stopped at 0xc18f9000: addb %al,0(%eax) db> trace Tracing pid 26 tid 100020 td 0xc1502000 _end(c1a98300,c18fe9ec,c1a98400,c1a98300,cbd20be8) at 0xc18f9000 m_tag_delete_chain(c1a98300,0) at m_tag_delete_chain+0x37 mb_dtor_mbuf(c1a98300,100,0,0,0) at mb_dtor_mbuf+0x14 uma_zfree_arg(c1045ae0,c1a98300,0) at uma_zfree_arg+0x38 m_freem(c1a98300) at m_freem+0x2e sscf_uni_upper(82008013,c18fb000,c1a98300,0,c18fd000) at sscf_uni_upper+0x1a9 sscop_bgn_outconn(c18fd000,c1a98300,c16a9e00) at sscop_bgn_outconn+0xd8 sscop_upper(81808011,c18fd000,c1a98300,0,c1a98300) at sscop_upper+0x8d harp_recv_stack(c18fe9ec,c1a98300) at harp_recv_stack+0x45 atm_intr(c1a98300) at atm_intr+0x1a netisr_processqueue(c072d75c) at netisr_processqueue+0x9f swi_net(0) at swi_net+0xa6 ithread_loop(c14eb480,cbd20d38) at ithread_loop+0x151 fork_exit(c04edef8,c14eb480,cbd20d38) at fork_exit+0x74 fork_trampoline() at fork_trampoline+0x8 --- trap 0x1, eip = 0, esp = 0xcbd20d6c, ebp = 0 --- db>call boot(0) Waiting (max 60 seconds) for system process `vnlru' to stop...done Waiting (max 60 seconds) for system process `bufdaemon' to stop...done Waiting (max 60 seconds) for system process `syncer' to stop...panic: atm_stack_drain: Queue not emptied KDB: enter: panic [thread pid 27 tid 100021 ] Stopped at kdb_enter+0x2b: nop Ok, I pull the fiber... The OS is: FreeBSD air.schlaf.bilch.com 5.4-STABLE FreeBSD 5.4-STABLE #1: Wed Jun 22 14:35:39 CEST 2005 heiner@g2.schlaf.bilch.com:/usr/src/sys/i386/compile/HARP i386 > HS> > HS>> HS>I have googled around and found examples for PVCs, but the switch > HS>> supports > HS>> HS>only SVCs. Both ends seem to send/receive SONET frames but nothing more: > HS>> HS> > HS>> HS>hatm0: flags=841 mtu 9180 > HS>> HS> media: ATM Multi-mode/155MBit > HS>> HS> status: active > HS>> HS>fa0: flags=43 mtu 9180 > HS>> HS> ether 00:20:48:2e:13:67 > HS>> HS> > HS>> HS>On the switch the Link Status LED is green. At the end I want to build > HS>> HS>something like this: > HS>> HS> > HS>> HS>Telco -- DSL Router -- FreeBSD as a IP/ATM bridge/router or switch -- > HS>> 3Com > HS>> HS>with ethernet clients > HS>> HS> > HS>> HS>Is this possible or do I need a real ATM switch ? > HS>> > HS>> What do you want the FreeBSD to do here? Should it terminate the pppoa or > HS>> whatever your DLS uses? Or do you want it to transparently connect the DSL > HS>> to the ATM switch on the ATM layer? > HS>> > HS> > HS>Not exactly. For the beginning I just want to build a private ATM net. The > HS>FreeBSD host should provide (IP)-services (imap,http,video...) to the > HS>Ethernet VLANs clients at the 3Com switch. The telco DSL Router is giving me > HS>ethernet, maybe it's possible to connect it to a VLAN at the switch and make > HS>the ATM cells available to my private net. But this is for later. Basicly I > HS>want to have some practical expirience with ATM. > > Ok so let's start with the first thing. Yes :) > > harti -- Heiner Strauss heiner@bilch.com Bilch International Consulting www.bilch.com Hamburg Markusstrasse 4 20355 Hamburg Tel.: +49 40 3480667