Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
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.
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.
So I installed it. What does it do? How do you start it? There are no "shortcuts" to launch it. Aren't there man pages for it? Is this actually the package I need to connect to my home wireless network?
What I've found is that its not a gui program, its a collection of terminal commands. They have their own man pages.
As far as I can tell, they are:
iwconfig, iwlist, iwspy, and iwpriv.
Not for this thread, but, I scanned and found my home network but I currently cannot get iwconfig to accept an access point, and I need to put iwconfig into a boot-time script.
I scanned and found my home network but I currently cannot get iwconfig to accept an access point, and I need to put iwconfig into a boot-time script.
This all depends on what the encryption of your wireless router is. If you're using WEP encryption then you can just use wireless tools with a few easy steps.
Code:
iwlist
ifconfig wlan0 down
iwconfig wlan0 enc "<YOUR HEX ENC KEY>" channel <your wireless channel from iwlist> mode Managed
ifconfig wlan0 up
dhclient wlan0
If your network is some form of WPA then you need to look into wpa_supplicant and wpa_supplicant.conf and create a configuration that works with your wireless.
As for the command documentation using google always helps. Just search "man <command>" in google and you'll likely find useful documentation on what you inquire.
Also typing "<command> --help" may also present useful information.
Thanks. That helps! It'll take approximately two weeks to work through this.
Hehe theres a reason I dont like debian - the lack of resources of what seems to be classed as "obvious stuff "
Stick with it - If you know your key, and know your network then it can be setup quite quickly, but iwconfig can be strange at times (and if like me, you have a wifi card which randomly refuses to work!) however once your setup its a kind of "set and forget" thing. I've had to reconfigure my wireless about.... 5 times in as many years and even then it was because I moved house etc and ended up with a new router/wifi network.
I also added the following sections to it...
2.1 Gaining root access
3.2 Use WPA/WPA2 Personal
3.3 Use WPA/WPA2 Enterprise
3.5 Autostarting network configuration
Distribution: Xubuntu 16.04.1 / Linux Mint 18 XFCE / Linux Mint 18 Mate / Ubuntu Server 16.04.1 / Lubuntu 16.04.1
Posts: 146
Rep:
Quote:
Originally Posted by sag47
I just edited the wiki...
Any chance of adding a section to the wiki about enabling and disabling wireless cards using iwconfig? It took me ages to figure this out by myself (http://www.linuxquestions.org/questi...1/#post4066717), and others may find it useful.
Hey genogebot,
I added it to the wireless wiki. However I highly encourage you, and others, to create a wiki login so that you can contribute to it as you find and create answers to others' questions!
I decided on using same thread because the big problem is still about wireless-tools > iwconfig.
Someone at the local user group installed wicd on my Compaq/broadcom4312, and it connected to a totally unsecured wireless network at the local hackerspace, but it always fails to obtain an IP at my home (currently wpa2/psk/aes).
I made the following script (but I wasn't able to make it executable with chmod +x ; I'll deal with that later).
Following my script and keyboarding commands into a root terminal fails too, particularly at the "custom pass phrase" (what my 2wire router calls security). I read iwconfig doesn't do pass phrase but I'm unclear on hex vs ascii.
The access point never wants to associate.
So here is the script I had hoped I would boot with:
Where frodo is your wpa passphrase. Alternatively if you don't want people to easily know your network key then you can encode the passphrase with wpa_passphrase and use it instead of frodo.
Code:
wpa_passphrase Mordor frodo
Then once you have your wpa_supplicant.conf file you need your script which I wrote directly into the LQ Wiki for you.
Code:
#!/bin/sh
iface=wlan0
#shut down interface
ifconfig $iface down
#set ad-hoc/management of wireless device
iwconfig $iface mode Managed
#enable interface
ifconfig $iface up
#stop any persistent wireless wpa2 sessions
killall wpa_supplicant
#apply WPA/WPA2 personal settings to device
wpa_supplicant -B -Dwext -i $iface -c ./wireless-wpa.conf -dd
#obtain an IP address
dhclient $iface
If you just want the bare minimum commands like your script then here they are corrected...
My Windows machine has IP address automatically obtained
(on this wireless network).
From the lq wiki I changed the location to
/etc/wireless-wpa.conf
instead of
./wireless-wpa.conf
Also my root shell doesn't recognize hwinfo as a command.
I think the wpa_supplicant command worked, it didn't complain so hope you didn't need to see that clutter.
I hate to be a pill but this will take me a couple of years w/o help. THANK YOU SO MUCH!!
Looking at the output below, I suspect the unknown hardware address type 801 and socket/fallback point to a problem...Here is the output from dhclient:
POS-Compaq:/home/evil# dhclient wlan0
There is already a pid file /var/run/dhclient.pid with pid 3267
killed old client process, removed PID file
Internet Systems Consortium DHCP Client V3.1.1
Copyright 2004-2008 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:90:4b:5e:f3:8e
Sending on LPF/wlan0/00:90:4b:5e:f3:8e
Sending on Socket/fallback
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 5
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 10
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 21
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 16
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 9
No DHCPOFFERS received.
No working leases in persistent database - sleeping.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.