[BlueOnyx:24390] Re: In mysql, user at localhost and user at 127.0.0.1 are different.

Michael Stauber mstauber at blueonyx.it
Thu Oct 15 21:51:05 -05 2020


Hi Ernie,

> The real killer was the speed difference between http and https it was over
> 500% which really surprised me. I had no idea https bogged down a sever so
> much. I didn't test the nginx proxy, just straight apache to keep it simple.

Yeah, HTTPS and TLS adds a lot of overhead. And it gets worse the
stronger the encryption is that you throw at it. It's also costly in
terms of CPU usage.

I had an interesting issue recently where I needed to move stuff via
RSYNC between servers, but the source server was already kinda busy with
it's usual stuff.

A regular RSYNC over SSH like this ...

/usr/bin/rsync -harvl --delete --progress --links --hard-links --perms
--owner --group --devices --times root@<source_host>:/files/* /files/

... quickly drove the CPU load on the source server into crazy regions
such as a load average of 225.

Then I ran the same RSYNC with this switch added:

--rsh="ssh -c arcfour"

That forces SSH to not negotiate the best and strongest ciphers and
protocols for the data transfer, but limits it to use "arcfour" instead.
Which isn't exactly unsafe, but of a hell of a lot weaker. On the upside
it uses a lot fewer CPU computations. Which made it ideal for this case.

Bottom result was: The load stayed at slightly above normal without the
server skipping a beat.

Encryption is good and often necessary. But it's costly.

-- 

With best regards

Michael Stauber



More information about the Blueonyx mailing list