From owner-freebsd-hackers@freebsd.org Fri May 18 17:19:47 2018 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 17547EAEE83 for ; Fri, 18 May 2018 17:19:47 +0000 (UTC) (envelope-from fjwcash@gmail.com) Received: from mail-lf0-x22c.google.com (mail-lf0-x22c.google.com [IPv6:2a00:1450:4010:c07::22c]) (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 739217FBA8 for ; Fri, 18 May 2018 17:19:46 +0000 (UTC) (envelope-from fjwcash@gmail.com) Received: by mail-lf0-x22c.google.com with SMTP id r2-v6so15053310lff.4 for ; Fri, 18 May 2018 10:19:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=/VEf/shxNvRx0+ZwD4xvN/t4TQMn0F5vs3lEwlPbXTc=; b=QioHw5DB/d7218hmyvhk42z9Okjp5bzEMVk7Lbo1xhnTPtjMzaGnGFmxoHoHbiY/ZS JasJNlYwVDI9INff1FBqigj81jjE+MTSMo44Y5KWDbO6ucZCtZyUwFBdYOpVlEQqOSGp IrKZVUOTGAdpJyI75jzq2UZph7YcPWZKYjTxlk2C2M41AMWqWGupglTizj6r1zk0sYid tJB4OAcf2WALCCp6TmCBBIRg5IW3+z8yiEcBmDNmvjdcpiG/cnzlN2RQ8jkp1EIYS0D7 2dVB1afkh0DTN9xmgNoAn6WgUBnOjNO+6N+J6F6HGWaPR73mrLdIMBaVr0C1F7p4FmWv ipvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=/VEf/shxNvRx0+ZwD4xvN/t4TQMn0F5vs3lEwlPbXTc=; b=fsmHmdHH0iHbclDtdjpStZvOBkS/3x55PY687/m5T4i0vFB2Qkhxk2qTdpclXMnQqO q5vyFmauh1iADRCMyHH3mzhYXVf9GZ/xh9/bHm6Ecp0KkrvxupcdArbMFR6lOWmECuAk w684OXkLXjlMTxcnCvgYGYWgn15J8gI2gB5O/w42Drx7eL+m5zM+XJw7VqunElD/u/ZC 6d9idx+B6AIqPQtGGLbVHvTzZzle8RwDyrbKgEKwpOB072qW7wbdzgU3XzHMafGifsT0 yFYsOgz7Q2b7EnBsbGEnz/SLA3+wChdxGeDhXA5vtiU8yZUWAHzylNzxWzBUnC+KbIo4 FBtw== X-Gm-Message-State: ALKqPwcxeBeLlzuvV21xiVM78sDnEO62Zav0X1YNcy8pxtLdlwzHoQhL qRW75KXomSoeVN+mf8qKKaDep/Vof/cuHc800oEtDg== X-Google-Smtp-Source: AB8JxZqAiAzk5p7XMW07vGssumQyTid7iIKMThlVw5Ki6Xz6wByslXzkdljtVkONBT9w4G8ZfgUS/nMectW2Cu5lqNM= X-Received: by 2002:a2e:9d07:: with SMTP id t7-v6mr5311138lji.7.1526663985001; Fri, 18 May 2018 10:19:45 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a2e:219:0:0:0:0:0 with HTTP; Fri, 18 May 2018 10:19:44 -0700 (PDT) In-Reply-To: <20180518.113009.439302765921485452.ish@amail.plala.or.jp> References: <20180518.113009.439302765921485452.ish@amail.plala.or.jp> From: Freddie Cash Date: Fri, 18 May 2018 10:19:44 -0700 Message-ID: Subject: Re: How can I wait for a USB Ethernet adapter to appear to configure lagg on startup? To: Masachika ISHIZUKA Cc: FreeBSD Hackers Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.26 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 May 2018 17:19:47 -0000 On Thu, May 17, 2018 at 7:30 PM, Masachika ISHIZUKA wrote: > Hi. > > I use a nootbook machine. > As this machine has no internal nic, I use a USB ethernet adapter(ue0). > I want to configure lagg0 of ue0 and iwm0, but I must wait to start > /etc/rc.d/netif until appearing the ue0. > I'm using patched netif as follows, but I must keep it whenever > 'mergemaster -Ui' is run. > Is there a more elegant way? > =E2=80=8BYour situation is pretty much the entire reason for the existence = of =E2=80=8B/etc/rc.d/netwait Read through the comments in that script for mo= re information. And the comments in /etc/defaults/rc.conf for netwait. Something along these lines in /etc/rc.conf is what you want (along with your normal ifconfig_* and wpa_* entries): netwait_if=3D"ue0 iwm0" That will cause the boot process to pause and wait for those two interfaces to appear before continuing on with the network configuration. There are various other netwait_* configuration entries that can used as well. --=20 Freddie Cash fjwcash@gmail.com