[YLUG] Getting three machines online at the same time using one mobile broadband dongle.

Seb James seb at esfnet.co.uk
Sat May 21 21:25:27 UTC 2011


On Fri, 2011-05-20 at 20:56 +0100, ALEX ARMANI wrote:
> Getting three machines online at the same time using one mobile
> broadband dongle.
> 
> 
> Hi all. I've recently moved to a house which doesn't have a landline,
> so I bought a 3 Mobile Broadband dongle as a temporary measure. 30 day
> contract 5 gigs a month for £15.99 (which is the same as I was paying
> madasafish in my last place, and amazingly, it gives about the same
> performance to! ~ 6.7 Mbps. ) and it works fine with Linux. BT have
> said that they would like to install a landline for me for £122.50, so
> I'm thinking to maybe I'll stay with 3, but how do I connect my 2
> towers to my laptop and have them all online at the same time?
> Laptop's running Windows 7 and Ubuntu, both towers running Ubuntu.
> Would my old wifi router be okay to do this? Also, all the machines
> have bluetooth, so maybe it would be easier to connect all 3 machines
> using bluetooth?

Hello Alex,

I set this up in such as way that I could plug a dongle into my little
"household gateway" machine (A little AMD Geode device running Debian)
and have it revert from routing via the landline adsl to using the 3G
modem.

I had udev call fireup_dongle and ppp0_route_setup when the usb dongle
was plugged in. fireup_dongle used wvdial to setup ppp0.

Attached are the scripts in case they're useful. I don't think it was
ever quite perfect (perhaps name resolution was a bit flaky - I forget
now), but if you're only using the modem, you won't need the complexity
of switching the routing.

On your own "household gateway" machine (I'd advise using the dongle in
one of the Ubuntu tower when you are using all 3 computers), you'll need
to make sure that ipv4 forwarding is switched on and that your iptables
rules are sensible. Also, you'll need to set up bind (or one of the
simpler DNS forwarders) for DNS resolution.

It might take more than 122 quids worth of your time...

Good luck!

best regards,

Seb James

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: bringdown_dongle
Type: application/x-shellscript
Size: 240 bytes
Desc: not available
URL: <http://mailman.lug.org.uk/pipermail/york/attachments/20110521/ae03fb99/attachment.bin>
-------------- next part --------------
#    BUS=="usb", SYSFS{idVendor}=="12d1", SYSFS{idProduct}=="1003",
ACTION=="add", \
    KERNEL=="ttyUSB1" \
    RUN+="/usr/local/bin/fireup_dongle"
#BUS=="usb", SYSFS{idVendor}=="12d1", SYSFS{idProduct}=="1003",
ACTION=="remove", \
    KERNEL=="ttyUSB1" \
    RUN+="/usr/local/bin/bringdown_dongle"

ACTION=="add", SUBSYSTEM=="net", KERNEL=="ppp0", \
    RUN+="/usr/local/bin/ppp0_route_setup"
ACTION=="remove", SUBSYSTEM=="net", KERNEL=="ppp0", \
    RUN+="/usr/local/bin/ppp0_route_revert"


-------------- next part --------------
# wvdial for Vodacom Data. Created by Tazz_tux
# Version 1.0

# Change Log:
#
# Added support for HSDPA.
# Added Headers and version control.

[Dialer Defaults]
Phone = *99***1#
Username = username
Password = password
Stupid Mode = 1
Dial Command = ATDT

[Dialer hsdpa]
Modem = /dev/ttyUSB0
Baud = 460800
Init2 = ATZ
Init3 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ISDN = 0
Modem Type = Analog Modem
Audo DNS = off

[Dialer hsdpaUSB1]
Modem = /dev/ttyUSB1
Baud = 460800
Init2 = ATZ
Init3 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
ISDN = 0
Modem Type = Analog Modem
Audo DNS = off
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fireup_dongle
Type: application/x-shellscript
Size: 352 bytes
Desc: not available
URL: <http://mailman.lug.org.uk/pipermail/york/attachments/20110521/ae03fb99/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ppp0_route_revert
Type: application/x-shellscript
Size: 464 bytes
Desc: not available
URL: <http://mailman.lug.org.uk/pipermail/york/attachments/20110521/ae03fb99/attachment-0002.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ppp0_route_setup
Type: application/x-shellscript
Size: 826 bytes
Desc: not available
URL: <http://mailman.lug.org.uk/pipermail/york/attachments/20110521/ae03fb99/attachment-0003.bin>


More information about the York mailing list