Re: [2.1.35] PPP device increments after HUP

B. James Phillippe (bryan@Terran.ORG)
Thu, 17 Apr 1997 21:43:19 -0700


[1997.4.18] bofh@snoopy.virtual.net.au spoke of "Re: [2.1.35] PPP device increments after HUP"
> > I'm using 2.1.35 with all the current fixins, connected to the Net via
> >33.6 PPP (dedicated). The problem I'm seeing, is that when the
> >connection is first made (after bootup, for instance), the device driver
> >allocated is "ppp0". If the modem drops carrier, the scripts I wrote will
> >notice that device is no longer up and will redial. So far, so good.
> >But, after the successful redial, the device allocated is ppp1. Forever
> >after, I can not get ppp0 to come up. This breaks the scripts the check
> >the line because they look for specific devices to know which connections
> >are up. This system has worked without modification since 2.0.something.
> >It may have broken before 2.1.35 but I never noticed before.
>
> If this is considered broken, then it was broken before 2.1.35. The numbers seem to be allocated almost randomly between 0 and the highest number of concurrant PPP connections.
> I recommend just writing your scripts without assumptions about ppp device numbers (as to do otherwise will just make them break if you add more serial lines). A simple application of "ifconfig", "grep", and "cut" should give you the correct device number (or even just grep the appropriate /proc file directly).

I can see your logic here, and believe me, I've given it thought. However,
although PPP devices are traditionally short-lived and number independant,
with static, dedicated connections there should be some rhyme and reason
to device number allocation. When we ifconfig an ethernet device, it darn
well matters whether we're talking about eth0 or eth1 (especially with
firewalls!!). I don't see why PPP devices shouldn't enjoy the same
consistancy. To go a step further, perhaps pppd should be able to be
given a device number to assign at startup. That way, PPP connections
can be relied upon to have set device orders even when started out of
sequence (think of a PPP firewall with dynamic IP's on each end. Contrived,
I know, but valid nonetheless). =]

Thoughts? I know the discussion of pppd is beyond the scope of this list,
but what about the behavior I'm noticing? It is kernel-related, yes no?

thanks,

-- 
# B. James Phillippe # Network/Sys Admin Terran.ORG #
# <bryan@terran.org> # http://w3.terran.org/~bryan  #
# Finger for PGP key # Linux Convert - circa 1.1.59 #
# Systems Administrator, Seattle Software Labs, Inc #