Help setting up Internet connection sharing

Discussion in 'Linux, BSD and Other OS's' started by sabashuali, Feb 6, 2006.

  1. sabashuali

    sabashuali Ani Ma'amin

    Likes Received:
    6
    Trophy Points:
    38
    Hi all

    I hope someone can help me here (well... I am sure you can!)
    I have mandriva running on the host PC which is connected via ADSL modem to the internet.

    The laptop I am trying to cennect to the host is running Ubuntu 5.10.
    I have run through the configuration in Mandriva but not sure what it is I need to do with the Ubuntu machine....

    Any help will be greatly appreciated.

    Thanks!

    Update - I just realised that I was using a direct cable connection (ethernet) without using a loopback cable.
    So I need to get a loopback cable or a network hub......
    Try again tomorrow....
     
  2. Anti-Trend

    Anti-Trend Nonconformist Geek

    Likes Received:
    118
    Trophy Points:
    63
    I'm not sure I understand. Are you saying that you want to use your Mandriva system as a NAT gateway, or that you want to connect the Ubuntu system directly to the ADSL modem (called an ATU not a modem, actually)?
     
  3. sabashuali

    sabashuali Ani Ma'amin

    Likes Received:
    6
    Trophy Points:
    38
    I think this is what I am trying to do....
    Sorry if I sound a bit unsure... first time for me....
     
  4. Anti-Trend

    Anti-Trend Nonconformist Geek

    Likes Received:
    118
    Trophy Points:
    63
    First let me get off my chest that it's always better to have a headless system dedicated just to acting as your edge router/firewall, so this is not an ideal situation. But at least your router will be a Linux box, so it could be a lot worse! :)

    OK, the first thing you'll need is two network cards for your edge system; one for your LAN, one for the WAN. You'll also need a switch with which to connet the other systems on your LAN. With Mandriva, the rest is pretty easy. Just run Mandriva Control Center:
    Code:
    mcc
    ...go to the "Network and Internet" section, and "Share the Internet connection with other local machines". That should pretty much walk you through the whole process. The only difficulty after that will be if you've done away with the default firewall, you'll have to make the appropriate changes to whichever firewall interface you're using. For instance, Firestarter has an option specifically to enable your system to act as a router.
     
  5. sabashuali

    sabashuali Ani Ma'amin

    Likes Received:
    6
    Trophy Points:
    38
    Point taken but unfortunately this is the best, immidiate solution I can afford...


    From that I understand that one card will form the connection to the internet and one will create the connection to the other computer. How am I doing so far? ;)
    Just to confirm that my host PC is connected to the net via a USB adsl modem.
    And I have an onboard (enabled) ethernet port. My Mandriva installation has got Shorewall on it. I dare not try and remove it as it seem to function OK and last time I just could not get rid of it or make it work. So I would prefer to leave as is.... long story.......


    I only have one more laptop which I want to connect to my host PC. It also has an ethernet port. However, I remember a freind once telling me that you cannot just connect the two using one standard ethernet cable. He mentioned either using (I am sure that's what he called it) a 'loopback' cable or using a network hub. I can probably get hold of either... I would prefer to use a single cable as my current set-up already resembles a 'comms room'..... what do you recon?


    As I said, that bit is already done and was very easy to do. However, will I need to redo all this when I finally connect the second compuetr properly? Or can you do it regardless of a 'live' connection? I think I'm asking whether you can do all the configuration even if you are not connected to another PC. Or do you have to make sure both computers are truely 'seeing' each other before attempting to configure?

    [ot] Are we spilling over to Networking and Security? If so please move to the right section[/ot]

    Thanks AT :cool:
     
  6. Anti-Trend

    Anti-Trend Nonconformist Geek

    Likes Received:
    118
    Trophy Points:
    63
    It's called a crossover cable, and you only need one if you're connecting two ethernet cards directly with no switch. As I said earlier, if you want to connect multiple machines to the gateway PC simultaneously, you will need a switch to connect them all, and in that case you will not need crossovers. A switch is basically a better hub, which will act as a central point for your network. If you don't have a switch bite the bullet and purchase one, you'll need it eventually anyway and they don't cost much. I've noticed that switches in metal chassis last longer if this helps your decision.
    [ot]
    Yes we are, but the implementation is on Linux, so either category is acceptible. :)[/ot]
     
  7. sabashuali

    sabashuali Ani Ma'amin

    Likes Received:
    6
    Trophy Points:
    38
    Thanks AT for the info.

    Yes, you are right, a switch is indeed the way forward.

    Many thanks for all the info. I am going to start off with the crossover cable and when possible, will get a hub or switch. Thanks for the tip regarding the type...
     

Share This Page