0

I had a working raspberry pi website for a few years. I moved and have to use a different internet provider and have been having some issues. I called them and they gave me this infornmation:

IP - (my public ip)
Subnet - 255.255.255.240
Gateway - 50.221.225.225
DNS1 - 8.8.8.8
DNS2 - 8.8.4.4

I tried to edit the /etc/dhcpcd.conf file via plugging in the microsd card into my computer via a usb adapter to make it connect directly, but then I realized that this was the wrong way to go about it. However in doing so I broke everything! I tried to set it back to its original state and I'm pretty sure I did - however now it looks like everything is not letting me access it. When I put the local ip address for the pi into the url it gives me 403 forbidden and when I try to ssh it gives me kex_exchange_identification: read: Connection reset by peer Connection reset by 192.168.1.2 port 22

I will work with Dish Fiber support to get my website back up but now I am just hoping i have some way to get my rpi back to how it started. Do you know how to fix ssh capabilities? BTW my dhcpcd.conf is now at default settings (all commented out) because that is how it originally was back when my website worked in the first place. Thank you! MW

Edit: I am connected via wifi, not ethernet cable

I know now that changing the dhcpcd.conf won't actually help. That is how I originally had my pi setup back when the site worked, but the technical support at dish fiber said I needed to change the dhcpcd.conf, I think they were just wrong (I'm really not sure why I thought that the help desk for the internet provider would give good advice on editing my Pi). Originally when the website used to work, everything in dhcpcd.conf was just commented out so I reset it to that

Mira Welner
  • 101
  • 1
  • When I put the local ip address for the pi into the url it gives me 403 forbidden what did it used to do when you did that - are you connected via wifi or ethernet cable? – Jaromanda X Jul 21 '23 at 00:16
  • Your ISP seems to have issued you a /28 address block, although the rest of your Question seems to have little to do with this. The settings you have in dhcpcd.conf make no sense and won't work. See How to set up networking/WiFi for details of dhcpcd.conf. It is unclear why you are attempting to assign static IP - it would make more sense to use the ISP DHCP server or assign in your router. How to set up Static IP Address – Milliways Jul 21 '23 at 06:58
  • @JaromandaX I am connected using wifi. I know that the pi is connected to wifi because it is visible on my router but it doesn't seem to be able to connect – Mira Welner Jul 22 '23 at 15:18
  • @Milliways Yeah i know - I used to have a working website and I should not have messed with the dhcpd. When you say they make no sense and won't work, i actually had not edited it back when I had my rpi working as a website. I had to connect it to wifi but I did not edit it. Should I just comment everything out? Idk how to un-break what I just did – Mira Welner Jul 22 '23 at 15:19
  • everything in dhcpcd.conf was just commented out so I reset it to that so, it wasn't in default (installed) state when it worked – Jaromanda X Jul 22 '23 at 17:19
  • Isn't that default state? If it isn't then I reset it wrong and that may be the issue. I remeber I did not edit dhcpcd.conf the first time around. I tried to reset it to default state. Do you know where I could find the dhcpcd.conf default state? – Mira Welner Jul 22 '23 at 17:33
  • You have not explained how you are connected to the ISP. Normally you would enter the ISP specific details into your router or NTU and the Pi would its by DHCP. – Milliways Jul 22 '23 at 22:55
  • I was originally connected to ISP via my router - however right now I am not going that far ahead. I had port forwarding set up. Right now I am just trying to ssh in locally. and Idk why I am getting a 403 error @Milliways – Mira Welner Jul 25 '23 at 15:33

1 Answers1

0

I figured nothing was going to fix this issue so I removed the files I needed from the raw SD card and just reflashed the whole thing and now it works!

Mira Welner
  • 101
  • 1