Find the answer to your Linux question:
Results 1 to 5 of 5
Hello, all. Great resource you have here. I'm a newbie to Linux, although I was fairly good at Windows. I like Linux a lot, but I can't get internet to ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    jhk
    jhk is offline
    Just Joined!
    Join Date
    May 2004
    Posts
    7

    Connecting a USB cable modem to Linux??


    Hello, all. Great resource you have here.

    I'm a newbie to Linux, although I was fairly good at Windows. I like Linux a lot, but I can't get internet to work with my Linux box. I use a cable modem that has ethernet and USB, but my Linux box doesn't have a networking card and my Windows box uses the Ethernet cable anyway, so I have to use the USB connection on the Linux machine.

    However, I can't get it to work! I use Mandrake 9.2 and I've tried the connectdrake software. It twiddled a bit and tried installing drivers but didn't work. I've seen this post
    http://www.linuxforums.org/forum/viewtopic.php?t=15028

    but it rather confused me. Can somebody explain exactly what I need to configure in order to get Linux to talk to my modem?

    thanks

    -JHK

  2. #2
    Linux Enthusiast
    Join Date
    Apr 2004
    Location
    UK
    Posts
    682

    Re: Connecting a USB cable modem to Linux??

    From your post it seems that you want to connect your windows pc to the ethernet socket on your modem and the linux computer to the usb socket. Unless your modem is designed to do so, these will not work at the same time. One at a time will probably be OK, but you may need to switch off the PC you are not using.

    How far did you get with setting it up, and where are you confused?
    Connectdrake isn't able to find the connection so you will have to set it up by hand but I can help you with that if you need.

    What you need to configure depends on the settings your ISP gave you. If the connection uses DHCP (dynamic IP) then you just need to set up the USBNET device to use DHCP and it will work everything else out on it's own. If you get a static IP then you will need to set up the USBNET device to use it and put your ISP's DNS servers into /etc/resolve.conf.

    Also, is there anything specific about your ISP? For instance, Blueyonder requires you to register the MAC address of your network device before they will allow it to work.

    Lots of questions and not much help I know, but we need to know more before we can help you properly.

    Chris...

  3. #3
    jhk
    jhk is offline
    Just Joined!
    Join Date
    May 2004
    Posts
    7
    Hello, thanks for the response.

    My cable modem's manual says that it is possible to connect two seperate PCs tot he modem at the same time by using ethernet and USB cables, so I don't think that's an issue. Connectdrake told me I had a USB device connected, but it searched for drivers and couldn't find any.

    I think I'm using DHCP... windows gives me a location for my DHCP server if I run winipcfg, at any rate. So what do I need to do to configure it manually?

    I use Comcast cable, and I don't think it has any specific issues.

    -JHK

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Enthusiast
    Join Date
    Apr 2004
    Location
    UK
    Posts
    682

    Re: Connecting a USB cable modem to Linux??

    Drivers should be fairly easy. First of all you need to get a list of current network devices. As root:

    ifconfig -a

    Then load the modem drivers. It strikes me that I should have asked what model of modem you used, but we will continue along this track because nothing we are doing at the moment is permanent and it can't damage anything. Again as root:

    modprobe CDCEther
    modprobe usbnet


    CDCEther allows you to connect to the modem, and usbnet creates network device to communicate over this connection. Check that these have worked by going

    ifconfig -a

    again and checking that the new device has appeared (shoud be "eth" followed by a number). Take a note of the device's name, we will need it in a minute.

    Next you need to configure this device to use DHCP. The settings for this device are stored in the file /etc/sysconfig/network-scripts/ifcfg-<device name you noted earlier>. You will probably need to create this file yourself. It should contain the following:

    DEVICE=<device name you noted earlier>
    BOOTPROTO=dhcp
    ONBOOT=yes


    That should be the configuration complete, issue the following commands to start the new network device:

    ifdown <device name>
    ifup <device name>


    Try pinging a website. There are a few things that can happen at this stage. If you get an error saying unknown host, check that the firewall is clear and that there are suitable nameserver entries in /etc/resolv.conf. If there are no nameserver entries in resolv.conf, they can be added simply by entering the DNS settings from the windows PC. Entries should look like:

    nameserver <ip address of DNS server>

    If anything goes wrong, could you reply with the error, the output of ifconfig -a (remember to put Xs over the last part of any routable IP), the output of lsmod, any messages in dmesg that relate to CDCEther or usbnet, and the make and model of your modem.

    On the other hand, if it works, it is simple to make these settings permanent by putting CDCEther and usbnet on seperate lines in /etc/modules. All of the rest of the settings are already in place.

    Hope this helps,

    Chris...

  6. #5
    jhk
    jhk is offline
    Just Joined!
    Join Date
    May 2004
    Posts
    7
    Thanks! That worked, and it was pretty easy as well. Thanks!

    -JHK

Posting Permissions

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