From owner-freebsd-hackers@FreeBSD.ORG Thu Aug 16 13:37:56 2012 Return-Path: Delivered-To: hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C46DC106564A for ; Thu, 16 Aug 2012 13:37:56 +0000 (UTC) (envelope-from daved@tamu.edu) Received: from nostrum.com (nostrum-pt.tunnel.tserv2.fmt.ipv6.he.net [IPv6:2001:470:1f03:267::2]) by mx1.freebsd.org (Postfix) with ESMTP id 8179E8FC15 for ; Thu, 16 Aug 2012 13:37:56 +0000 (UTC) Received: from nis-128-194-60-144.dhcp.tamu.edu (nis-128-194-60-144.dhcp.tamu.edu [128.194.60.144]) (authenticated bits=0) by nostrum.com (8.14.3/8.14.3) with ESMTP id q7GDbtwf035145 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Thu, 16 Aug 2012 08:37:55 -0500 (CDT) (envelope-from daved@tamu.edu) Mime-Version: 1.0 (Apple Message framework v1278) Content-Type: multipart/signed; boundary="Apple-Mail=_A91C3812-AF82-4830-AAAC-9A3C77211A2C"; protocol="application/pkcs7-signature"; micalg=sha1 From: Dave Duchscher In-Reply-To: <5029ED51.9000600@rdtc.ru> Date: Thu, 16 Aug 2012 08:37:49 -0500 Message-Id: References: <5029ED51.9000600@rdtc.ru> To: Eugene Grosbein X-Mailer: Apple Mail (2.1278) Received-SPF: pass (nostrum.com: 128.194.60.144 is authenticated by a trusted mechanism) X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: hackers@freebsd.org Subject: Re: Disabling ethernet link on an Intel nic? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Aug 2012 13:37:56 -0000 --Apple-Mail=_A91C3812-AF82-4830-AAAC-9A3C77211A2C Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=koi8-r On Aug 14, 2012, at 1:16 AM, Eugene Grosbein wrote: > 11.08.2012 20:35, David Duchscher =D0=C9=DB=C5=D4: >> Greetings,=20 >>=20 >> I have a need to turn off the link of an ethernet port on a Intel = nic. The issue is not a big deal but one we would like to solve. we = have no way of signaling an upstream router that a path is down but via = turning off the link of the ethernet port. This would only be used when = something goes wrong. The hope is that we could automate some problems = and handle other situations remotely avoiding having to visit the system = in person. >>=20 >> Any thoughts? We can modify the system so if it means modifying the = driver or some other code, I am willing to try. Just need a little = direction. >>=20 >> Thanks for your time, >=20 > I made such patch a couple of years ago and run it in production with = copper-based > em(4) and igb(4) NICs. The patch introduces new sysctls like = dev.em.X.down_disables_link > and dev.igb.X.down.disables_link with default zero values.=20 > Setting sysctl dev.em.0.down_disables_link=3D1 makes "ifconfig em0 = down" bring link down. >=20 > http://www.grosbein.net/freebsd/patches/em_sysctl-8.3.diff.gz > http://www.grosbein.net/freebsd/patches/igb_sysctl-8.3.diff.gz This is exactly what we needed. Thanks for sharing this with us. -- DaveD --Apple-Mail=_A91C3812-AF82-4830-AAAC-9A3C77211A2C--