[squid-users] Setting Squid to work with a remote DB?
roee klinger
roeeklinger60 at gmail.com
Sat Aug 28 18:59:14 UTC 2021
Hello,
I have multiple Squid servers installed in different data centers across
different cloud providers, and they all need to authenticate users using
a single database (MySQL) on a separate server, which is also on a
different cloud provider on a different data center.
I have already written an external authentication script that reads from
MySQL and everything is working fine, however, I have some
performance concerns, since the DB is located externally and in a different
region of the world from the Squid server.
I made some speed tests to see how long it takes to query the DB as Squid
would:
if the database is located on the same machine as Squid: 1.067-millisecond
average query
if the database is located on the same datacenter as Squid:
2.67-millisecond average query
if the database is located on a different datacenter than Squid (different
country as well): 38.9-millisecond average query
Now I am wondering, is 36-millisecond average added query time a big deal
when dealing with HTTP/S traffic? how significant is this added time to
Squid and will performance get hurt drastically?
I know there is some caching going on the Squid side, but I had to set the
caching to really low values (around 15s), as per the requirement I was
given.
If I will have no other choice, I will simply replicate the DB table from
the DB server to the Squid server, but I prefer not to do that, as it will
require installing MySQL on all the Squid servers (or some other DB, but
then I have to do replication from different DBs).
Thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squid-cache.org/pipermail/squid-users/attachments/20210828/9c6a7cd0/attachment.htm>
More information about the squid-users
mailing list