Slackware This Forum is for the discussion of Slackware Linux.
|
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
|
07-06-2013, 07:32 PM
|
#1
|
Senior Member
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482
|
Thinkpad T400 Wireless
I bought a refurbished Thinkpad T400. This is my first laptop and first wireless device.
I am unable to get wireless to function. Problems likely are between my ears because I always have used static IP addresses in my home LAN and never before used NetworkManager or wireless.
In the beginning I configured rc.inet1.conf with the usual static IP address. No problems with a wired connection. I used only rc.inet1.conf for several days while I installed and tweaked Slackware 14.0.
Next I enabled rc.networkmanager, configured for a manual wired connection using the same static IP address as rc.inet1.conf.
NetworkManager always overwrites /etc/resolv.conf with an empty file. I found two clunky work-arounds: 1) a script ( https://bbs.archlinux.org/viewtopic.php?id=45394) and 2) chattr +i. Yet I still had no problem connecting wired.
Next the great chasm, wireless.
The router is a Linksys WRT54GL 1.1. I'm using DD-WRT v24 preSP2. I have been using the router and DD-WRT for several years. I enabled the router wireless radio.
Nothing I did allowed me to ping when I pulled the cable and used only wireless, despite popup dialogs that the connection was established.
Help appreciated. I haven't been this confused in a long time. Please start with the basics.
Thanks. 
Last edited by Woodsman; 07-06-2013 at 07:33 PM.
|
|
|
07-06-2013, 07:35 PM
|
#2
|
Senior Member
Registered: Dec 2009
Posts: 1,387
Rep: 
|
are you sure you need to go Arch way? ubuntu should be easier on that task.
4 ways to get wifi working on linux
|
|
|
07-06-2013, 07:52 PM
|
#3
|
Senior Member
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482
Original Poster
|
Thanks but I have no idea what you're talking about. This is the Slackware forum. 
|
|
|
07-06-2013, 07:59 PM
|
#4
|
LQ Veteran
Registered: Nov 2005
Location: London
Distribution: Slackware64-current
Posts: 5,836
|
Perhaps you should revert rc.inet1.conf (and any other network configuration files) to their original states and let networkmanager or wicd do their jobs. Might there be some clashes? I might be wrong but I think you're overcomplicating things a bit. I've actually never used NetworkManager but have been using wicd for both wired and wireless connections for a long time. As long as the network card is detected, it should be as easy as this:
Code:
# installpkg ./path/to/wicd-....txz (from /extra)
# wicd
$ wicd-client
At this point a GUI program will pop up where you'll be able to choose your wifi network (edit the settings) and connect to it.
That's all I always do after installing a fresh Slackware system.
HTH.
On a separate note, make sure you've got the correct settings for DNS/Gateway etc.
|
|
|
07-06-2013, 08:08 PM
|
#5
|
Member
Registered: Jan 2006
Location: Dallas
Distribution: Slackware
Posts: 912
Rep: 
|
You can issue "iwconfig" to list the wireless interfaces on your laptop.
Then try "iwlist <interface> scanning" to make sure your laptop wireless NIC is able to pick up your router's broadcast. For example, "iwlist eth1 scanning", if eth1 is your wireless interface. If you get nothing from iwlist, then check to make sure the laptop wireless radio is turned on. There's usually a hard switch or a special function key soft switch to toggle it on or off.
Make sure you have an active dhcp server somewhere on your network, probably on your router.
Verify your router's wireless access point is enabled and configured with an ssid and security keys (preferably wpa2).
There's more than one way to configure your wireless setup. Here is how I do it:
Turn off networkmanager and/or wicd. (I don't use them, so I don't know anything about them.) Edit rc.inet1.conf and set USE_DHCP(n) to "yes" for your wireless interface. Leave the other parameters null, except perhaps DHCP_HOSTNAME(n) if you want. Verify that you have the address of your gateway specified in the GATEWAY parameter.
Make sure /etc/rc.d/rc.wireless is executable.
In /etc/rc.d/rc.wireless.conf, make sure this section near the top is NOT commented out:
Code:
## Pick up any Access Point, should work on most 802.11 cards
*)
INFO="Any ESSID"
ESSID="any"
;;
Configure any specific wireless settings pertinent to your network in /etc/wpa_supplicant.conf. Here is an example for a network with ssid "eatmorepizza":
Code:
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=root
eapol_version=1
ap_scan=1
fast_reauth=1
# 7/6/2006 Use wpa_passphrase to obtain pre-computed hexadecimal psk:
# wpa_passphrase eatmorepizza "this is just a fake sample password"
network={
ssid="eatmorepizza"
proto=WPA RSN
key_mgmt=WPA-PSK
pairwise=CCMP TKIP
group=CCMP TKIP WEP104 WEP40
psk=a05a1952c8abcd92104f9c5ff6daf0077d23ebb66cf810b931beea889a1803f0
priority=10
}
# Plaintext connection (no WPA, no IEEE 802.1X),
# nice for hotel/airport types of WiFi network.
network={
key_mgmt=NONE
priority=0
}
Make sure the /etc/wpa_supplicant.conf is rw for root only.
Let me know if any of that helps.
Last edited by Z038; 07-06-2013 at 08:10 PM.
|
|
2 members found this post helpful.
|
07-06-2013, 08:40 PM
|
#6
|
Senior Member
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482
Original Poster
|
Quote:
Perhaps you should revert rc.inet1.conf (and any other network configuration files) to their original states and let networkmanager or wicd do their jobs.
|
I ran netconfig to empty rc.inet1.conf and use NM. Rebooting with the cable pulled resulted in no network.
Quote:
have been using wicd for both wired and wireless connections for a long time
|
I tried wicd. I was successful once. After rebooting I could not again get wicd to connect.
Quote:
You can issue "iwconfig" to list the wireless interfaces on your laptop.
|
I ran ifconfig to find three interfaces: eth0, lo, and wlan0.
I ran iwconfig and I see some information about wlan0.
I ran 'iwlist wlan0 scanning' and I receive a message the interface doesn't support scanning because the network is down.
Quote:
Make sure you have an active dhcp server somewhere on your network, probably on your router.
|
I don't have the router configured that way. I always have used static IP addresses with my home LAN. Is there no way to use static IP addresses with wireless?
If I have to configure the router as a DHCP server, I want the laptop to use the same IP address wired or wireless. Is that possible?
Whether using NM, wicd, or rc.wireless, I don't want to login and start the desktop just to get wireless working. I have system scripts that need networking that I run in rc.local for auto updates of various system files. Whether the system is using wired or wireless I want those scripts to run before any logins. I want the laptop to use wired when available but to otherwise first look for wireless.
|
|
|
07-06-2013, 08:57 PM
|
#7
|
Member
Registered: Jan 2006
Location: Dallas
Distribution: Slackware
Posts: 912
Rep: 
|
Quote:
Originally Posted by Woodsman
Is there no way to use static IP addresses with wireless?
|
I haven't ever done that, but I think you can. Just specify the IP address in rc.inet1.conf in the IPADDR(n) parameter, set the NETMASK(n) for your network, and change USE_DHCP(n) to null or NO.
Quote:
Originally Posted by Woodsman
If I have to configure the router as a DHCP server, I want the laptop to use the same IP address wired or wireless. Is that possible?
|
Yes, you can do that. You would set up the DHCP server to assign a particular IP address based on the MAC of the wireless NIC. If you decide you want to do that, I can give you an example dhcpd.conf. I run dhcpd on my desktop, not in my router, but the dhcp server on many of the routers I've used could be configured that way too.
Quote:
Originally Posted by Woodsman
Whether using NM, wicd, or rc.wireless, I don't want to login and start the desktop just to get wireless working. I have system scripts that need networking that I run in rc.local for auto updates of various system files. Whether the system is using wired or wireless I want those scripts to run before any logins. I want the laptop to use wired when available but to otherwise first look for wireless.
|
On my Thinkpad T43, dhcpcd (note, not dhcpd the server, but rather dhcpcd, the client) runs sometime before rc.local and solicits an IP address from my dhcp server.
|
|
|
07-06-2013, 09:02 PM
|
#8
|
Member
Registered: Aug 2006
Distribution: Slackware
Posts: 804
Rep: 
|
You don't have to start a desktop to have NM start your connection. I have a T510 and NM starts just fine when I boot. I use dispatcher.d to start some stuff, like mounting NFS shares, when booting. I know rc.nfs can do that, but I don't want it to try to mount on hostile networks. One thing I would look at, is firmware. What chipset are you using, and do you need to load any firmware for it? You can also try nmcli and see if you can see any of the networks.
|
|
|
07-06-2013, 09:18 PM
|
#9
|
Senior Member
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482
Original Poster
|
Much of the configuring of the laptop has gone well, despite being my first laptop and me wanting to configure some special things because of the laptop's mobility. The last day and half trying to get wireless running has been mind numbing.
With the above responses I think I have something working. After I ran netconfig, which wiped the rc.inet1.conf (as somewhat hinted by sycamorex) and also wiped my /etc/hosts (not nice Pat  ) I then disabled rc.wicd and re-enabled rc.networkmanager. With the cable pulled I rebooted and the wireless network now seems to be working, also with static IP addresses defined in NetworkManager.
So at least one problem would seem to have been a conflict between NM and rc.inet1? Is this written somewhere and I missed getting the memo?
I have rebooted a couple of times now, but I notice wireless seems to initialize in steps, or very slowly. When my rc.local attempts to run my auto updating scripts, they all fail. During that period the laptop wireless LED is blinking. After many seconds the LED goes solid. When the LED goes solid I then can manually run the same set of auto updating scripts.
Apparently I need some kind of wireless test before running the scripts in rc.local. Are there any programmatic ways to validate the wireless network is up and stable and not just initialized?
Related, how do I programmatically detect which interface the laptop is using (eth0/wlan0)?
Another question: should rc.inet1 be disabled when using rc.networkmanager?
Last edited by Woodsman; 07-06-2013 at 09:20 PM.
|
|
|
07-06-2013, 09:29 PM
|
#10
|
Member
Registered: Aug 2006
Distribution: Slackware
Posts: 804
Rep: 
|
RE: rc.inet1: Mine is still executable and I don't have any issues at all. Instead of testing for connection then running rc.local, check out /etc/NetworkManager/dispatcher.d.
|
|
|
07-06-2013, 09:32 PM
|
#11
|
Senior Member
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482
Original Poster
|
Another question: iwconfig lists Bit Rate=1 Mb/s. Should that be 54 Mb/s or at least something close to that?
|
|
|
07-06-2013, 10:02 PM
|
#12
|
LQ 5k Club
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware64-15.0
Posts: 6,570
|
Quote:
So at least one problem would seem to have been a conflict between NM and rc.inet1? Is this written somewhere and I missed getting the memo?
|
You missed the memo.  From the email to root titled ' Welcome to Linux (Slackware 14.0)!'
Quote:
With NetworkManager or wicd, it's
a good idea to remove any existing network configuration in
/etc/rc.d/rc.inet1.conf first. This can be done by running netconfig
and setting the machine to use loopback. Then, if you're using
NetworkManager run it a second time and select NetworkManager.
|
Quote:
Apparently I need some kind of wireless test before running the scripts in rc.local. Are there any programmatic ways to validate the wireless network is up and stable and not just initialized?
Related, how do I programmatically detect which interface the laptop is using (eth0/wlan0)?
|
As mentioned by manwichmakesameal, you can setup scripts in /etc/NetworkManager/dispatcher.d
For example: http://www.linuxquestions.org/questi...1/#post4579765
BTW - Did you see this in CHANGES_AND_HINTS.TXT?
|
|
|
07-06-2013, 10:54 PM
|
#13
|
Senior Member
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482
Original Poster
|
Sigh. So much to read. So little remembered.
Yes, I ran into that same problem. The rc.firewall script runs from rc.inet2 but the NM script runs from rc.M.
The challenge is running rc.firewall in rc.inet2 works just fine in any wired system. Only the new laptop hiccups with that and only when I use NM.
Why is the NM script launched in rc.M rather than rc.inet2?
Quote:
BTW - Did you see this in CHANGES_AND_HINTS.TXT?
|
Nope, missed that too. Or I should say, ignored because at the time I never owned a laptop. I added pci=reboot as a kernel parameter and saw a message about unknown option. I'm not seeing any delay when rebooting. Perhaps the problem is resolved with newer kernels?
Quote:
Are there any programmatic ways to validate the wireless network is up and stable and not just initialized?
|
I came up with the following kludge:
Code:
if [ "`ifconfig eth0 | grep 'inet '`" = "" ]; then
# Probably using wireless and not wired.
# Another way to delay would be using 'iwconfig | grep Frequency'.
echo "Waiting for the wlan0 interface to stabilize..."
while [ "`ifconfig wlan0 | grep 'inet '`" = "" ]; do
sleep 1
done
fi
|
|
|
07-06-2013, 10:56 PM
|
#14
|
Slackware Maintainer
Registered: Dec 2002
Location: Minnesota
Distribution: Slackware! :-)
Posts: 3,115
|
Quote:
Originally Posted by Woodsman
Why is the NM script launched in rc.M rather than rc.inet2?
|
Because DBus isn't running when rc.inet2 is executed.
|
|
1 members found this post helpful.
|
07-06-2013, 11:00 PM
|
#15
|
Senior Member
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482
Original Poster
|
Quote:
Because DBus isn't running when rc.inet2 is executed.
|
No matter where I go, there I am.
Okay, thanks.
Perhaps add a comment in rc.M so other dweebs like me don't ask again? 
|
|
|
All times are GMT -5. The time now is 01:29 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|