Bug 20142 - ppp DEMAND options and static-routes don't mix well
Summary: ppp DEMAND options and static-routes don't mix well
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: initscripts
Version: 7.0
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact: David Lawrence
URL:
Whiteboard:
: 69659 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2000-11-01 11:10 UTC by Göran Uddeborg
Modified: 2014-03-17 02:17 UTC (History)
4 users (show)

Fixed In Version: 8.09-1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2005-04-25 17:01:10 UTC
Embargoed:


Attachments (Terms of Use)
my hacked ifup-ppp (from wolverine) that fixes this as well as allowing pppd to detach (3.54 KB, text/plain)
2001-03-02 04:23 UTC, Brian Smith
no flags Details
Patch to ifup-ppp to solve this bug. (721 bytes, patch)
2005-04-24 14:19 UTC, Fredrik Öhrn
no flags Details | Diff

Description Göran Uddeborg 2000-11-01 11:10:13 UTC
With 7.0 it is possible to do ppp demand dialling.  That's a good
addition.  But it seems it doesn't mix well with static-routes.  Since
ifup-post (and hence ifup-routes) ar run from the /etc/ppp/ip-up script,
the static routes aren't added until the interface is brought up (except
for "defaultroute" if applicable, since that is an option to pppd).  It
seems to me it would make more sense to do the ordinary static routes when
the interface itself is brought up.

It appears there is no script run by pppd when the interface is brought up
but not dialled, so I assume it would require using some other strategy in
the ifup scripts.

Comment 1 Brian Smith 2001-03-02 04:23:44 UTC
Created attachment 11541 [details]
my hacked ifup-ppp (from wolverine) that fixes this as well as allowing pppd to detach

Comment 2 Brian Smith 2001-03-02 04:30:54 UTC
I've attached the modified ifup-ppp I'm using (with wolverine now, but it's the 
same basic thing I did with 7.0) which runs ifup-routes after pppd detaches for 
demand-dialed interfaces. It still exec's pppd for regular connections. Hope 
this helps... this issue caused me some grief as well until I figured out how 
easy it was to fix it.

There is one thing which might irk the easily irkable: when ifup-post runs 
after the connection is made, ifup-routes will try to add the same routes again 
and fail. ifup-post should check if the device is a demand-dialed ppp device 
and skip the ifup-routes, but I haven't bothered doing that yet since it 
doesn't really cause any problems, and I try not to fix what isn't broken.


Comment 3 Fredrik Öhrn 2005-04-24 14:19:16 UTC
Created attachment 113599 [details]
Patch to ifup-ppp to solve this bug.

This bug is still around in fc4test2. I got stuck on it when trying to setup an
on demand VPN tunnel from home to my office subnet.

I've attached an imho robust patch for ifup-ppp that builds on the suggestions
by Göran and Brian. The patch applies to initscripts v6 to v8.

In my testing it's not a problem that ifup-routes is run again by ip-up, it's
actually necessary. When the connection is "dialed", pppd downs and ups the
ppp0 interface causing the initial routes added by ifup-ppp to be removed.

Comment 4 Bill Nottingham 2005-04-25 17:01:10 UTC
Added, will be in 8.09-1. Thanks!

Comment 5 Bill Nottingham 2005-04-28 19:07:04 UTC
*** Bug 69659 has been marked as a duplicate of this bug. ***


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