Best practice if you are behind a CGNAT?

Hi Guys,

unfortunately I am behind a CGNAT and my ISP offers only dslite, so I have not a real IPv4 address.

At the moment I use VPN with Private Internet Access, but I see many VPN servers from PIA where already other storj nodes are running and the automatic port changes from PIA aren`t good for my online score^^.

So I am curous what is the best practice if you are behind a CGNAT and how to get an unused /24 subnet?

Using another VPN provider with port forwarding? Getting a VPS and connect STORJ storage via ZFS?

I´m an interested newbie and need some hints from the experts. I run 3 nodes from home at the moment with 54 TB storage and I want to ramp up and to get good ingress to fill up my space.

Thanks for your help!

You can search for other VPN providers with port forwarding feature, but likely they will have nodes too.
Please, do not use network connected storage, they are much slower to respond and you will have a huge memory usage in a happy case, or disqualified node in worse.

2 Likes

Likely the the mix of two would be better: get a VPS with sufficient bandwidth and run vpn endpoint on it, e.g. wireguard, with port forwarding to your server.

Since this requires some configuration not many people would have done it and you likely won’t be sharing the /24 subnet. You can always check the public IP you are issued here Neighbors before going through the trouble of configuring the tunnel.

1 Like

Yeah I got already a VPS and I saved money for the next 18 TB HDD. I will give it a try to setup my own VPN server. This month ingress is really low on my nodes until now.

I know it’s a bit old thread, but I think it’s the best place to write.

I have been reading the forum a lot lately, received valuable information, but I’ve decided to write myself for the first time.

I live in Russia, Saint Petersburg, and lately I completed setting up 6 nodes, using 6 HDDs on 6 VMs hosted on a Windows Server based on a 7-year-old computer. The big problem I had was with port forwarding, as I’m behind CgNAT. I managed to find a VPN service that allows static port forwarding, but I had to use a second VPN service to access the first one.

In a nutshell, the server connects to a VPN that doesn’t provide static port forwarding (but works in Russia) and the VMs connect to the VPN that does allow static port forwarding (but doesn’t work in Russia). Speed is like 70/20Mbps for the nodes, 40ms ping.

Yes, it’s working, vetting done, but could my setup with double VPN be the reason for these yellow online percentages? Does this affect the utilization of the disks? I’m thinking of adding a couple more (rather big disks), but I’m skeptical, as I don’t know if they manage to be fully used with these 96-99 percentages for online status.

I had a bad vpn provider myself. Yes that caused the yellow (and sometimes red) online marked. So it could be the same for you.
The question is, wouldn’t it be easier to rent a small vps and set up a vpn there? (And maybe cheaper?)
I used a oracle vps for that with zerotier vpn. It works flawless for me and I have max speed and online scores again.
Double vpn provide 2 more points that may brake at any time.

Here are many good tutorials to set up a own vps with like openvpn or something else. (I never read someone use zerotier but I use it, because it works best for me)

Edit: this is a pretty good tutorial from @arrogantrabbit
It workes on any Linux machine. So you don’t have to use Oracle for that.

As I understand, the Oracle VPS is “the computer with public IP” and you connect on that using Zerotier. I suppose is something similar with the RPi I set up in my home town in Greece, to have domestic IP access from there. Wouldn’t that mean that if I did so, I would get one public IP for all the VMs? Is that proper, considering that each VM works independently? If that’s the case, I could ask them if I could get a static IP from the ISP and avoid the mess with setting up a VPS, maybe.

If you can get a a ip (dynamic or static doesn’t matter) that you can use port forwarding with. That would be the best, because it removes latency and a fail point.
Your vpn is basically the same: " just a computer with a public IP, that allows port forwarding"

But I personally would choose my own server owner a public vpn, because I have more control over it. I had very bad experience with other managed vpns

And yes, the public IP would be for all nodes. But you can add one server/ip per node.

I understand… I’ll have to think this through. Thank you very much for your response!

With 70Mbps those disks would never fill. You need faster internet first.

I’m kinda glad you touched this topic.

My first attempt was 2 nodes with 1TB each. I was frequently checking them and I realized that even without having vetted yet, they were filling with an approximate rate of 18GB/h. That was around and of April. Maybe the VPN servers somehow managed to reach better speed during this period, or Storj decided to use all the available speed? I have a gut filling that it was a Storj version “bug”, but I can’t prove it. All I know is that I didn’t see anything even close to that 2 months later. I guess I’ll have to improve my speeds anyway.

For any internet speed you will reach one day a balance between deletes and incoming new data. Current test data comes with 30 days TTL, so the math is easy to do.

Hello @christos,
Welcome to the forum!

Yes, this is absolutely the correct way. Since all VMs are working in the same physical place, they should not try to trick a node selection system to mimic a different physical locations, which will alter the default Storj network behavior and would allow to store more than a one piece of the same segment in the same physical location or for the same ISP, this will reduce the resilience and the customer may lost data if your server or ISP would go offline.
So, if you can get a public dynamic or static IP from your ISP - it will be a best way. You may also remove all VMs and run the Windows services with help of a @Vadim’s Win GUI Storj Node Toolbox directly on the server or using docker. This will significantly simplify the setup.

Thank you for welcoming me! :slightly_smiling_face:

Yes, I guess I could get that static IP. I was thinking about doing the docker thing, but it got too scary just copying and pasting commands that I have absolutely no idea what they are doing, so I gave it up. But maybe I could use the toolbox, as it’s Windows based. I’ll give it a shot, thank you for your response!

1 Like

The static IP is not necessary thing, since you may use a NOIP service to get your own DDNS domain and setup an updater. You would use this DDNS domain and port instead of a plain IP and port and you wouldn’t be forced to update you config, when the ISP would change the IP.
If you would go this route, I would recommend to setup an updater on your router (most of them supports NOIP) and do not install their client on your box.

In some cases the public dynamic IP would cost you nothing (take a look on a SkyNet (I know) ISP provider - they usually have a best offering in the St. Petersburg, I have a “dynamic” IP, which never changing, unless you fail to pay the bill… Then it will change, but then it’s pretty much as a static IP, I didn’t have bothered to setup a NOIP either).

Well, yes, that would be the best. However, I’m on Rostelecom Cloud plan and I wouldn’t like to change to something else (exactly because of the huge cloud storage). So, when I asked, they told me, static IP, or no public IP at all. :slight_smile:

1 Like

By the way, you may consider to use a Storj cloud instead :wink:

Apparently I missed the email notification.

I could use Storj cloud, it’s rather inexpensive, sure, but the other is actually free. Even comparing with the cheapest ISP at that speed, the difference is 1 dollar for 16TB. It’s unbeatable!