From owner-freebsd-questions@freebsd.org Mon Jul 6 10:23:06 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id A05E83630D4 for ; Mon, 6 Jul 2020 10:23:06 +0000 (UTC) (envelope-from contact@evilham.com) Received: from yggdrasil.evilham.com (yggdrasil.evilham.com [46.19.33.155]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4B0hV15xjgz3c4P for ; Mon, 6 Jul 2020 10:23:05 +0000 (UTC) (envelope-from contact@evilham.com) Received: from yggdrasil.evilham.com (localhost [IPv6:::1]) by yggdrasil.evilham.com (Postfix) with ESMTP id 4B0hTs3gzTz12F0 for ; Mon, 6 Jul 2020 12:22:57 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=evilham.com; h=from:to :subject:references:in-reply-to:date:message-id:mime-version :content-type; s=mail; bh=pwiSSE//r9iI4p1pFN0vyqQgow8=; b=ZBD1fC rWJTwB+Ud8hjEWazWP/Bcs+YcIBd2yf2S53gDsU+i196YfgiWyvx/7HoqMnwhWVb 1nzH7nq8b4+FA7W/xQDugKMIWXeEHHkxeFIafRdFENSWvnRyH4U8PK2WLo7RagIk mwQkArLNXxHfTM6Hk9RKIJ1bWjpu/RCMtcReQ= Received: from yggdrasil.evilham.com (unknown [IPv6:2a0a:e5c1:121:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by yggdrasil.evilham.com (Postfix) with ESMTPSA id 4B0hTr4gQ4z12Dy for ; Mon, 6 Jul 2020 12:22:56 +0200 (CEST) From: Evilham To: freebsd-questions@freebsd.org Subject: Re: mpd5 link up References: <20200706093639.64kx6wehespfqgnt@x1> In-reply-to: <20200706093639.64kx6wehespfqgnt@x1> Date: Mon, 06 Jul 2020 12:22:55 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; format=flowed X-Rspamd-Queue-Id: 4B0hV15xjgz3c4P X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=fail (headers rsa verify failed) header.d=evilham.com header.s=mail header.b=ZBD1fC r; dmarc=pass (policy=none) header.from=evilham.com; spf=pass (mx1.freebsd.org: domain of contact@evilham.com designates 46.19.33.155 as permitted sender) smtp.mailfrom=contact@evilham.com X-Spamd-Result: default: False [-3.44 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.94)[-0.938]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; R_DKIM_REJECT(0.00)[evilham.com:s=mail]; DKIM_TRACE(0.00)[evilham.com:-]; DMARC_POLICY_ALLOW(0.00)[evilham.com,none]; NEURAL_HAM_SHORT(-0.71)[-0.706]; DMARC_POLICY_ALLOW_WITH_FAILURES(-0.50)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:196752, ipnet:46.19.32.0/21, country:NL] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Jul 2020 10:23:06 -0000 On dl., jul. 06 2020, Julien Cigar wrote: > Hello, > > I switched from base ppp to mpd5 for my "home" router/firewall > (small > APU2C4) as ppp consumes a lot of CPU usage (100% CPU in fact) > and is > unable to use multiple cores for a single PPPOE connection. It > works > well but as I have a dynamic IP and a DYNDNS-like hostname I > don't see > any option in mpd5 to execute a script whenever the IP address > changes. > There is set "iface up-script xxx.sh" but it is called only when > the > interface changes it's state to UP (first connection). > > This is my configuration: > https://gist.github.com/silenius/0a40de647b48829fd76c5dec098188e3 > > Any idea if I missed something in the documentation? > Otherwise, is there a way to detect an address IP changes in > devd? > > Thanks! > > Julien Hi Julien, I actually recently did precisely that as well (also on an APU :-)). You can have up and down scripts with: set iface up-script /up-stuff set iface down-script /down-stuff This is documented with the port in: /usr/local/share/doc/mpd5/mpd28.html Cheers, and enjoy the *much* better performance :-) -- Evilham