From owner-freebsd-net@FreeBSD.ORG Sun Jan 25 13:18:55 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AFFED16A4CE for ; Sun, 25 Jan 2004 13:18:55 -0800 (PST) Received: from mails.tsinghua.edu.cn (mails.tsinghua.edu.cn [166.111.8.16]) by mx1.FreeBSD.org (Postfix) with SMTP id 7CF4843D5A for ; Sun, 25 Jan 2004 13:18:53 -0800 (PST) (envelope-from lguohan00@mails.tsinghua.edu.cn) Received: (eyou send program); Mon, 26 Jan 2004 05:14:51 +0800 Message-ID: <275065291.05318@mails.tsinghua.edu.cn> Received: from unknown (HELO mails.tsinghua.edu.cn) (unknown@127.0.0.1) by 127.0.0.1 with SMTP; Mon, 26 Jan 2004 05:14:51 +0800 Received: (eqmail ); 25 Jan 2004 21:14:50 -0000 Received: from unknown (HELO lyfnotebook) (lguohan00@218.194.22.69) by mails.tsinghua.edu.cn with SMTP; 25 Jan 2004 21:14:50 -0000 Message-ID: <001301c3e388$a35b8f90$6401a8c0@lyfnotebook> From: "Guohan Lu" To: Date: Mon, 26 Jan 2004 05:17:27 +0800 MIME-Version: 1.0 Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: base64 X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 Subject: Bad "bad" retransmit recovery in TCP X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 25 Jan 2004 21:18:55 -0000 aGksDQogICAgSSBub3RpY2VkIGluIG15IFRDUCB0cmFjZSB0aGF0IHRoZXJlIGFyZSBtYW55IGJh ZCAiYmFkIiByZXRyYW5zbWl0IHJlY292ZXJpZXMuIFRoYXQgaXMgdGhlIHBhY2tldCBnZXQgbG9z dCwNCnRoZSB0aW1lb3V0IGhhcHBlbnMuIEhvd2V2ZXIsIHdoZW4gdGhlIGxvc3QgcGFja2V0IGFy ZSBhY2tub3dsZWRnZWQsIHRoZSBjd25kIG9mIHNlbmRlciBpcyBub3QgMiwgDQpidXQgcmVzdW1l cyB0aGUgdmFsdWUgYmVmb3JlIHRpbWVvdXQuIFRoaXMga2luZCBvZiBiZWhhdmlvciBoYXBwZW5z IHdoZW4gdGhlIFJUVCBpcyB2ZXJ5IHNtYWxsLCANCmFyb3VuZCBzZXZlcmFsIG1zLCBubyBtb3Jl IHRoYW4gMTBtcy4NCiAgICBJdCBzZWVtcyB0byBtZSB0aGF0IGZvbGxvd2luZyBjb2RlIGlzIHJ1 biB3aGVuIHRoZSBhY2tub3dsZWRnZW1lbnQgZm9yIHRoZSBsb3N0IHBhY2tldCBpcyByZWNlaXZl ZC4NCiAgaWYgKHRwLT50X3J4dHNoaWZ0ID09IDEgJiYgdGlja3MgPCB0cC0+dF9iYWRyeHR3aW4p IHsNCiAgIHRwLT5zbmRfY3duZCA9IHRwLT5zbmRfY3duZF9wcmV2Ow0KICAgdHAtPnNuZF9zc3Ro cmVzaCA9IHRwLT5zbmRfc3N0aHJlc2hfcHJldjsNCiAgIHRwLT5zbmRfbnh0ID0gdHAtPnNuZF9t YXg7DQogICB0cC0+dF9iYWRyeHR3aW4gPSAwOyAvKiBYWFggcHJvYmFibHkgbm90IHJlcXVpcmVk ICovIA0KICB9DQogICBJIHdvbmRlciBpZiB0X2JhZHJ4dHdpbiBpcyBub3QgY29ycmVjdGx5IHNl dCBpbiB0aGlzIHNpdHVhdGlvbj8gKHdoZW4gdGhlIHJ0dCBpcyB2ZXJ5IHNtYWxsKQ0KICAgDQpH dW9oYW4gTHU= From owner-freebsd-net@FreeBSD.ORG Sun Jan 25 14:49:21 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5B46316A4CE for ; Sun, 25 Jan 2004 14:49:21 -0800 (PST) Received: from mailtoaster1.pipeline.ch (mailtoaster1.pipeline.ch [62.48.0.70]) by mx1.FreeBSD.org (Postfix) with ESMTP id B7DB943D41 for ; Sun, 25 Jan 2004 14:49:19 -0800 (PST) (envelope-from andre@freebsd.org) Received: (qmail 46071 invoked from network); 25 Jan 2004 22:49:18 -0000 Received: from unknown (HELO freebsd.org) ([62.48.0.54]) (envelope-sender ) by mailtoaster1.pipeline.ch (qmail-ldap-1.03) with SMTP for ; 25 Jan 2004 22:49:18 -0000 Message-ID: <401447EA.716B266C@freebsd.org> Date: Sun, 25 Jan 2004 23:49:14 +0100 From: Andre Oppermann X-Mailer: Mozilla 4.76 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 To: Guohan Lu References: <275065291.05318@mails.tsinghua.edu.cn> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit cc: freebsd-net@freebsd.org Subject: Re: Bad "bad" retransmit recovery in TCP X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 25 Jan 2004 22:49:21 -0000 Guohan Lu wrote: > > hi, > I noticed in my TCP trace that there are many bad "bad" retransmit > recoveries. That is the packet get lost, the timeout happens. However, > when the lost packet are acknowledged, the cwnd of sender is not 2, > but resumes the value before timeout. This kind of behavior happens when > the RTT is very small, around several ms, no more than 10ms. > It seems to me that following code is run when the acknowledgement > for the lost packet is received. > if (tp->t_rxtshift == 1 && ticks < tp->t_badrxtwin) { > tp->snd_cwnd = tp->snd_cwnd_prev; > tp->snd_ssthresh = tp->snd_ssthresh_prev; > tp->snd_nxt = tp->snd_max; > tp->t_badrxtwin = 0; /* XXX probably not required */ > } > I wonder if t_badrxtwin is not correctly set in this situation? (when > the rtt is very small) What version of FreeBSD are you running? A 'uname -a' would be great of great help. >From your description it sounds like the code which is supposed to recover from the case when just a returning ACK is lost (not the sent segment) is going in here. For some reason it looks like the code doesn't detect that a real retransmit of the segment happend. On the other hand it could be that you see fast recovery in action. A packet trace of your case would be helpful too to narrow down the problem. -- Andre From owner-freebsd-net@FreeBSD.ORG Sun Jan 25 20:18:37 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B4FFE16A4CE for ; Sun, 25 Jan 2004 20:18:37 -0800 (PST) Received: from mail.oisca.org (mail.oisca.org [164.46.152.13]) by mx1.FreeBSD.org (Postfix) with ESMTP id 47A8A43D2D for ; Sun, 25 Jan 2004 20:18:35 -0800 (PST) (envelope-from r_ikeda@oisca.org) Received: from oisca.org (9.32.44.61.ap.yournet.ne.jp [61.44.32.9]) (authenticated)i0Q4IY024067 for ; Mon, 26 Jan 2004 13:18:34 +0900 Message-ID: <40149506.6090602@oisca.org> Date: Mon, 26 Jan 2004 13:18:14 +0900 From: "Rommel B. Ikeda" Organization: OISCA-International User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.6b) Gecko/20040115 Thunderbird/0.4 X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-net@freebsd.org Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Subject: Setting-Up my PC to a Printer in our LAN - FX DocuColor 1250 CP X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: r_ikeda@oisca.org List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Jan 2004 04:18:37 -0000 Hi, I am just wandering if anyone in this Mailing List can give me any hints, help or advice on how to set up my FreeBSD Box so that I can finally Print from my PC instead of asking my officemates who are using Windows to Print for me... I can give you the details after I get a confirmation from this List that I am in the right place to ask some advice or I should be using the freebsd-questions@freebsd.org instead...Of course the Printer I mentioned about is connected to our LAN with an IP Address... Thanks for any response... Rommel Ikeda From owner-freebsd-net@FreeBSD.ORG Sun Jan 25 20:28:28 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DAB7C16A4CE for ; Sun, 25 Jan 2004 20:28:28 -0800 (PST) Received: from mail.cs.ait.ac.th (mail.cs.ait.ac.th [192.41.170.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id 27D6843D41 for ; Sun, 25 Jan 2004 20:28:24 -0800 (PST) (envelope-from on@cs.ait.ac.th) Received: from banyan.cs.ait.ac.th (on@banyan.cs.ait.ac.th [192.41.170.5]) by mail.cs.ait.ac.th (8.12.10/8.9.3) with ESMTP id i0Q4SKvH089451; Mon, 26 Jan 2004 11:28:20 +0700 (ICT) Received: (from on@localhost) by banyan.cs.ait.ac.th (8.8.5/8.8.5) id LAA18910; Mon, 26 Jan 2004 11:31:20 +0700 (ICT) Date: Mon, 26 Jan 2004 11:31:20 +0700 (ICT) Message-Id: <200401260431.LAA18910@banyan.cs.ait.ac.th> X-Authentication-Warning: banyan.cs.ait.ac.th: on set sender to on@banyan.cs.ait.ac.th using -f From: Olivier Nicole To: r_ikeda@oisca.org In-reply-to: <40149506.6090602@oisca.org> (r_ikeda@oisca.org) References: <40149506.6090602@oisca.org> X-Virus-Scanned: by amavisd-milter (http://amavis.org/) cc: freebsd-net@freebsd.org Subject: Re: Setting-Up my PC to a Printer in our LAN - FX DocuColor 1250 CP X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Jan 2004 04:28:29 -0000 > I am just wandering if anyone in this Mailing List can give me any > hints, help or advice on how to set up my FreeBSD Box so that I can > finally Print from my PC instead of asking my officemates who are using > Windows to Print for me... I am not sure I understand what you exactelly mean. You want to print a job from FreeBSD to a printer attached to a Windows based machine? Samba does it very well. You want to print a job from FreeBSD to a printer attached to a FreeBSD machine? That is basic Unix printing. You want to print form a Windows system to a printer attached to a freeBSD machine? Samba again. You want to print from a Windows system to a printer attached to a Windows system? Uh? We are out of topic :) Olivier From owner-freebsd-net@FreeBSD.ORG Sun Jan 25 21:10:54 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1C55816A4CE for ; Sun, 25 Jan 2004 21:10:54 -0800 (PST) Received: from mail.oisca.org (mail.oisca.org [164.46.152.13]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4CE9943D39 for ; Sun, 25 Jan 2004 21:10:39 -0800 (PST) (envelope-from r_ikeda@oisca.org) Received: from oisca.org (9.32.44.61.ap.yournet.ne.jp [61.44.32.9]) (authenticated)i0Q5Ab028584 for ; Mon, 26 Jan 2004 14:10:38 +0900 Message-ID: <4014A13B.2040109@oisca.org> Date: Mon, 26 Jan 2004 14:10:19 +0900 From: "Rommel B. Ikeda" Organization: OISCA-International User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.6b) Gecko/20040115 Thunderbird/0.4 X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-net@freebsd.org References: <40149506.6090602@oisca.org> <200401260431.LAA18910@banyan.cs.ait.ac.th> In-Reply-To: <200401260431.LAA18910@banyan.cs.ait.ac.th> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: Setting-Up my PC to a Printer in our LAN - FX DocuColor 1250 CP X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: r_ikeda@oisca.org List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Jan 2004 05:10:54 -0000 Olivier Nicole wrote: >>I am not sure I understand what you exactelly mean. >> >>You want to print a job from FreeBSD to a printer attached to a >>Windows based machine? Samba does it very well. >> >>You want to print a job from FreeBSD to a printer attached to a >>FreeBSD machine? That is basic Unix printing. >> >>You want to print form a Windows system to a printer attached to a >>freeBSD machine? Samba again. >> >>You want to print from a Windows system to a printer attached to a >>Windows system? Uh? We are out of topic :) >> >> I am sorry for my English...I knew I was supposed to be short and specific... I just want to print from my FreeBSD Machine....The Printer I am talking about is connected to our LAN with an IP Address...It is not connected to any machine...I think it has a built-in LAN Card (I am sorry, I have read about Networking in the Handbook and the Complete FreeBSD Book but still I am having a difficulty in understanding things... I hope this time I am a little specific on what I want... Rommel Ikeda From owner-freebsd-net@FreeBSD.ORG Mon Jan 26 01:18:18 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C6AE216A4CE for ; Mon, 26 Jan 2004 01:18:18 -0800 (PST) Received: from diaspar.rdsnet.ro (diaspar.rdsnet.ro [213.157.165.224]) by mx1.FreeBSD.org (Postfix) with ESMTP id AB9AA43D41 for ; Mon, 26 Jan 2004 01:18:16 -0800 (PST) (envelope-from dudu@diaspar.rdsnet.ro) Received: (qmail 90137 invoked by uid 89); 26 Jan 2004 09:11:31 -0000 Received: from unknown (HELO diaspar.rdsnet.ro) (dudu@diaspar.rdsnet.ro@213.157.165.224) by 0 with AES256-SHA encrypted SMTP; 26 Jan 2004 09:11:31 -0000 Date: Mon, 26 Jan 2004 11:11:29 +0200 From: Vlad Galu To: freebsd-net@freebsd.org Message-Id: <20040126111129.29787c89.dudu@diaspar.rdsnet.ro> X-Mailer: Sylpheed version 0.9.8a (GTK+ 1.2.10; i386-portbld-freebsd4.9) Mime-Version: 1.0 Content-Type: multipart/signed; protocol="application/pgp-signature"; micalg="pgp-sha1"; boundary="Signature=_Mon__26_Jan_2004_11_11_29_+0200_d5W8nBayDs8L2Y3B" Subject: sk(4) and 3Com's 3c940 X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Jan 2004 09:18:18 -0000 --Signature=_Mon__26_Jan_2004_11_11_29_+0200_d5W8nBayDs8L2Y3B Content-Type: text/plain; charset=US-ASCII Content-Disposition: inline Content-Transfer-Encoding: 7bit Hi guys. Does the sk driver support all the features in the 3c940 chipset ? According to http://www.3com.com/products/en_US/detail.jsp?tab=prodspec&sku=3C940-MV00&pathtype=purchase, it has a lot of features. I'm running -CURRENT and ifconfig does not report any special options for my sk0 interface. I'd also like some reports from people who have used this chipset. Thanks in advance. ---- If it's there, and you can see it, it's real. If it's not there, and you can see it, it's virtual. If it's there, and you can't see it, it's transparent. If it's not there, and you can't see it, you erased it. --Signature=_Mon__26_Jan_2004_11_11_29_+0200_d5W8nBayDs8L2Y3B Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFAFNnDP5WtpVOrzpcRAmQ6AJwIcoMZLGkFhx37LmKuwRTT42/SUwCfeGKo OhSc1IIZCvL0b1aA98W7IG0= =vMeZ -----END PGP SIGNATURE----- --Signature=_Mon__26_Jan_2004_11_11_29_+0200_d5W8nBayDs8L2Y3B-- From owner-freebsd-net@FreeBSD.ORG Mon Jan 26 05:57:53 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CB9DC16A4CE for ; Mon, 26 Jan 2004 05:57:53 -0800 (PST) Received: from stewart.chicago.il.us (stewart.chicago.il.us [66.93.186.36]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5675343D58 for ; Mon, 26 Jan 2004 05:57:10 -0800 (PST) (envelope-from randall@stewart.chicago.il.us) Received: from stewart.chicago.il.us (stewart.chicago.il.us [127.0.0.1]) i0QDv1O6044895; Mon, 26 Jan 2004 07:57:02 -0600 (CST) (envelope-from randall@stewart.chicago.il.us) Message-ID: <40151CAD.9080502@stewart.chicago.il.us> Date: Mon, 26 Jan 2004 07:57:01 -0600 From: "Randall R. Stewart (home)" User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.4) Gecko/20031008 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Juan Rodriguez Hervella References: <200401191533.i0JFXUDE050449@soth.ventu> <40106D1A.3000902@stewart.chicago.il.us> <200401231843.14422.jrh@it.uc3m.es> In-Reply-To: <200401231843.14422.jrh@it.uc3m.es> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-net@freebsd.org Subject: Re: Two ISP lines X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Jan 2004 13:57:54 -0000 Juan Rodriguez Hervella wrote: >Just some questions about this paper: > >"(...) Note that this route has to be at the same level of the tree, i.e. >the code cannot return a less specific match or a more specific >match (...)" > >Question: I don't understand why if you are looking for an alternate >route you aren't allowed to retrieve a more specific route. This doesn't >make sense to me. If you are routing packets using a route when >there is a more specific match, you aren't doing "longest prefix match".\ > When you first ask for a route.. you get the longest prefix match. So you are at say a depth in the tree of N. If you try to go to a lower level in the tree (say N-1) then you could be going to the wrong place... I suppose one could go to a N+ level in the tree.. i.e. more specific match (assuming that maybe a new route was added lower in the tree).. but I never contemplated that aspect much because it would be more of a corner case I think... It would also make the code a bit more complex as well :-> > >Another question: if ISP-1 goes down, and you use this feature of >alternatives routes, this still doesn't fix the communication problem. Unless >you make something with the source addr. of the multihomed site's >packets, the reply packets will be lost in the faulty ISP, imho. > Ahh.. it is true that SOME ISP's do ingress filtering.. for TCP this would be a problem.. But for SCTP (a multi-homed protcol) this is NOT a problem.. the SCTP association would just use the source address of the outbound interface (since the association is made up of a SET of addresses on each side and a port on each side).... Now there are still ISP's that do NOT filter (I have one that does and one that does not :->)... R > >Regards. > > > > >On Friday 23 January 2004 01:38, Randall R. Stewart (home) wrote: > > >>Andrea/all: >> >>An interesting question... the following link has >>some thoughts along these lines... and something >>for the BSD community to think upon... >> >>http://www.sctp.org/what_is_alt_route >> >>TCP could definetly use something like the above (with Itojun's Multi-path >>updates as well).. it would give more reliability to even a singly >>homed protocol such as TCP :-> >> >>R >> >>Andrea Venturoli wrote: >> >> >>>Ok, I asked already asked something similar to this in the past, but it's >>>not the same thing... maybe it's a trivial question... >>>If I had two lines to the Internet: how would I use both? >>>Could I just provide two default routes? How? >>>What algorithm would be used to choose among the two? >>>What if one failed? >>> >>>bye & Thanks >>> av. >>> >>> >>> >>>_______________________________________________ >>>freebsd-net@freebsd.org mailing list >>>http://lists.freebsd.org/mailman/listinfo/freebsd-net >>>To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org" >>> >>> > > > -- Randall R. Stewart 815-477-2127 (office) 815-342-5222 (cell phone) From owner-freebsd-net@FreeBSD.ORG Mon Jan 26 11:02:47 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4C0CB16A4CF for ; Mon, 26 Jan 2004 11:02:47 -0800 (PST) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4F92A43D62 for ; Mon, 26 Jan 2004 11:01:57 -0800 (PST) (envelope-from owner-bugmaster@freebsd.org) Received: from freefall.freebsd.org (peter@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.10/8.12.10) with ESMTP id i0QJ1hFR038071 for ; Mon, 26 Jan 2004 11:01:43 -0800 (PST) (envelope-from owner-bugmaster@freebsd.org) Received: (from peter@localhost) by freefall.freebsd.org (8.12.10/8.12.10/Submit) id i0QJ1gXB038065 for freebsd-net@freebsd.org; Mon, 26 Jan 2004 11:01:42 -0800 (PST) (envelope-from owner-bugmaster@freebsd.org) Date: Mon, 26 Jan 2004 11:01:42 -0800 (PST) Message-Id: <200401261901.i0QJ1gXB038065@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: peter set sender to owner-bugmaster@freebsd.org using -f From: FreeBSD bugmaster To: freebsd-net@FreeBSD.org Subject: Current problem reports assigned to you X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Jan 2004 19:02:47 -0000 Current FreeBSD problem reports Critical problems Serious problems Non-critical problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2003/07/11] kern/54383 net NFS root configurations without dynamic p 1 problem total. From owner-freebsd-net@FreeBSD.ORG Mon Jan 26 13:22:27 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D9EDB16A4D0 for ; Mon, 26 Jan 2004 13:22:27 -0800 (PST) Received: from odin.ac.hmc.edu (Odin.AC.HMC.Edu [134.173.32.75]) by mx1.FreeBSD.org (Postfix) with ESMTP id D3DF743D1D for ; Mon, 26 Jan 2004 13:22:18 -0800 (PST) (envelope-from brdavis@odin.ac.hmc.edu) Received: from odin.ac.hmc.edu (IDENT:brdavis@localhost.localdomain [127.0.0.1]) by odin.ac.hmc.edu (8.12.10/8.12.3) with ESMTP id i0QLMDaT000975; Mon, 26 Jan 2004 13:22:13 -0800 Received: (from brdavis@localhost) by odin.ac.hmc.edu (8.12.10/8.12.3/Submit) id i0QLMDKv000972; Mon, 26 Jan 2004 13:22:13 -0800 Date: Mon, 26 Jan 2004 13:22:12 -0800 From: Brooks Davis To: net@freebsd.org Message-ID: <20040126212212.GA30225@Odin.AC.HMC.Edu> References: <20040123200238.GA3133@Odin.AC.HMC.Edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040123200238.GA3133@Odin.AC.HMC.Edu> User-Agent: Mutt/1.5.4i X-Virus-Scanned: by amavisd-milter (http://amavis.org/) on odin.ac.hmc.edu Subject: Re: review request: interface renaming patch X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Jan 2004 21:22:28 -0000 On Fri, Jan 23, 2004 at 12:02:38PM -0800, Brooks Davis wrote: > The patch is split into cleanups that apply to the tree regardless of > this functional change and the actual functional changes. You will need > to use "patch -p2" to apply the patch due to they way I generated it > from my perforce trees. Here's a new version of the patch. Following a suggestion from Vincent Jardin, I announce the departure of the interface before renaming it and announce its arrival afterwards. I've also added some documentation for SIOCSIFNAME to ifnet.9. -- Brooks *** Cleanup diffs *** --- ../freebsd/sbin/ifconfig/ifconfig.c Wed Oct 29 10:24:27 2003 +++ ../cleanup/sbin/ifconfig/ifconfig.c Fri Jan 23 10:44:54 2004 @@ -113,7 +113,7 @@ struct sockaddr_in netmask; struct netrange at_nr; /* AppleTalk net range */ -char name[32]; +char name[IFNAMSIZ]; int flags; int setaddr; int setipdst; @@ -596,8 +596,9 @@ addrcount++; next += nextifm->ifm_msglen; } - strncpy(name, sdl->sdl_data, sdl->sdl_nlen); - name[sdl->sdl_nlen] = '\0'; + strlcpy(name, sdl->sdl_data, + sizeof(name) <= sdl->sdl_nlen ? + sizeof(name) : sdl->sdl_nlen + 1); if (all || namesonly) { if (uponly) --- ../freebsd/sbin/ifconfig/ifconfig.h Thu Oct 9 18:23:30 2003 +++ ../cleanup/sbin/ifconfig/ifconfig.h Fri Jan 23 10:44:54 2004 @@ -36,7 +36,7 @@ extern struct ifreq ifr; -extern char name[32]; /* name of interface */ +extern char name[IFNAMSIZ]; /* name of interface */ extern int allmedia; extern int supmedia; struct afswtch; --- ../freebsd/sys/net/if.c Fri Jan 23 09:26:48 2004 +++ ../cleanup/sys/net/if.c Fri Jan 23 10:21:15 2004 @@ -410,36 +410,34 @@ * create a Link Level name for this device */ namelen = strlen(ifp->if_xname); -#define _offsetof(t, m) ((int)((caddr_t)&((t *)0)->m)) - masklen = _offsetof(struct sockaddr_dl, sdl_data[0]) + namelen; + masklen = offsetof(struct sockaddr_dl, sdl_data[0]) + namelen; socksize = masklen + ifp->if_addrlen; #define ROUNDUP(a) (1 + (((a) - 1) | (sizeof(long) - 1))) if (socksize < sizeof(*sdl)) socksize = sizeof(*sdl); socksize = ROUNDUP(socksize); +#undef ROUNDUP ifasize = sizeof(*ifa) + 2 * socksize; - ifa = (struct ifaddr *)malloc(ifasize, M_IFADDR, M_WAITOK | M_ZERO); - if (ifa) { - IFA_LOCK_INIT(ifa); - sdl = (struct sockaddr_dl *)(ifa + 1); - sdl->sdl_len = socksize; - sdl->sdl_family = AF_LINK; - bcopy(ifp->if_xname, sdl->sdl_data, namelen); - sdl->sdl_nlen = namelen; - sdl->sdl_index = ifp->if_index; - sdl->sdl_type = ifp->if_type; - ifaddr_byindex(ifp->if_index) = ifa; - ifa->ifa_ifp = ifp; - ifa->ifa_rtrequest = link_rtrequest; - ifa->ifa_addr = (struct sockaddr *)sdl; - sdl = (struct sockaddr_dl *)(socksize + (caddr_t)sdl); - ifa->ifa_netmask = (struct sockaddr *)sdl; - sdl->sdl_len = masklen; - while (namelen != 0) - sdl->sdl_data[--namelen] = 0xff; - ifa->ifa_refcnt = 1; - TAILQ_INSERT_HEAD(&ifp->if_addrhead, ifa, ifa_link); - } + ifa = malloc(ifasize, M_IFADDR, M_WAITOK | M_ZERO); + IFA_LOCK_INIT(ifa); + sdl = (struct sockaddr_dl *)(ifa + 1); + sdl->sdl_len = socksize; + sdl->sdl_family = AF_LINK; + bcopy(ifp->if_xname, sdl->sdl_data, namelen); + sdl->sdl_nlen = namelen; + sdl->sdl_index = ifp->if_index; + sdl->sdl_type = ifp->if_type; + ifaddr_byindex(ifp->if_index) = ifa; + ifa->ifa_ifp = ifp; + ifa->ifa_rtrequest = link_rtrequest; + ifa->ifa_addr = (struct sockaddr *)sdl; + sdl = (struct sockaddr_dl *)(socksize + (caddr_t)sdl); + ifa->ifa_netmask = (struct sockaddr *)sdl; + sdl->sdl_len = masklen; + while (namelen != 0) + sdl->sdl_data[--namelen] = 0xff; + ifa->ifa_refcnt = 1; + TAILQ_INSERT_HEAD(&ifp->if_addrhead, ifa, ifa_link); ifp->if_broadcastaddr = 0; /* reliably crash if used uninitialized */ if (domains) *** Functional diffs *** --- ../cleanup/sbin/ifconfig/ifconfig.8 Fri Jan 23 09:36:11 2004 +++ sbin/ifconfig/ifconfig.8 Fri Jan 23 10:58:58 2004 @@ -322,6 +322,9 @@ and 802.11g .Pq Dq 11g operating modes. +.It Cm name Ar name +Set the interface name to +.Ar name . .It Cm rxcsum , txcsum If the driver supports user-configurable checksum offloading, enable receive (or transmit) checksum offloading on the interface. @@ -353,7 +356,10 @@ If the interface is given without a unit number, try to create a new device with an arbitrary unit number. If creation of an arbitrary device is successful, the new device name is -printed to standard output. +printed to standard output unless the interface is renamed or destroyed +in the same +.Nm +invocation. .It Cm destroy Destroy the specified network pseudo-device. .It Cm plumb --- ../cleanup/sbin/ifconfig/ifconfig.c Fri Jan 23 10:44:54 2004 +++ sbin/ifconfig/ifconfig.c Fri Jan 23 10:58:58 2004 @@ -129,6 +129,7 @@ int supmedia = 0; int listcloners = 0; +int printname = 0; /* Print the name of the created interface. */ #ifdef INET6 char addr_buf[MAXHOSTNAMELEN *2 + 1]; /*for getnameinfo()*/ @@ -172,6 +173,7 @@ c_func setifipdst; c_func setifflags, setifmetric, setifmtu, setifcap; c_func clone_destroy; +c_func setifname; void clone_create(void); @@ -286,6 +288,7 @@ { "compress", IFF_LINK0, setifflags }, { "noicmp", IFF_LINK1, setifflags }, { "mtu", NEXTARG, setifmtu }, + { "name", NEXTARG, setifname }, { 0, 0, setifaddr }, { 0, 0, setifdstaddr }, }; @@ -525,7 +528,7 @@ clone_create(); argc--, argv++; if (argc == 0) - exit(0); + goto end; } ifindex = if_nametoindex(name); if (ifindex == 0) @@ -629,6 +632,9 @@ if (namesonly && need_nl > 0) putchar('\n'); +end: + if (printname) + printf("%s\n", name); exit (0); } @@ -1037,6 +1043,30 @@ warn("ioctl (set mtu)"); } +void +setifname(const char *val, int dummy __unused, int s, + const struct afswtch *afp) +{ + char *newname; + + newname = strdup(val); + + ifr.ifr_data = newname; + if (ioctl(s, SIOCSIFNAME, (caddr_t)&ifr) < 0) { + warn("ioctl (set name)"); + free(newname); + return; + } + strlcpy(name, newname, sizeof(name)); + free(newname); + + /* + * Even if we just created the interface, we don't need to print + * its name because we just nailed it down separately. + */ + printname = 0; +} + #define IFFBITS \ "\020\1UP\2BROADCAST\3DEBUG\4LOOPBACK\5POINTOPOINT\6SMART\7RUNNING" \ "\10NOARP\11PROMISC\12ALLMULTI\13OACTIVE\14SIMPLEX\15LINK0\16LINK1\17LINK2" \ @@ -1883,8 +1913,13 @@ if (ioctl(s, SIOCIFCREATE, &ifr) < 0) err(1, "SIOCIFCREATE"); + /* + * If we get a different name back then we put in, we probably + * want to print it out, but we might change our mind later so + * we just signal our intrest and leave the printout for later. + */ if (strcmp(name, ifr.ifr_name) != 0) { - printf("%s\n", ifr.ifr_name); + printname = 1; strlcpy(name, ifr.ifr_name, sizeof(name)); } @@ -1898,4 +1933,9 @@ (void) strncpy(ifr.ifr_name, name, sizeof(ifr.ifr_name)); if (ioctl(s, SIOCIFDESTROY, &ifr) < 0) err(1, "SIOCIFDESTROY"); + /* + * If we create and destroy an interface in the same command, + * there isn't any reason to print it's name. + */ + printname = 0; } --- ../cleanup/share/man/man9/ifnet.9 Fri Jan 23 10:08:43 2004 +++ share/man/man9/ifnet.9 Mon Jan 26 13:11:57 2004 @@ -950,6 +950,13 @@ Get interface configuration. (No call-down to driver.) .Pp +.It Dv SIOCSIFNAME +Set the interface name. +.Dv RTM_IFANNOUCNE departure and arrival messages are sent so that +routing code that relies on the interface name will update its interface +list. +Caller must have appropriate privilege. +(No call-down to driver.) .It Dv SIOCGIFCAP .It Dv SIOCGIFFLAGS .It Dv SIOCGIFMETRIC --- ../cleanup/sys/net/if.c Fri Jan 23 10:21:15 2004 +++ sys/net/if.c Fri Jan 23 20:52:02 2004 @@ -410,7 +410,11 @@ * create a Link Level name for this device */ namelen = strlen(ifp->if_xname); - masklen = offsetof(struct sockaddr_dl, sdl_data[0]) + namelen; + /* + * Always save enough space for any possiable name so we can do + * a rename in place later. + */ + masklen = offsetof(struct sockaddr_dl, sdl_data[0]) + IFNAMSIZ; socksize = masklen + ifp->if_addrlen; #define ROUNDUP(a) (1 + (((a) - 1) | (sizeof(long) - 1))) if (socksize < sizeof(*sdl)) @@ -733,17 +737,16 @@ int bytoff, bitoff; int unit; - ifc = if_clone_lookup(name, &unit); - if (ifc == NULL) - return (EINVAL); - - if (unit < ifc->ifc_minifs) - return (EINVAL); - ifp = ifunit(name); if (ifp == NULL) return (ENXIO); + unit = ifp->if_dunit; + + ifc = if_clone_lookup(ifp->if_dname, NULL); + if (ifc == NULL) + return (EINVAL); + if (ifc->ifc_destroy == NULL) return (EOPNOTSUPP); @@ -1228,25 +1231,11 @@ struct ifnet * ifunit(const char *name) { - char namebuf[IFNAMSIZ + sizeof("net")]; /* XXX net_cdevsw.d_name */ struct ifnet *ifp; - dev_t dev; - - /* - * Now search all the interfaces for this name/number - */ - /* - * XXX - * Devices should really be known as /dev/fooN, not /dev/net/fooN. - */ - snprintf(namebuf, sizeof(namebuf), "%s/%s", net_cdevsw.d_name, name); IFNET_RLOCK(); TAILQ_FOREACH(ifp, &ifnet, if_link) { - dev = ifdev_byindex(ifp->if_index); - if (strcmp(devtoname(dev), namebuf) == 0) - break; - if (dev_named(dev, name)) + if (strncmp(name, ifp->if_xname, IFNAMSIZ) == 0) break; } IFNET_RUNLOCK(); @@ -1289,6 +1278,10 @@ struct ifstat *ifs; int error = 0; int new_flags; + size_t namelen, onamelen; + char new_name[IFNAMSIZ]; + struct ifaddr *ifa; + struct sockaddr_dl *sdl; ifr = (struct ifreq *)data; switch (cmd) { @@ -1370,6 +1363,46 @@ error = mac_ioctl_ifnet_set(td->td_ucred, ifr, ifp); break; #endif + + case SIOCSIFNAME: + error = suser(td); + if (error) + return (error); + error = copyinstr(ifr->ifr_data, new_name, IFNAMSIZ, NULL); + if (error) + return (error); + if (ifunit(new_name) != NULL) + return (EEXIST); + + /* Announce the departure of the interface. */ + rt_ifannouncemsg(ifp, IFAN_DEPARTURE); + + strlcpy(ifp->if_xname, new_name, sizeof(ifp->if_xname)); + ifa = TAILQ_FIRST(&ifp->if_addrhead); + IFA_LOCK(ifa); + sdl = (struct sockaddr_dl *)ifa->ifa_addr; + namelen = strlen(new_name); + onamelen = sdl->sdl_nlen; + /* + * Move the address if needed. This is safe because we + * allocate space for a name of length IFNAMSIZ when we + * create this in if_attach(). + */ + if (namelen != onamelen) { + bcopy(sdl->sdl_data + onamelen, + sdl->sdl_data + namelen, sdl->sdl_alen); + } + bcopy(new_name, sdl->sdl_data, namelen); + sdl->sdl_nlen = namelen; + sdl = (struct sockaddr_dl *)ifa->ifa_netmask; + bzero(sdl->sdl_data, onamelen); + while (namelen != 0) + sdl->sdl_data[--namelen] = 0xff; + IFA_UNLOCK(ifa); + + /* Announce the return of the interface. */ + rt_ifannouncemsg(ifp, IFAN_ARRIVAL); + break; case SIOCSIFMETRIC: error = suser(td); --- ../cleanup/sys/sys/sockio.h Fri Jan 23 09:38:05 2004 +++ sys/sys/sockio.h Mon Dec 8 12:03:32 2003 @@ -82,6 +82,7 @@ #define SIOCGIFINDEX _IOWR('i', 32, struct ifreq) /* get IF index */ #define SIOCGIFMAC _IOWR('i', 38, struct ifreq) /* get IF MAC label */ #define SIOCSIFMAC _IOW('i', 39, struct ifreq) /* set IF MAC label */ +#define SIOCSIFNAME _IOW('i', 40, struct ifreq) /* set IF name */ #define SIOCADDMULTI _IOW('i', 49, struct ifreq) /* add m'cast addr */ #define SIOCDELMULTI _IOW('i', 50, struct ifreq) /* del m'cast addr */ -- Any statement of the form "X is the one, true Y" is FALSE. PGP fingerprint 655D 519C 26A7 82E7 2529 9BF0 5D8E 8BE9 F238 1AD4 From owner-freebsd-net@FreeBSD.ORG Mon Oct 20 09:34:59 2003 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 87BAD16A4B3 for ; Mon, 20 Oct 2003 09:34:59 -0700 (PDT) Received: from smtpout.mac.com (A17-250-248-84.apple.com [17.250.248.84]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4A6A243FCB for ; Mon, 20 Oct 2003 09:34:58 -0700 (PDT) (envelope-from cswiger@mac.com) Received: from mac.com (smtpin08-en2 [10.13.10.153]) by smtpout.mac.com (8.12.6/MantshX 2.0) with ESMTP id h9KGdGfX012935; Mon, 20 Oct 2003 09:39:18 -0700 (PDT) Received: from mac.com (dpvc-68-161-244-25.ny325.east.verizon.net [68.161.244.25]) (authenticated bits=0)h9KGYsbn007965; Mon, 20 Oct 2003 09:34:54 -0700 (PDT) Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v552) To: Wes Peters From: Charles Swiger In-Reply-To: <200308212235.03055.wes@softweyr.com> Message-Id: <56419842-031B-11D8-922D-003065ABFD92@mac.com> Content-Transfer-Encoding: 7bit X-Mailer: Apple Mail (2.552) cc: freebsd-net@freebsd.org Subject: Re: IP_ONESBCAST and upcoming RELENG_4_9 freeze X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Date: Mon, 20 Oct 2003 16:34:59 -0000 X-Original-Date: Mon, 20 Oct 2003 12:34:55 -0400 X-List-Received-Date: Mon, 20 Oct 2003 16:34:59 -0000 On Friday, August 22, 2003, at 01:35 AM, Wes Peters wrote: > On Thursday 21 August 2003 07:22 am, Bruce M Simpson wrote: >> Hi all, >> >> Does anyone have any major objections to an MFC'ing of IP_ONESBCAST >> which I committed yesterday before the upcoming 4.9 code freeze next >> Monday? No, please do-- your and Wes' work on this area is both appreciated and of interest to me. Thanks, -- -Chuck From owner-freebsd-net@FreeBSD.ORG Thu Oct 23 20:35:04 2003 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DEBB416A4B3 for ; Thu, 23 Oct 2003 20:35:04 -0700 (PDT) Received: from smtp017.mail.yahoo.com (smtp017.mail.yahoo.com [216.136.174.114]) by mx1.FreeBSD.org (Postfix) with SMTP id 39FA643FB1 for ; Thu, 23 Oct 2003 20:35:04 -0700 (PDT) (envelope-from q_dolan@yahoo.com.au) Received: from vdub.onthenet.net (HELO ?172.22.1.10?) (q?dolan@203.10.89.16 with plain) by smtp.mail.vip.sc5.yahoo.com with SMTP; 24 Oct 2003 03:35:03 -0000 From: Q To: Dan In-Reply-To: <200310240210.14992.dan@ntlbusiness.com> References: <200310240210.14992.dan@ntlbusiness.com> Message-Id: <1066966493.79539.76.camel@boxster.onthenet.com.au> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.5 Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.1 cc: freebsd-net@freebsd.org Subject: Re: IPFW rules being weird? X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Date: Fri, 24 Oct 2003 03:35:05 -0000 X-Original-Date: Fri, 24 Oct 2003 13:34:54 +1000 X-List-Received-Date: Fri, 24 Oct 2003 03:35:05 -0000 The easiest way I have found to quickly resolve these kinds of problems is to put a "permit all' rule at the bottom and start it up from there a rule at a time until it works. When you work out which rule is causing the problem, check out what it's blocking that you need and replace the 'permit all' with an appropriate rule. This method lets you get to the heart of the problem quickly without a lot of head scratching. Seeya...Q On Fri, 2003-10-24 at 11:10, Dan wrote: > Hello there. > Odd query for you. > > My setup is that sis0 is the ethernet which has the business cable modem > attached to it - which serves as a gateway. sis1 is the Ethernet which my > laptop connects to (wirelessly through a HE501 wireless pc card, and HE102 > access point (both by Netgear)). > > The problem that is occuring, is that if I have the IPFW rules below, > everything works GREAT! > > fwcmd="/sbin/ipfw" > $fwcmd -f flush > $fwcmd add divert natd all from any to any via sis0 > $fwcmd add allow all from any to any > $fwcmd add allow icmp from any to any icmptypes 0,3,8,11,12,13,14 > > > However, the above is not "secure" as you might say. > The script below stops the laptop from being able to access th enet and i have > NO idea why! > > # Define the firewall command (as in /etc/rc.firewall) for easy > # reference. Helps to make it easier to read. > fwcmd="/sbin/ipfw" > > # Force a flushing of the current rules before we reload. > $fwcmd -f flush > > # Divert all packets through the tunnel interface. > $fwcmd add 50 divert natd all from any to any via sis0 > > # Allow all connections that have dynamic rules built for them, > # but deny established connections that don't have a dynamic rule. > # See ipfw(8) for details. > $fwcmd add check-state > $fwcmd add pass tcp from any to any established > > # Allow all localhost connections > ${fwcmd} add 100 pass all from any to any via lo0 > ${fwcmd} add 200 deny all from any to 127.0.0.0/8 > ${fwcmd} add 300 deny ip from 127.0.0.0/8 to any > > # Allow all connections from my network card that I initiate > $fwcmd add allow tcp from me to any out xmit any setup keep-state > $fwcmd add deny tcp from me to any > $fwcmd add allow ip from me to any out xmit any keep-state > $fwcmd add allow all from 192.168.0.0/24 to any > > # Everyone on the Internet is allowed to connect to the following > # services on the machine. This example specifically allows connections > # to sshd and a webserver. > $fwcmd add allow tcp from any to any established > $fwcmd add allow tcp from any to me 80 setup > $fwcmd add allow tcp from any to me 21 setup > $fwcmd add allow tcp from any to me 22 setup > > # This sends a RESET to all ident packets. > $fwcmd add reset log tcp from any to me 113 in recv any > > # Enable ICMP: remove type 8 if you don't want your host to be pingable > $fwcmd add allow icmp from any to any icmptypes 0,3,8,11,12,13,14 > > # Deny all the rest. > $fwcmd add deny log ip from any to any > > > If you can help with this it'd be much appreciated. > Thanks!!! > > Running FreeBSD 4.8-RELEASE. > _______________________________________________ > freebsd-net@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-net > To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"nsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org" From owner-freebsd-net@FreeBSD.ORG Sat Nov 15 14:35:04 2003 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8474716A4CE for ; Sat, 15 Nov 2003 14:35:04 -0800 (PST) Received: from hypernet.hyper.net (hypernet.hyper.net [193.218.1.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id F080443F93 for ; Sat, 15 Nov 2003 14:35:01 -0800 (PST) (envelope-from dxoch@escape.gr) Received: from escape.gr (bus.hyper.gr [193.218.2.30]) ESMTP id hAFMVHu14340; Sun, 16 Nov 2003 00:31:18 +0200 Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v552) To: Maxim Konovalov From: Jim Xochellis In-Reply-To: <20031115235809.R94964@news1.macomnet.ru> Message-Id: <6F8729E0-17B9-11D8-9B39-003065C4E486@escape.gr> Content-Transfer-Encoding: 7bit X-Mailer: Apple Mail (2.552) cc: net@freebsd.org Subject: Re: ip-up script of pppd no triggered X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Date: Sat, 15 Nov 2003 22:35:04 -0000 X-Original-Date: Sun, 16 Nov 2003 00:17:01 +0200 X-List-Received-Date: Sat, 15 Nov 2003 22:35:04 -0000 Hi Maxim, On Saturday, November 15, 2003, at 11:02 PM, Maxim Konovalov wrote: > On Sat, 15 Nov 2003, 22:44+0200, Jim Xochellis wrote: > >> Hi Maxim, >> >> On Friday, November 14, 2003, at 09:13 PM, Maxim Konovalov wrote: >> >>> On Fri, 14 Nov 2003, 16:02+0200, Jim Xochellis wrote: >>> >>>> Hi list, >>>> >>>> I have also posted this mail to the freebsd-questions list a few >>>> days >>>> ago, but I had no luck. Hence, I decided to try this list too, which >>>> probably is the most appropriate for my problem. >>>> >>>> I need to persuade pppd to call its ip-up script in order to add a >>>> non-default route as soon as the link is up and running. >>>> Unfortunately >>>> it seems that my ip-up script is not being called. The mode of the >>>> file >>>> is rwxr-xr-x and the owner root:wheel. I am calling the pppd from >>>> inside a "/usr/local/etc/rc.d/ppp.sh" script by using the following >>>> command: >>>> "/usr/sbin/pppd /dev/cuaa0 115200 A.A.A.A:B.B.B.B noauth persist >>>> netmask 255.255.255.252" >>>> >>>> I have read all the chapter #18 of the handbook, but I haven't found >>>> anything about the ip-up script. On the contrary the PPPD(8) man >>>> page >>>> claims that the /etc/ppp/ip-up is executed when the link is >>>> available >>>> for sending and receiving IP packets. My link becomes available for >>>> sending/receiving IP packets, but ip-up is never executed. Any ideas >>>> why? >>>> By the way, I am using kernel PPP, (on ppp0) if it makes any >>>> difference. >>>> >>>> Am I doing something wrong? >>> >>> Did you look at /usr/share/examples/pppd/ip-up.sample ? >>> >>> ip-up worked for me six months ago. >> >> Yes I have looked at ip-up.sample file. Please note that my problem is >> not what to put inside the script, but the fact that the script itself >> is not being called. On the contrary your are saying that it worked >> for > > Are you sure it isn't called? Did you check pppd logs? Were there > any interesting? Is there '#!/bin/sh' on the top of your script? > /var/log/ppp.log only contains lines like: Nov 15 23:53:15 MyHost /kernel: ppp configured! Yes '#!/bin/sh' is on the top of the file. I have also added the following lines to the script: echo " ppp is up!!!" echo " ppp is up!" >> ip-up.log But no sign :-( >> you and thats great news! Was it in the /etc/ppp/ip-up path? What were >> its file mode? Any other info maybe? > > It was /etc/ppp/ip-up, 0555. I've tried 0555 too, but no luck :-( My owner is root:wheel, yours? Are you using the "noauth" or "persist" pppd options too? Thanks for the help Jim Xochellis