1995-01-31 06:24:33 +00:00
|
|
|
#########################################################################
|
|
|
|
#
|
|
|
|
# Example of ppp.linkup file
|
|
|
|
#
|
|
|
|
#
|
1997-02-23 14:04:23 +00:00
|
|
|
# This file is checked when PPP establishes a connection.
|
|
|
|
# PPP searches the labels in this file as follows:
|
1995-01-31 06:24:33 +00:00
|
|
|
#
|
1997-02-23 14:04:23 +00:00
|
|
|
# 1) The label that matches the IP number assigned to our side.
|
1995-01-31 06:24:33 +00:00
|
|
|
#
|
1997-02-23 14:04:23 +00:00
|
|
|
# 2) The label specified on the command line to ppp.
|
1995-01-31 06:24:33 +00:00
|
|
|
#
|
1997-02-23 14:04:23 +00:00
|
|
|
# 3) If no label has been found, use MYADDR if it exists.
|
1995-01-31 06:24:33 +00:00
|
|
|
#
|
1997-11-07 20:44:12 +00:00
|
|
|
# $Id: ppp.linkup.sample,v 1.9 1997/09/21 02:10:41 brian Exp $
|
1995-01-31 06:24:33 +00:00
|
|
|
#
|
|
|
|
#########################################################################
|
1997-02-23 14:04:23 +00:00
|
|
|
|
1995-01-31 06:24:33 +00:00
|
|
|
# If we've got 192.244.176.32 as our address, then regard peer as a gateway
|
|
|
|
# to 192.244.176.0 network.
|
|
|
|
#
|
1997-02-23 14:04:23 +00:00
|
|
|
192.244.176.32:
|
|
|
|
add 192.244.176.0 0 HISADDR
|
|
|
|
|
|
|
|
# If we are invoked with an argument ``iij-demand'', then delete all
|
|
|
|
# existing route entries and add the peer as the default gateway.
|
1995-01-31 06:24:33 +00:00
|
|
|
#
|
|
|
|
iij-demand:
|
|
|
|
delete ALL
|
|
|
|
add 0 0 HISADDR
|
1997-02-23 14:04:23 +00:00
|
|
|
|
1996-01-31 15:03:18 +00:00
|
|
|
# Otherwise, simply add peer as default gateway.
|
1995-01-31 06:24:33 +00:00
|
|
|
#
|
|
|
|
MYADDR:
|
1997-09-21 02:10:41 +00:00
|
|
|
delete 0
|
1995-01-31 06:24:33 +00:00
|
|
|
add 0 0 HISADDR
|
1997-02-23 14:04:23 +00:00
|
|
|
|
|
|
|
# If we are invoked with an argument ``pmdemand'', then
|
|
|
|
# delete all existing (wrong) routing entries and add the peer IP
|
|
|
|
# as our default gateway.
|
|
|
|
# This is vital if you don't already know either sides IP number.
|
|
|
|
#
|
1997-06-10 10:04:20 +00:00
|
|
|
# We create a loopback route to ourselves so that we can "ping"
|
|
|
|
# our side of the connection
|
|
|
|
#
|
1997-02-23 14:04:23 +00:00
|
|
|
# We also want to execute a script on startup. This script can do
|
|
|
|
# nice things such as kick off "sendmail -q", "popclient my.isp" and
|
1997-06-10 10:04:20 +00:00
|
|
|
# "slurp -d news". It can be passed MYADDR, HISADDR and INTERFACE
|
|
|
|
# too - useful for informing a DNS.
|
1997-02-23 14:04:23 +00:00
|
|
|
#
|
|
|
|
pmdemand:
|
|
|
|
delete ALL
|
|
|
|
add 0 0 HISADDR
|
1997-06-10 10:04:20 +00:00
|
|
|
add MYADDR 255.255.255.255 127.0.0.1
|
1997-08-25 01:07:08 +00:00
|
|
|
!bg /etc/ppp/ppp.etherup.pmdemand
|
1997-11-07 20:44:12 +00:00
|
|
|
|
|
|
|
# If your minimum call charge is 5 minutes, you may as well stay on
|
|
|
|
# the line for that amount of time. If we want a 60 second subsequent
|
|
|
|
# timeout, set your timeout to 0 in ppp.conf and then do this:
|
|
|
|
#
|
|
|
|
min5minutes:
|
|
|
|
!bg sh -c "sleep 240; pppctl -p mypassword 3000 set timeout 60"
|