Find the answer to your Linux question:
Results 1 to 5 of 5
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    Sharing connection Linux Windows

    I tried to connet my pc (S.O. Lunux Slackeware) to internet using as a gateway another pc with Windows Xp.The second one is connet to the net with a Cable modem.

    I configurated my net card (eth0) with ifconfig but an error occured when i tried to config the netmask.
    Then when i tried to ping the gateway or another ip the return was
    Net unreacheable.

    Ther is a solution to thid problem thanks.

  2. #2
    Linux Engineer Nerderello's Avatar
    Join Date
    Apr 2003
    North East England
    can I just confirm that this is the setup :-

    Linux PC -- Ethernet-- WinXP PC -- Cabel Modem-- Internet

    If so, you have two TCP/IP networks. One is an ethernet network with both PCs as the only hosts, while the other has your WinXP and a router (possiblly the cable modem or possibly the ISP's gateway router). Each of the networks will have a different network address. The local network (Linux - WinXP) can have any TCP/IP address you like to give it. The other will have addresses set by your ISP.

    You WinXP PC will have to act as a router (don't know WinXP so can't tell youi how or even if this is possible). It will have to receive packets from Linux and pass them to your ISP. This means that your ISP will have to be told that there is another network "behind" your WinXP PC. Don't know how this is done, suggest that you talk to your ISP.


    Use Suse 10.1 and occasionally play with Kubuntu
    Also have Windows 98SE and BeOS

  3. #3
    Just Joined!
    Join Date
    May 2004
    For this configuration to work, your cable modem must be an ethernet modem as usually the USB one don't work well in internet connection sharing scenarios (but am not 100% sure about this one).

    You have to plug the modem in your Windows XP box and then enable internet connection sharing on that box (this one is pretty easy and can be done through a wizard). In windows, internet connection sharing automatically enables the DHCP service.

    On your linux box, which will be connected to the other network interface of the windows box, all you have to do is set its network adapter to be automatically configured using DHCP.

    Hope this helped.


  4. $spacer_open
  5. #4
    At the startup i recieved a message like

    DHCP brocasting recieved

    So if i enable on my pc the DHCP it sould work but ,how can i do that?


    yes the second machine is connect with a ethernet bus to the modem

    thanks for everything

  6. #5
    Just Joined!
    Join Date
    May 2004
    Edit the file "/etc/sysconfig/network-scripts/ifcfg-eth0" (if the network adapter you are trying to configure is not eth0, then change the file name accordingly). You should be root to do this.

    Then in this file make sure that you have the following two lines:
    If any one of them is missing, add them and reboot.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts