<div dir="ltr"><div><div>This is the only error message we received from ab. <br><br></div><div>I googled it and found that it is due to the connection drop. So It would be Great, If you could check my Apache server configuration I shared in the thread and let me know your thoughts on this. <br></div><div><br></div>Thanks,<br></div>Hari <br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Mar 8, 2018 at 4:56 PM, Juan Hernández <span dir="ltr"><<a href="mailto:jhernand@redhat.com" target="_blank">jhernand@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">But other than those SSL error messages, are the connections really failing? Can you share the results reported by "ab"?<div class="HOEnZb"><div class="h5"><br>
<br>
On 03/08/2018 12:16 PM, Hari Prasanth Loganathan wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
No Juan, It is not working with any benchmark / application tool. It fails<br>
with the same error SSL handshake failed (5).<br>
<br>
Could you let me know the configuration of Apache web server is correct?<br>
<br>
Thanks,<br>
Hari<br>
<br>
On Thu, Mar 8, 2018 at 1:08 AM, Juan Hernández <<a href="mailto:jhernand@redhat.com" target="_blank">jhernand@redhat.com</a>> wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
If you are still having problems I am inclined to think that it is a<br>
client issue. For example, I'd try to remove the "-k" option from the "ab"<br>
command. If you use keep alive the server may decide anyhow to close the<br>
connection after certain number of requests, even if the client asks to<br>
keep it alive. Some clients don't handle that perfectly, "ab" may have that<br>
problem. If that makes the SSL error messages disappear then I think you<br>
can safely ignore them, and restore the "-k" option, if you want.<br>
<br>
On 03/07/2018 07:30 PM, Hari Prasanth Loganathan wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Thanks Juan for your response. Appreciate it.<br>
But for some reason still, I am facing the same SSL handshake failed (5).<br>
Could you please check this configuration and let me know the issue in my<br>
ovirt engine environment.<br>
<br>
*Configuration of Apache server:*<br>
<br>
<br>
1) httpd version,<br>
<br>
# httpd -v<br>
Server version: Apache/2.4.6 (CentOS)<br>
Server built: Oct 19 2017 20:39:16<br>
<br>
2) I checked the status using the following command,<br>
<br>
# systemctl status httpd -l<br>
● httpd.service - The Apache HTTP Server<br>
Loaded: loaded (/usr/lib/systemd/system/httpd<wbr>.service; enabled;<br>
vendor<br>
preset: disabled)<br>
Active: active (running) since Wed 2018-03-07 23:46:32 IST; 1min 55s<br>
ago<br>
Docs: man:httpd(8)<br>
man:apachectl(8)<br>
Process: 4351 ExecStop=/bin/kill -WINCH ${MAINPID} (code=exited,<br>
status=0/SUCCESS)<br>
Main PID: 4359 (httpd)<br>
Status: "Total requests: 264; Current requests/sec: 0.1; Current<br>
traffic: 204 B/sec"<br>
CGroup: /system.slice/httpd.service<br>
├─4359 /usr/sbin/httpd -DFOREGROUND<br>
├─4360 /usr/sbin/httpd -DFOREGROUND<br>
├─4362 /usr/sbin/httpd -DFOREGROUND<br>
├─5100 /usr/sbin/httpd -DFOREGROUND<br>
├─5386 /usr/sbin/httpd -DFOREGROUND<br>
├─5415 /usr/sbin/httpd -DFOREGROUND<br>
└─5416 /usr/sbin/httpd -DFOREGROUND<br>
<br>
3) Since the httpd is pointing to the path :<br>
/usr/lib/systemd/system/httpd.<wbr>service<br>
<br>
vi /usr/lib/systemd/system/httpd.<wbr>service<br>
<br>
[Unit]<br>
Description=The Apache HTTP Server<br>
After=network.target remote-fs.target nss-lookup.target<br>
Documentation=man:httpd(8)<br>
Documentation=man:apachectl(8)<br>
<br>
[Service]<br>
Type=notify<br>
EnvironmentFile=/etc/sysconfig<wbr>/httpd<br>
ExecStart=/usr/sbin/httpd $OPTIONS -DFOREGROUND<br>
ExecReload=/usr/sbin/httpd $OPTIONS -k graceful<br>
ExecStop=/bin/kill -WINCH ${MAINPID}<br>
# We want systemd to give httpd some time to finish gracefully, but still<br>
want<br>
# it to kill httpd after TimeoutStopSec if something went wrong during the<br>
# graceful stop. Normally, Systemd sends SIGTERM signal right after the<br>
# ExecStop, which would kill httpd. We are sending useless SIGCONT here to<br>
give<br>
# httpd time to finish.<br>
KillSignal=SIGCONT<br>
PrivateTmp=true<br>
<br>
[Install]<br>
WantedBy=multi-user.target<br>
<br>
<br>
4) As per the above command I found the env file is available<br>
'/etc/sysconfig/httpd'<br>
<br>
vi /etc/sysconfig/httpd<br>
<br>
#<br>
# This file can be used to set additional environment variables for<br>
# the httpd process, or pass additional options to the httpd<br>
# executable.<br>
#<br>
# Note: With previous versions of httpd, the MPM could be changed by<br>
# editing an "HTTPD" variable here. With the current version, that<br>
# variable is now ignored. The MPM is a loadable module, and the<br>
# choice of MPM can be changed by editing the configuration file<br>
/etc/httpd/conf.modules.d/00-m<wbr>pm.conf<br>
#<br>
<br>
#<br>
# To pass additional options (for instance, -D definitions) to the<br>
# httpd binary at startup, set OPTIONS here.<br>
#<br>
#OPTIONS=<br>
<br>
#<br>
# This setting ensures the httpd process is started in the "C" locale<br>
# by default. (Some modules will not behave correctly if<br>
# case-sensitive string comparisons are performed in a different<br>
# locale.)<br>
#<br>
LANG=C<br>
<br>
<br>
5) As per the above command, I found that the conf fileis available in the<br>
path : /etc/httpd/conf.modules.d/00-m<wbr>pm.conf<br>
<br>
vi /etc/httpd/conf.modules.d/00-m<wbr>pm.conf<br>
<br>
# Select the MPM module which should be used by uncommenting exactly<br>
# one of the following LoadModule lines:<br>
<br>
# prefork MPM: Implements a non-threaded, pre-forking web server<br>
# See: <a href="http://httpd.apache.org/docs/2.4/mod/prefork.html" rel="noreferrer" target="_blank">http://httpd.apache.org/docs/2<wbr>.4/mod/prefork.html</a><br>
#LoadModule mpm_prefork_module modules/mod_mpm_prefork.so<br>
<br>
# worker MPM: Multi-Processing Module implementing a hybrid<br>
# multi-threaded multi-process web server<br>
# See: <a href="http://httpd.apache.org/docs/2.4/mod/worker.html" rel="noreferrer" target="_blank">http://httpd.apache.org/docs/2<wbr>.4/mod/worker.html</a><br>
#<br>
LoadModule mpm_worker_module modules/mod_mpm_worker.so<br>
<br>
# event MPM: A variant of the worker MPM with the goal of consuming<br>
# threads only for connections with active processing<br>
# See: <a href="http://httpd.apache.org/docs/2.4/mod/event.html" rel="noreferrer" target="_blank">http://httpd.apache.org/docs/2<wbr>.4/mod/event.html</a><br>
#<br>
#LoadModule mpm_event_module modules/mod_mpm_event.so<br>
<br>
<IfModule mpm_worker_module><br>
ServerLimit 1000<br>
MaxRequestWorkers 1000<br>
</IfModule><br>
<br>
<br>
<br>
As per your comment, I enabled the 'LoadModule mpm_worker_module<br>
modules/mod_mpm_worker.so' with the ServerLimit and MaxRequestWorkers as<br>
1000 still I am facing the issue for the following command in apache<br>
benchmark test.<br>
<br>
Completed 100 requests<br>
SSL handshake failed (5).<br>
SSL handshake failed (5).<br>
SSL handshake failed (5).<br>
SSL handshake failed (5).<br>
SSL handshake failed (5).<br>
SSL handshake failed (5).<br>
<br>
<br>
NOTE : It always scales when I have concurrent request below 400<br>
<br>
What is wrong in this apache configuration, why SSL handshake is failing<br>
for concurrent request above 400 ?<br>
<br>
Thanks,<br>
Hari<br>
<br>
<br>
<br>
<br>
<br>
<br>
On Wed, Mar 7, 2018 at 9:20 PM, Juan Hernández <<a href="mailto:jhernand@redhat.com" target="_blank">jhernand@redhat.com</a>><br>
wrote:<br>
<br>
It means that with the default configuration the Apache web server can't<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
serve more than 256 concurrent connections. This applies to any<br>
application<br>
that uses Apache as the web frontend, not just to oVirt. If you want to<br>
change that you have to change the MaxRequestWorkers and ServerLimit<br>
parameters, as explained here:<br>
<br>
<a href="https://httpd.apache.org/docs/2.4/mod/mpm_common.html#m" rel="noreferrer" target="_blank">https://httpd.apache.org/docs/<wbr>2.4/mod/mpm_common.html#m</a><br>
axrequestworkers<br>
<br>
So, go to your oVirt engine machine and create a<br>
/etc/httpd/conf.d/my.conf<br>
file with this content:<br>
<br>
MaxRequestWorkers 1000<br>
ServerLimit 1000<br>
<br>
Then restart the Apache server:<br>
<br>
# systemctl restart httpd<br>
<br>
Then your web server should be able to handle 1000 concurrent requests,<br>
and you will probably start to find other limits, like the amount of<br>
memory<br>
and CPU that those 1000 Apache child processes will consume, the number<br>
of<br>
threads in the JBoss application server, the number of connections to the<br>
database, etc.<br>
<br>
Let me insist a bit that if you base your benchmark solely on the number<br>
of concurrent requests or connections that the server can handle you may<br>
end up with meaningless results, as a real world application can/should<br>
use<br>
the server much better than that.<br>
<br>
On 03/07/2018 04:33 PM, Hari Prasanth Loganathan wrote:<br>
<br>
With the default configuration of the web server it is impossible to<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
handle<br>
more than 256 *connections* simultaneously. I guess that "ab" is<br>
opening a<br>
connection for each concurrent request, so when you reach request 257<br>
the<br>
web server will just reject the connection, there is nothing that the<br>
JBoss<br>
can do about it; you have to increase the number of connections<br>
supported<br>
by the web server.<br>
<br>
*So Does it mean that oVirt cannot serve more than 257 request? *<br>
<br>
My question is, If its possible How to scale this and what is the<br>
configuration we need to change?<br>
<br>
Also, we are taking a benchmark in using oVirt, So I need to find the<br>
maximum possible oVirt request. So please let me know the configuration<br>
tuning for oVirt to achieve maximum concurrent request.<br>
<br>
Thanks,<br>
Hari<br>
<br>
On Wed, Mar 7, 2018 at 7:25 PM, Juan Hernández <<a href="mailto:jhernand@redhat.com" target="_blank">jhernand@redhat.com</a>><br>
wrote:<br>
<br>
With the default configuration of the web server it is impossible to<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
handle more than 256 *connections* simultaneously. I guess that "ab" is<br>
opening a connection for each concurrent request, so when you reach<br>
request<br>
257 the web server will just reject the connection, there is nothing<br>
that<br>
the JBoss can do about it; you have to increase the number of<br>
connections<br>
supported by the web server.<br>
<br>
Or else you may want to re-consider why you want to use 1000<br>
simultaneous<br>
connections. It may be OK for a performance test, but there are better<br>
ways<br>
to squeeze performance. For example, you could consider using HTTP<br>
pipelining, which is much more friendly for the server than so many<br>
connections. This is what we use when we need to send a large number of<br>
requests from other systems. There are examples of how to do that with<br>
the<br>
Python and Ruby SDKs here:<br>
<br>
Python:<br>
<br>
<a href="https://github.com/oVirt/ovirt-engine-sdk/blob/master/sdk/" rel="noreferrer" target="_blank">https://github.com/oVirt/ovirt<wbr>-engine-sdk/blob/master/sdk/</a><br>
examples/asynchronous_inventor<wbr>y.py<br>
<br>
Ruby:<br>
<br>
<a href="https://github.com/oVirt/ovirt-engine-sdk-ruby/blob/master/" rel="noreferrer" target="_blank">https://github.com/oVirt/ovirt<wbr>-engine-sdk-ruby/blob/master/</a><br>
sdk/examples/asynchronous_inve<wbr>ntory.rb<br>
<br>
<br>
On 03/07/2018 02:43 PM, Hari Prasanth Loganathan wrote:<br>
<br>
Hi Juan,<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Thanks for the response.<br>
<br>
I agree web server can handle only limited number of concurrent<br>
requests.<br>
But Why it is failing with SSL handshake failure for few requests,<br>
Can't<br>
the JBOSS wait and serve the request? We can spare the delay but not<br>
with<br>
the request fails. So Is there a configuration in oVirt which can be<br>
tuned<br>
to achieve this?<br>
<br>
Thanks,<br>
Hari<br>
<br>
On Wed, Mar 7, 2018 at 7:05 PM, Juan Hernández <<a href="mailto:jhernand@redhat.com" target="_blank">jhernand@redhat.com</a>><br>
wrote:<br>
<br>
The first thing you will need to change for such a test is the number<br>
of<br>
<br>
simultaneous connections accepted by the Apache web server: by default<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
the<br>
max is 256. See the Apache documentation here:<br>
<br>
<a href="https://httpd.apache.org/docs/2.4/mod/mpm_common.html#m" rel="noreferrer" target="_blank">https://httpd.apache.org/docs/<wbr>2.4/mod/mpm_common.html#m</a><br>
axrequestworkers<br>
<br>
In addition I also suggest that you consider using the "worker"<br>
multi-processing module instead of the "prefork", as it usually works<br>
better when talking to a Java application server, because it re-uses<br>
connections better.<br>
<br>
On 03/07/2018 02:20 PM, Hari Prasanth Loganathan wrote:<br>
<br>
Hi Team,<br>
<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
*Description of problem:*<br>
<br>
I am trying to achieve 1000 concurrent request to oVirt. What are<br>
the<br>
tunable parameters to achieve this?<br>
<br>
I tried to perform the benchmarking for ovirt engine using Apache<br>
benchmark<br>
using the same SSO token.<br>
<br>
ab -n 1000 -c 500 -k -H "accept: application/json" -H<br>
"Authorization:<br>
Bearer SSOTOKEN" <a href="https://172.30.56.70/ovirt-engine/" rel="noreferrer" target="_blank">https://172.30.56.70/ovirt-eng<wbr>ine/</a><br>
<<a href="https://172.30.56.70/ovirt-engine/api/vms/5440271b-afb3-48b" rel="noreferrer" target="_blank">https://172.30.56.70/ovirt-en<wbr>gine/api/vms/5440271b-afb3-48b</a><br>
b-9ff1-076fc07ebf50/statistics<wbr>><br>
<br>
When the number of concurrent request is 500, we are getting more<br>
than<br>
100<br>
failures with the following error,<br>
<br>
SSL read failed (1) - closing connection<br>
139620982339352:error:<br>
<br>
NOTE: It is scaling for concurrent request below 500.<br>
<br>
I used the profiler to get the memory and CPU and it seems very<br>
less,<br>
<br>
PID USER PR NI VIRT RES SHR S %CPU %MEM<br>
TIME+<br>
COMMAND<br>
30413 ovirt 20 0 4226664 882396 6776 S 126.0 23.0 27:48.53<br>
java<br>
<br>
Configuration of the machine in which Ovirt is deployed :<br>
<br>
RAM - 4GB,<br>
Hard disk - 100GB,<br>
core processor - 2,<br>
OS - Cent7.x.<br>
<br>
In which 2GB is allocated to oVirt.<br>
<br>
<br>
Version-Release number of selected component (if applicable):<br>
<br>
4.2.2<br>
<br>
<br>
How reproducible:<br>
<br>
If the number of concurrent requests are above 500, we are easily<br>
facing<br>
this issue.<br>
<br>
<br>
*Actual results:*<br>
<br>
SSL read failed (1) - closing connection<br>
139620982339352:error:<br>
<br>
*Expected results:*<br>
<br>
Request success.<br>
<br>
<br>
Thanks,<br>
Hari<br>
<br>
<br>
<br>
______________________________<wbr>_________________<br>
Users mailing list<br>
<a href="mailto:Users@ovirt.org" target="_blank">Users@ovirt.org</a><br>
<a href="http://lists.ovirt.org/mailman/listinfo/users" rel="noreferrer" target="_blank">http://lists.ovirt.org/mailman<wbr>/listinfo/users</a><br>
<br>
<br>
<br>
<br>
<br>
</blockquote>
<br>
</blockquote>
<br>
</blockquote>
<br>
</blockquote>
<br>
</blockquote>
<br>
</blockquote>
<br>
</blockquote>
<br>
</blockquote>
<br>
</blockquote>
<br>
</div></div></blockquote></div><br></div>
<br>
<p style="text-align:justify"><span lang="EN-US"><font size="1">DISCLAIMER</font></span></p>
<p style="text-align:justify"><font size="1"><span lang="EN-US">The information in this e-mail is confidential and may be subject to
legal privilege. It is intended solely for the addressee. Access to this e-mail
by anyone else is unauthorized. If you have received this communication in
error, please address with the subject heading "Received in error,"
send to <a href="mailto:it@msystechnologies.com" target="_blank">it@msystechnologies.com</a>,
then delete the e-mail and destroy any copies of it. If you are not the
intended recipient, any disclosure, copying, distribution or any action taken
or omitted to be taken in reliance on it, is prohibited and may be unlawful.
The views, opinions, conclusions and other information expressed in this
electronic mail and any attachments are not given or endorsed by the company
unless otherwise indicated by an authorized representative independent of this
message.</span></font></p>
<font size="1"><span lang="EN-US">MSys cannot guarantee
that e-mail communications are secure or error-free, as information could be
intercepted, corrupted, amended, lost, destroyed, arrive late or incomplete, or
contain viruses, though </span>all reasonable
precautions have been taken to ensure no viruses are present in this e-mail<span lang="EN-US">. </span>As our company cannot accept responsibility for
any loss or damage arising from the use of this e-mail or attachments we
recommend that you subject these to your virus checking procedures prior to use</font>