-
Notifications
You must be signed in to change notification settings - Fork 83
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stuck on Starting v6 Control Plane #35
Comments
I'm not immediately sure what question you're asking but:
Here's my service definition:
The one thing I did note is your If that doesn't help, try setting
In my case, everything is transiting the Ethernet port. The WiFi port is really only there as a backup. If you prefer to stick with
Another possibility is to start with If it looks like the container is running and the net-filters are in place, try sniffing the zerotier interface:
where you can get the interface from If you're just getting started with ZeroTier-router, you might also find this helpful. |
I did try with NFT, but not that did not work. NFT tables does not look to be supported on Ubuntu, and the ZeroTier docs say NFT is only on Raspberry PI systems. |
I think this maybe an issue with the permissions on the /var/lib/zerotier. Appears it sets aa weird ownership |
I assume you mean the following words from README-router.md:
That doesn't actually say only on Raspberry Pi. It simply says it is needed on Pi Bullseye. It may also be needed on other systems. Some background may help. At the time I was writing that readme file, I was doing the work on a Bullseye Pi. The only thing I knew for certain was that setting up the net filters with
I do not believe that is true. All this is from an Ubuntu guest running on Proxmox-VE:
No containers, no images, nothing up my sleeves:
What's the story with net filters:
The If you don't get a similar result then I'd suggest maybe revisiting how you installed Docker on this system. Please treat that as a serious suggestion. You'd be surprised at how many problems can be traced to an improper installation of Docker. And those improper installations can often be traced to bad advice in YouTube videos or "how to" documents on the web. If you want me to expand on this, I'd be happy to. You also wrote this:
The answer here is roughly the same as for At the time I didn't know the origin of 999 and 994. I still don't. Those IDs aren't defined inside the container so I'd definitely agree this is a bit "weird". But, because I didn't understand it, I preserved those IDs as the defaults. On the Linux systems I play with, the first non-root user gets UID=1000, GID=1000 so I tested that ZeroTier (as implemented in the container) didn't object to those values being applied via environment variables. I work mainly with In any event, the ZeroTier processes run as root so, as far as I'm aware, the only thing that gets affected by PUID/PGID is the ownership of In short, I doubt that 999/994 is going to be the answer. We're going to be talking about "routing" so let's baseline the routing table on this Ubuntu system so we can spot changes later:
Here's my compose file:
Let's give it a whirl:
Now, yes, the last line is "Starting V6 Control Plane" but that doesn't mean it's somehow stuck. That's just the last message it emitted. What does the container think is going on?
It thinks ZeroTier is up but this newly-established client is not authorised to connect to my ZeroTier network. That's expected. I haven't gone to ZeroTier Central to authorise this new client. Also expected is that the routing table hasn't changed (because the client hasn't joined my ZeroTier network and can't forward traffic to/from):
Meanwhile, what's the story with net filters:
Thus some new rules have been added. I'll go to ZeroTier Central and authorise this client ... What does the container think now?
It has joined the network. The routing table?
All as expected. 10.244/16 is the ZeroTier network, while 192.168/23 is being advertised by ZeroTier Cloud. So what about reachability of a host where the only possible path is via the ZeroTier Cloud?
All works. Now, I've never done this before but I'll try using
The decks are cleared. Holding my breath:
Notes:
What's the situation now this is running?
I reckon it works. On Ubuntu 24.04.1 LTS (Noble Numbat). At least when that's running as a Proxmox-VE guest on an old Intel-based MacBook Pro. That said, I now realise that the "Command line example" in the documentation lacks a lot. It really should be something like this:
Similarly, the example service definition needs some tweaks:
The section on
Please tell me if you are able to get it working and whether you'd like to see anything else in the documentation. Then I'll prepare a pull request. |
Starting with no containers or images. I get the following on Ubuntu and this worked with version 1.20 of Zerotier on another Ubuntu Box.
Distributor ID: Ubuntu
Description: Ubuntu 24.04.1 LTS
Release: 24.04
Codename: noble
When I run the following command (NetworkID Changed)
docker run --name zerotier-one --device=/dev/net/tun --cap-add=NET_ADMIN --cap-add=NET_RAW --cap-add=SYS_ADMIN --env TZ=Etc/UTC --env PUID=999 --env PGID=994 --env ZEROTIER_ONE_LOCAL_PHYS=enp1s0f0 --env ZEROTIER_ONE_USE_IPTABLES_NFT=false --env ZEROTIER_ONE_GATEWAY_MODE=inbound --env ZEROTIER_ONE_NETWORK_IDS=xxxxxxxxxx -v /var/lib/zerotier-one:/var/lib/zerotier-one zyclonite/zerotier:router
I get the following
sagadmin@mn-zerotier:~$ sudo docker run --name zerotier-one --device=/dev/net/tun --cap-add=NET_ADMIN --cap-add=NET_RAW --cap-add=SYS_ADMIN --env TZ=Etc/UTC --env PUID=999 --env PGID=994 --env ZEROTIER_ONE_LOCAL_PHYS=enp1s0f0 --env ZEROTIER_ONE_USE_IPTABLES_NFT=false --env ZEROTIER_ONE_GATEWAY_MODE=inbound --env ZEROTIER_ONE_NETWORK_IDS=xxxxxxxxx -v /var/lib/zerotier-one:/var/lib/zerotier-one zyclonite/zerotier:router
Unable to find image 'zyclonite/zerotier:router' locally
router: Pulling from zyclonite/zerotier
20aa84b242f8: Pull complete
04e7b3706e72: Pull complete
43f96568de03: Pull complete
Digest: sha256:78540326002a2b6fa2249f64e3d0d716fe8b457c7be990d16c1f75245f42796e
Status: Downloaded newer image for zyclonite/zerotier:router
Tue Nov 26 01:22:26 UTC 2024 - launching ZeroTier-One in routing mode
adding iptables-legacy rules for inbound traffic (ZeroTier to local interfaces enp1s0f0)
Tue Nov 26 01:22:26 UTC 2024 - ZeroTier daemon is running as process 17
Starting Control Plane...
Starting V6 Control Plane...
The text was updated successfully, but these errors were encountered: