Installation of adsl on Debian 2.2

 There are at least two ways to connect your Debian system to Belgacom adsl:

PPP over Ethernet

PPP over ethernet (Point-to-Point Protocol over Ethernet)  is described in RFC 2516. It uses an ethernet interface for transport and PPP runs above it.
Authentication is done using PAP (as with other PPP connections  (e.g. over modem) you already may have).

Unfortunately the Debian package
                    pppoe          1.0-1          PPP over Ethernet driver
did not work with me ( Adsl = Belgacom turboline, service provider = skynet.be).
The package only contains some documentation  (see  /usr/share/doc/pppoe/README.Debian) which explain how to setup your system for a adsl connection at startup.  I did not yet experiment with this possibility.

Since the Debian pppoe package does not seem to work, I did install the original pppoe source distribution from
                   http://www.roaringpen­guin.com/pppoe/
After unpacking  installation goes :

yoko:/usr/src/local/# tar zxvf /home/jean/src/adsl/pppoe/rp-pppoe-2.3.tar.gz
yoko:/usr/src/local/# cd rp-pppoe-2.3
yoko:/usr/src/local/rp-pppoe-2.3# ./configure
creating cache ./config.cache
checking for gcc... gcc
checking whether the C compiler (gcc  ) works... yes
checking whether the C compiler (gcc  ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/wait.h that is POSIX.1 compatible... yes
checking for fcntl.h... yes
checking for sys/ioctl.h... yes
checking for sys/time.h... yes
checking for syslog.h... yes
checking for unistd.h... yes
checking for netinet/if_ether.h... yes
checking for getopt.h... yes
checking for sys/uio.h... yes
checking for sys/param.h... yes
checking for fcntl.h... (cached) yes
checking for net/bpf.h... no
checking for netpacket/packet.h... yes
checking for net/ethernet.h... yes
checking for asm/types.h... yes
checking for linux/if_packet.h... yes
checking for linux/if_ether.h... yes
checking for sys/socket.h... yes
checking for sys/cdefs.h... yes
checking for net/if.h... yes
checking for net/if_dl.h... no
checking for net/if_ether.h... no
checking for net/if_types.h... no
checking for netinet/if_ether.h... (cached) yes
checking for net/if_types.h... (cached) no
checking for net/if_dl.h... (cached) no
checking for sys/dlpi.h... no
checking for working const... yes
checking for pid_t... yes
checking whether time.h and sys/time.h may both be included... yes
checking whether struct tm is in sys/time.h or time.h... time.h
checking for struct sockaddr_ll... yes
checking for N_HDLC line discipline... yes
checking for 8-bit clean memcmp... yes
checking whether setvbuf arguments are reversed... no
checking return type of signal handlers... void
checking for select... yes
checking for socket... yes
checking for strerror... yes
checking for strtol... yes
checking for a BSD compatible install... /usr/bin/install -c
checking size of unsigned short... 2
checking size of unsigned int... 4
checking size of unsigned long... 4
checking for pppd... /usr/sbin/pppd
checking for setsid... /usr/bin/setsid
updating cache ./config.cache
creating ./config.status
creating Makefile
creating adsl-connect
creating adsl-start
creating adsl-stop
creating adsl-init
creating adsl-init-suse
creating adsl-setup
creating config.h
config.h is unchanged

Type 'make' to compile the software.
yoko:/usr/src/local/rp-pppoe-2.3#   make
gcc -g -O2 -Wall -Wstrict-prototypes -ansi -pedantic  '-DPPPOE_PATH="/usr/sbin/pppoe"' '-DPPPD_PATH="/usr/sbin/pppd"' 
                    '-DPPPOE_SERVER_OPTIONS="/etc/ppp/pppoe-server-options"' '-DVERSION="2.3"' -c -o pppoe.o pppoe.c
gcc -g -O2 -Wall -Wstrict-prototypes -ansi -pedantic  '-DPPPOE_PATH="/usr/sbin/pppoe"' '-DPPPD_PATH="/usr/sbin/pppd"' 
                    '-DPPPOE_SERVER_OPTIONS="/etc/ppp/pppoe-server-options"' '-DVERSION="2.3"' -c -o if.o if.c
gcc -g -O2 -Wall -Wstrict-prototypes -ansi -pedantic  '-DPPPOE_PATH="/usr/sbin/pppoe"' '-DPPPD_PATH="/usr/sbin/pppd"' 
                    '-DPPPOE_SERVER_OPTIONS="/etc/ppp/pppoe-server-options"' '-DVERSION="2.3"' -c -o debug.o debug.c
gcc -g -O2 -Wall -Wstrict-prototypes -ansi -pedantic  '-DPPPOE_PATH="/usr/sbin/pppoe"' '-DPPPD_PATH="/usr/sbin/pppd"' 
                    '-DPPPOE_SERVER_OPTIONS="/etc/ppp/pppoe-server-options"' '-DVERSION="2.3"' -c -o common.o common.c
gcc -g -O2 -Wall -Wstrict-prototypes -ansi -pedantic  '-DPPPOE_PATH="/usr/sbin/pppoe"' '-DPPPD_PATH="/usr/sbin/pppd"' 
                    '-DPPPOE_SERVER_OPTIONS="/etc/ppp/pppoe-server-options"' '-DVERSION="2.3"' -c -o ppp.o ppp.c
gcc -o pppoe pppoe.o if.o debug.o common.o ppp.o
gcc -g -O2 -Wall -Wstrict-prototypes -ansi -pedantic  '-DPPPOE_PATH="/usr/sbin/pppoe"' '-DPPPD_PATH="/usr/sbin/pppd"' 
           '-DPPPOE_SERVER_OPTIONS="/etc/ppp/pppoe-server-options"' '-DVERSION="2.3"' -c -o pppoe-server.o pppoe-server.c
gcc -g -O2 -Wall -Wstrict-prototypes -ansi -pedantic  '-DPPPOE_PATH="/usr/sbin/pppoe"' '-DPPPD_PATH="/usr/sbin/pppd"' 
                    '-DPPPOE_SERVER_OPTIONS="/etc/ppp/pppoe-server-options"' '-DVERSION="2.3"' -c -o md5.o md5.c
gcc -o pppoe-server pppoe-server.o if.o debug.o common.o md5.o
gcc -g -O2 -Wall -Wstrict-prototypes -ansi -pedantic  '-DPPPOE_PATH="/usr/sbin/pppoe"' '-DPPPD_PATH="/usr/sbin/pppd"' 
             '-DPPPOE_SERVER_OPTIONS="/etc/ppp/pppoe-server-options"' '-DVERSION="2.3"' -c -o pppoe-sniff.o pppoe-sniff.c
gcc -o pppoe-sniff pppoe-sniff.o if.o common.o

Type 'make install' as root to install the software.
yoko:/usr/src/local/rp-pppoe-2.3# make install
mkdir -p /usr/sbin
/usr/bin/install -c -m 755 -s pppoe /usr/sbin
/usr/bin/install -c -m 755 -s pppoe-server /usr/sbin
/usr/bin/install -c -m 755 -s pppoe-sniff /usr/sbin
/usr/bin/install -c -m 755 adsl-connect adsl-start adsl-status adsl-stop adsl-setup /usr/sbin
mkdir -p /usr/doc/rp-pppoe-2.3
/usr/bin/install -c -m 644 CHANGES HOW-TO-CONNECT LICENSE README firewall pap-secrets adsl-state.pl /usr/doc/rp-pppoe-2.3
mkdir -p /usr/man/man8
/usr/bin/install -c -m 644 pppoe.8 adsl-start.8 adsl-stop.8 adsl-status.8 adsl-connect.8 adsl-setup.8 pppoe-server.8 pppoe-sniff.8 /usr/man/man8
mkdir -p /usr/man/man5
/usr/bin/install -c -m 644 pppoe.conf.5 /usr/man/man5
mkdir -p /etc/ppp
NOT overwriting existing /etc/ppp/pppoe.conf
NOT overwriting existing /etc/ppp/firewall-standalone
NOT overwriting existing /etc/ppp/firewall-masq
/usr/bin/install -c -m 644 pppoe-server-options /etc/ppp/pppoe-server-options

Type 'adsl-setup' to configure the software.
yoko:/usr/src/local/rp-pppoe-2.3#
Adsl-setup will ask you some questions, the answers below are for my 1 month test period with skynet:
yoko:/usr/src/local/rp-pppoe-2.3# adsl-setup
Welcome to the Roaring Penguin ADSL client setup.  First, I will run
some checks on your system to make sure the PPPoE client is installed
properly...

Looks good!  Now, please enter some information:

USER NAME

>>> Enter your PPPoE user name (default bxxxnxnx@sympatico.ca): bk235187@SKYNET

INTERFACE

>>> Enter the Ethernet interface connected to the ADSL modem
For Solaris, this is likely to be something like /dev/hme0.
For Linux, it will be ethn, where 'n' is a number.
(default eth1): eth1

Do you want the link to come up on demand, or stay up continuously?
If you want it to come up on demand, enter the idle time in seconds
after which the link should be dropped.  If you want the link to
stay up permanently, enter 'no' (two letters, lower-case.)
NOTE: Demand-activated links do not interact well with dynamic IP
addresses.  You may have some problems with demand-activated links.
>>> Enter the demand value (default no): no

DNS

Please enter the IP address of your ISP's primary DNS server.
If your ISP claims that 'the server will provide DNS addresses',
enter 'server' (all lower-case) here.
If you just press enter, I will assume you know what you are
doing and not modify your DNS setup.
>>> Enter the DNS information here: server

PASSWORD

>>> Please enter your PPPoE password:
>>> Please re-enter your PPPoE password:

FIREWALLING

Please choose the firewall rules to use.  Note that these rules are
very basic.  You are strongly encouraged to use a more sophisticated
firewall setup; however, these will provide basic security.  If you
are running any servers on your machine, you must choose 'NONE' and
set up firewalling yourself.  Otherwise, the firewall rules will deny
access to all standard servers like Web, e-mail, ftp, etc.  If you
are using SSH, the rules will block outgoing SSH connections which
allocate a privileged source port.

The firewall choices are:
0 - NONE: This script will not set any firewall rules.  You are responsible
          for ensuring the security of your machine.  You are STRONGLY
          recommended to use some kind of firewall rules.
1 - STANDALONE: Appropriate for a basic stand-alone web-surfing workstation
2 - MASQUERADE: Appropriate for a machine acting as an Internet gateway
                for a LAN
>>> Choose a type of firewall (0-2): 0

** Summary of what you entered **

Ethernet Interface: eth1
User name:          bk235187@SKYNET
Activate-on-demand: No
DNS addresses:      Supplied by ISP's server
Firewalling:        NONE

>>> Accept these settings and adjust configuration files (y/n)? y
Adjusting /etc/ppp/pppoe.conf
Adjusting /etc/ppp/pap-secrets and /etc/ppp/chap-secrets
  (But first backing it up to /etc/ppp/pap-secrets-bak)
  (But first backing it up to /etc/ppp/chap-secrets-bak)



Congratulations, it should be all set up!

Type 'adsl-start' to bring up your ADSL link and 'adsl-stop' to bring
it down.  Type 'adsl-status' to see the link status.
yoko:/usr/src/local/rp-pppoe-2.3#
Some remarks:


Test your setup

 yoko:/usr/src/local/rp-pppoe-2.3# adsl-start
. Connected!
yoko:/usr/src/local/rp-pppoe-2.3# ping mailrelay.cs.kuleuven.ac.be
PING mailrelay.cs.kuleuven.ac.be (134.58.40.3): 56 data bytes
64 bytes from 134.58.40.3: icmp_seq=0 ttl=243 time=30.6 ms
64 bytes from 134.58.40.3: icmp_seq=1 ttl=243 time=26.8 ms

--- mailrelay.cs.kuleuven.ac.be ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max = 26.8/28.7/30.6 ms
yoko:/usr/src/local/rp-pppoe-2.3# ssh snoopy.cs.kuleuven.ac.be
....
yoko:/usr/src/local/rp-pppoe-2.3# adsl-stop
Killing adsl-connect (3317)
Killing pppd (3326)
Remarks:

Setting up your firewall


Done but not yet documented