I have run this script on my desktop - AMD Sempron 3100+ 1.84GHz 1Gig Ram running Ubuntu Breezy Badger 5.10 and currently on my IBM Thinkpads T30 P4 Mobile 1.8GHz 512Mb Ram running BB 5.10 - no problems.
SpeedTouch USB ADSL Modem HowTo for Ubuntu 5.10 Breezy Badger (UK)
--------------------------------------------------------------------
Requirements for the U.K. only!
NOTE: This script should work on any computer that uses the Silver adsl SpeedTouch 330 usb modem and OS Ubuntu 5.10 Breezy Badger.I have installed it and use it currently on both my IBM T30 Thinkpads - Model No.s 2366 - GG1 (without touchpad) and 2366 - G85 (with touchpad).
Print a copy of this HowTo or have it visible on another machine that doesn't require an internet connection. Else save it and transfer it onto your ubuntu machine.
If you're a newbie, it would also be a good idea to print a copy of basic questions and commands (if you don't have a book) that will speed up your development. These are general to most linux distro's (distributions) and are available from - Download: http://www.linuxhelp.net/newbies/newbies-print.php
00 - SpeedTouch ADSL version 4 modem (Thomson / Alcatel)
0 - br2684ctl_20040226-1_i386.deb(I've added this to the list of requirements because when I tested this script on my new IBM T30 Thinkpad (with touchpad), it didn't work. I realised that maybe this file was missing, which it was because my modem connected after installing it and following the script again).
1 - libatm1_2.4.1-17_i386.deb
('libatm' is already packaged with Breezy Badger but you should re-install it to prevent any further frustrations. Newer versions will possibly supercede this, but this works) Download: http://packages.ubuntu.com/hoary/libs/libatm1
2 - speedtouch-firmware_0.3012k_all.deb
(Modem firmware that ensures your modem runs everytime you plug it in, switch your computer on or click to browse the internet.) Download: http://ftp.linux.it/pub/People/md/warez/speedtouch-firmware_0.3012k_all.deb
3 - speedtch.txt
(This script is necessary for hotplugging the modem ie: connecting / disconnecting when the usb plug to the modem is inserted / pulled out of the usb port [PlugandPlay].
Copy and save in Notepad everything between the lines as "speedtch.txt"
-------------------------------------------------------------------------------------
#!/bin/sh
# Script based on /etc/hotplug/usb/speedtouch from the speedtouch debian package.
# This package is not required with kernel 2.6.10, but without this little bit
# of its functionality, we would lose automatic connection on hotplugging the
# speedtouch modem (and immediate killing of the pppd on disconnection).
PATH=/sbin:/bin:/usr/sbin:/usr/bin
export PATH
# ignore device events
#[ "$PRODUCT" ] exit 0
# a PPP peer to call
PPPD_PEER="adslscript" # the name of a connection script in /etc/ppp/peers
# start the pppd process
pppd call $PPPD_PEER
#This will make sure that the pppd process is killed immediately if the
# modem is unplugged, thereby making everything ready for immediate reconnection
[ "$REMOVER" ] exit 0
{ echo "#!/bin/sh"
[ "$PPPD_PEER" ] && printf "poff $PPPD_PEER\nsleep 5\n"
} >> $REMOVER
chmod +x $REMOVER
exit 0
-------------------------------------------------------------------------------------
MAKE SURE YOU HAVE EVERYTHING PRINTED OR SAVED IN YOUR HOME DIRECTORY IN UBUNTU THAT YOU REQUIRE! IT IS SOMETIMES BETTER IF YOU HAVE THE HOWTO LOADED ON THE SAME SYSTEM SO YOU CAN JUST COPY AND PAST.
FINALLY MAKE SURE YOU HAVE AN INTERNET CONNECTION BUT DON'T PLUG YOUR USB MODEM IN JUST YET. YOU WILL BE PROMPTED TO DO THIS LATER.
Assuming you're already in Ubuntu - OPEN A TERMINAL (Application -> Accessories -> Terminal)
STEP 0: install the package 'br2684ctl_20040226-1_i386.deb'
CODE TO TYPE:
sudo su
dpkg -i br2684ctl_20040226-1_i386.deb
STEP 1: install the package 'libatm1_2.4.1-17_i386.deb'
CODE TO TYPE:
sudo su
dpkg -i libatm1_2.4.1-17_i386.deb
Step 2: install the modem firmware package 'speedtouch-firmware_0.3012k_all.deb'
CODE TO TYPE:
dpkg -i speedtouch-firmware_0.3012k_all.deb
Step 3: configure the software
You are now going to load the pppoatm module, and set up your machine so the pppoatm module is loaded at every boot - before you do this type 'exit' to get out of root ie: root@your username:/home/yourusername# exit
CODE TO TYPE:
sudo modprobe pppoatm
sudo gedit /etc/modules
Now we're going to create a pppd connection script to control logging on to your ISP:
CODE TO TYPE:
sudo cp /usr/share/doc/ppp/examples/peers-pppoe /etc/ppp/peers/adslscript
sudo gedit /etc/ppp/peers/adslscript
# user "myusername@myprovider.com"
to
user "your-own-isp-username"
below this you are going to replace a few lines (remember to include the blank line, up to eth0), which are:
# Load the pppoe plugin. plugin rp-pppoe.so
.........ethernet interface...........eth0
and replace with
CODE TO TYPE:
# These options configure pppd to talk with the kernelspace speedtch driver.
# Don't forget to adapt the VP.VC pair to your ISP/country settings.
# (see http://www.linux-usb.org/SpeedTouch/faq/index.html#q12)
plugin pppoatm.so
0.38 #UK
After this you should have the following:
# Assumes that your IP address is allocated dynamically by the ISP.noipdefault# Try to get the name server addresses from the ISP.usepeerdns# Use this connection as the default route.defaultroute
# Makes pppd "dial again" when the connection is lost.persist
# Do not ask the remote to authenticate.noauth
If you have the above, then there's nothing else to do here except save and exit the editor.
But, if you have the following towards the bottom, comment out (ie put a # at the beginning of the line):
noaccomp
and
default-asyncmap
After you have commented out the above lines, save and exit the editor.
Now you are going to set up your isp password:
CODE TO TYPE:
sudo gedit /etc/ppp/chap-secrets
your-isp-username * your-isp-password * (Note: there is a space between username, *, password and *)
Save file and close the editor.
CODE TO TYPE:
sudo gedit /etc/ppp/pap-secrets
Save file and close the editor. (Only one of these two files that you have just edited will be used by your ISP to connect, it just depends on the authentication method used by your ISP.)
Finally, setup the hotplug system to automatically connect when the modem is plugged in and at boot time:
CODE TO TYPE:
sudo cp /your/path/to/speedtch.txt /etc/hotplug/usb/speedtch
Now we are going to turn this script into an executable file
CODE TO TYPE:
sudo chmod +x /etc/hotplug/usb/speedtch
CODE TO TYPE:
tail -f /var/log/messages
usbcore: registered new driver speedtchspeedtch: loaded successfullyPlugin pppoatm.so loadedpppd 2.4.3 started...found stage 2 firmware...ExitExit
Using interface ppp0
Connect: ppp0 <--> 0.38ADSL line is synchronising
CHAP authentication succeeded
PPP...registered
PPP...registeredlocal IP address ......remote IP address ......primary DNS address ........secondary DNS address .......
ADSL line is up (2272 Kib/s down ¦ 288 Kib/s up)
CODE TO TYPE:
ctrl-c (to get out of the scrolling messages display).
You should now be connected to the internet.
NOTE: In other countries using PPPoA should work by changing the VPI/VCI numbers. To check what your VPI/VCI numbers are look at http://www.linux-usb.org/SpeedTouch/ubuntu/index.html.
3 comments:
Ali
Glad you found my script useful, you're right, the script isn't much different to the others you have tried but I feel it is more easy to understand. I'm not sure what system you're using but I only included step "0" as an insurance that everything was loaded that you might need, as was my case with my 2 slightly different T30's.
Will this work on my Xubuntu 8.04? I'm also not in the UK, but I use the same modem (Speedtouch 330 ADSL USB ).
Post a Comment