PPP: Difference between revisions
(simplification, references to man pages, completion) |
m (typo) |
||
(8 intermediate revisions by 3 users not shown) | |||
Line 3: | Line 3: | ||
== Installation == | == Installation == | ||
PPP (Point-to-Point Protocol) allows multiple transports, eg. | PPP (Point-to-Point Protocol) allows multiple transports, eg. PPPoE is PPP over Ethernet. | ||
=== PPPoE === | === PPPoE === | ||
Line 15: | Line 15: | ||
Such file is usually located as ''/etc/ppp/peers/<isp>''. See [https://ppp.samba.org/pppd.html pppd(8)] for all possible options. | Such file is usually located as ''/etc/ppp/peers/<isp>''. See [https://ppp.samba.org/pppd.html pppd(8)] for all possible options. | ||
==== | ==== PPPoE ==== | ||
This example peer file is based on Debian's [https://salsa.debian.org/debian/ppp/-/raw/master/debian/extra/peers-pppoe peers-pppoe] extra file. | This example peer file is based on Debian's [https://salsa.debian.org/debian/ppp/-/raw/master/debian/extra/peers-pppoe peers-pppoe] extra file. See that ''pppoe.so'' plugin as ''eth0'' as device defined. | ||
<pre> | <pre> | ||
user "myusername@realm" | user "myusername@realm" | ||
plugin | plugin pppoe.so eth0 | ||
eth0 | |||
noipdefault | noipdefault | ||
usepeerdns | usepeerdns | ||
Line 29: | Line 28: | ||
noauth | noauth | ||
</pre> | </pre> | ||
Note that if you have a version of ppp older than 2.4.9, the <code>pppoe.so</code> plugin is named <code>rp-pppoe.so</code>. | |||
=== Authentication === | === Authentication === | ||
Line 44: | Line 45: | ||
== Kernel modules == | == Kernel modules == | ||
''pppoe'' must be present in ''/etc/modules''. | === PPPoE === | ||
''pppoe'' must be present in ''/etc/modules'' when using PPPoE. | |||
== ''ifupdown-ng'' intergration == | == ''ifupdown-ng'' intergration == | ||
Line 55: | Line 58: | ||
<pre> | <pre> | ||
auto eth0 | |||
iface eth0 up | |||
auto ppp0 | auto ppp0 | ||
iface ppp0 | iface ppp0 | ||
ppp-provider isp | ppp-provider isp | ||
</pre> | </pre> | ||
== Tips == | |||
=== pppoeconf === | |||
Debian created ''[https://sources.debian.org/data/main/p/pppoeconf/1.21%2Bnmu2/pppoeconf pppoeconf]'' tool which helps configuring PPPoE. First some utils have to be installed. | |||
{{cmd|apk add ppp-pppoe newt gettext sed}} | |||
{{cmd|wget https://sources.debian.org/data/main/p/pppoeconf/1.21%2Bnmu2/pppoeconf}} | |||
{{cmd|chmod +x ./pppoeconf && ./pppoeconf}} | |||
[[Category:Networking]] | [[Category:Networking]] |
Latest revision as of 21:53, 10 May 2023
Installation
PPP (Point-to-Point Protocol) allows multiple transports, eg. PPPoE is PPP over Ethernet.
PPPoE
apk add ppp-pppoe
Configure PPP
PPP peer file
Such file is usually located as /etc/ppp/peers/<isp>. See pppd(8) for all possible options.
PPPoE
This example peer file is based on Debian's peers-pppoe extra file. See that pppoe.so plugin as eth0 as device defined.
user "myusername@realm" plugin pppoe.so eth0 noipdefault usepeerdns defaultroute persist noauth
Note that if you have a version of ppp older than 2.4.9, the pppoe.so
plugin is named rp-pppoe.so
.
Authentication
CHAP authentication is most used one but there are other ones, see pppd(8).
/etc/ppp/chap-secrets
# Secrets for authentication using CHAP # client server secret IP addresses "myusername@realm" * "<your password>"
Kernel modules
PPPoE
pppoe must be present in /etc/modules when using PPPoE.
ifupdown-ng intergration
To use /etc/network/interfaces with a ppp defintion automatically, ifupdown-ng-ppp package must be installed.
apk add ifupdown-ng-ppp
Example for PPP configuration in /etc/network/interfaces, see interfaces-ppp(5) for more info.
auto eth0 iface eth0 up auto ppp0 iface ppp0 ppp-provider isp
Tips
pppoeconf
Debian created pppoeconf tool which helps configuring PPPoE. First some utils have to be installed.
apk add ppp-pppoe newt gettext sed
wget https://sources.debian.org/data/main/p/pppoeconf/1.21%2Bnmu2/pppoeconf
chmod +x ./pppoeconf && ./pppoeconf