LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-23-2012, 02:14 AM   #1
SuSE_Lamer
Member
 
Registered: Nov 2004
Location: Hamburg/Germany
Distribution: Debian 10
Posts: 169

Rep: Reputation: 16
Connection to WPA-PSK-network wit NetApplet


Hello @all,

I have a problem connecting to WPA-PSK-protected networks. Short description: I have Thinkpad T43p, WLAN-card is recognized and running. Several years ago, when NetApplet was too young and unusable, I decided to write a script, which switched on and off my WLAN (including connection to the router using wpa_supplicant). A month ago I gave a try to NetApplet. It looks quite good now, and I wanted to use it regularly. Unfortunatelly, I could not connect to my router.

On the week-end I switched from Debian to Ubuntu - I installed Ubuntu 11.10. Under "Unity" I could connect to my router, under GNOME - not. Since I'm going to use GNOME, I would like to get my NetApplet and WLAN running.

Here is my question: can anyone give me a hint, what I should to do to resolve the issue? I think, it has anything to do with my wpa_supplicant configuration, which I created when I used my old scripts, but I'm not quite sure.

Additional information: when I try to connect to WLAN using NetApplet, it tries several seconds and then asks for a password, although I have it already set in the network profile.

I would appreciate any help, thanks in advance.

Greetings from Hamburg,
Andrey.
 
Old 01-24-2012, 07:46 PM   #2
thund3rstruck
Member
 
Registered: Nov 2005
Location: East Coast, USA
Distribution: Fedora 18, Slackware64 13.37, Windows 7/8
Posts: 386

Rep: Reputation: 43
I actually just did this in Puppy Linux. Puppy is designed to be run as a Live distro that's not designed to be run like a standard everyday distro so it requires you to manually (re)-enter the network info every time you start the machine!

To resolve this I had to create a login script to connect to the WPA2 router. Basically all you need to do is edit the wpa_supplicant's config file and then reference that file when calling the wpa_supplicant program.

Create/Edit /etc/wpa_supplicant.conf
Code:
## SAMPLE wpa_supplicant ##
## Calculate PSK HEX Key: http://jorisvr.nl/wpapsk.html
ctrl_interface=/var/run/wpa_supplicant

network={
	ssid="mySSID"
	scan_ssid=1
	psk="MyHexWPA2Passphrase"
	proto=RSN
	key_mgmt=WPA-PSK
	pairwise=CCMP
	group=CCMP
}
Establish WPA2 connection
Code:
wpa_supplicant -D wext -i wlan0 -c /etc/wpa_supplicant.conf
 
Old 01-24-2012, 08:03 PM   #3
Roken
Member
 
Registered: Oct 2011
Location: Warrington, UK
Distribution: Arch local, Debian on VPS, several RPIs.
Posts: 300
Blog Entries: 1

Rep: Reputation: 55
Personally, I don't bother with a NM anymore. I have wpa_supplicant configured to start at boot, and leave it to it. No more dropped wifi, no more bad connections etc.

However, if you must have a NM, take a look at wicd. It's about the best out there.
 
Old 01-25-2012, 03:09 AM   #4
SuSE_Lamer
Member
 
Registered: Nov 2004
Location: Hamburg/Germany
Distribution: Debian 10
Posts: 169

Original Poster
Rep: Reputation: 16
wpa_supplicant vs. NetworkManager

Hello @all,

thanks for your hints and replies. Actually, I used to work with "Access Connections" from IBM/Lenovo. I want to be able to switch manually from cable to WLAN. That's why I want to get NetworkManager running.

Quote:
Originally Posted by Roken View Post
Personally, I don't bother with a NM anymore. I have wpa_supplicant configured to start at boot, and leave it to it. No more dropped wifi, no more bad connections etc.

However, if you must have a NM, take a look at wicd. It's about the best out there.
To be honest, I do not really understand the realtionship between NetworkManager and wpa_supplicant. Someone says "they must run together", someone says "NetworkManager has its own WPA-driver, and that's why they conflict". Does anyone know the real situation?

Greetings from Hamburg,
Andrey
 
Old 01-25-2012, 06:40 AM   #5
Roken
Member
 
Registered: Oct 2011
Location: Warrington, UK
Distribution: Arch local, Debian on VPS, several RPIs.
Posts: 300
Blog Entries: 1

Rep: Reputation: 55
I can't be certain, but when I have used a Network Manager, a quick look at ps -A (or your task manager if you use one) will confirm that wpa_supplicant is still running. As such, I suspect that NMs are just basically another layer over the top of wpa_supplicant. My own experience, however, is that NMs can cause problems. Whenever I've used one (whether it be gnome-network-manager, wicd etc) I've had problems with stalling connections, dropped connections etc. Since I went directly to wpa_supplicant with no intermediate layer my wireless is rock solid.

Granted, you don't get all the pretty GUI configuration that a NM provides, and you have to take care of monitoring your network yourself if you want to know what's going on (a fairly trivial task with something like conky), but the stability IMO more than makes up for it.

NB. This may just be something peculiar to my PC, network, router etc., so YMMV.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
can't find a wifi tool to connect to wpa-psk network lumix Linux - Networking 4 11-13-2008 01:01 AM
Accessing WPA PSK encrypted wireless network from linux firewiz87 Linux - Wireless Networking 4 02-21-2008 12:18 AM
Wpa-psk LDJ Linux - Wireless Networking 3 01-05-2007 11:39 AM
how do I get my AP to use WPA-PSK ? lemon_hou Linux - Wireless Networking 1 12-28-2004 02:22 AM
How do i set up WPA PSK with wpa supplicant and linuxant? Eleavings Linux - Wireless Networking 4 12-27-2004 11:24 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:06 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration