From owner-freebsd-bugs Thu Oct 17 7:20: 5 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 69DDF37B401 for ; Thu, 17 Oct 2002 07:20:02 -0700 (PDT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id D448D43E6A for ; Thu, 17 Oct 2002 07:20:00 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.6/8.12.6) with ESMTP id g9HEK0x3046825 for ; Thu, 17 Oct 2002 07:20:00 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.6/8.12.6/Submit) id g9HEK07T046824; Thu, 17 Oct 2002 07:20:00 -0700 (PDT) Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8B8DD37B401 for ; Thu, 17 Oct 2002 07:11:34 -0700 (PDT) Received: from cell.sick.ru (cell.sick.ru [195.91.162.238]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9759043E65 for ; Thu, 17 Oct 2002 07:11:33 -0700 (PDT) (envelope-from glebius@cell.sick.ru) Received: from cell.sick.ru (glebius@localhost [127.0.0.1]) by cell.sick.ru (8.12.6/8.12.6) with ESMTP id g9HEBVns001067 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO) for ; Thu, 17 Oct 2002 18:11:32 +0400 (MSD) (envelope-from glebius@cell.sick.ru) Received: (from glebius@localhost) by cell.sick.ru (8.12.6/8.12.6/Submit) id g9HEBVlV001066; Thu, 17 Oct 2002 18:11:31 +0400 (MSD) Message-Id: <200210171411.g9HEBVlV001066@cell.sick.ru> Date: Thu, 17 Oct 2002 18:11:31 +0400 (MSD) From: Gleb Smirnoff To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Subject: conf/44170: Add ability to run multiple pppoed(8) on startup Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 44170 >Category: conf >Synopsis: Add ability to run multiple pppoed(8) on startup >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Thu Oct 17 07:20:00 PDT 2002 >Closed-Date: >Last-Modified: >Originator: Gleb Smirnoff >Release: FreeBSD 4.7-PRERELEASE i386 >Organization: Moscow State University >Environment: System: FreeBSD cell.sick.ru 4.7-PRERELEASE FreeBSD 4.7-PRERELEASE #7: Fri Sep 6 02:58:47 MSD 2002 root@cell.sick.ru:/usr/obj/usr/src/sys/NUCLEUS i386 >Description: If machine acts as an Access Concentrator for PPPoE service, the pppoed(8) service should be run on it. Quite often the AC can offer PPPoE to several subnets, if it has several interfaces. The rc.conf gives ability to run only one instance of pppoed(8) on single interface, the interface name is given in variable ${pppoed_interface}. The following patch to rc.network gives ability to start multiple pppoeds on all interfaces listed in variable ${pppoed_interfaces}. If this variable is null, then rc.network behaves as it does now. >How-To-Repeat: Try to start 2 pppoeds on startup. >Fix: --- rc.network.bak Thu Oct 17 01:15:52 2002 +++ /etc/rc.network Thu Oct 17 01:15:58 2002 @@ -792,13 +792,21 @@ case ${pppoed_enable} in [Yy][Ee][Ss]) + echo -n ' pppoed'; + if [ -n "${pppoed_interfaces}" ]; then + for i in ${pppoed_interfaces}; do + _opts=$-; set -f + /usr/libexec/pppoed -P /var/run/pppoed.${i}.pid ${pppoed_flags} -p ${pppoed_provider} ${i} + set +f; set -${_opts} + done + else if [ -n "${pppoed_provider}" ]; then pppoed_flags="${pppoed_flags} -p ${pppoed_provider}" fi - echo -n ' pppoed'; _opts=$-; set -f /usr/libexec/pppoed ${pppoed_flags} ${pppoed_interface} set +f; set -${_opts} + fi ;; esac >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message