LINUX.IE, website of the Irish Linux Users' Group
Tux rules!

   
Home
New Users
Articles
::In The News
::Industry
::Interviews
::Reviews
::Tips
::Tutorials
Download
Projects
Community
Vendors

  Print Version
Email to...
 
Archives:


planetILUG

Recent News

News Archive


Join the
ILUG
on FaceBook


Join the
ILUG
on LinkedIn


Join the
ILUG SETI
Group



















 
 :: Articles :: Tutorials :: ADSL HowTo

By Declan McMullen

This tutorial is written for anyone who wishes to use Eircom I-Stream with the SpeedTouch USB Modem
from Alcatel.

I got this to work on Debian 3.0 with a 2.4.18 kernel.
So please note that all later 2.4.X kernels now come with bridging/pppoe support and the alcatel speedtouch usb modem driver all built in to the kernel. As such the patching of the kernel and compiling of the speedtouch module as mentioned in the tutorial are no longer a necessary step.
Before we begin here are the packages you will need to get this working.

For The Hardware:

The speedmgmt application from Alcatel; http://www.speedtouchdsl.com
The Open Source Kernel Module written and maintained by John Verrept; http://linux-usb.sourceforge.net/SpeedTouch
The SARLib; http://sarlib.sourceforge.net
A linux kernel, 2.4.2 or above.; http://ftp.kernel.org/pub/linux/kernel/v2.4

For PPPoE:

A PPPoE aware daemon; http://skyhawk.redbrick.dcu.ie/Adsl/ppp-2.4.0-pppoe4.tgz

The RFC2684 Bridging kernel patch and configuration utility
http://skyhawk.redbrick.dcu.ie/Adsl/br2684-against2.4.17.diff
http://skyhawk.redbrick.dcu.ie/Adsl/brctl-010226.c

The versions I used of these packages are available here

Firstly you must patch the kernel:

Change to the directory where you will be untarring the kernel
cd /usr/src

Untar the kernel source:

tar zxvf linux-2.4.x.tar.gz

Your source may be in .tar.bz2 format
If so do this

bunzip2 linux-2.4.x.tar.bz2
tar xvf linux-2.4.x.tar

Now to apply the PPPoE patch:

cd /usr/src/linux
patch -p1 -s -E < /pathTo/br2684-against2.4.17.diff

Now you must configure the kernel:
choose your preferred kernel config program
e.g make menuconfig, make xconfig

The Following options must be set for the adsl to work:

Code Maturity Level Options
Prompt for development and/or incomplete code/drivers [Y]

Loadable Module Support
Enable Loadable Module Support [Y]

Processor type and features
Symmetric multi-processing support [N]

Networking Options
Packet Socket [Y]
Asynchronus Transfer Mode (ATM) (EXPERIMENTAL) [Y]
RFC 1482/2684 Bridged protocols [Y]

Network Device Support
PPP (Point-to-Point Protocol) Support [Y]
PPP Deflate Compression [Y]
PPP over Ethernet (EXPERIMENTAL)

USB Support
Support for USB [Y]
Preliminary USB Device Filesystem [Y]
UHCI (Intel PIIX4, VIA,...) Support [M]
OHCI (Compag, iMacs, Opti, SiS, Ali,...) support [M]


NOTE:These are merely the options needed to get the adsl functioning
Don't forget to select the other modules needed for your systems
correct operation.

Once your selections have been made save your new kernel configuration
and compile your new kernel.

make dep
make bzImage
make modules
make modules_install
make install

If all goes to plan you should now have a new kernel.
Reboot for the changes to take effect.

On reboot type uname -a to verify the new kernel version.


Next the Speedtouch module must be compiled:
Untar and build the SARLib:

tar xvzf sarlib-0.2.x.tgz
ln -s sarlib-0.2.x sarlib
cd sarlib
make

Now the SpeedTouch module:

tar xvzf speedtouch-1.x.tar.gz
cd SpeedTouch
make
make install

You should now have the required kernel module.

Next we need to install the Binary Management Application:

tar xvzf speedmgmt-1.x.gz
cd mgmt
cp speedmgmt /usr/sbin

DO NOT compile these files, we only need the firmware application itself.

Next you need to install PPPoE support:
Firstly the ATM Package:

tar xvzf atm-0.78.tar.gz
cd atm
make
make install

Next compile the br2684 utility

cc -o br2684ctl brctl-010226.c -latm
cp br2684ctl /usr/sbin

Lastly install the PPPoE daemon:

tar xvzf ppp-2.4.0-pppoe4.tgz
cd ppp-2.4.0.pppoe4
./configure
make
make install

That completes the installation of the required packages.
Now all thats left is to configure the system.

Configuring the usb system
Add this line to /etc/fstab

/dev/usb /proc/bus/usb usbdevfs defaults 0 0

This will mount your usb filesystem at boot-time

Configuring PPPoE

Edit your /etc/ppp/options file and replace it with:
lock
defaultroute
noipdefault
noauth
passive
asyncmap 0
name yourIstreamName@eircom.net
user yourIstreamName@eircom.net
lcp-echo-interval 2
lcp-echo-failure 7
plugin /usr/lib/pppd/plugins/pppoe.so
nas0

Next edit /etc/ppp/chap-secrets and /etc/ppp/pap-secrets and add the following
"yourIstreamName@eircom.net" * "yourIstreamPass"


And finally testing the system:

Make sure your usb modules and speedtouch modules are active
type modconf
go to /kernel/drivers/usb
and select the speedtch module and your required usb module/s
Verify the modules have taken by typing lsmod.

Now the moment of truth
Firstly bring up the Ethernet bridge

br2684ctl -b -c 0 -a 8.35
Next bring up the nas0 interface

ifconfig nas0 up
Now initialise the modem with the binary application
speedmgmt
And lastly initialise your ppp daemon
pppd

IF all goes well you should see the following in /var/log/syslog


pulsar pppd[245]: Plugin /usr/lib/pppd/plugins/pppoe.so loaded.
pulsar pppd[245]: PPPoE Plugin Initialized
pulsar pppd[246]: pppd 2.4.0 started by root, uid 0
pulsar pppd[246]: Sending PADI
pulsar pppd[246]: HOST_UNIQ successful match
pulsar pppd[246]: HOST_UNIQ successful match
pulsar pppd[246]: Got connection: f41
pulsar pppd[246]: Connecting PPPoE socket: 00:02:3b:01:de:88 410f nas0
pulsar pppd[246]: Using interface ppp0
pulsar pppd[246]: Connect: ppp0 <--> nas0
pulsar pppd[246]: Remote message: CHAP authentication success, unit 38
pulsar pppd[246]: local IP address 159.134.96.31
pulsar pppd[246]: remote IP address 159.134.96.1

CONGRATULATIONS your adsl line is working.

There are a lot of ways in which things can go wrong whilst attempting this.
It took me countless recompiles and reboots to finally get it going.
If you are having problems feel free to drop me a mail and hopefully
it's an error that I may have come across during my ordeal in getting this
working.



About the author, Declan McMullen.

USERS COMMENTS


                                                                                                    

 

Hosted by HEAnet


Maintained by the ILUG website team. The aim of Linux.ie is to support and help commercial and private users of Linux in Ireland. You can display ILUG news in your own webpages, read backend information to find out how. Networking services kindly provided by HEAnet, server kindly donated by Dell. Linux is a trademark of Linus Torvalds, used with permission. No penguins were harmed in the production or maintenance of this highly praised website. Looking for the Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!
RSS Version
Powered by Dell