aboutsummaryrefslogtreecommitdiffstats
path: root/sysconfig
diff options
context:
space:
mode:
authorMichael K. Johnson <johnsonm@redhat.com>1999-08-04 23:52:11 +0000
committerMichael K. Johnson <johnsonm@redhat.com>1999-08-04 23:52:11 +0000
commitbc662c04ae3f3a7d441a22bb5ca57c14dd57e81e (patch)
treeb3b55fc4e4262f34f9ce4578df2291bfb80c359d /sysconfig
parentda1e21b54543316fb1e9e83fb6049762f0d4c611 (diff)
downloadinitscripts-bc662c04ae3f3a7d441a22bb5ca57c14dd57e81e.tar
initscripts-bc662c04ae3f3a7d441a22bb5ca57c14dd57e81e.tar.gz
initscripts-bc662c04ae3f3a7d441a22bb5ca57c14dd57e81e.tar.bz2
initscripts-bc662c04ae3f3a7d441a22bb5ca57c14dd57e81e.tar.xz
initscripts-bc662c04ae3f3a7d441a22bb5ca57c14dd57e81e.zip
take advantage of userpeerdns
Diffstat (limited to 'sysconfig')
-rwxr-xr-xsysconfig/network-scripts/ifup-post31
-rwxr-xr-xsysconfig/network-scripts/ifup-ppp3
2 files changed, 34 insertions, 0 deletions
diff --git a/sysconfig/network-scripts/ifup-post b/sysconfig/network-scripts/ifup-post
index 6ddf2167..cd5b0267 100755
--- a/sysconfig/network-scripts/ifup-post
+++ b/sysconfig/network-scripts/ifup-post
@@ -28,6 +28,37 @@ if [ -n "$NEEDHOSTNAME" -a "${DEVICE}" != lo -a "${DEVICETYPE}" != "ppp" -a "${D
eval `/bin/ipcalc --silent --hostname ${IPADDR}` && set_hostname $HOSTNAME
fi
+if [ "$DEVICETYPE" = ppp -a "$PEERDNS" = yes -a -n "$DNS1" ] &&
+ tr=`mktemp /tmp/resolv.XXXXXX` ; then
+ # replace only the first two nameserver lines; cannot count on awk
+ # and do not know if sed is capable of this...
+ current_replacement="$DNS1"
+ next_replacement="$DNS2"
+ while read answer < /etc/resolv.conf ; do
+ case $answer in
+ nameserver*)
+ if [ -n "$current_replacement" ] ; then
+ echo "nameserver $current_replacement" >> $tr
+ if [ -n "$next_replacement" ] ; then
+ current_replacement="$next_replacement"
+ next_replacement=
+ else
+ current_replacement=
+ fi
+ else
+ echo "$answer" >> $tr
+ fi
+ ;;
+ *)
+ echo "$answer" >> $tr
+ ;;
+ esac
+ done
+ # maintain permissions
+ cat $tr > /etc/resolv.conf
+ rm -f $tr
+fi
+
# Notify programs that have requested notification
do_netreport
diff --git a/sysconfig/network-scripts/ifup-ppp b/sysconfig/network-scripts/ifup-ppp
index 1727a778..ef5b0281 100755
--- a/sysconfig/network-scripts/ifup-ppp
+++ b/sysconfig/network-scripts/ifup-ppp
@@ -57,6 +57,9 @@ fi
if [ "${DEFROUTE}" = yes ] ; then
opts="$opts defaultroute"
fi
+if [ "${PEERDNS}" = yes ] ; then
+ opts="$opts usepeerdns"
+fi
if [ -n "${MRU}" ] ; then
opts="$opts mru ${MRU}"
fi
ts
+ LOCALES"sr" || LOCALES"tg" || LOCALES"tt" || LOCALES"uz" urw-fonts
LOCALES"ru" || LOCALES"uk" urw-fonts XFree86-cyrillic-fonts
+ LOCALES"am" fonts-ttf-ethiopic
+ LOCALES"ar" || LOCALES"fa" || LOCALES"ur" fonts-ttf-arabic
+ LOCALES"as" || LOCALES"bn" fonts-ttf-bengali
LOCALES"el" fonts-type1-greek
- LOCALES"he" || LOCALES"yi" fonts-hebrew-elmar
+ LOCALES"he" || LOCALES"yi" fonts-hebrew-elmar fonts-type1-hebrew
LOCALES"hy" fonts-ttf-armenian
LOCALES"ja" fonts-ttf-japanese
+ LOCALES"kn" fonts-ttf-kannada
LOCALES"ko" fonts-ttf-korean
LOCALES"ta" fonts-ttf-tamil fonts-ttf-tscii fonts-bitmap-tscii
LOCALES"th" fonts-ttf-thai
@@ -525,7 +528,7 @@ SYSTEM
1 fdutils genromfs mailcap pinfo
BOOKS
- 5 man-pages-cs man-pages-de man-pages-es man-pages-fr man-pages-hu man-pages-id man-pages-ja man-pages-ko man-pages-pl man-pages-ru man-pages-zh
+ 5 man-pages-cs man-pages-de man-pages-de man-pages-es man-pages-fr man-pages-hu man-pages-id man-pages-it man-pages-ja man-pages-ko man-pages-pl man-pages-pt_BR man-pages-ru man-pages-zh
4 grub-doc lilo-doc
howto-html-de howto-html-fr