LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Can a wifi adapter become a access point? (https://www.linuxquestions.org/questions/linux-networking-3/can-a-wifi-adapter-become-a-access-point-4175604415/)

square-eyes 04-22-2017 10:47 PM

Can a wifi adapter become a access point?
 
I have a small computer being used as a media playback device connected to a TV. Internet comes in on the lan via the ethernet jack.

Could I somehow configure the (otherwise unused) wifi adapter to serve as a lan wifi access point for a couple of phones?

frankbell 04-22-2017 10:51 PM

I know there are many articles about how to use a Linux computer with two network cards as a router, so I'm sure there is a way to accomplish this, though I've not done it myself.

This article from the Arch wiki looks as if it could be a good starting point for your research: https://wiki.archlinux.org/index.php...e_access_point

Turbocapitalist 04-22-2017 11:35 PM

Only certain models can work as an access point. Look up the brand and exact model number you have and then check the driver documentation. Which brand and model do you have?

ferrari 04-23-2017 12:18 AM

Check the capability of your wifi device with
Code:

iw list
This doesn't work with all hardware though, so you may need to try setting AP mode with
Code:

sudo iwconfig wlan0 mode master
and observing the output (if any). No errors a re a good sign. Check the status again with
Code:

iwconfig
Assuming the device is capable proceed to configuring with hostapd.

Turbocapitalist 04-23-2017 12:32 AM

You might find the info on which model you have with lspci

Code:

lspci | grep -i wireless

lspci | less


square-eyes 04-23-2017 02:19 AM

Quote:

Originally Posted by frankbell (Post 5700880)
I know there are many articles about how to use a Linux computer with two network cards as a router, so I'm sure there is a way to accomplish this, though I've not done it myself.

This article from the Arch wiki looks as if it could be a good starting point for your research: https://wiki.archlinux.org/index.php...e_access_point

Good 'ole Arch. The king of the Linux howto.

Exactly what I wanted. Thanks. Bridge setup is what I was trying to ask for. Though, NAT setup is very tempting.

square-eyes 04-23-2017 02:23 AM

Quote:

Originally Posted by Turbocapitalist (Post 5700892)
Only certain models can work as an access point. Look up the brand and exact model number you have and then check the driver documentation. Which brand and model do you have?

I have a few old laptops I can fall back on (and practice on) on until I find something that might promise to work.

square-eyes 04-23-2017 02:25 AM

Quote:

Originally Posted by ferrari (Post 5700903)
Check the capability of your wifi device with
Code:

iw list
This doesn't work with all hardware though, so you may need to try setting AP mode with
Code:

sudo iwconfig wlan0 mode master
and observing the output (if any). No errors a re a good sign. Check the status again with
Code:

iwconfig
Assuming the device is capable proceed to configuring with hostapd.

Quote:

Originally Posted by Turbocapitalist (Post 5700908)
You might find the info on which model you have with lspci

Code:

lspci | grep -i wireless

lspci | less



Thanks. This info is all helpful for next weekend when I go to attack this.

sundialsvcs 04-23-2017 11:19 AM

NAT setup, versus Bridge, is probably what you do want, because you could have traffic conflicts (IP address collision and so forth) if you attempt to rebroadcast everything that anyone hears, as Bridge mode basically does. (You also will cut down on wireless traffic.)

square-eyes 04-23-2017 03:17 PM

Quote:

Originally Posted by sundialsvcs (Post 5701094)
NAT setup, versus Bridge, is probably what you do want, because you could have traffic conflicts (IP address collision and so forth) if you attempt to rebroadcast everything that anyone hears, as Bridge mode basically does. (You also will cut down on wireless traffic.)

Good to know.

lsalab 04-24-2017 10:41 PM

Check out 'hostapd', you should be able to bring up your WiFi adapter as an access point with this:

https://w1.fi/hostapd/

Hope it helps!


All times are GMT -5. The time now is 01:19 AM.