2

Today I was hoping to setup a network extender. I want it to connect to my router via ethernet, and then share out that connection via WiFi, and stay on the same network. All of the tutorials I looked at configured it in a way that the connected devices are on their own network with the raspberry pi, whereas I want mine to connect them to the 192.168.1.0/24 subnet. Is there anyway I can do this?

Thanks!

  • Any specific reason you need them on the same subnet? All the home routers I've seen / tried are find with multiple subnets as long as you use the switch in the back of them for the extenders. Its sometimes an advantage to see who is connecting to what AP (using the sub-net) when trying to sort out an issue - just ask my son... – Andyroo Apr 2 at 17:11
  • @Andyroo oh, yeah, I need them to be able to access the network directly to see servers and stuff on the network – Toffee Apr 2 at 17:14
  • But the routing on the Pi AP will bridge the two networks in both directions for you so it will be transparent to the devices on the WiFi side. They should pick the Pi AP up as the router and that passes the data between the two sub-nets for you. If they need access outside the LAN the Pi will bridge to the router and that will pass out to the internet for you. – Andyroo Apr 2 at 17:25
  • It's important that I have direct access to a network tho, I am using this a testing device to develop a pen-testing device. It is designed to just plug in and share out the network on the same subnet – Toffee Apr 2 at 17:31
  • Sorry but not going there - sounds like a hack device. – Andyroo Apr 2 at 17:33
2

It seems that you only found setups, using routing. But it is no problem to setup the WiFi access point on the RasPi to be on the same internal subnet as the internet router. You have to bridge the wired connection to the router on eth0 with the wlan0 interface of the access point. This way you are even on the same broadcast domain as the router, so your clients connected by WiFi will also use the DHCP server from the router. And it will give all clients ip addresses from the same subnet. How to setup it just have a look at Setting up a Raspberry Pi as an access point - the easy way. Beside the other options using routing you should follow the section ♦ Setting up an access point with a bridge.

| improve this answer | |
  • It works! Thank you so much. Quick question - what would happen to the Pi if there was no Ethernet plugged in and a USB tethering device instead? – Toffee Apr 7 at 14:29
  • @SlipDip USB tethering is usually provided by mobile phones to share its mobile internet connection to the connected device. This also works with the RasPi. You will get an additional interface usb0 that you can use to connect direct to the internet by the mobile phone. But it doesn't fit to the current network setup, so you have to do additional configuration. – Ingo Apr 7 at 16:58
  • sorry for the bad wording, what I meant was would it still broadcast an access point when it isn't connected to ethernet? I realised I worded that question horribly, sorry. – Toffee Apr 7 at 21:27
  • @SlipDip Yes, the access point is made by wpa_supplicant, which isn't effected by the wired connection. Then you have a standalone access point without internet connection. – Ingo Apr 8 at 13:24
  • Okay, thank you! – Toffee Apr 9 at 0:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.