From owner-freebsd-questions@freebsd.org Mon Oct 26 16:30:48 2015 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 26C6BA1E069 for ; Mon, 26 Oct 2015 16:30:48 +0000 (UTC) (envelope-from matthew@freebsd.org) Received: from smtp.infracaninophile.co.uk (smtp.infracaninophile.co.uk [IPv6:2001:8b0:151:1:3cd3:cd67:fafa:3d78]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.infracaninophile.co.uk", Issuer "infracaninophile.co.uk" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id AD6A31302 for ; Mon, 26 Oct 2015 16:30:47 +0000 (UTC) (envelope-from matthew@freebsd.org) Received: from ox-dell39.ox.adestra.com (no-reverse-dns.metronet-uk.com [85.199.232.226] (may be forged)) (authenticated bits=0) by smtp.infracaninophile.co.uk (8.15.2/8.15.2) with ESMTPSA id t9QGUNPF023941 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO) for ; Mon, 26 Oct 2015 16:30:40 GMT (envelope-from matthew@freebsd.org) Authentication-Results: smtp.infracaninophile.co.uk; dmarc=none header.from=freebsd.org DKIM-Filter: OpenDKIM Filter v2.10.3 smtp.infracaninophile.co.uk t9QGUNPF023941 Authentication-Results: smtp.infracaninophile.co.uk/t9QGUNPF023941; dkim=none; dkim-atps=neutral X-Authentication-Warning: lucid-nonsense.infracaninophile.co.uk: Host no-reverse-dns.metronet-uk.com [85.199.232.226] (may be forged) claimed to be ox-dell39.ox.adestra.com Subject: Re: NIC naming To: freebsd-questions@freebsd.org References: <562E4D92.3000308@gmail.com> From: Matthew Seaman X-Enigmail-Draft-Status: N1110 Message-ID: <562E551F.6060406@freebsd.org> Date: Mon, 26 Oct 2015 16:30:23 +0000 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <562E4D92.3000308@gmail.com> Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="NRIAXedgCDVb5GcVFeGWCSvAnftbxHVTe" X-Virus-Scanned: clamav-milter 0.98.7 at lucid-nonsense.infracaninophile.co.uk X-Virus-Status: Clean X-Spam-Status: No, score=-2.6 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on lucid-nonsense.infracaninophile.co.uk X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Oct 2015 16:30:48 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --NRIAXedgCDVb5GcVFeGWCSvAnftbxHVTe Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 10/26/15 15:58, Johan Hendriks wrote: > Is it possible to make sure em0 stays em0 even if more network cards ar= e > added. > I try to goole for it but could not find anything. Unlike hard drives, I do not believe that there is any way to force the kernel to number NICs in any way other than the order that they appear on whatever system buses at the time the kernel is booted. However, you can arbitrarily rename NICs using ifconfig(8). It's supported in /etc/rc.conf: ifconfig_em0_name=3D"net0" and then you can refer to net0 in the rest of the config: ipv4_addrs_net0=3D"192.0.2.1/24" This probably doesn't solve your problem, which appears to be knowing which of the ethernet ports on your machine is em0 -- the usual method to do that is by ifconfig'ing everything else down and then testing with a network cable until you find the working port. However it might help clarify the system configuration. It's not like an em(4) interface can be added to a server without powering the machine down and opening the case, so you'ld need to have people physically working on the machine in any case. Various USB connected devices might be a different matter. Cheers, Matthew --NRIAXedgCDVb5GcVFeGWCSvAnftbxHVTe Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQIcBAEBCgAGBQJWLlUfAAoJEABRPxDgqeTnJ64P/3V4A3h/YZJqUu3DGYkI5uxH BhyDxI+ikQnMtOVFFhOqcgoa1dmX5Id8Mh83m2KirCp5fI6OzPcnVa0SuvjRelTV 0+jf4C1/NoT5Wkm/ZL89ehQpEgIo9Be1kGiTC75g7EqnaT7BJgDcW0f4Wp3fEb9j Xbv46NcPePdfqx7LFeIxuDYaBocQJvOPA8uARjYL5Ba6FSjxu6PH9TaBQnDGlRpM verJ39Dpe0csoI0ATmhkb6zJulsyWxymXpeI5afsD78oTRdoWy8YaqNypby+bauE eCT5Mixzf4PJqMDpu3Wo9PgifwTYQnktTDFvIsiCvRRRztXaz4fp7/4v9NCbE+vB 6arfXd6PpJt7m0Cxg/oJZQEEg0+SwI7BbmdT6FPeZ3RvBzRH9SY2KHmeAV2CzcBI vI4jj/DWKvyCYXF6gjUopEZPw4pGet1Pi+sHp8VrfE/+GsWRAZDeNzRG6ynR90FJ qOr4LSL8xPc+PMR1K2dMZzEZqK1VN0LwNIFIuIJfVQCqn110jO3Y87/BY6pPD9bW 5dTkJnIY6wNYmEZrs/tykQEfudOkjGuLQY41c5ritxFfrYg7S0ixlKE5O3zchdNN OEx0Nog2men/ckxaqgIQRRwi1IszLXHLCS6fMnDNetQA+PBc0Yhu7InvVilka1zu 0l9SK9j+8nqY8Uv7sKK1 =OBSO -----END PGP SIGNATURE----- --NRIAXedgCDVb5GcVFeGWCSvAnftbxHVTe--