Denk758
Denk758

Reputation: 3

Host server on Raspberry

Ive made a simple chat Program in c#. It uses tcp. I can start the server and clients can connect and chat if everyone is in the same network. I now want to put the server on my raspberry pi which has raspbian installed. So far so good it works and i can connect again if everyone is in the same network, but now i want to access the server over the internet as a private person cant geht their hands on an public static ip adress, ive read that i could use ddns. I have a host name on no-ip and installed noip2 on the raspberry and followed the instructions. On their site they write you can test it with the command sudo noip2 -S. It shows that it connected with my account and will update my hostname. In theory everything should be working, but i cannot connect to the server neither to the raspberry. Anyone of you knows what i can do to make it work or is it the completely wrong way?

Thanks in advance!

Upvotes: -1

Views: 67

Answers (2)

ohlr
ohlr

Reputation: 1909

You could use dyndns together with cname. You would need to open port 80, 443 on your router. This implies risk for the other devices in your network.

Instead of using rpi locally you could get a small virtual hosting server at AWS/Google for around 3$ per month.

Upvotes: 0

Duston
Duston

Reputation: 1641

Simply put, if you don't have a public IP, there's no way to connect to your RPi. If the IP address starts with 192.168, 172.16 through 32 or 10. then it's by convention (or definition depending on how you look at it) a non-routable address which means you can't get to it over the Internet.

DDNS is just a way of translating from a name to an IP address and doesn't imply anything about being accessible to the public. Noip is just a way of being able to associate a name with a dynamic IP address, which again does not imply anything about being accessible to the public. In other words, if www.yourdomain.com resolves to 192.168.1.2 (for example), it doesn't matter who can resolve the name, they still can't get to your server.

If your router has a public IP (which you said it doesn't) then you would be able to do a NAT translation, but based on what you said, that's not possible either.

Upvotes: 0

Related Questions