From 73fac075b24476924bc2eef76ef193fb079647ad Mon Sep 17 00:00:00 2001 From: Brian Somers Date: Mon, 26 Jul 1999 15:17:23 +0000 Subject: [PATCH] Start ppp before natd, not afterwards. Submitted by: Josef L. Karthauser --- etc/network.subr | 36 ++++++++++++++++++------------------ etc/rc.d/netoptions | 36 ++++++++++++++++++------------------ etc/rc.d/network1 | 36 ++++++++++++++++++------------------ etc/rc.d/network2 | 36 ++++++++++++++++++------------------ etc/rc.d/network3 | 36 ++++++++++++++++++------------------ etc/rc.d/routing | 36 ++++++++++++++++++------------------ etc/rc.network | 36 ++++++++++++++++++------------------ 7 files changed, 126 insertions(+), 126 deletions(-) diff --git a/etc/network.subr b/etc/network.subr index 007d0f928594..946e66cbdb51 100644 --- a/etc/network.subr +++ b/etc/network.subr @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.50 1999/07/16 09:26:52 jkh Exp $ +# $Id: rc.network,v 1.51 1999/07/26 10:49:31 brian Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -96,6 +96,23 @@ network_pass1() { fi done + # Warm up user ppp if required, must happen before natd. + if [ "X$ppp_enable" = X"YES" ]; then + # Establish ppp mode. + if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ + -a "X$ppp_mode" != X"dedicated" ]; then \ + ppp_mode="auto"; + fi + ppp_command="-${ppp_mode} "; + + # Switch on alias mode? + if [ "X$ppp_alias" = X"YES" ]; then + ppp_command="${ppp_command} -alias"; + fi + + echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} + fi + # Initialize IP filtering using ipfw echo "" /sbin/ipfw -q flush > /dev/null 2>&1 @@ -144,23 +161,6 @@ network_pass1() { fi fi - # Warm up user ppp if required. - if [ "X$ppp_enable" = X"YES" ]; then - # Establish ppp mode. - if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ - -a "X$ppp_mode" != X"dedicated" ]; then \ - ppp_mode="auto"; - fi - ppp_command="-${ppp_mode} "; - - # Switch on alias mode? - if [ "X$ppp_alias" = X"YES" ]; then - ppp_command="${ppp_command} -alias"; - fi - - echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} - fi - # Additional ATM interface configuration if [ -n "${atm_pass1_done}" ]; then atm_pass2 diff --git a/etc/rc.d/netoptions b/etc/rc.d/netoptions index 007d0f928594..946e66cbdb51 100644 --- a/etc/rc.d/netoptions +++ b/etc/rc.d/netoptions @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.50 1999/07/16 09:26:52 jkh Exp $ +# $Id: rc.network,v 1.51 1999/07/26 10:49:31 brian Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -96,6 +96,23 @@ network_pass1() { fi done + # Warm up user ppp if required, must happen before natd. + if [ "X$ppp_enable" = X"YES" ]; then + # Establish ppp mode. + if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ + -a "X$ppp_mode" != X"dedicated" ]; then \ + ppp_mode="auto"; + fi + ppp_command="-${ppp_mode} "; + + # Switch on alias mode? + if [ "X$ppp_alias" = X"YES" ]; then + ppp_command="${ppp_command} -alias"; + fi + + echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} + fi + # Initialize IP filtering using ipfw echo "" /sbin/ipfw -q flush > /dev/null 2>&1 @@ -144,23 +161,6 @@ network_pass1() { fi fi - # Warm up user ppp if required. - if [ "X$ppp_enable" = X"YES" ]; then - # Establish ppp mode. - if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ - -a "X$ppp_mode" != X"dedicated" ]; then \ - ppp_mode="auto"; - fi - ppp_command="-${ppp_mode} "; - - # Switch on alias mode? - if [ "X$ppp_alias" = X"YES" ]; then - ppp_command="${ppp_command} -alias"; - fi - - echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} - fi - # Additional ATM interface configuration if [ -n "${atm_pass1_done}" ]; then atm_pass2 diff --git a/etc/rc.d/network1 b/etc/rc.d/network1 index 007d0f928594..946e66cbdb51 100644 --- a/etc/rc.d/network1 +++ b/etc/rc.d/network1 @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.50 1999/07/16 09:26:52 jkh Exp $ +# $Id: rc.network,v 1.51 1999/07/26 10:49:31 brian Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -96,6 +96,23 @@ network_pass1() { fi done + # Warm up user ppp if required, must happen before natd. + if [ "X$ppp_enable" = X"YES" ]; then + # Establish ppp mode. + if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ + -a "X$ppp_mode" != X"dedicated" ]; then \ + ppp_mode="auto"; + fi + ppp_command="-${ppp_mode} "; + + # Switch on alias mode? + if [ "X$ppp_alias" = X"YES" ]; then + ppp_command="${ppp_command} -alias"; + fi + + echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} + fi + # Initialize IP filtering using ipfw echo "" /sbin/ipfw -q flush > /dev/null 2>&1 @@ -144,23 +161,6 @@ network_pass1() { fi fi - # Warm up user ppp if required. - if [ "X$ppp_enable" = X"YES" ]; then - # Establish ppp mode. - if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ - -a "X$ppp_mode" != X"dedicated" ]; then \ - ppp_mode="auto"; - fi - ppp_command="-${ppp_mode} "; - - # Switch on alias mode? - if [ "X$ppp_alias" = X"YES" ]; then - ppp_command="${ppp_command} -alias"; - fi - - echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} - fi - # Additional ATM interface configuration if [ -n "${atm_pass1_done}" ]; then atm_pass2 diff --git a/etc/rc.d/network2 b/etc/rc.d/network2 index 007d0f928594..946e66cbdb51 100644 --- a/etc/rc.d/network2 +++ b/etc/rc.d/network2 @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.50 1999/07/16 09:26:52 jkh Exp $ +# $Id: rc.network,v 1.51 1999/07/26 10:49:31 brian Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -96,6 +96,23 @@ network_pass1() { fi done + # Warm up user ppp if required, must happen before natd. + if [ "X$ppp_enable" = X"YES" ]; then + # Establish ppp mode. + if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ + -a "X$ppp_mode" != X"dedicated" ]; then \ + ppp_mode="auto"; + fi + ppp_command="-${ppp_mode} "; + + # Switch on alias mode? + if [ "X$ppp_alias" = X"YES" ]; then + ppp_command="${ppp_command} -alias"; + fi + + echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} + fi + # Initialize IP filtering using ipfw echo "" /sbin/ipfw -q flush > /dev/null 2>&1 @@ -144,23 +161,6 @@ network_pass1() { fi fi - # Warm up user ppp if required. - if [ "X$ppp_enable" = X"YES" ]; then - # Establish ppp mode. - if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ - -a "X$ppp_mode" != X"dedicated" ]; then \ - ppp_mode="auto"; - fi - ppp_command="-${ppp_mode} "; - - # Switch on alias mode? - if [ "X$ppp_alias" = X"YES" ]; then - ppp_command="${ppp_command} -alias"; - fi - - echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} - fi - # Additional ATM interface configuration if [ -n "${atm_pass1_done}" ]; then atm_pass2 diff --git a/etc/rc.d/network3 b/etc/rc.d/network3 index 007d0f928594..946e66cbdb51 100644 --- a/etc/rc.d/network3 +++ b/etc/rc.d/network3 @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.50 1999/07/16 09:26:52 jkh Exp $ +# $Id: rc.network,v 1.51 1999/07/26 10:49:31 brian Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -96,6 +96,23 @@ network_pass1() { fi done + # Warm up user ppp if required, must happen before natd. + if [ "X$ppp_enable" = X"YES" ]; then + # Establish ppp mode. + if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ + -a "X$ppp_mode" != X"dedicated" ]; then \ + ppp_mode="auto"; + fi + ppp_command="-${ppp_mode} "; + + # Switch on alias mode? + if [ "X$ppp_alias" = X"YES" ]; then + ppp_command="${ppp_command} -alias"; + fi + + echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} + fi + # Initialize IP filtering using ipfw echo "" /sbin/ipfw -q flush > /dev/null 2>&1 @@ -144,23 +161,6 @@ network_pass1() { fi fi - # Warm up user ppp if required. - if [ "X$ppp_enable" = X"YES" ]; then - # Establish ppp mode. - if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ - -a "X$ppp_mode" != X"dedicated" ]; then \ - ppp_mode="auto"; - fi - ppp_command="-${ppp_mode} "; - - # Switch on alias mode? - if [ "X$ppp_alias" = X"YES" ]; then - ppp_command="${ppp_command} -alias"; - fi - - echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} - fi - # Additional ATM interface configuration if [ -n "${atm_pass1_done}" ]; then atm_pass2 diff --git a/etc/rc.d/routing b/etc/rc.d/routing index 007d0f928594..946e66cbdb51 100644 --- a/etc/rc.d/routing +++ b/etc/rc.d/routing @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.50 1999/07/16 09:26:52 jkh Exp $ +# $Id: rc.network,v 1.51 1999/07/26 10:49:31 brian Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -96,6 +96,23 @@ network_pass1() { fi done + # Warm up user ppp if required, must happen before natd. + if [ "X$ppp_enable" = X"YES" ]; then + # Establish ppp mode. + if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ + -a "X$ppp_mode" != X"dedicated" ]; then \ + ppp_mode="auto"; + fi + ppp_command="-${ppp_mode} "; + + # Switch on alias mode? + if [ "X$ppp_alias" = X"YES" ]; then + ppp_command="${ppp_command} -alias"; + fi + + echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} + fi + # Initialize IP filtering using ipfw echo "" /sbin/ipfw -q flush > /dev/null 2>&1 @@ -144,23 +161,6 @@ network_pass1() { fi fi - # Warm up user ppp if required. - if [ "X$ppp_enable" = X"YES" ]; then - # Establish ppp mode. - if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ - -a "X$ppp_mode" != X"dedicated" ]; then \ - ppp_mode="auto"; - fi - ppp_command="-${ppp_mode} "; - - # Switch on alias mode? - if [ "X$ppp_alias" = X"YES" ]; then - ppp_command="${ppp_command} -alias"; - fi - - echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} - fi - # Additional ATM interface configuration if [ -n "${atm_pass1_done}" ]; then atm_pass2 diff --git a/etc/rc.network b/etc/rc.network index 007d0f928594..946e66cbdb51 100644 --- a/etc/rc.network +++ b/etc/rc.network @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.50 1999/07/16 09:26:52 jkh Exp $ +# $Id: rc.network,v 1.51 1999/07/26 10:49:31 brian Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -96,6 +96,23 @@ network_pass1() { fi done + # Warm up user ppp if required, must happen before natd. + if [ "X$ppp_enable" = X"YES" ]; then + # Establish ppp mode. + if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ + -a "X$ppp_mode" != X"dedicated" ]; then \ + ppp_mode="auto"; + fi + ppp_command="-${ppp_mode} "; + + # Switch on alias mode? + if [ "X$ppp_alias" = X"YES" ]; then + ppp_command="${ppp_command} -alias"; + fi + + echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} + fi + # Initialize IP filtering using ipfw echo "" /sbin/ipfw -q flush > /dev/null 2>&1 @@ -144,23 +161,6 @@ network_pass1() { fi fi - # Warm up user ppp if required. - if [ "X$ppp_enable" = X"YES" ]; then - # Establish ppp mode. - if [ "X$ppp_mode" != X"ddial" -a "X$ppp_mode" != X"direct" \ - -a "X$ppp_mode" != X"dedicated" ]; then \ - ppp_mode="auto"; - fi - ppp_command="-${ppp_mode} "; - - # Switch on alias mode? - if [ "X$ppp_alias" = X"YES" ]; then - ppp_command="${ppp_command} -alias"; - fi - - echo -n 'Starting ppp: '; ppp ${ppp_command} ${ppp_profile} - fi - # Additional ATM interface configuration if [ -n "${atm_pass1_done}" ]; then atm_pass2