Reliance Jio 4G: Strange public IPv4 address assigned behind NAT

  • Thread starter Thread starter varkey
  • Start date Start date
  • Replies Replies 86
  • Views Views 24,434
@varkey @popcorn I guess I have a valid idea to get the cameras live.
I can host docker server on my computer and in ZeroTier we have a option to redirect the traffic to specific LAN ip which will be my old DVR ip.
Using the docker server I can access and manage the cameras anytime anywhere 😂.

Lot of work need to be done for this 😴.

What do you think?

1593580659047.png


thanks @varkey for letting me know this cool stuff (ZeroTier). Even it is open source so we can tweak features 👨‍💻.
 

I also got this pre-built docker image for ZeroTier which helps to directly run the docker container without doing any config. Just plug and play.

Even you can host the ZeroTier custom container on the AWS this is next level.
 
troubles are more then rewards.
Rs. 400 x 12 = INR 4800. (Your Static IP cost) keeping a computer on 24x7.
You can spend a little more & can get a good dvr/nvr with latest technology.
You can use any internet and live view.

With your existing setup (You have a new nvr & old dvr)
I am not sure if with your new nvr, can you connect the old dvr using switch? Will that newer nvr detect the cameras from old dvr?
Try experimenting it. As far as I know in Hikvision newer dvrs you can install few analog & over that few IP camera also which are detected if you on a common switch.
 
@varkey I implemented ZeroTier, But as you can see I get very poor ping results on Jio network, But the Vodafone was performing some what better then Jio since in Vodafone I get assigned ipv4 only. These pings are not good for remote live view 😬.

PS. As you can see Jio is using IPV6 due to which ZeroTier RFC4193 causing overhead (bottleneck) to translate between ipv6 to ipv4 which is the main reason behind poor ping.

Also I am using private node which also results in this poor ping.
Can we use public node? Is it safe to use?

🤔 I doubt that has anything to do with IPv4/IPv6. If the ZeroTier node on the other end has both IPv4 and IPv6, the appropriate mode is chosen automatically depending on the available connectivity options on the source side. Also, just cause it displays the IPv6 address on the ZeroTier UI, doesn't mean that path is chosen by each node. Each peer to peer connection would use the best available mode always, if it can establish a direct connectivity over IPv4 between peer A and peer B, then it uses that. However if the best path between peer B and peer C is over IPv6, then that is used.

Which connection do you have on the source side? One end is JIo 4G. The poor ping was because it wasn't able to establish direct connectivity and hence was making use of a ZeroTier relay node. If you have Jio 4G on both sides of the link, they you might have challenges, however if one side has good non CG-NAT based connectivity options it improves things.

This is a comparison between direct and via ZeroTier, note that this is not on Jio and the other end has a public IP address

Code:
root@varkey:~# ping -c 4 172.22.1.200
PING 172.22.1.200 (172.22.1.200): 56 data bytes
64 bytes from 172.22.1.200: seq=0 ttl=64 time=149.855 ms
64 bytes from 172.22.1.200: seq=1 ttl=64 time=153.211 ms
64 bytes from 172.22.1.200: seq=2 ttl=64 time=152.443 ms
64 bytes from 172.22.1.200: seq=3 ttl=64 time=149.765 ms

--- 172.22.1.200 ping statistics ---
4 packets transmitted, 4 packets received, 0% packet loss
round-trip min/avg/max = 149.765/151.318/153.211 ms
root@varkey:~# ping -c 4 159.69.86.136
PING 159.69.86.136 (159.69.86.136): 56 data bytes
64 bytes from 159.69.86.136: seq=0 ttl=39 time=149.486 ms
64 bytes from 159.69.86.136: seq=1 ttl=39 time=149.246 ms
64 bytes from 159.69.86.136: seq=2 ttl=39 time=149.089 ms
64 bytes from 159.69.86.136: seq=3 ttl=39 time=149.315 ms

--- 159.69.86.136 ping statistics ---
4 packets transmitted, 4 packets received, 0% packet loss
round-trip min/avg/max = 149.089/149.284/149.486 ms
root@varkey:~#
 
troubles are more then rewards.
Rs. 400 x 12 = INR 4800. (Your Static IP cost) keeping a computer on 24x7.
You can spend a little more & can get a good dvr/nvr with latest technology.
You can use any internet and live view.

With your existing setup (You have a new nvr & old dvr)
I am not sure if with your new nvr, can you connect the old dvr using switch? Will that newer nvr detect the cameras from old dvr?
Try experimenting it. As far as I know in Hikvision newer dvrs you can install few analog & over that few IP camera also which are detected if you on a common switch.

I already though of buying new NVR but my father is not allowing me to spend on it so I had to think other bullshit ideas😢.

I'll try to add older cameras to NVR and check if it work
 


🤔 I doubt that has anything to do with IPv4/IPv6. If the ZeroTier node on the other end has both IPv4 and IPv6, the appropriate mode is chosen automatically depending on the available connectivity options on the source side. Also, just cause it displays the IPv6 address on the ZeroTier UI, doesn't mean that path is chosen by each node. Each peer to peer connection would use the best available mode always, if it can establish a direct connectivity over IPv4 between peer A and peer B, then it uses that. However if the best path between peer B and peer C is over IPv6, then that is used.

Which connection do you have on the source side? One end is JIo 4G. The poor ping was because it wasn't able to establish direct connectivity and hence was making use of a ZeroTier relay node. If you have Jio 4G on both sides of the link, they you might have challenges, however if one side has good non CG-NAT based connectivity options it improves things.

This is a comparison between direct and via ZeroTier, note that this is not on Jio and the other end has a public IP address

Code:
root@varkey:~# ping -c 4 172.22.1.200
PING 172.22.1.200 (172.22.1.200): 56 data bytes
64 bytes from 172.22.1.200: seq=0 ttl=64 time=149.855 ms
64 bytes from 172.22.1.200: seq=1 ttl=64 time=153.211 ms
64 bytes from 172.22.1.200: seq=2 ttl=64 time=152.443 ms
64 bytes from 172.22.1.200: seq=3 ttl=64 time=149.765 ms

--- 172.22.1.200 ping statistics ---
4 packets transmitted, 4 packets received, 0% packet loss
round-trip min/avg/max = 149.765/151.318/153.211 ms
root@varkey:~# ping -c 4 159.69.86.136
PING 159.69.86.136 (159.69.86.136): 56 data bytes
64 bytes from 159.69.86.136: seq=0 ttl=39 time=149.486 ms
64 bytes from 159.69.86.136: seq=1 ttl=39 time=149.246 ms
64 bytes from 159.69.86.136: seq=2 ttl=39 time=149.089 ms
64 bytes from 159.69.86.136: seq=3 ttl=39 time=149.315 ms

--- 159.69.86.136 ping statistics ---
4 packets transmitted, 4 packets received, 0% packet loss
round-trip min/avg/max = 149.089/149.284/149.486 ms
root@varkey:~#

I'll try with public nodes it may help to get better ping. the above results were on the private nodes which I created.

Is public node safe to use?
 
@devangpatel What do you mean by public nodes? Are you referring to the ZeroTier private and public networks? That has no difference, you should always use a Private Network unless you really want to make it public.
 
@varkey After some trial and error I observed that I get better ping (70-150 ms) when I use ZeroTier with ipv4 accessible network I mean the local ISP network with static ip. With ipv6 accessible network like Jio 4G or any network which is behind Double NAT (CG-NAT) I get poor ping (generally more then 250 ms).

I also read on the ZeroTier documentation that if you have open port 9993 (which is default port for ZeroTier) for UDP you get better ping.

Also this TCP fallback is the slowest form of relaying as per the docs.
Screen Shot 2020-07-05 at 10.14.49 AM.webp


Screen Shot 2020-07-05 at 10.15.06 AM.png
 
@devangpatel As I mentioned earlier, what is the network connection on the other end? One one side its Jio 4G. If both sides are behind CG-NAT, then you might have challenges, but if once side has good direct connectivity and the other end is on Jio, it will still establish a direct path. Also, regarding the output you shared, you need to be looking at tcpFallbackActive not allowTcpFallbackRelay. The latter simply states that TCP fallback is allowed not whether it is active at the moment.

Right now, for me, one side in Jio 4G, and the other end is on a properly connected network with public IP address. I get direct access to the Jio 4G node and tcpFallbackActive is false

IPv6/IPv4 is not really an issue, it will choose the optimal path. In the above case I mentioned, the direct path was established with Jio IPv4 behind CG-NAT.
 
@varkey now I have been using ZeroTier for couple of week on local ISP who provide public IP. Now I am getting better pings and even faster data rates. But at Jio end it still sucks.

Also I tried ngrok and other SSH tunnelling(Localhost.run) programs but data transfer rate where not up to the mark as ZeroTier.

PS. I Got open port 9993 from my ISP and setup port forwarding which helped me to get better speeds and better pings.
 
@devangpatel Did you make sure to use region IN in config when using ngrok? By default traffic will go through US. With IN option it will go through AWS Mumbai and if ISP has peering with AWS it's quite fast.
 

Top