Re: kern/154676: [netgraph] [panic] HEAD, 8.1-RELEASE panic after some play with netgraph

2011-04-21 Thread glebius
Synopsis: [netgraph] [panic] HEAD, 8.1-RELEASE panic after some play with 
netgraph

State-Changed-From-To: patched->closed
State-Changed-By: glebius
State-Changed-When: Thu Apr 21 08:11:52 UTC 2011
State-Changed-Why: 
Merged to stable/8.


Responsible-Changed-From-To: freebsd-net->glebius
Responsible-Changed-By: glebius
Responsible-Changed-When: Thu Apr 21 08:11:52 UTC 2011
Responsible-Changed-Why: 
Merged to stable/8.

http://www.freebsd.org/cgi/query-pr.cgi?pr=154676
___
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"


IPv6 after reboot: noting works for ~5 minutes, normal operation after that.

2011-04-21 Thread Lev Serebryakov
Hello, Freebsd-net.

  Ok, I've set up my router for IPv6 support (everything work at last:
routing, prefix announcements, firewall, which allows ping but not
access computers in my LAN from outer world, etc), double-check all
configs and reboot router to be sure, that everything will work in
case of reboot (that all manual changes are reflected in configuration
files).

  Router boots up, all interfaces and firewall are Ok, gif0 interface is
up. But for first 5 minutes IPv6 is useless! It can not even ping6
its own end of HE tunnel (bind to gif0)! Echo requests are sent, but no
replies. It can not ping other end of tunnel, Goolge's IPv6 addresses,
it can not be pinged from outside, etc.

  I've panicked, but about 5 minutes later everything works!
Fully-functional IPv6 router, everything can be pinged, tracerouted, I can
connect to outside IPv6 hosts, I can ping internal hosts from outside,
etc.

 I've repeated reboot -- result is the same. 5 minutes router ``doesn't
support'' IPv6, everything works after 5 minutes without any changes in
configuration from my side.

 Is it normal? What do I do wrong?

 I'm sure that it is not firewall problem, as after these 5 minutes
"deny" counters of my firewall are almost all zeroes -- only my ISP
local network (IPv4) protection shows dropped packets (it has many
script kiddies and zombie systems in local network, so it is not
surprise me).

  FreeBSD 8.2-STABLE

-- 
// Black Lion AKA Lev Serebryakov 

___
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: kern/156493: [msk] Marvell Yukon 2 device works only few seconds

2011-04-21 Thread cyberGn0m
Hi all

Some other investigations done and I found the following: device still
receives data but due to unknown (for me) reason data can't be processed and
when msk_handle_events called event ring does not contains OP_RXSTAT events.
And after a while RX overrun happens. I tried to change some code but with
no success.
___
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: stateless dhcp6 server for FreeBSD?

2011-04-21 Thread J.R. Oldroyd
On Thu, 21 Apr 2011 02:45:15 +0400, Lev Serebryakov  wrote:
>
> Hello, Freebsd-net.
> 
>   Is here any stateless dhcp6 solution for FreeBSD?
> 
>   I need only distribute IPv6 DNS server addresses to clients, but not
>  prefixes or address information.
> 

DHCP is stateful.  If you want stateless, you need IPv6 RDNSS router
advertisements.

Just over a month ago on this list, I posted patches for IPv6 stateless
autoconfiguration of DNS information.  There are four parts to the patch:

- changes to rtadvd to send the DNS info
- changes to rtsold to receive it
- a new script, resolvconf(8), to manage resolv.conf updates
- changes to /sbin/dhclient-script to use resolvconf(8) (so
that IPv4 DHCP and IPv6 RA info can co-exist)

These patches conform to RFC 6106.

Since you just want to send DNS info and not prefixes, you can use these
patches in rtadvd and just configure rdnss info and no prefix info.

The patches are here:

http://opal.com/jr/freebsd/rdnss/

I've since filed a PR (http://www.freebsd.org/cgi/query-pr.cgi?pr=156259)
to have this reviewed and committed.

-jr
___
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: stateless dhcp6 server for FreeBSD?

2011-04-21 Thread sthaug
> >   Is here any stateless dhcp6 solution for FreeBSD?
> > 
> >   I need only distribute IPv6 DNS server addresses to clients, but not
> >  prefixes or address information.
> > 
> 
> DHCP is stateful.  If you want stateless, you need IPv6 RDNSS router
> advertisements.

Claiming that DHCP is (always) stateful is wrong. DHCP can be stateful
or stateless - it depends on what kind of information you ask for, and
the type of DHCP request.

For DHCPv4 - you can use the DHCPINFORM request to ask for DNS servers
and similar, without the server storing any state.

For DHCPv6 - you can use the Information-request in a similar way. See
RFC 3736, "Stateless Dynamic Host Configuration Protocol (DHCP) Service
for IPv6", .

ISC DHCP version 4 implements Information-request. See for instance
file dhcpv6.c, routine dhcpv6_information_request.

Steinar Haug, Nethelp consulting, sth...@nethelp.no
___
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: stateless dhcp6 server for FreeBSD?

2011-04-21 Thread Lev Serebryakov
Hello, J.R..
You wrote 21 апреля 2011 г., 18:53:56:

>>   I need only distribute IPv6 DNS server addresses to clients, but not
>>  prefixes or address information.
> DHCP is stateful.  If you want stateless, you need IPv6 RDNSS router
> advertisements.
  Information-Request message doesn't need state on server side. And
IPv6 RDNSS is good thing, but doesn't supported by Windows (yet?)...
:(

> Since you just want to send DNS info and not prefixes, you can use these
> patches in rtadvd and just configure rdnss info and no prefix info.
  I want to advertise Prefixes and routes via pure IPv6 mechanisms
(rtadv), as it supported by all known IPv6-enabled systems. And DNS
needs DHCPv6 for Windows clients :(

> I've since filed a PR
> (http://www.freebsd.org/cgi/query-pr.cgi?pr=156259)
> to have this reviewed and committed.
   Great! I looks like very valuable addition to FreeBSD, but,
unfortunately, it doesn't help client Windows machines in any way :(

-- 
// Black Lion AKA Lev Serebryakov 

___
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: stateless dhcp6 server for FreeBSD?

2011-04-21 Thread Lev Serebryakov
Hello, J.R..
You wrote 21 апреля 2011 г., 18:53:56:

> - changes to rtadvd to send the DNS info
  BTW, does this change allow to announce ``default'' DNS info (from
/etc/resolv.conf) without rtadvd.conf file, as now rtadv announce
``default'' (interface's) prefixes without config.

  It is good feature, as it allow to have addresses only in on place
for simple configs. And duplication of information (addresses in rc.conf
and rtadvd.conf, DNSes in resolv.conf and rtadvd.conf) looks
excessive.

-- 
// Black Lion AKA Lev Serebryakov 

___
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"


RFC further mii(4) changes

2011-04-21 Thread Marius Strobl

Hi,

with the addition of mii_attach() and fleshing out the generic flow
control I've pretty much brought the FreeBSD mii(4) in line with
NetBSD and OpenBSD as much as can be done without breaking the API
or ABI, resulting in changes that could be MFC'ed. As you're probably
aware however, especially NetBSD fixed and improved their mii(4) over
time since it was initially ported to FreeBSD. I think now that
stable/7 is basically closed as 7.4 was the last release based on it,
9.0 being right around the corner and probably also only 2-3 further
releases being based on stable/8 I think now is actually a good time
to incorporate that work and commit any other ABI/API-breaking changes
to mii(4). I've prepared a patch which merges all relevant changes
from NetBSD I'm ware of and implements some other stuff I had in mind:
http://people.freebsd.org/~marius/mii_abi_breaking.diff
A list of the anticipated changes is below. The most painful change
likely is the fix for the OUI bit reversion problem, which on one
hand once again allows us to mostly share miidevs with NetBSD but
on the other hand won't allow us to MFC updates of this file verbatim
to the existing stable branches in the future (IIRC at least imp@
also was in favor for fixing this bug at some point in time though).
An earlier version of this patch was already reviewed by yongari@
(support for setting BMCR_LOOP/MIIF_NOLOOP was removed completely
instead of extended and some entries in miidevs fixed, both based on
his feedback).
If there are no objections I'll commit these changes on April 30th.

- Remove attempts to implement setting of BMCR_LOOP/MIIF_NOLOOP
  (reporting IFM_LOOP based on BMCR_LOOP is left in place though as
  it might provide useful for debugging). For most mii(4) drivers it
  was unclear whether the PHYs driven by them actually support
  loopback or not. Moreover, typically loopback mode also needs to
  be activated on the MAC, which none of the Ethernet drivers using
  mii(4) implements. Given that loopback media has no real use (and
  obviously hardly had a chance to actually work) besides for driver
  development (which just loopback mode should be sufficient for
  though, i.e one doesn't necessary need support for loopback media)
  support for it is just dropped as both NetBSD and OpenBSD already
  did quite some time ago.
- Let mii_phy_add_media() also announce the support of IFM_NONE.
- Restructure the PHY entry points to use a structure of entry points
  instead of discrete function pointers, and extend this to include
  a "reset" entry point. Make sure any PHY-specific reset routine is
  always used, and provide one for lxtphy(4) which disables MII
  interrupts (as is done for a few other PHYs we have drivers for).
  This includes changing NIC drivers which previously just called the
  generic mii_phy_reset() to now actually call the PHY-specific reset
  routine, which might be crucial in some cases. While at it, the
  redundant checks in these NIC drivers for mii->mii_instance not being
  zero before calling the reset routines were removed because as soon
  as one PHY driver attaches mii->mii_instance is incremented and we
  hardly can end up in their media change callbacks etc if no PHY driver
  has attached as mii_attach() would have failed in that case and not
  attach a miibus(4) instance.
  Consequently, NIC drivers now no longer should call mii_phy_reset()
  directly, so it was removed from EXPORT_SYMS.
- Add a mii_phy_dev_attach() as a companion helper to mii_phy_dev_probe().
  The purpose of that function is to perform the common steps to attach
  a PHY driver instance and to hook it up to the miibus(4) instance and to
  optionally also handle the probing, addition and initialization of the
  supported media. So all a PHY driver without any special requirements
  has to do in its bus attach method is to call mii_phy_dev_attach()
  along with PHY-specific MIIF_* flags, a pointer to its PHY functions
  and the add_media set to one. All PHY drivers were updated to take
  advantage of mii_phy_dev_attach() as appropriate. Along with these
  changes the capability mask was added to the mii_softc structure so
  PHY drivers taking advantage of mii_phy_dev_attach() but still
  handling media on their own do not need to fiddle with the MII attach
  arguments anyway.
- Keep track of the PHY offset in the mii_softc structure. This is done
  for compatibility with NetBSD/OpenBSD.
- Keep track of the PHY's OUI, model and revision in the mii_softc
  structure. Several PHY drivers require this information also after
  attaching and previously had to wrap their own softc around mii_softc.
  NetBSD/OpenBSD also keep track of the model and revision on their
  mii_softc structure. All PHY drivers were updated to take advantage
  as appropriate.
- Convert the mebers of the MII data structure to unsigned where
  appropriate. This is partly inspired by NetBSD/OpenBSD.
- According to IEEE 802.3-2002 the bits actually have to be reversed
  when

Re: stateless dhcp6 server for FreeBSD?

2011-04-21 Thread Mikhail Strizhov

On 04/20/2011 04:45 PM, Lev Serebryakov wrote:

Hello, Freebsd-net.

   Is here any stateless dhcp6 solution for FreeBSD?

   isc-dhcp 4.1 seems to not support statless mode by server

   dibbler is not ported to FreeBSD.

   dhcp6s (WIDE-dhcpd) works only with one interface... It is possible,
  of course, to run multiple instances of dhcp6s for multiple
  interfaces, but it doesn't look very convenient.

   I need only distribute IPv6 DNS server addresses to clients, but not
  prefixes or address information.


/usr/ports/net/radvd   ?


--
Sincerely,
Mikhail Strizhov
Web: http://www.netsec.colostate.edu/~strizhov 


Email: striz...@netsec.colostate.edu 
___
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"