BTinternet pppd mini-HOWTO

Matt Wright

Matt Wright Consulting

            matt@consultmatt.co.uk
         

Greg Ferguson - Converted the mini-HOWTO from HTML to Docbook 3.1 (SGML).

2002-03-26

Revision History
Revision v0.292002-03-26Revised by: mww
Added a small bit of first-hand tech support about cross-frequency.
Revision v0.282002-01-17Revised by: mww
New information about PPPoATM involving kernels and distibutions.
Revision v0.272001-12-20Revised by: mww
Minor technical problems highlighted by Robert Smith.
Revision v0.262001-11-21Revised by: mww
Added a point about the Kernel HOWTO.
Revision v0.252001-11-17Revised by: mww
Added a troubleshooting answer about "_mmx_memcpy". Other minor updates as well.
Revision v0.242001-11-09Revised by: mww
Technical detail with the chatscript timeout (and found a spelling mistake or two!). Thanks again to Bill Staehle.
Revision v0.232001-11-07Revised by: mww
Changed the Chatscript dialing method, thanks go to TonyC from btinternet.linux newsgroup.
Revision v0.222001-11-06Revised by: mww
Changed a couple more little botches. Thanks again go to Bill Staehle.
Revision v0.212001-11-03Revised by: mww
Changed discrepancies reported by Bill Staehle.
Revision v0.202001-11-01Revised by: mww
Added Alcatel Speedtouch Information.
Revision v0.192001-10-31Revised by: mww
Initial public release.

Table of Contents
1. Introduction
1.1. Copyright and License
1.2. Mailing Lists
1.3. About the author
1.4. Acknowledgements
2. Requirements
3. Surftime
3.1. PPPd Setup
3.2. Chatscript (Dialup)
3.3. Authentication
3.4. Setting your global options
3.5. Testing your link
3.6. Dialing scripts
4. BTi Anytime
5. BTOpenworld Home 500 (Alcatel Speedtouch USB)
5.1. About this section
5.2. Warning
5.3. Distribution Specific Information
5.4. Requirements
5.5. Software Downloads
5.6. Patching your kernel
5.7. Kernel Drivers and Software
5.8. PPPd Configuration
5.9. Testing your link
6. Simple IP Masquerading
7. Troubleshooting
7.1. Help! Lynx gives unable to access document
7.2. My kernel < 2.4.2 crashes using the Alcatel driver
7.3. PPPd crashes when it loads the PPPoATM module
7.4. insmod speedtch.o gives: "Unresolved symbol: _mmx_memcpy"
7.5. There are strange noises on the telephone line when I pick up the phone.
8. Further Reading

1. Introduction

This HOWTO exists because a mate of mine needed to easily set up an Internet connection to BTinternet and here is a quick and concise way to get a running PPPd to Btinternet. This HOWTO also briefly covers Howto setup basic IP Masquerading to allow connection sharing.


1.2. Mailing Lists

Please note: There is a mailing list available for this howto. If you wish to join please email with the body:

subscribe bti-howto

This will then be followed up by the mailing list bot and subsequent emails should arrive confirming your request. The list is intended to be for annoucing changes to this HOWTO and also to dicuss the finer points of getting pppd to work on BTinternet.


2. Requirements

The following is needed to use this HOWTO:


3. Surftime


4. BTi Anytime

I'm sorry, for all you Anytime customers its really hard! NOT! Read all the instructions for Surftime above. They all apply in most places, the only things to watch out for is you obviously don't need any of the Surftime/daytime distinctions. So only have one peers file (using the correct phoen number) and one dialup option in your /usr/bin/internet file. (eg. dial and off)


5. BTOpenworld Home 500 (Alcatel Speedtouch USB)

5.1. About this section

There is rather a large amount of credit due here, to Chris Jones for writing the Alcatel Speedtouch USB ASDL Modem mini-HOWTO that is now part of the DSL HOWTO. This helped me a great deal when trying to get my Speedtouch to work.


5.4. Requirements

To get your Speedtouch USB working in Linux you have a fairly heavyweight task ahead of you, but hey, if I could do it so can you! This is what you'll need to get it working:

  • You must have the kernel source installed and know the procedure for installing and compiling a new kernel. If this is a problem then read the Kernel HOWTO.

  • You must be running one of the following Kernels: 2.3.39, 2.4.0-test4, 2.4.1-pre7, 2.4.7, 2.4.8-pre5. This is because the PPPoATM patch for the kernel exists patched against specific kernels, some may work with similar kernel versions but I cannot vouch for that

  • You, obviously, need a USB controller of some description with at least one free plug. It also must be Linux compatible, nowadays this is most USB controllers that are UHCI/OHCI based. If you don't have one your local supplier would probably have a PCI USB Controller.

  • A heap-load of confidence with meddling with your config. eg: kernel recompiling, program installation...


5.5. Software Downloads

To get the Speedtouch working under Linux you will need some software and kernel patches found below:


5.6. Patching your kernel

Once you have the PPPoATM kernel patch (this assumes you use the patch against kernel 2.4.7) you need to make sure you have a working 2.4.7 kernel tree, next unzip the PPPoATM patch by doing:

NOTE: From rougly kernel 2.4.16 (I haven't tested to see hwo far back it goes) the PPPoATM patch is included in Linus' main kernel tree, therefore you may skip the patching below and resume ready to configure the kernel.

gzip -d pppoatm-2.zip

Next we will need to test-patch the kernel using the following commands:

patch -p1 -s -E --dry-run < /point/to/pppoatm-2

If that ran without failure then patch the kernel by removing the --dry-run as such:

patch -p1 -s -E < /point/to/pppoatm-2

That should have patched the kernel good-and-proper so we can go ahead and configure it, make sure the following options are selected along with your personal build options:

You could select any of these as modules or compiled-in but as I followed Chris Jones' HOWTO I compiled the all but UHCI/OHCI as compiled-in code. Save the kernel config and compile the kernel and modules as you normally do.


6. Simple IP Masquerading

To allow sharing of your internet conenction you can eitehr use a proxy server or IP Masquerading. I'll cover IP Masquerding as it's simple to set up on the other client machines. I use a 2.4.x generation kernel and in effect I use IPTables. If you use a 2.2.x or 2.0.x kernel then you need the IP Masquerading HOWTO.

This part of the HOWTO assumes that your Netfilter software is modularised, if it isnt then no big deal, either ignore the modprobe lines or recompile your kernel.

Simple now, just run the commands:

modprobe iptable_nat

iptables -t nat -F POSTROUTING

iptables -t nat -A POSTROUTING -o ppp0 -s 10.0.0.0/16 -j MASQUERADE

echo 1 > /proc/sys/net/ipv4/ip_forward

Note: The space between 1 and > is vital. It seems not to activate the IP Forwarding if the space is not there.

Change the ppp0 and/or the 10.0.0.0/16 for your relevant network settings and put that file either before the case "$1" in in the internet file or somewhere in your startup.


7. Troubleshooting


8. Further Reading

For further reading on related topics see this list: