FOSSFEEDWhere activity matters more than stars. Discover Fire Pit Noted Submit a project
← All articles

Tailscale Part 2: Access Your Entire Homelab With Subnet Routing

Learn how Tailscale subnet routing lets you securely access your entire homelab remotely without installing Tailscale on every device.

In the first part of this series, we covered getting Tailscale installed and connecting to a server remotely. It's a great starting point, but there's one limitation you might have noticed. By default, you can only connect directly to devices that have Tailscale installed.

If your homelab is anything like mine, you probably have quite a few devices scattered around your network. Installing Tailscale on every single machine isn't necessarily something you want to do, especially when some devices don't support it in the first place.

Fortunately, Tailscale has a feature called subnet routing that solves this problem.

What is subnet routing? #

Subnet routing allows one device running Tailscale to provide access to other devices on your local network. Instead of installing Tailscale everywhere, you designate an existing machine to act as a gateway between your private Tailscale network and your homelab.

For example, let's say your home network uses the 192.168.1.x address range. You might have Proxmox running alongside a NAS and several other devices. With subnet routing configured on a Linux server, you can connect to those devices remotely using their existing local IP addresses.

The nice thing about this approach is that nothing needs to change on those other devices. They don't even need to know Tailscale exists.

Setting up your subnet router #

For this example, we'll use a Linux server that's already connected to Tailscale. Ideally, choose a machine that stays powered on, since your remote connections will depend on it being available.

First, we need to enable something called IP forwarding. This allows Linux to pass network traffic between interfaces instead of only accepting traffic intended for itself.

Run these commands:

echo 'net.ipv4.ip_forward = 1' | sudo tee /etc/sysctl.d/99-tailscale.conf
sudo sysctl -p /etc/sysctl.d/99-tailscale.conf

Next, tell Tailscale which local network you want to make accessible:

sudo tailscale set --advertise-routes=192.168.1.0/24

The /24 tells Tailscale we're advertising the entire 192.168.1.x subnet. Make sure you replace this example with your actual network range.

Approving your subnet route #

We're almost finished, but there's one more important step. Tailscale requires advertised subnet routes to be approved before they become available, unless you've configured automatic approval.

Open the Tailscale administration dashboard and locate your Linux server. Open its route settings and approve the advertised subnet.

Your tailnet's access policies must also allow connections to that subnet. Before granting access, consider which users and devices actually need to reach your homelab.

On phones and Windows devices, approved subnet routes are normally picked up automatically. If you're connecting from another Linux machine, you'll need to run:

sudo tailscale set --accept-routes

Testing your connection #

Now comes the fun part. Disconnect your phone from Wi-Fi, enable mobile data, and connect to Tailscale.

Open your browser and enter the local IP address of a service running on your homelab. For example, if Proxmox is available at https://192.168.1.50:8006, try accessing that address.

Assuming your routing and firewall settings permit the connection, the familiar Proxmox login screen should appear. You've just accessed a device on your home network without installing Tailscale directly on it.

That's a pretty useful addition to any homelab, especially if you're managing multiple machines.

What's next? #

Now that we can access our homelab remotely, there's another Tailscale feature worth exploring. It's called MagicDNS, and it allows us to connect to Tailscale devices using readable names instead of remembering their IP addresses.

We'll cover that in Part 3.

Comments 0

Join the conversation.

Write a comment

No comments yet. Be the first to comment.

Leave a comment

Anonymous comments are reviewed before publication. Sign in to comment as a member.

Navigation