I am interested in setting up a node-red server locally on a headless RPi. I expect the raspberry to host a local wifi network with the node-red server running on a static IP. I want to then access the node-red server from my laptop which is connected to the local wifi network hosted by the RPi. The raspberry pi is not connected to the internet, its meant to be hosting a local network.

I tried the following,

  1. I made a fresh installation of Raspbian Lite and created the ssh and wpa_supplicant.conf files. In the wpa_supplicant, I added the ssid and password of my wifi which is connected to internet.(This is required to download and setup the packages onto the Pi)
  2. Now I followed these instructions towards setting up an access point using RPi upto Step 6
  3. I started the hostapd and dnsmasq services and commented out the stuff I had added in the wpa_supplicant.conf in the /etc/wpa_supplicant/.
  4. sudo reboot

Now, I am able to connect to the ssid hosted by the RPi, but when I try to ssh it shows me "ssh: connect to host port 22: Network is unreachable". (I have set the static ip on RPi wlan0 to and given ip's from 0.2 to 0.30). On pinging this IP, I get "Request timeout for icmp_seq 1"

Could you please help me out here

  • If you like you can try Setting up a Raspberry Pi as an access point - the easy way using section "♦ Setting up a stand alone access point".
    – Ingo
    May 11, 2020 at 21:06
  • @Ingo Thanks a ton for you detailed answer. I understand that we are creating a new wpa_supplicant configuration. I would like to know if it is possible to switch between this and the pre-existing wpa_supplicant configuration(which allows me to connect to the internet). Could you please let me know hoe this can be done.
    – Some_Guy
    May 12, 2020 at 0:50
  • As far as I understand you want to have a standalone access point. Only the RasPi should have access to the internet. Is it a problem that only it always have internet access but other devices connected to its access point do not?
    – Ingo
    May 12, 2020 at 9:01
  • @ingo i dont have a ethernet connection. I plan to use my rpi as a local server for iot, but i want to raspberry pi to acess internet to use github. The iot devices should be behind the network. When i follow your answer, i thought by creating the wpa_supplicant-wlan0 we are creating the new local hotspot. What happens to the default conf which has ssid and psk of my internet wifi. Could you please explain how only rpi will be connected to internet while iot devices are local.
    – Some_Guy
    May 12, 2020 at 13:46

1 Answer 1


As told in a comment you have an internet WiFi, means there is an internet router to that you can connect by WiFi. The internet router does not have a wired port or cannot be used. You want to have a stand alone access point using a Raspberry Pi. Devices connected to the RasPis access point should not have access to the internet but the RasPi itself should have it to install and update software. So you need a wireless client connection to your internet router (uplink) in addition to the wireless access point provided by the RasPi.

You have linked to a tutorial that uses a wired (not wireless) connection as uplink but that isn't what you need. The Raspberry Pi is able to create an access point simultaneous with a WiFi client uplink that can be used as a WiFi repeater. How to setup this you can look at an Access point as WiFi router/repeater, optional with bridge. Because you do not need a bridge, use only the first part of the tutorial. To avoid access of the local devices to the internet, just omit the option IPMasquerade=yes in the configuration file /etc/systemd/network/12-ap0.network as shown in the tutorial. The RasPi itself can use the uplink.

  • During the boot up I get a message below the 4 raspberry icons, the message reads as follows "/etc/systemd/system/hostapd.service.d/override.conf:4:Failed to parse service restart specifier ignoring:" Will this cause any issue? Apart from this everything else works as expected
    – Some_Guy
    May 17, 2020 at 18:04
  • @Some_guy It doesn't matter. You can ignore it. Thanks for the hint. It shows me that the dhcpcd5 package isn't clean deinstalled. Seems someone has made a drop in file but not corrected the package. You can just delete the stub with sudo rm -r /etc/systemd/system/dhcpcd.service.d. Then the warning should disappear.
    – Ingo
    May 17, 2020 at 20:44
  • Sorry, I was unable to find that file. The directory does not exist
    – Some_Guy
    May 20, 2020 at 16:58
  • One more observation I have made so far : If the rpi is connected to internet, i am able to easily connect my laptop to the access point, however if the rpi is not connected to internet my laptop fails to connect to the access point... Do you see any reason behind this? Thanks for you time
    – Some_Guy
    May 20, 2020 at 16:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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