I've installed Raspberry OS on a MicroSD via the Windows installer downloaded here.

I then used this tutorial.

However, when I try curl -sSL https://install.pi-hole.net | bash via the Windows command prompt (that I run as Administrator) I get the error:

curl: (23) Failed writing body (2691 != 16384)

How can I install Pi-Hole via Windows 10?

I tried connecting via SSH, like so: ssh pi@

I get the error:

ssh: connect to host port 22: Connection refused

I then checked this post which states that I need to enable SSH on the Pi by placing a ssh file in the BOOT folder; however using Windows Explorer I cannot access the SD card anymore (needs to be formatted first).

So then I looked here. Option 1 is "Launch Raspberry Pi Configuration" (no idea how I can do that) Option 2 is run sudo raspi-config, however sudo is not available in Windows Powershell, and Start-Process raspi-config cannot find the file specified.

So I'm stuck now. How can I enable SSH on my Rasperberry Pi (which runs Raspberry Pi OS) so I can install Pi-Hole?


Found the BOOT disk and placed an empty ssh.txt file on it. I reattempted to connect via SSH ssh pi@ but get the same error:

ssh: connect to host port 22: Connection refused

  • 1
    The card has a windows readable partition and a linux partition so you can put the SD card in your PC and ignore the message about needing to format it. You will see a new drive called BOOT - put the ssh file on this, eject the card and try again. The raspi-config program (and the sudo command) is only available on the Linux OS on the Pi.
    – user130616
    Mar 1 '21 at 16:30
  • Ok, those first steps worked but I still get the same error now, please see update 2
    – Adam
    Mar 2 '21 at 8:27
  • 1
    Check if the file has gone off the disk - that's a sign that the boot completed normally and ssh has been enabled. Normally I use a file called 'ssh' (no extension) but I think ssh.txt should work. If the file has gone then it points to the IP address being the wrong one. You will need to look at your home router to see what address the PI has been given.
    – user130616
    Mar 2 '21 at 12:39
  • Had to unplug and replug the pi , now it works, thanks!
    – Adam
    Mar 2 '21 at 15:58

Normally you would SSH to the Pi and issue the command on the Pi not on Windows.

You may need to install PuTTY on Windows first.


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.