From owner-freebsd-stable@freebsd.org Tue Sep 6 02:18:04 2016 Return-Path: Delivered-To: freebsd-stable@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 96B34B96376 for ; Tue, 6 Sep 2016 02:18:04 +0000 (UTC) (envelope-from eborisch@gmail.com) Received: from mail-it0-x229.google.com (mail-it0-x229.google.com [IPv6:2607:f8b0:4001:c0b::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 6CAEE1A6 for ; Tue, 6 Sep 2016 02:18:04 +0000 (UTC) (envelope-from eborisch@gmail.com) Received: by mail-it0-x229.google.com with SMTP id e124so170994093ith.0 for ; Mon, 05 Sep 2016 19:18:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=9nkce15UgPxMFOAOCq6rtvOAK4CeMWda60xWtlwG0Dc=; b=xGtlncGXTv1BrTD/TgY+IOkZm5tsY+lctqrd1pF6sJcb9w0dUbJSlXtk8dGlsyinQr pzm+YQovlMbVew/ppfuyjBkgxHy+jriKS/YnahAhGcJIC8awsHHw/VIX55o7W3YzMbgM MVBG5uzXztbks5EOASoxw5muBTccHwvEtjTO4wXoeQxb3brLl98Tfv+7Db0hLQZIdM0T ylYmuUpAVOwX9yYgPwti/tF4fiIY1KII5Su20rSdG8pqn9tIFyZ7CBfibZ+EGzq+CwcJ r+Rq89jsiGqJsZhaF7Qo0x2BKSHhXolFjTW8jkzvOlLCxlskaviCtx+cQZTzQYZNP85p fZKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=9nkce15UgPxMFOAOCq6rtvOAK4CeMWda60xWtlwG0Dc=; b=cI0G5wTlnUxIoMLLFjmHRbbCfsMLXq/VOxwiztYwnLD9dmjMHHiO5HWG0tdKA4tKv+ GI6JcAuho9Whsw62DJLz/+C9WZe6pxOrQc/j3nR8PktqA6q87FIW5zAaMTZ39a4B1WBl VAuSHig/5qCKbdqn3qS8Dc9e5lPa7vmJ8eBbX1IWzSOsLfKE++T7li1axjKOluPwahAD 2uRv4aznv9dTs3b4InEWO5s7Df2GOjSvGyZN0OflE54n3hunERpl00uiQRX7lUQaff7n X1yzKy5bj7IZYB8lMRnxaXMBdx/BscbDrot5nifJkTB4qLIFcqwFXaN/ecQNr6NSiEqZ JDZA== X-Gm-Message-State: AE9vXwMZveh45WRt0WEyAq/PVXaStC4nN+kYv3g7O6jWkWURicfUivnBdf3DvzAfaWP8zkUDi68R4HVS48OPbA== X-Received: by 10.107.205.197 with SMTP id d188mr2196242iog.46.1473128283704; Mon, 05 Sep 2016 19:18:03 -0700 (PDT) MIME-Version: 1.0 Received: by 10.107.10.42 with HTTP; Mon, 5 Sep 2016 19:18:02 -0700 (PDT) In-Reply-To: <20160904093514.cf43252dfecfd9b21540c717@eternamente.info> References: <20160901222144.8b9271868373b86e04dbd1a2@eternamente.info> <9e77a50390471340a8f9e0afbfa3785a.squirrel@cabo.dyn.arroway.org> <20160904004912.fde07f06fae6198257138737@eternamente.info> <20160904093514.cf43252dfecfd9b21540c717@eternamente.info> From: "Eric A. Borisch" Date: Mon, 5 Sep 2016 21:18:02 -0500 Message-ID: Subject: Re: ue1 and ue2 swinging To: Nenhum_de_Nos Cc: "freebsd-stable@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Sep 2016 02:18:04 -0000 On Sunday, September 4, 2016, Nenhum_de_Nos wrote: > On Sun, 4 Sep 2016 00:00:38 -0500 > "Eric A. Borisch" > wrote: > > > On Sat, Sep 3, 2016 at 11:28 PM, Eric A. Borisch > wrote: > > > On Saturday, September 3, 2016, Nenhum_de_Nos < > matheus@eternamente.info > > > > wrote: > > >> > > >> On Fri, 2 Sep 2016 13:05:45 -0300 > > >> "Nenhum_de_Nos" > wrote: > > >> > > >> > > > >> > On Thu, September 1, 2016 23:34, Eric A. Borisch wrote: > > >> > > Matheus, > > >> > > > > >> > > I had a very similar problem, which led me to throw this together: > > >> > > > > >> > > https://github.com/eborisch/ethname > > >> > > > > >> > > I think the comments in it are fairly complete, let me know if > > >> > > anything > > >> > > doesn't make sense. > > >> > > > > >> > > Perhaps there is an easier way, but most discussions I found > ended in > > >> > > "you > > >> > > could rename them on boot" - which is what this rc.d script does. > I > > >> > > use it > > >> > > on my home router to great effect. (I rename the adapters to > cable and > > >> > > priv > > >> > > just to make firewall rules etc. even clearer.) > > >> > > > > >> > > - Eric > > >> > > > >> > Eric, > > >> > > > >> > great hint there, I will try it later when I get home and report > back > > >> > here. Thanks! > > >> > > > >> > matheus > > >> > > >> Hi Eric, > > >> > > >> I tried it and something is not working here, I suppose. I have the > > >> /usr/local/etc/ifmap, the ethname is on /usr/local/etc/rc.d, and if I > run it > > >> past boot it works fine. But on reboot it doesn't. Is this the > inteded way > > >> or am I missing something? > > >> > > >> thanks, > > >> > > >> matheus > > > > > > > > > You have ethname_enabled="YES" and ethname_devices="ue0 ue1" (or > whichever > > > devices you want renamed) in your rc.conf; their original names, not > what > > > you want them to become? > > > > > > If you have console access, can you try running it manually? I'll > double > > > check in a bit that the version on github matches what I'm running. > > > > > > - Eric > > > > I'm running (and have been running) the version on github verbatim with > success. > > > > Does 'service -e | grep ethname' return the path the ethname? If not, > > put the 'ethname' script chmod-ed 555 and owned by root into > > /usr/local/etc/rc.d ... > > > > I'm also running 11.0RC2, but on amd64; I don't think that should be > > the issue, especially if you can run it manually via 'service ethname > > start'. > > > > - Eric > > Eric, > > I think all things are fine here: > > root@bee:~ # service -e | grep eth > /usr/local/etc/rc.d/ethname > root@bee:~ # cat /etc/rc.conf | grep ethn > ethname_enable="YES" > ethname_devices="ue1 ue2" > root@bee:~ # ls -l /usr/local/etc/rc.d/ethname > -r-xr-xr-x 1 root wheel 3119 Sep 2 20:28 /usr/local/etc/rc.d/ethname > root@bee:~ # cat /usr/local/etc/ifmap > > #b8:27:eb:fe:5a:e5 lan > 00:00:00:00:00:00 net > 00:00:0:00:00:01 cabo > root@bee:~ # /usr/local/etc/rc.d/ethname restart > tempdev0 > tempdev1 > cabo > net > root@bee:~ # > > > I don't get it working right after boot, despite service -e returns it. > > after running on terminal I get it fine then. > > any hints? > > thanks! > > matheus > Bringing back to the list for resolution. The ueN (axe based) devices were not quite up yet on this system when the renaming script was run. I've updated (on github) the script to wait for the requested devices to appear (with configurable timeout), as well as added notes regarding making sure the drivers for the devices you wish to rename are either compiled in, or loaded via loader.conf, such that we aren't dependent upon devd to do so. I'd love some feedback on the script if anyone else has a use case for it / wants to kick the tires, and then I'll file a PR to add to ports. - Eric