]>
Commit | Line | Data |
---|---|---|
763b88c2 AM |
1 | #!/bin/sh |
2 | # | |
763b88c2 AM |
3 | # This file should not be modified |
4 | # | |
5 | # This script is run by the pppd after the link is established. | |
6 | # | |
7 | # This script is called with the following arguments: | |
5e6dfc29 JR |
8 | # Arg Name Example |
9 | # $1 Interface name ppp0 | |
10 | # $2 The tty ttyS1 | |
11 | # $3 The link speed 38400 | |
12 | # $4 The network number ??? | |
13 | # $5 Local IPX node address ??? | |
14 | # $6 Remote IPX node address ??? | |
15 | # $7 Local IPX routing protocol ??? | |
16 | # $8 Remote IPX routing protocol ??? | |
17 | # $9 Local IPX router name ??? | |
18 | # $10 Remote IPX router name ??? | |
19 | # $11 Optional ``ipparam'' value foo | |
20 | # $12 PPPD pid 1276 | |
763b88c2 AM |
21 | |
22 | set +e | |
23 | ||
5e6dfc29 | 24 | # The environment is cleared before executing this script |
763b88c2 AM |
25 | # so the path must be reset |
26 | PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin | |
27 | export PATH | |
28 | # These variables are for the use of the scripts run by run-parts | |
29 | PPP_IFACE="$1" | |
30 | PPP_TTY="$2" | |
31 | PPP_SPEED="$3" | |
32 | PPP_NETWORK="$4" | |
33 | PPP_LOCAL="$5" | |
34 | PPP_REMOTE="$6" | |
35 | PPP_LOCAL_RPROTO="$7" | |
36 | PPP_REMOTE_RPROTO="$8" | |
37 | PPP_LOCAL_RNAME="$9" | |
38 | PPP_REMOTE_RNAME="$10" | |
39 | PPP_IPPARAM="$11" | |
40 | PPP_PID="$12" | |
41 | ||
42 | export PPP_IFACE PPP_TTY PPP_SPEED PPP_NETWORK PPP_LOCAL PPP_REMOTE | |
43 | export PPP_LOCAL_RPROTO PPP_REMOTE_RPROTO PPP_LOCAL_RNAME PPP_REMOTE_RNAME | |
44 | export PPP_IPPARAM PPP_PID | |
45 | ||
46 | . /etc/rc.d/init.d/functions | |
f67ce454 | 47 | . /lib/rc-scripts/functions.network |
763b88c2 AM |
48 | CONFIG="$PPP_IPPARAM" |
49 | source_config | |
50 | ||
51 | # as an additional convenience, $PPP_TTYNAME is set to the tty name, | |
52 | # stripped of /dev/ (if present) for easier matching. | |
53 | PPP_TTYNAME=$(basename "$PPP_TTY") | |
54 | export PPP_TTYNAME | |
55 | ||
56 | # Main Script starts here | |
5e6dfc29 | 57 | [ -x /etc/ppp/ipx-down.local ] && /etc/ppp/ipx-down.local |
763b88c2 AM |
58 | |
59 | run-parts /etc/sysconfig/interfaces/down.d/ipx | |
60 | ||
61 | exit 0 |