Can only connect to my server locally??
This ones got me scratching my head. I made a post on reddit but I'm asking here too. First time building a server. It's on a raspberry pi 4. JDK 17 and minecraft 1.20.4. I've added port assignments to my router, tried different ports, tried changing server.properties, what am I missing here? Like I said in the title, I can connect using my local ip, but when I try my public:25565 or whatever port I'm trying at the moment, it doesn't seem to work.
15 Replies
Thanks for asking your question!
Make sure to provide as much helpful information as possible such as logs/what you tried and what your exact issue is
Make sure to mark solved when issue is solved!!!
/close
!close
!solved
!answered
Requested by whiskee.ry#0
Because you cant lol
Since your hosting, connect to localhost, others will be able to join via your public IP. Although, I recommend you setup this https://tcpshield.com
It will proxy your server with TCPShield, you will be able to join via the domain you set and it will give better routing to others
Did you port forward?
!cgnat
We may have bad news for you :C
Open your router's configuration interface. Somewhere you'll see something like 'external' or 'public' IP.
If your external IP is in one of the following ranges, you're basically screwed as long as portforwards go:
- 10.0.0.0/8
- 172.16.0.0/20
- 192.168.0.0/16
- 100.64.0.0/10
- any IPv6 address/range - This shouldn't be a problem, but Minecraft's IPv6 support is still rather quirky. You're at your own but we're happy if you share your experience.
You should ask your ISP for a public and IPv4 address (but this may cost you money).
NB: your internal IP should and most probably will be in one of the first three ranges, don't mix them up
Admincraft Canned Responses
I must add, I have only tried to connect to the public ip from the same network. I suspect that my assumption that it should be able to connect that way on the same network was wrong and will be testing with a friend soon.
Does tpcshield work with PaperMC?
Yes
Yeah so if you have a server on the same LAN and you try to access it via your public address you get what's called NAT hairpinning.
Basically the packets don't ever leave the LAN and just come back because they don't need to and your router knows this.
In essence, you connecting to your public IP for stuff on your LAN is the same as connecting using
127.0.0.1
.
To allow people outside of your LAN to connect? You'll need one of a few methods, port fowarding is popular, TCPShield is popular, some people use tunnel solutions like playit.gg, Wireguard, Tailscale, or Minekube.
Personally speaking I'd suggest learning how to port forward since tunnels are inherently risky from a network perspective if you don't understand the complications.Thanks yall! I will dive into the tcpshield thing later and report back with how the test goes
Good luck, mate.
Btw you do not need to install the TCPshield plugin to your server, so if you are running something like forge or fabric (which there ARE mods that add spigot/bukkit/paper api) you can still set it up. Buy a domain i suggest porkbun it will be worth it, get a domain for $10/Year.
It takes seconds to setup TCPShield once you have a domain. You can also use those free domains sites but I can not give any suggestions as I do not use them.
If you need help just let me know
or Aeon
I think I need to wrap my head around DNS a bit better before diving in. If you know a good article/guide that would be helpful for noobs, lmk
Cloudflare Docs
Full setup · Cloudflare DNS docs
If you want to use Cloudflare as your primary DNS provider and manage your DNS records on Cloudflare, your domain should be using a full setup.
But with TCPShield its super easy, you literally click a few buttons, type in your IP. Boom
Atomatrix Development
YouTube
How to add DDOS PROTECTION to your Minecraft Server! (TCPShield Tut...
This tutorial shows you how to Set up TCPShield on your Minecraft Server/Domain. TCPShield is a highly available DDoS protection platform, built for gaming networks that demand 100% uptime.
You can purchase Atomatrix Resources from BuiltByBit or Polymart.
TCPShield Dashboard: https://panel.tcpshield.com/
ProtocolLib Download: https://www.spigot...
For what you need to know? You make an A record pointing the base domain at your public IP, then a CNAME pointing your subdomain at your base domain.
Anything beyond that is out of scope for simple MC.
If you use TCPShield then you skip the A record and point a CNAME at the TCPShield record you get given.