This is the old SliTaz forum - Please use the main forum.slitaz.org

[RESOLVED] PCMCIA Ethernet Adapter not Detected
  • JingJing April 2010
    I have recently installed Slitaz 3.0 on an old laptop and so far have not been able to make my eithernet adapter to work.

    The card is a Linksys EtherFast PCMCIA/CardBus PC Card, Model No: PCM100

    The leds on the card light up when the card is plugged in but I doubt it is really detected. Here is what I observed:

    1. When I click on the network connection icon on the right bottom corner of the desktop I get:
    Name: eith0
    Status: error
    2. Then I click the button to "Configure". Under "Connections' I only see "lo"
    3. The Linksys card is not listed from "lspci" command. I can only see two Card Bus bridge entries listed.

    I would appreciate it very much if someone can point me to the right direction how to solve the issue.

    Do I need to install certain driver for my ethernet adapter card? Since I cannot connect to internet with this laptop can I somehow download the driver using other computer and then transfer the driver to this laptop and run it? Sorry but I am new to linux.

  • erniaernia April 2010
    try
    modprobe pcnet_cs
  • JingJing April 2010
    Thanks.

    I tried the command and got nothing in return:

    #modprobe pcnet_cs
    #

    There is no error message but I guess it does not detect anyting? I tried "ifconfig eth0" after that and I got:

    ifconfig: eth0: error fetching interface information: Device not found

    Thanks again for your reply!
  • JingJing April 2010
    I tried "lsmod" and only related listings are:

    Module Size Used by
    pcnet_cs 33900 1
    pcmcia 28656 1 pcnet_cs

    ...

    pcmcia_core 27628 3 pcmcia, yanta_socket, rsrc_nonstatic

    I am not sure whether above info is useful to diagnose the problem. I am learning linux.
  • erniaernia April 2010
    don't worry :-)
    reboot, modprobe pcnet_cs, and post the output of following commands:
    dmesg | tail -30

    (this will give you the last 30 lines of dmesg http://unixhelp.ed.ac.uk/CGI/man-cgi?dmesg+8 )
    cat /proc/net/dev

    this will show you network intefaces even if they are not configured
  • JingJing April 2010
    Wow. That definitly helps. I did the "dmesg" command and noticed the following lines:

    eth0: NE2000 (DL10022 rev 05): io 0x300 , irq 3, hw_addr 00:04:5a:96:84:76
    udev: renamed network interface eth0 to eth1

    I do not fully comprehend what above messages mean but it seems like I should use "eth1" instead?

    I immedialty tried "ifconfig "eth1" and sure enough the card seems to be recoginized:

    eth1 Link encap: Ethernet HWaddr 00:04:5A:96:84:76
    BROADCAST MULTICAST MTU: 1500 Metric: 1
    ...

    Let me go ahead and try using eth1 now.
  • erniaernia April 2010
    if you put eth1 in INTERFACE variable in /etc/network.conf and give
    /etc/init.d/network.sh restart 
    you are done, unless udev keep changing device number, but it should not happen anymore
  • JingJing April 2010
    I am almost there! Thanks a lot.

    I tried your suggestion above and indeed I got the ethernet adapter to work and internet, for the first time!

    The problem is, after reboot, it seems what I have done is not "remembered" by the system and I had to issue those commands again.

    The "udev" keeps using "eth1". That's good. But unless I do a "modprobe pcnet_cs", "eth1" is not retected and of course network does not work.

    So after each reboot I have to first "modprobe pcnet_cs" and then "/etc/init.d/network.sh restart " to get network to work.

    I hope I can get everything automated soon.
  • JingJing April 2010
    I understand the system /etc/init.d/network.sh at startup. So I guess my question here is how to get the system to recognize my card without me manually use "modprobe" all the time...
  • erniaernia April 2010
    sorry, i forgot to tell you to add your module in /etc/rcS.conf in the row LOAD_MODULES=.

    LOAD_MODULES=" whatisalreadyhere pcnet_cs"
  • JingJing April 2010
    OK. I got it done!

    I added the modprobe pcnet_cs command in the network.sh so system run it before the network setup at bootup.

    Now it works! I am not sure if there is any problem with this though.
  • JingJing April 2010
    I was experimenting and did not see your reply.

    I guess yours is a better solution. Let me try it now. I am excited about the progress.
  • erniaernia April 2010
    your solution is valuable as mine, just mine is the default Slitaz one, so you don't risk to get your work overwritten when you update your system.
    if you are a linux newbie you are learning fast :-)
  • JingJing April 2010
    Thank you very much for the encouragement. I tried and of course your solution works perfectly.

    Now that I am ready to explorer more with linux I guess I will have more questions. I will try to absorb as much as I can first and will be back when I get confused again.

    This problem is now RESOLVED.
  • JingJing April 2010
    In case some other newbies like me have similar issues and find this discussion, here is a summary of how this issue gets resolved, from the view of a new linux user.

    The problem: ethernet adapter card is not working.

    The diagnose process:

    1. Since we know exactly what device we are dealing with, we used "modprobe pcnet_cs" command to probe and load device driver, pcnet_cs being the PCMCIA ethernet card driver.

    2. Unfortunatly, the card still refuses to work. Apparently the linux system is not really using it properly, even though it knows how to use it as the device driver is loaded. To find out why, we run a "dmesg" command to list detais how the system loads hardware devices.

    Sure enough, there is a problem. The linux device manager "udev" uses "eth1" instead of the default "eth0" for ethernet adapter. Since system setup scritps use "eth0" we need to do some modifications.

    The Solution:

    1. " /etc/rcS.conf " is modified by adding "pcnet_cs" to "LOAD_MODULES"

    "rcS.conf" is the configuration file used by the the system initializatin script "rcS". We basically ask the system to load "pcnet.cs" at boot time.

    2, "/etc/network.conf" is modifed; INTERFACE shall set to "eth1" so the network script uses "eth1" instead of the default "eth0" for setting up network.

    Detailed info how the linux system boots up and load devices can be found in the Slitaz handbook. The diagnose process now makes perfect sense to me.
  • erniaernia April 2010
    Your problems of udev changing eth0 -> eth1 is due to the fact that you did the install putting your hard disk in another pc. I've seen this in your other help request, i did not remember before.
    Udev remembers the mac address of the network card he sees and try to reassign the same name to the same mac address. So he thinks that eth0 should be the network card you had in the other pc and refuses to assign eth0 to other cards.
    If you want you should be able to assign eth0 to your card editing /etc/udev/rules.d/70-persistent-net.rules and changing the NAME= value and reboot (don't know how to properly restart udev, i'm not a udev expert and slitaz does not have an init script to do it)
    If you do so remember to put /etc/network.conf back to eth0
  • JingJing April 2010
    I keep learning from you. I find two entries inside the file "70-persistent-net.rules ". One for a pci device, which must be the onboard ethernet adapter from my other computer where I installed the system, and another pcmcia device that I currently use.

    I commented out the pci one and set the pcmcia one to eth0. Now everything works properly.

    Thanks again!

  • SickboySickboy July 2010
    Cheers! =)

    This solution has brought my old cf-27 mk2 toughbook back to life. My pcmcia card was a CNet CNF401 10/100 32bit.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In Apply for Membership

SliTaz Social