Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 6378 - redo net.ppp0
Summary: redo net.ppp0
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Martin Schlemmer (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-08-12 15:05 UTC by Jacob Perkins
Modified: 2003-02-04 19:42 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jacob Perkins 2002-08-12 15:05:04 UTC
This is just a suggestion and not really necessary since net.ppp0 works fine the
way it is. But, every other rc script that needs to, takes their configuration
data from a file in conf.d. net.ppp0 is the only one that I've run into where
you have to edit the script to configure it. I propose that all the user
configuration variables be moved to the file /etc/conf.d/ppp0 (or pppX) and then
modify net.ppp0 accordingly. I'm pretty inexperienced with bash programming, but
I will try to take a swing at it and upload anything I can get working. One
issue this might resolve is that net.ppp0 no longer has to have 700 perms since
it won't contain the config vars anymore. I don't know if the 700 perms are what
causes it, but after I connect, I need to do a chmod +r as root on resolv.conf
so that I can use the net as a user.
Comment 1 SpanKY gentoo-dev 2002-08-12 17:30:55 UTC
heh, the /etc/init.d/net.ppp0 was so phearsome with options i `echo>net.ppp0` 
and just made it run adsl-start/adsl-stop

shouldnt take that long to rewrite it ... just move the variables 
into /etc/conf.d/net ... when the net.ppp0 script is run it automatically 
sources that file before running anything
Comment 2 Jacob Perkins 2002-08-12 20:22:15 UTC
But what if you're using net.eth0 and net.ppp0 interchangeably. Maybe you can
only connect to the net through dialup, but have a router for a home network. I
think being able to use both eth0 and ppp0 at the same time might need some
redesigning of the net.eth0 too. I think each network script should have
separate config files in conf.d instead of just sourcing from net
Comment 3 SpanKY gentoo-dev 2002-08-12 20:26:42 UTC
why ?
the variable names dont clash
Comment 4 Martin Schlemmer (RETIRED) gentoo-dev 2002-08-13 15:48:07 UTC
I'd go for a /etc/conf.d/net.ppp0, etc as well.  Reason is if you have
more than one ppp connection (yes, some of us without adsl do :P), you
want each one to be different.  You will also (like I did when /etc/conf.d
was first proposed) make it root only readible on install.

BTW:  what country Jacob ?  I am from South Africa, and wrote it to work for
      me.  Did a few posts to ask for people to test and make it more universal,
      but nobody got back to me.  Glad it works for you !! :)
Comment 5 SpanKY gentoo-dev 2002-08-13 16:18:52 UTC
what an odd thing, having more than 1 ppp connection
i never thought of that :)

so why not follow suit with /etc/conf.d/net where the variables are all 
VAR_ethX and put the ppp variables in there, like PEER_ppp0 ... just put them 
at the end after a big comment block like 'IF YOU DO NOT USE PPP STOP EDITING'
Comment 6 Jacob Perkins 2002-08-13 16:57:53 UTC
I'm in the USA, St. Louis, MO, and I have net.ppp0 and net.ppp1 right now, and
could even make a net.ppp2. Luckily, I just got my replacement dsl modem and
have no need for dialup anymore, but that doesn't change the fact that I think
there should be multiple files in conf.d, one for each net connection, and that
I might need to use one of those ppp connections in the future, at the same time
as I'm using my net.eth0 connection. I think that having multiple files is much
more straightforward than having multiple variables in one file. So, conf.d
should have both net.eth0 and net.ppp0, along with any net.ethX and net.pppX.
Giving the conf.d/net.pppX files 700 perms protects the passwords, and ought to
fix the need to do a chmod +r on resolv.conf after connecting.
Comment 7 Martin Schlemmer (RETIRED) gentoo-dev 2002-08-13 18:04:58 UTC
SpanKY: because there are so *many* variables for only *one* net.ppp script.
        Things will really get out of hand if you have to put say only two
        net.ppp config variables in /etc/conf.d/net
Comment 8 Martin Schlemmer (RETIRED) gentoo-dev 2002-08-25 02:42:24 UTC
Fixed on CVS.