Re: Corrupted IPv6 routing table

2015-01-08 Thread Mike Tancsa

On 1/7/2015 6:14 PM, Przemyslaw Frasunek wrote:

Dear all,

We are running FreeBSD 9.2-RELEASE-p3 on few PPPoE access servers, each
servicing about 1000 customers. Each server exchanges customers' /32 (for IPv4)
and /64 (for IPv6) routes using OSPF and BIRD.

Few times in a month, we are experiencing routing table corruption, which causes
spurious IPv6 routes appearing with prefixlen 0:


I saw this a few yrs ago when I tried mpd with ipv6 after about a month. 
 There are some threads (i think on freebsd-net) about it and some of 
the areas that needed to be fixed.  I had to give up on v6 and mpd as a 
result.  I seem to recall some commits to RELENG_10 that might had 
addresses some of the bugs I saw, but thats just speculation.  Have you 
tried RELENG_10 as an LNS ?


---Mike


--
---
Mike Tancsa, tel +1 519 651 3400
Sentex Communications, m...@sentex.net
Providing Internet services since 1994 www.sentex.net
Cambridge, Ontario Canada   http://www.tancsa.com/
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


Re: Corrupted IPv6 routing table

2015-01-08 Thread Tiago Felipe
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

I use mpd5 v4 and v6 in freebsd 10.0 and 10.1, I had no problem just
like your for now.

On 01/08/2015 09:54 AM, Mike Tancsa wrote:
> On 1/7/2015 6:14 PM, Przemyslaw Frasunek wrote:
>> Dear all,
>> 
>> We are running FreeBSD 9.2-RELEASE-p3 on few PPPoE access
>> servers, each servicing about 1000 customers. Each server
>> exchanges customers' /32 (for IPv4) and /64 (for IPv6) routes
>> using OSPF and BIRD.
>> 
>> Few times in a month, we are experiencing routing table
>> corruption, which causes spurious IPv6 routes appearing with
>> prefixlen 0:
> 
> I saw this a few yrs ago when I tried mpd with ipv6 after about a
> month. There are some threads (i think on freebsd-net) about it and
> some of the areas that needed to be fixed.  I had to give up on v6
> and mpd as a result.  I seem to recall some commits to RELENG_10
> that might had addresses some of the bugs I saw, but thats just
> speculation.  Have you tried RELENG_10 as an LNS ?
> 
> ---Mike
> 
> 

- -- 
=
Tiago Felipe Gonçalves.
Gerente de Infraestrutura de TI.
+55 19 981811543
PGP Fingerprint -
A2:82:BD:48:EE:8D:C4:99:C2:4E:81:D4:C4:7B:1C:2E:C7:F3:04:C9
=
-BEGIN PGP SIGNATURE-
Version: GnuPG v2

iQIcBAEBCAAGBQJUrnMuAAoJEMR7HC7H8wTJMXcP/3SGWpZOayZSoFr0eatFu+m7
LskNoUkszQLqy/7L+sGdomPQHi3Cudb+1+PyxKtpWwPcbQJXFyGrB4vxkyzqV5LZ
8te1/Zw0JBD7y9CKE3NswXpbZvggojTyxvr9GVna2rTIa8LQJnxbiVZFnzmcSlq4
fDv/NlPO58qqhI7cXa9JXpbb6wGM/IF5R/f1Hg1LOkf6nEfxalAeDV4R6g37bKgL
OS/gcf+33VCQWirnNlCNgJ/rIV9YB5n+5BTj+ZsWpg1W/ZpN00hbttOnqQhpLLPV
eLS/vBgjmoxwHWpdjonEpLYVKOuZK3bADeg1u0PuyVT4qCi9t7rzhMMRKlKxWvnv
vbIGIt7BtnlnlqbvFvDbHT0GNt0LqcrW3lmTnSV0qbWdbT5oOWVQIQQOBZ5MmDYG
cqew8rK0i5dSokYaA4eaQzQDqndVWbwQaiXXm+rAmoG+HsF1602Ez98ilkxjY0DH
fCvFGJHhWJgjSKgl+XEMeLEXD/FfWG52n9UmOEEoRsLm2nGnvmtmln61pyjLz/dt
InUBS3zu935FXEuveaFZEmbEjdmqEndQOwfF8Xkt8fdvZ8X+wii0Uq6/aq8o3Eib
s1iG/LFPHuE2UlMSKj/HqIu5Il3s68xe1zYr2e3fbzwsx/7FMJL9Mrf93IP4UQmP
EC2pHoxaqHqDmUYGHC7D
=bkKO
-END PGP SIGNATURE-
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


Re: Corrupted IPv6 routing table

2015-01-08 Thread Alexander V. Chernikov
On 08.01.2015 02:14, Przemyslaw Frasunek wrote:
> Dear all,
>
> We are running FreeBSD 9.2-RELEASE-p3 on few PPPoE access servers, each
> servicing about 1000 customers. Each server exchanges customers' /32 (for 
> IPv4)
> and /64 (for IPv6) routes using OSPF and BIRD.
>
> Few times in a month, we are experiencing routing table corruption, which 
> causes
> spurious IPv6 routes appearing with prefixlen 0:
>
> # netstat -nr -f inet6 | grep "/\0"
> 2a02:2928:6:989e::/0  fe80::21e:67ff:fe02:e82b%vlan0 UG1   
> vlan0
> 2a02:2928:6:989f::/0  fe80::21e:67ff:fe02:e82b%vlan0 UG1   
> vlan0
>
> It is impossible to delete such routes and they override default route, making
> IPv6 networking nonfunctional. They definitely does not originate from OSPF, 
> as
> there is an export filter which denies prefixlen < 32.
>
> Has anyone seen this before?
Fixed in 9 by r257389 (So you should try either stable or 10.x).
> ___
> freebsd-net@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"
>

___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


How to get the IP and TCP fields in mbuf

2015-01-08 Thread Wei Hu
Hi,

I am wondering if there is existing macros in the FreeBSD kernel to extract to 
get to the point of the IP and TCP head in a given mbuf.

Thanks,
Wei


___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


Re: How to get the IP and TCP fields in mbuf

2015-01-08 Thread Julian Kirsch
Hi Wei,

Are you looking for something like this?

+   struct ip *ip = mtod(m, struct ip *);

m is a struct mbuf *. You cann look into my knock-patch for FreeBSD [0]
for further examples.

Best,
Julian

[0] https://gnunet.org/knock

On 08.01.2015 14:18, Wei Hu wrote:
> Hi,
> 
> I am wondering if there is existing macros in the FreeBSD kernel to extract 
> to get to the point of the IP and TCP head in a given mbuf.
> 
> Thanks,
> Wei
> 
> 
> ___
> freebsd-net@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"
> 


-- 
Julian Kirsch
Chair for IT-Security (I20)
Department of Computer Science, Technische Universität München
Boltzmannstrasse 3, D-85748 Garching bei München
Phone: +49-89-289-18587
Room: 01.08.53
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


Re: Corrupted IPv6 routing table

2015-01-08 Thread Przemyslaw Frasunek
>> Has anyone seen this before?
> Fixed in 9 by r257389 (So you should try either stable or 10.x).

Thanks a lot! I'll schedule an upgrade.


___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


Re: CARP Problem/Bug? on 10.1-RELEASE

2015-01-08 Thread Patrick Lamaiziere
Le Mon, 05 Jan 2015 07:57:33 +0100,
Sascha  a écrit :

Hello,

> you made my day! It's working again. But I continue my research.
> 
> Rebooting takes the Port-Channel on the switch down. When the machine 
> comes up the port-channel on the switch needs some seconds until it's 
> up. 

Any spanning tree on the port switch ? You can try to disable it

Regards,
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


Re: ntpd bind() failure: Can't assign requested address

2015-01-08 Thread Hajimu UMEMOTO
Hi,

> On Wed, 7 Jan 2015 16:56:58 -0800
> hiren panchasara  said:

hiren> I see this message on july 2014 time-frame -CURRENT. I tried to
hiren> disable IPv6 in rc.conf via ipv6_activate_all_interfaces="NO" without
hiren> success.

hiren> Has this been fixed? Or any workarounds?

Perhaps, your interface has an IPv6 link-local address which is
tentative state.
Please try the attached patch.  This patch ignores a tentative
address.

Sincerely,

Index: contrib/ntp/ntpd/ntp_io.c
===
--- contrib/ntp/ntpd/ntp_io.c	(revision 276829)
+++ contrib/ntp/ntpd/ntp_io.c	(working copy)
@@ -1176,12 +1176,13 @@
 
 #ifdef INCLUDE_IPV6_SUPPORT
 static isc_boolean_t
-is_anycast(struct sockaddr *sa, char *name)
+is_not_bindable(struct sockaddr *sa, char *name)
 {
-#if defined(SIOCGIFAFLAG_IN6) && defined(IN6_IFF_ANYCAST)
+#if defined(SIOCGIFAFLAG_IN6) && \
+	(defined(IN6_IFF_ANYCAST) || defined(IN6_IFF_NOTREADY))
 	struct in6_ifreq ifr6;
 	int fd;
-	u_int32_t flags6;
+	u_int32_t flags6, exclude = 0;
 
 	if (sa->sa_family != AF_INET6)
 		return ISC_FALSE;
@@ -1197,9 +1198,15 @@
 	}
 	close(fd);
 	flags6 = ifr6.ifr_ifru.ifru_flags6;
-	if ((flags6 & IN6_IFF_ANYCAST) != 0)
+#if defined(IN6_IFF_ANYCAST)
+	exclude |= IN6_IFF_ANYCAST;
+#endif
+#if defined(IN6_IFF_NOTREADY)
+	exclude |= IN6_IFF_NOTREADY;
+#endif
+	if ((flags6 & exclude) != 0)
 		return ISC_TRUE;
-#endif /* !SIOCGIFAFLAG_IN6 || !IN6_IFF_ANYCAST */
+#endif /* !SIOCGIFAFLAG_IN6 || !(IN6_IFF_ANYCAST && IN6_IFF_NOTREADY) */
 	return ISC_FALSE;
 }
 #endif /* !INCLUDE_IPV6_SUPPORT */
@@ -1344,7 +1351,7 @@
 			continue;
 
 #ifdef INCLUDE_IPV6_SUPPORT
-		if (is_anycast((struct sockaddr *)&interface.sin, isc_if.name))
+		if (is_not_bindable((struct sockaddr *)&interface.sin, isc_if.name))
 			continue;
 #endif /* !INCLUDE_IPV6_SUPPORT */
 

--
Hajimu UMEMOTO
u...@mahoroba.org  ume@{,jp.}FreeBSD.org
http://www.mahoroba.org/~ume/
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"

Re: ntpd bind() failure: Can't assign requested address

2015-01-08 Thread hiren panchasara
On Thu, Jan 8, 2015 at 9:28 AM, Hajimu UMEMOTO  wrote:
> Hi,
>
>> On Wed, 7 Jan 2015 16:56:58 -0800
>> hiren panchasara  said:
>
> hiren> I see this message on july 2014 time-frame -CURRENT. I tried to
> hiren> disable IPv6 in rc.conf via ipv6_activate_all_interfaces="NO" without
> hiren> success.
>
> hiren> Has this been fixed? Or any workarounds?
>
> Perhaps, your interface has an IPv6 link-local address which is
> tentative state.
> Please try the attached patch.  This patch ignores a tentative
> address.

Indeed its in tentative state and I figured it was causing the issue.
Getting it out of tentative state (by enabling IPv6 by 'inet6
-ifdisabled' "fixed" the problem.)
But your patch seems like a right way to do it. I'll try it out and report back.

Btw, do you mind opening a phabricator review request so we can get a
closure on this?

cheers,
Hiren
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


Re: ntpd bind() failure: Can't assign requested address

2015-01-08 Thread hiren panchasara
On Thu, Jan 8, 2015 at 9:48 AM, hiren panchasara
 wrote:
> On Thu, Jan 8, 2015 at 9:28 AM, Hajimu UMEMOTO  wrote:
>> Hi,
>>
>>> On Wed, 7 Jan 2015 16:56:58 -0800
>>> hiren panchasara  said:
>>
>> hiren> I see this message on july 2014 time-frame -CURRENT. I tried to
>> hiren> disable IPv6 in rc.conf via ipv6_activate_all_interfaces="NO" without
>> hiren> success.
>>
>> hiren> Has this been fixed? Or any workarounds?
>>
>> Perhaps, your interface has an IPv6 link-local address which is
>> tentative state.
>> Please try the attached patch.  This patch ignores a tentative
>> address.
>
> Indeed its in tentative state and I figured it was causing the issue.
> Getting it out of tentative state (by enabling IPv6 by 'inet6
> -ifdisabled' "fixed" the problem.)
> But your patch seems like a right way to do it. I'll try it out and report 
> back.
>

Attached patch is fixing the problem for me.

cheers,
Hiren

> Btw, do you mind opening a phabricator review request so we can get a
> closure on this?
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


Re: CARP Problem/Bug? on 10.1-RELEASE

2015-01-08 Thread Sascha

Spanning Tree is disabled on the ports.

Best Regards

On 08/01/2015 16:45, Sascha wrote:

Le Mon, 05 Jan 2015 07:57:33 +0100,
Sascha  a écrit :

Hello,


you made my day! It's working again. But I continue my research.

Rebooting takes the Port-Channel on the switch down. When the machine
comes up the port-channel on the switch needs some seconds until it's
up.

Any spanning tree on the port switch ? You can try to disable it

Regards,


___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


[Bug 196501] [em] Intel 82573 nic built on my pdsbm-ln2 1U server and only one port will work.

2015-01-08 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=196501

--- Comment #5 from Mark  ---
Here is my 

pciconf -lv


none1@pci0:2:0:0:   class=0x02 card=0x109a15d9 chip=0x109a8086 rev=0x00
hdr=0x00
class  = network
subclass   = ethernet
em0@pci0:3:0:0: class=0x02 card=0x109a15d9 chip=0x109a8086 rev=0x00
hdr=0x00
class  = network
subclass   = ethernet

Please note when this happens I can not install PCI card.. Either a wifi one or
Intel 2 port pci.. which is slightly older chips.  They work fine if you turn
off both built on ports then you can use PCI and both older Intel work but I
need more then 2 ports so I am stuck

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


[Bug 196501] [em] Intel 82573 nic built on my pdsbm-ln2 1U server and only one port will work.

2015-01-08 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=196501

Mark  changed:

   What|Removed |Added

URL||http://pastebin.com/tW9Qe3g
   ||2

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


[Bug 196501] [em] Intel 82573 nic built on my pdsbm-ln2 1U server and only one port will work.

2015-01-08 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=196501

--- Comment #6 from Mark  ---
And not a hardware problem, Ubuntu works fine, Windows works fine, only thing
that I seen this problem with is going from 8.1 to 10.1 .. Never had any
problems and will not have problem if I go back to 8.1 or run some other system

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


[Bug 196501] [em] Intel 82573 nic built on my pdsbm-ln2 1U server and only one port will work.

2015-01-08 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=196501

--- Comment #7 from Mark  ---
Note: I read your reply again.  I noticed you do not have a dual port but 2
different chips running.  That might by why you can run both

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"