Notes
![]() ![]() Notes - notes.io |
I would like to play Minecraft with my friends and I already have a server connected to the internet. However my server is underpowered and is unable to run an actual Minecraft server instance. On the other hand, I have a spare powerful laptop that can take on the load, but port forwarding is not feasible. Both the server and the laptop are connected to my Tailscale network. What could I do with all this to create a Minecraft server that has an IP public? Yes, and I was surprised at how simple it was. The server is extremely user-friendly, and the latency was lower than other "free hosting" services.
Tailscale Halfway to Tailscale
Tailscale is already installed on all my devices. This means that if I create an Minecraft server instance on one device, I can connect immediately to it from the other devices. My friends don't yet have Tailscale! ) So node sharing is not in the picture at the moment. However, I can still take advantage of Tailscale in that my laptop will always have a static IP relative to the server and the server will always have a static IP to the public internet. Mpservers Thus, the connection will be deterministic and I won't have to resort to any dynamic shenanigans.
Let's test the theory.
And let's check whether Minecraft can see it if I add the Tailscale IP...
Great success! It's just a matter of making it available via the internet.
Iptables is here to save the day!
In essence, iptables lets you to set the rules of the Linux kernel firewall. It's really simple. The user creates tables and packets are routed through tables. Java edition Minecraft servers use TCP port 25565 between the server and client.
NixOS configuration
It was easy to enable IP forwarding, and to add 25565 to my list of open TCP ports:
The rule is designed
We are now able to adding the following commands to our firewall setup. Let dest_ip be the Tailscale IP address of the server. The first command is an additional rule to the PREROUTING chain. This is where the packets arrive before they are processed. We basically forward the packet to Tailscale's IP address. The second command allows the IP address of the packet remain the same, which means the server just acts as a router.
Now we have the following setup:
We now reconfigure the server configuration and check it again in Minecraft using the public IP. It all is working exactly as expected!
Final touches: A DNS record
An A record was added to my configuration to give people an attractive URL instead of an IP address.
Performance
As far as performance goes it's pretty decent! My friends and I were able to play on the proxy server that is located on the East coast. The Minecraft server is located on the West coast. I was able to pin players via the connection, and the latency was not too bad (77 milliseconds for someone from New York).
Refer to
Xe's post on Tailscale, NixOS and Minecraft inspired me to write this post, however, my requirements were different. I didn't want my friends to install Tailscale in order to play on my server. I wanted to utilize the hardware I already had, essentially letting my server serve as an internet router.
Homepage: https://mpservers.net/
![]() |
Notes is a web-based application for online taking notes. You can take your notes and share with others people. If you like taking long notes, notes.io is designed for you. To date, over 8,000,000,000+ notes created and continuing...
With notes.io;
- * You can take a note from anywhere and any device with internet connection.
- * You can share the notes in social platforms (YouTube, Facebook, Twitter, instagram etc.).
- * You can quickly share your contents without website, blog and e-mail.
- * You don't need to create any Account to share a note. As you wish you can use quick, easy and best shortened notes with sms, websites, e-mail, or messaging services (WhatsApp, iMessage, Telegram, Signal).
- * Notes.io has fabulous infrastructure design for a short link and allows you to share the note as an easy and understandable link.
Fast: Notes.io is built for speed and performance. You can take a notes quickly and browse your archive.
Easy: Notes.io doesn’t require installation. Just write and share note!
Short: Notes.io’s url just 8 character. You’ll get shorten link of your note when you want to share. (Ex: notes.io/q )
Free: Notes.io works for 14 years and has been free since the day it was started.
You immediately create your first note and start sharing with the ones you wish. If you want to contact us, you can use the following communication channels;
Email: [email protected]
Twitter: http://twitter.com/notesio
Instagram: http://instagram.com/notes.io
Facebook: http://facebook.com/notesio
Regards;
Notes.io Team