RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 746579 - Default route and ip-down.local handled incorrectly
Summary: Default route and ip-down.local handled incorrectly
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: rp-pppoe
Version: 6.0
Hardware: Unspecified
OS: Linux
unspecified
medium
Target Milestone: rc
: 6.0
Assignee: Than Ngo
QA Contact: Desktop QE
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-10-17 06:47 UTC by John Cameron
Modified: 2016-06-07 11:44 UTC (History)
2 users (show)

Fixed In Version: rp-pppoe-3.10-13.el6
Doc Type: Bug Fix
Doc Text:
cause: the DEFROUTE and DEFAULTROUTE was not defined and handle correct in the pppoe-connect Consequence: the default route was not set Fix: set DEFROUTE and DEFAULTROUTE in pppoe-connect correctly so that the default route can set Result: the default route is set correctly
Clone Of:
Environment:
Last Closed: 2016-05-11 00:41:19 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:0923 0 normal SHIPPED_LIVE rp-pppoe bug fix update 2016-05-10 22:53:21 UTC

Description John Cameron 2011-10-17 06:47:49 UTC
Description of problem: Default route and ip-down.local handled incorrectly

Version-Release number of selected component (if applicable): rp-pppoe-3.10-8.el6.x86_64

How reproducible: Constant

Steps to Reproduce:

Configure Dual PPPoE config :

yum -q -y install rp-pppoe
PPPOE_DIR=`readlink -f /usr/share/doc/rp-pppoe*`
SAMPLE_PPPOE_CONF=${PPPOE_DIR}/configs/pppoe.conf
SAMPLE_PPPOE_INIT=${PPPOE_DIR}/pppoe-init
USERNAME0=user0
PASSWORD0=pass0
USERNAME1=user1
PASSWORD1=pass1

cp -f $SAMPLE_PPPOE_INIT /etc/init.d/pppoe0 
sed –i “s/\$START/\$START \/etc\/ppp\/pppoe0.conf/” /etc/init.d/pppoe0
sed –i “s/\$STATUS/\$STATUS \/etc\/ppp\/pppoe0.conf/” /etc/init.d/pppoe0
sed –i “s/subsys\/pppoe/subsys\/pppoe0/” /etc/init.d/pppoe0
chmod 755 /etc/init.d/pppoe0
chkconfig --add pppoe0
cp -f $SAMPLE_PPPOE_CONF /etc/ppp/pppoe0.conf 
sed -i 's/^PPPD_EXTRA=.*$/PPPD_EXTRA="unit 0"/' /etc/ppp/pppoe0.conf
sed -i "s/^DEFAULTROUTE=.*$/DEFAULTROUTE=yes/" /etc/ppp/pppoe1.conf
echo "\"$USERNAME0\"     * \"$PASSWORD0\"     \"\"" >> /etc/ppp/pap-secrets
sed -i "s/^USER=.*$/USER=${USERNAME0}/" /etc/ppp/pppoe0.conf
service pppoe0 start

cp -f $SAMPLE_PPPOE_INIT /etc/init.d/pppoe1
sed –i “s/\$START/\$START \/etc\/ppp\/pppoe1.conf/” /etc/init.d/pppoe1
sed –i “s/\$STATUS/\$STATUS \/etc\/ppp\/pppoe1.conf/” /etc/init.d/pppoe1
sed –i “s/subsys\/pppoe/subsys\/pppoe1/” /etc/init.d/pppoe1
chmod 755 /etc/init.d/pppoe1
chkconfig --add pppoe1
cp -f $SAMPLE_PPPOE_CONF /etc/ppp/pppoe1.conf
sed -i 's/^PPPD_EXTRA=.*$/PPPD_EXTRA="unit 1"/' /etc/ppp/pppoe1.conf
sed -i "s/^DEFAULTROUTE=.*$/DEFAULTROUTE=no/" /etc/ppp/pppoe1.conf
echo "\"$USERNAME1\"     * \"$PASSWORD1\"     \"\"" >> /etc/ppp/pap-secrets
sed -i "s/^USER=.*$/USER=${USERNAME1}/" /etc/ppp/pppoe1.conf
service pppoe1 start

Actual results:

1. Check Default Route :

Run : ip route show | grep default

Result : default dev ppp0  scope link

2. Restart Second PPPoE and check Default Route :

Run : service pppoe1 restart

Run : ip route show | grep default

Result : null

Expected results:

Run : ip route show | grep default

Result : default dev ppp0  scope link

Additional info:

1. DEFROUTE variable not defined or parsed 

Fix : sed -i '/if test "\$DEFROUTE"/ iDEFROUTE=\$DEFAULTROUTE' /sbin/pppoe-connect

2. “nodefaultroute” has to be specified via PPPD_EXTRA in pppoe1.conf even when DEFAULTROUTE=no is specified

Fix : sed -i 's/DEFAULTROUTE=""/DEFAULTROUTE="nodefaultroute"/g' /sbin/pppoe-connect

3. “/sbin/pppoe-stop” kills process therefor ip-down.local not parsed 

Fix : sed -i "/exit 0/ i[ -x \/etc\/ppp\/ip-down.local ] && \/etc\/ppp\/ip-down.local > \/dev\/null 2>&1" /sbin/pppoe-stop

Comment 2 RHEL Program Management 2011-10-17 07:08:36 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated
in the current release, Red Hat is unfortunately unable to
address this request at this time. Red Hat invites you to
ask your support representative to propose this request, if
appropriate and relevant, in the next release of Red Hat
Enterprise Linux. If you would like it considered as an
exception in the current release, please ask your support
representative.

Comment 4 Suzanne Logcher 2012-02-14 23:17:46 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated
in the current release, Red Hat is unfortunately unable to
address this request at this time. Red Hat invites you to
ask your support representative to propose this request, if
appropriate and relevant, in the next release of Red Hat
Enterprise Linux. If you would like it considered as an
exception in the current release, please ask your support
representative.

Comment 14 errata-xmlrpc 2016-05-11 00:41:19 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-0923.html

Comment 15 David Herselman 2016-06-07 11:33:35 UTC
Grrr... This now breaks default route selection which has been working perfectly for 10+ years:

We define connection via ifcfg-ppp# configuration script:

/etc/sysconfig/network-scripts/ifcfg-ppp0
USERCTL=yes
BOOTPROTO=dialup
NAME=DSLppp0
DEVICE=ppp0
TYPE=xDSL
ONBOOT=no
PIDFILE=/var/run/pppoe-adsl.pid
FIREWALL=NONE
PING=.
PPPOE_TIMEOUT=80
LCP_FAILURE=3
LCP_INTERVAL=20
CLAMPMSS=1412
CONNECT_POLL=6
CONNECT_TIMEOUT=60
DEFROUTE=no
SYNCHRONOUS=no
ETH=vlan11
PROVIDER=DSLppp0
USER=syrexd2354.co.za
PEERDNS=no
PPPD_EXTRA='ipparam out2'


pppoe-connect now incorrectly sets 'defaultroute':
root     15098  0.0  0.0   9240  1216 ?        S    13:26   0:00 /bin/bash /sbin/pppoe-connect /etc/sysconfig/network-scripts/ifcfg-ppp0
root     15122  0.0  0.0  21896  1344 ?        Ss   13:26   0:00  \_ /usr/sbin/pppd pty /usr/sbin/pppoe -p /var/run/pppoe-adsl.pid.pppoe -I vlan11 -T 80 -U  -m 1412    ipparam ppp0 linkname ppp0 noipdefault noauth default-asyncmap defaultroute hide-password nodetach mtu 1492 mru 1492 noaccomp nodeflate nopcomp novj novjccomp user syrexd2354.co.za lcp-echo-interval 20 lcp-echo-failure 3 ipparam out2

Comment 16 David Herselman 2016-06-07 11:44:14 UTC
Problem is that /sbin/pppoe-connect redefines DEFROUTE here:

DEFROUTE=$DEFAULTROUTE
if test "$DEFROUTE" != "no" ; then
    DEFAULTROUTE="defaultroute"
    # pppd will no longer delete an existing default route
    # so we have to help it out a little here.
    DEFRT=$(ip route list match 0/0)
    [ -n "${DEFRT}" ] && echo "$DEFRT" > /etc/default-routes
    echo "$DEFRT" | while read spec; do
        ip route del $spec;
    done
else
    DEFAULTROUTE="nodefaultroute"
fi

The script subsequently now always sets DEFROUTE='defaultroute' when DEFROUTE is defined in ifcfg-ppp#

RedHat definitely broke this by accident, work around would either be to comment out the 'DEFROUTE=$DEFAULTROUTE' statement or change ifcfg-ppp# definition to use 'DEFAULTROUTE=no' instead of 'DEFROUTE=no',


Note You need to log in before you can comment on or make changes to this bug.