Adding servers to the China zone

#293

Here is the git repository. I am sure that Ask would accept your pull request if you make one. https://github.com/abh/ntppool

#294

Good keep it there. It keeps dropping below 10 but I don’t know if that’s the monitor or it catching high load so I put a log on load averages and I’m inferring about bandwidth prices with the host.

Noah
https://logiplex.net

#295

As a side note. The one of my servers in the CN zone that is working, has kept a score of higher than 10 for a little while now at 100 speed setting. So I may increase that

#296

[root@logiplex.net][/opt/src/ntppool/lib/NP/Model]# grep -nA 2 active_score Server.pm
15:sub active_score {
16- return 10;
17-}

I know PERL quite well. I will keep you updated.

Next it is used in `./ntppool/lib/NP/Model/Zone.pm’ to get entries from an SQL server in :

my $entries = $dbh->selectall_arrayref(
    qq[SELECT s.ip, s.netspeed
     FROM servers s, server_zones l
     WHERE l.server_id = s.id AND l.zone_id = ? AND s.in_pool = 1 AND s.ip_version=?
     AND s.score_raw > ?
     and (s.deletion_on IS NULL OR s.deletion_on > DATE_ADD(NOW(), interval ? day))
    ], undef,
    $self->id,
    $ip_version,
    NP::Model::Server->active_score,
    $self->deletion_grace_days
);

[edit: this is inside of the active_servers method]

It is polling an SQL database for `score_raw’ larger than 10, so further is to look how this variable/information is used, but I’m almost positive this is it.

Further on, this does mean that `active_score’ is meaning the score to keep active in the DNS. That is, if this code is not simply for the web interface of ntppool, as it looks that way slightly. I would have to look further when I have time. [also further on, this is unable to be verified for the reason below]

Further on, that data is used by converting it into other object variable constructs in `DnsRoot.pm’ in the same directory. That information is further used in `./ntppool/lib/NTPPool/Control/DNSZone.pm’ in an object called `render’ via object reference. Yet no further code calls the `render’ object from there, so this is indicative that there is more code missing, and that it is unable to be told if this is indeed code used to update the DNS entries with the IP addresses or used to render the website. Inside of `DNSZone.pm’ the `render’ object is the last reference where of which the value is converted to JSON for use in another location, yet the object/data is never called/used in this code in the git repository you mentioned, as these are libraries to be used somewhere else.

A lot of edits, but there is some information. I am looking at this now as this explanation may not be exactly accurate. I was up late last night and needed to get to bed. [edit: looks like what I said above about no further reference, could very well be untrue]

Yes, I found the object’s next reference: `return $self->SUPER::render(@_);’ in `./ntppool/lib/NTPPool/Control/Basic.pm’ moving on… At the moment I am doing so many things for my 83 year old grandmother I am visiting in NY, from NC, that I will have to piece this together in time.

Further on, taking another reference path (from before it is used in DNSZone.pm), `active_servers()’ is called from `populate_country_zones’ in `DnsRoot.pm’ where I am leaving off, yet it is being used for pgeodns which is a PERL DNS server, I have found from googling. At this point it looks as if that either way active_score is going to be used for both updating the DNS and rendering the website.

Thanks,

Noah
https://logiplex.net

1 Like
#297

Okey, added. Thanks for helping :slight_smile:

#298

Okey, I have added the IPv6 servers to CN but IPv6 servers has never been a problem for the CN pool. Its IPv4 that is a problem. From now lets focus on adding IPv4 servers.
Its getting better with 18 IPv4 servers in the pool for now.

I have also moved the CA server to US.

#299

Thanks. It looks like the CN zone is doing better. I’m only getting about 15mbps of NTP which is about 25kpps.

#301

@iocc Please also add this server to the CN zone, thanks again!

https://www.ntppool.org/scores/148.251.69.45

#303

@iocc

Please also add these two servers to CN pool:

185.209.85.222
45.43.30.59

1 Like
#304

@iocc

https://www.ntppool.org/scores/45.124.64.93
https://www.ntppool.org/scores/2402:9e80:0:1000::1:68d6
https://www.ntppool.org/scores/2402:9e80:0:1000::1:aa56

Please place in the cn and hk zones and remove from the asia zone

Another HK VPS up for the next year

#305

Sure, its now added!

1 Like
#306

They are added now. Thanks for helping.

#307

I have added the IPv4 to cn and removed asia. IPv6 is not a problem for the CN pool.
Thanks.

#308

hey iocc:
can you please remove these servers from all zones except cn? Thanks
https://www.ntppool.org/scores/95.216.144.226
https://www.ntppool.org/scores/116.203.67.76

And add this server to the cn zone:
https://www.ntppool.org/scores/144.76.76.107
https://www.ntppool.org/scores/2a01:4f8:191:946a::2

#309

Done, done and done. Thanks.

#310

I put together one last unmetered kvm VPS to be dedicated to China. Does anyone know an appropriate speed setting for it? It is 2ghz 100MiBit. CPU will definitely be the limit. I think it should do 30kqps just fine. It’s a ways away but China needs it.

@iocc please add this last one to cn zone and take it out of everything else. It will score up in a bit.

https://www.ntppool.org/scores/192.99.68.38

#311

Ok, fixed.

For the moment the CN pool seems stable with around 20 servers.
I have experimented with different bandwidth settings and right now
with 20 working servers I get approx this amount of traffic for each
setting below:

100 Mbit/s - 2000 KB/s
250 Mbit/s - 2800 KB/s
500 Mbit/s - 3500 KB/s

Around 4000 KB/s the VM starts to drop packets and cant keep up with
the packetrate so I will stay on 500 Mbit/s for now.
Its good to to have margins as spikes might come.

1 Like
#312

On my main CN zone server, I am seeing around 10mbps at the 1000mbps setting. Before the 20th of March, I was seeing as much as 30mbps. Current packet numbers are about 20kpps down from around 40kpps before the 20th.


1 Like
#313

For anyone who interested about this. This is some monitoring result from China yesterday. Thanks for your help, CN zone running well.

The problem now is delay: most server has delay more than 100ms. Still need server in China to solve it.

#314

Theoretically we can have pool servers from other east Asian zones supporting China zone to achieve a lower latency for China users, however most Asian zones are in lack of pool servers, so it might not be a practical solution. I guess we still need to have a monitor inside China before we can really have pool servers inside China.