Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have an 3.5G USB Modem that I want to share its internet connection in Linux. I tried already, but only got having no internet on my own PC, still without sharing it.

It's really hard to find some documentation about this and the producer doesn't give support for Linux :(

My modem is from ZTE company, model MF622.

share|improve this question
    
Your question is difficult to understand. Consider rewriting it. –  Nathan Powell Jul 10 '10 at 12:37
    
Can you mention which Linux distribution you are using ? –  proy Jul 10 '10 at 18:34
    
I'm using Mandriva, but I appreciate something generic, like we most do on Unix. –  Ricardo Jul 10 '10 at 19:03
    
> "...I tried already, but only got having no internet on my own PC" Please give more detailed description the problem: 1) you "own PC" is running Windows or Linux; 2) how way the boxes connected each other(wireless or wired cable connection); 3) how the network is configured(manual IP configuration, DHCP, interfaces configuration); 4) is both boxes interacts via network as well; 5) your modem is configured proper, have you internet connection there? –  Ivan Chuchman Jul 11 '10 at 8:35

4 Answers 4

You've been spending too much time in the world of Microsoft - where connecting more computers to a network somehow requires extra software.

Since its a USB internet connection, that rather implies that the hardware only supports one computer connection at a time - but most operating systems provide routing support - if configured, they will choose the right interface to forward packets on.

The complication with this is that for domestic internet connections, the service provider usually only assigns a single IP address for your use. So the router has to rewrite the addressing information on the packets. This is generally referred to as NAT (network address translation) or, in the case where a network is exposed as if it were a single host, masquerading. Have a google for (the Linux distribution you use, e.g. Ubuntu) + masquerade

Assuming the internet connection works OK on your Linux box, then the actual hardware / upstream provision is irrelevant.

Note that you can buy masquerading routers off the shelf for less than 50 USD these days - if you're uncomfortable with the idea of tweaking your system this can be a simpler route.

C.

share|improve this answer
    
Agreed, the only thing missing is a link to the netfilter documentation: netfilter.org/documentation/HOWTO//NAT-HOWTO-4.html#ss4.1 which explains how to configure NAT/IP Maquerading. –  basvdlei Jul 12 '10 at 12:11

If you have ubuntu you can try this :

http://www.ubuntugeek.com/sharing-internet-connection-in-ubuntu.html

share|improve this answer

Important is to know your Linux distribution, not your modem model.

Solution for OpenSUSE is here.

share|improve this answer

The link provided by aleroot is quiet good. Alternatively you can use a front end for iptables(firewall for linux) like shorewall by which configuring iptables is made easier for you. One you install the showrewall package just follow this link http://www.shorewall.net/two-interface.htm

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.