Find the answer to your Linux question:
Results 1 to 3 of 3
Hi all, I'm trying to configure wireless on my laptop (iwl3945 and centos 5.3). I've installed iwl3945-firmware and loaded the module also. But I'm not able to get IP address ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Linux User saivin's Avatar
    Join Date
    Dec 2008
    Location
    Bengaluru, India
    Posts
    305

    '/sbin/dhclient wlan0' does not work in centos 5.3 (kde3)


    Hi all,
    I'm trying to configure wireless on my laptop (iwl3945 and centos 5.3). I've installed iwl3945-firmware and loaded the module also. But I'm not able to get IP address from DHCP.

    When I do /sbin/dhclient wlan0 I get the following error:
    Code:
    [saivin@sv-centos ~]$ sudo /sbin/dhclient wlan0
    Password:
    Internet Systems Consortium DHCP Client V3.0.5-RedHat
    Copyright 2004-2006 Internet Systems Consortium.
    All rights reserved.
    For info, please visit http://www.isc.org/sw/dhcp/
    
    wmaster0: unknown hardware address type 801
    wmaster0: unknown hardware address type 801
    Listening on LPF/wlan0/00:1c:bf:c8:f2:1b
    Sending on   LPF/wlan0/00:1c:bf:c8:f2:1b
    Sending on   Socket/fallback
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 8
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 18
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 16
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 19
    No DHCPOFFERS received.
    No working leases in persistent database - sleeping.
    However, dhclient works fine for eth0. What could be the problem and how to go about it?
    A candle looses nothing by lighting other candles. - Khalil Zibran.
    Registered Linux User #490076

  2. #2
    Linux User saivin's Avatar
    Join Date
    Dec 2008
    Location
    Bengaluru, India
    Posts
    305
    Hmm...before somebody asks, the iwconfig states it is associated with my AP and iwlist scans my AP fine.
    Code:
    [root@sv-centos saivin]# /sbin/iwconfig wlan0
    Warning: Driver for device wlan0 recommend version 21 of Wireless Extension,
    but has been compiled with version 20, therefore some driver features
    may not be available...
    
    wlan0     IEEE 802.11  ESSID:"SV"
              Mode:Managed  Frequency:2.412 GHz  Access Point: Not-Associated
              Tx-Power=15 dBm
              Retry min limit:7   RTS thr:off   Fragment thr=2352 B
              Encryption key:off
              Link Quality:0  Signal level:0  Noise level:0
              Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
              Tx excessive retries:0  Invalid misc:0   Missed beacon:0
    Code:
    [root@sv-centos saivin]# /sbin/iwlist wlan0 scan
    Warning: Driver for device wlan0 recommend version 21 of Wireless Extension,
    but has been compiled with version 20, therefore some driver features
    may not be available...
    
    wlan0     Scan completed :
              Cell 01 - Address: 00:1B:57:FD:4D:19
                        ESSID:"SV"
                        Mode:Master
                        Channel:11
                        Frequency:2.462 GHz (Channel 11)
                        Quality=93/100  Signal level=-36 dBm  Noise level=-127 dBm
                        Encryption key:on
                        Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s; 18 Mb/s
                                  24 Mb/s; 36 Mb/s; 54 Mb/s; 6 Mb/s; 9 Mb/s
                                  12 Mb/s; 48 Mb/s
                        Extra:tsf=00000000190c8185
    As you can see it is giving some warning. But I'm not able to makeout what it means. Is my problem related to this warning?
    A candle looses nothing by lighting other candles. - Khalil Zibran.
    Registered Linux User #490076

  3. #3
    Just Joined!
    Join Date
    Nov 2009
    Posts
    1
    There are some issues related with network-script against the WIFI card. We need walk around.
    Here is the description about using WEP encryption.

    1> It is supposed that related drivers are installed.
    run command "lspci | grep 4965" can see the hardware.
    run command "lsmod | grep 80211" can see the loaded modules.
    or the NetworkManager worked for you.

    2> disable NetworkManager service by commands
    chkconfig NetworkManager off
    service NetworkManager stop

    3> cp /etc/sysconfig/network-scripts/ifcfg-wmaster0 into /etc/sysconfig/network-scripts/ifcfg-wlan0

    4> change line "TYPE=Ethernet" into "TYPE=Wireless" against file /etc/sysconfig/network-scripts/ifcfg-wlan0 and save it.

    5> from the task bar by selection System->Administration->Network orderly,
    chosing item wlan0 as Device,
    focusing Devices tab, clicking Edit button,

    In General tab
    mark "Activate device when computer starts",
    chosing radio button "Automatically obtain IP address settings with dhcp"
    mark "Automatically obtain DNS information from provider"

    In Wireless Setings tab
    Mode->Managed
    Namework name(SSID)=>Specified into YOUR_SSID_FROM_YOUR_AP
    Authentication=>Open system (open) [my case]
    Key (use 0x for hex)=>0x[your AP SSID key], (NOT passphase)

    Click OK, click Save from menu item File.

    6> modifile /etc/sysconfig/network-scripts/ifup-eth
    6.1> add line
    /bin/rm -fr /var/lib/dhclient/dhclient-${DEVICE}.leases
    before line
    DHCLIENTARGS="${DHCLIENTARGS} ${ONESHOT} -q ${DHCLIENTCONF} -lf /var/lib/dhclient/dhclient-${DEVICE}.leases -pf /var/run/dhclient-${DEVICE}.pid"

    6.2> add 2 lines
    /bin/rm -fr /var/lib/dhclient/dhclient-${DEVICE}.leases
    /bin/rm -fr /var/run/dhclient-${DEVICE}.pid
    before line
    # end dynamic device configuration
    in the "else" section for line
    if /sbin/dhclient ${DHCLIENTARGS} ${DEVICE} ; then

    there will be like
    if /sbin/dhclient ${DHCLIENTARGS} ${DEVICE} ; then
    echo -n $" done."
    else
    /bin/rm -fr /var/lib/dhclient/dhclient-${DEVICE}.leases
    /bin/rm -fr /var/run/dhclient-${DEVICE}.pid
    echo -n $" failed."
    exit 1
    fi
    # end dynamic device configuration

    7> modify file /etc/sysconfig/network-scripts/ifup
    go to bottom of the file, change line
    exec ${OTHERSCRIPT} ${CONFIG} $2
    into following lines

    # exec ${OTHERSCRIPT} ${CONFIG} $2
    times_tried=0
    while (true); do
    if ${OTHERSCRIPT} ${CONFIG} $2 ; then
    exit 0
    else
    times_tried=$((times_tried + 1))
    if ((times_tried > 1)); then
    exit 1
    fi
    fi
    done

    Pay attentation: command exec in shell will call execel interface in C language.
    No exit after command exec executed.

    8> remarks

    8.1> comment for 6>
    dhclient command will hang up if its the pid file exists.

    8.2> comment for 7>
    boot Wireless always failed at the first time, need try one time at system booting up.
    It may be caused by script ifup-wirelss that I dont the inside.

    After those modification, my CentOS 5.4 on HP DV9500T notebook(Intel 4965 Wireless) can start wirelles conection at boot time.

    Good luck.

  4. $spacer_open
    $spacer_close

Posting Permissions

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