diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2005-10-16 17:34:42 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2005-10-16 17:34:42 +0000 |
commit | e1c8cdf529bba36dec64f16206e364ffa2b519d8 (patch) | |
tree | 6bcc6db8a954996aa88ebdfe8a45b9134c3fc79f /usr/local/sbin/ppp-linkup | |
parent | eba1ebc151a00fb008e39de009bb6ba366dc52f4 (diff) | |
download | pfsense-e1c8cdf529bba36dec64f16206e364ffa2b519d8.zip pfsense-e1c8cdf529bba36dec64f16206e364ffa2b519d8.tar.gz |
MFC 6871
If WAN is pppoe, hold down boot until connection is established This will help anyone with PPPOE on WAN and DHCP on OPTx not get incorrect gateways assigned.
Diffstat (limited to 'usr/local/sbin/ppp-linkup')
-rwxr-xr-x | usr/local/sbin/ppp-linkup | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/usr/local/sbin/ppp-linkup b/usr/local/sbin/ppp-linkup new file mode 100755 index 0000000..da43796 --- /dev/null +++ b/usr/local/sbin/ppp-linkup @@ -0,0 +1,22 @@ +#!/bin/sh + +rm -f /var/etc/nameservers.conf + +# unset CGI environment variables so as not to confuse PHP +unset CONTENT_TYPE GATEWAY_INTERFACE REMOTE_USER REMOTE_ADDR AUTH_TYPE +unset HTTP_USER_AGENT CONTENT_LENGTH SCRIPT_FILENAME HTTP_HOST +unset SERVER_SOFTWARE HTTP_REFERER SERVER_PROTOCOL REQUEST_METHOD +unset SERVER_PORT SCRIPT_NAME SERVER_NAME + +# write nameservers to file +if [ "$6" = "dns1" ]; then + echo $7 >> /var/etc/nameservers.conf +fi +if [ "$8" = "dns2" ]; then + echo $9 >> /var/etc/nameservers.conf +fi + +# let the configuration system know that the +# WAN IP address has changed +/etc/rc.newwanip + |