[users@httpd] TimeOut

2015-11-16 Thread Rose, John B
Looking in the Security Tips document for Apache this is said ...

  *   The TimeOut 
directive should be lowered on sites that are subject to DoS attacks. Setting 
this to as low as a few seconds may be appropriate. As 
TimeOut is currently 
used for several different operations, setting it to a low value introduces 
problems with long running CGI scripts.'

The default is 60 seconds, I have had a discussion where I was told maybe 2-5 
seconds is a good setting.

What is commonly used nowadays in 2.4 on robust networks and architectures?

thanks


Re: [users@httpd] TimeOut

2015-11-16 Thread Daniel Gruno
On 11/16/2015 05:50 PM, Rose, John B wrote:
> Looking in the Security Tips document for Apache this is said …
> 
>   * The |TimeOut
> | directive
> should be lowered on sites that are subject to DoS attacks. Setting
> this to as low as a few seconds may be appropriate. As |TimeOut
> | is
> currently used for several different operations, setting it to a low
> value introduces problems with long running CGI scripts.'
> 
> The default is 60 seconds, I have had a discussion where I was told
> maybe 2-5 seconds is a good setting. 
> 
> What is commonly used nowadays in 2.4 on robust networks and architectures?
> 
> thanks

For guarding against slow loris and the likes, please see
https://httpd.apache.org/docs/2.4/mod/mod_reqtimeout.html instead.

With regards,
Daniel.

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



Re: [users@httpd] TimeOut

2015-11-16 Thread Daniel
60 is a good overall value, but as you said it yourself, setting it too low
will cause problems with long running cgi scripts, set it to a logical
value according to *YOUR* needs. There is no magic value for timeout,
really.

El lun., 16 nov. 2015 a las 17:50, Rose, John B () escribió:

> Looking in the Security Tips document for Apache this is said …
>
>- The TimeOut  
> directive
>should be lowered on sites that are subject to DoS attacks. Setting this to
>as low as a few seconds may be appropriate. As TimeOut
> is currently
>used for several different operations, setting it to a low value introduces
>problems with long running CGI scripts.'
>
> The default is 60 seconds, I have had a discussion where I was told maybe
> 2-5 seconds is a good setting.
>
> What is commonly used nowadays in 2.4 on robust networks and architectures?
>
> thanks
>


[users@httpd] Re: FAQ?

2015-11-16 Thread William A Rowe Jr
On Sun, Nov 15, 2015 at 11:09 AM, yousuf sharief 
wrote:

> Hi All,
>
> Please share the FAQ's to update my skills on Apache.
>

At this time there isn't an actively maintained FAQ, but the historical
one is editable at http://wiki.apache.org/httpd/FAQ

If folks on users@ wanted to start maintaining and updating this more
frequently, it might be helpful for the users community.


Re: [users@httpd] How to post to HTTPD Users List

2015-11-16 Thread Rich Bowen


On 11/15/2015 12:17 PM, Yehuda Katz wrote:
> Also read the link on the mailing list description page: "How To Ask
> Questions The Smart Way"
> 

I ardently look forward to the day when people stop referencing that
document as though it's good advice.

-- 
Rich Bowen - rbo...@rcbowen.com - @rbowen
http://apachecon.com/ - @apachecon

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



Re: [users@httpd] Cross-compiled apache 2.4.17/OpenSSL 1.0.2d for SPARC fails to start on mutex error

2015-11-16 Thread spggwp7q

It works! Thanks a lot for the hint.

Am 16/11/2015 um 12:34 schrieb Rainer Jung:

Am 16.11.2015 um 10:22 schrieb spggwp7q:

Hi guys,

I cross-compiled apache 2.4.17 with APR 1.5.2 and APR Util 1.5.4 along
with OpenSSL 1.0.2d for 64-bit SPARC. I tried running it on one of my
boxes and got the following error in the apache error log (the box was
previously running 2.4.10):

[Mon Nov 16 10:04:52.463583 2015] [core:emerg] [pid 17310:tid 1]
(70023)This function has not been implemented on this platform: AH00023:
Couldn't create the ssl-cache mutex
AH00016: Configuration Failed

I suppose there are no changes between 2.4.10 and 2.4.17 that require
changes to the configuration, so I assume this is happening due to a
compile-time issue.

I was able to get over this error by explicitly setting:

Mutex sem default

However, now apache starts and then quickly dies.

[Mon Nov 16 10:13:59.531153 2015] [mpm_worker:notice] [pid 27481:tid 1]
AH00292: Apache/2.4.17 (Unix) OpenSSL/1.0.2d configured -- resuming
normal operations
[Mon Nov 16 10:13:59.532724 2015] [core:notice] [pid 27481:tid 1]
AH00094: Command line: '/opt/SP/apps/ena_apache/current/bin/httpd -f
/opt/SP/apps/apache/global/vfglfe/conf/httpd.conf'
[Mon Nov 16 10:14:02.533892 2015] [core:notice] [pid 27481:tid 1]
AH00051: child pid 27500 exit signal Bus error (10), possible coredump
in /var/tmp
[Mon Nov 16 10:14:02.534215 2015] [core:notice] [pid 27481:tid 1]
AH00060: seg fault or similar nasty error detected in the parent process

gdb is not installed on this box and I have no access to install
it...but just looking into the core file I see:

*** _THREAD_ERROR_DETECTION: lock usage error detected ***

Looking for this error, I found this:
https://issues.apache.org/jira/browse/STDCXX-1040, which seems to imply
a possible issue with certain versions of Solaris.

On my box, uname -a returns:

SunOS now-ena-fe346 5.10 Generic_150400-20 sun4v sparc
SUNW,SPARC-Enterprise-T5220

I don't know if this is impacted by the issue with the standard C++ 
library


Should I be using a specific version of the library for compilation?

Thanks in advance for your support.


The Bus error could also be due to this bug in 2.4.17, that was fixed 
after the release:


svn.apache.org/r1712294

Maybe you can try that patch?

Regards,

Rainer

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



Re: [users@httpd] Re: FAQ?

2015-11-16 Thread Francois Gingras
Actually, we locked down the httpd wiki because of spam in the past.

However, I can add anyone to the contributor list should they wish to add
or edit content.

Frank

On Mon, Nov 16, 2015 at 11:01 AM, William A Rowe Jr 
wrote:

> On Sun, Nov 15, 2015 at 11:09 AM, yousuf sharief 
> wrote:
>
>> Hi All,
>>
>> Please share the FAQ's to update my skills on Apache.
>>
>
> At this time there isn't an actively maintained FAQ, but the historical
> one is editable at http://wiki.apache.org/httpd/FAQ
>
> If folks on users@ wanted to start maintaining and updating this more
> frequently, it might be helpful for the users community.
>
>
>


[users@httpd] Getting "connection refused" Apache 2.4

2015-11-16 Thread o haya
Hi,

I am trying to do some load testing of Apache 2.4 on Redhat. 

Configuration displayed when I run "httpd -V" shows:

Server MPM: prefork
threaded: no
forked: yes (variable process count)

I am using Jmeter to test, and when I increase the number of simultaneous 
threads to > 200, I am seeing increasing number of errors, with a lot of 
"connection refused" errors, e.g.:

org.apache.http.conn.HttpHostConnectException: Connection to 
http://10.0.3.10:80 refused
at 
org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:190)
at 
org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedClientConnectionImpl.java:294)
at 
org.apache.jmeter.protocol.http.sampler.MeasuringConnectionManager$MeasuredConnection.open(MeasuringConnectionManager.java:107)
at 
org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:643)
at 
org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:479)
at 
org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:906)
at 
org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:805)
at 
org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.executeRequest(HTTPHC4Impl.java:517)
at 
org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.sample(HTTPHC4Impl.java:331)
at 
org.apache.jmeter.protocol.http.sampler.HTTPSamplerProxy.sample(HTTPSamplerProxy.java:74)
at 
org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1146)
at 
org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1135)
at 
org.apache.jmeter.threads.JMeterThread.process_sampler(JMeterThread.java:434)
at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:261)
at java.lang.Thread.run(Unknown Source)
Caused by: java.net.ConnectException: Connection timed out: connect
at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method)
at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source)
at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at 
org.apache.http.conn.scheme.PlainSocketFactory.connectSocket(PlainSocketFactory.java:127)
at 
org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:180)
... 14 more


I've been trying to re-configure the Apache to avoid these errors, e.g., 
increasing "MaxClients", and I've also increased the amount of memory for the 
machine (to 4GB) but so far, nothing I have done has improved the situation.

Is there something else that I can do to try to get the Apache so that it can 
accept the larger number of connections?

Thanks,
Jim



-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



[users@httpd] mod_deflate kudos for 2.4 change

2015-11-16 Thread Rose, John B
To whomever was involved, nice work


  *   mod_deflate will 
now skip compression if it knows that the size overhead added by the 
compression is larger than the data to be compressed.

http://httpd.apache.org/docs/2.4/upgrading.html

thanks



Re: [users@httpd] How to force browsers doesn't use cache

2015-11-16 Thread Christopher Schultz
Pete,

On 11/16/15 3:52 PM, Pete Houston wrote:
> On Mon, Nov 16, 2015 at 06:19:37PM -0200, Ronaldo Luiz de Carvalho wrote:
>> There are a way to setting apache in a way to force the users site browsers
>> doesn't use their cache?
> 
> You can use the Header directive to set the appropriate value of the
> Cache-Control header.
> 
> http://httpd.apache.org/docs/2.4/mod/mod_headers.html#header
> http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9

+1

Plus the "Pragma" header for ancient clients, if you want.

This is how we do it:

Header set Cache-Control "no-cache, no-store, must-revalidate"
Header set Pragma "no-cache"
Header set Expires 0

Make sure you don't overdo this... if you have .css, .js files, etc.
that *should* be cached, don't let this apply to them.

-chris

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



[users@httpd] Enabling sticky session mode for Apache/Tomcat load balancing

2015-11-16 Thread Raju Rathi
Hi All ,

I am trying to enable sticky sessions in Apache, however it is not working.
Below are the changes made by me. Can anyone please advice if I am missing
something?

I do not see any error in the access log, however request from one user is
still going to other server. Please let me know if any additional
information is needed to answer/help my query.appreciate quick response on
this ..

*Step 1*: Added below in httpd.conf of load balancer of server1 & server2


BalancerMember http://server1fullname:8080  route=server1
BalancerMember http://server2fullname:8080  route=server2
ProxySet lbmethod=bytraffic
ProxySet stickysession=JSESSIONID

ProxyPass /marsWAR/ balancer://marsBalancer/marsWAR/

*Step 2*: Updated below in server.xml

a) server.xml in server1



b) server.xml in server2




[users@httpd] How to force browsers doesn't use cache

2015-11-16 Thread Ronaldo Luiz de Carvalho
Hi all,

 

I need to force my site users to use the last version of the site php pages.

 

Some site users are getting information from their browsers cache.

 

There are a way to setting apache in a way to force the users site browsers
doesn't use their cache?

 

On all site access the page come from site, never from cache browser
version.

 

Thanks in advance

 

Ronaldo Luiz

 

 



Re: [users@httpd] Getting "connection refused" Apache 2.4

2015-11-16 Thread o haya
Hi Daniel,
Unfortunately, the Apache I'm working with is part of a product, so I won't be 
able to change to a different MPM type.
I've been trying what you suggested (increasing MinSpareServers) but I still 
get tons of connections refused, even when I can confirm that, for example, I 
get 500+ httpd instances at startup (e.g., ps -ef shows 500 instances).  Is it 
possible that something else (e.g., the Redhat OS itself) is limiting the 
number of connections?
Thanks,Jim

  From: Daniel 
 To: users@httpd.apache.org; o haya  
 Sent: Monday, November 16, 2015 3:07 PM
 Subject: Re: [users@httpd] Getting "connection refused" Apache 2.4
   
migrate to worker or event...if you have to stick with prefork mpm, increase 
the number of MinSpareServers to a very high number, prefork is very slow 
spawning new children since it is not threaded, so better spawn most when 
apache starts.


El lun., 16 nov. 2015 a las 20:58, o haya () escribió:

Hi,

I am trying to do some load testing of Apache 2.4 on Redhat.

Configuration displayed when I run "httpd -V" shows:

Server MPM: prefork
threaded: no
forked: yes (variable process count)

I am using Jmeter to test, and when I increase the number of simultaneous 
threads to > 200, I am seeing increasing number of errors, with a lot of 
"connection refused" errors, e.g.:

org.apache.http.conn.HttpHostConnectException: Connection to 
http://10.0.3.10:80 refused
        at 
org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:190)
        at 
org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedClientConnectionImpl.java:294)
        at 
org.apache.jmeter.protocol.http.sampler.MeasuringConnectionManager$MeasuredConnection.open(MeasuringConnectionManager.java:107)
        at 
org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:643)
        at 
org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:479)
        at 
org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:906)
        at 
org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:805)
        at 
org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.executeRequest(HTTPHC4Impl.java:517)
        at 
org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.sample(HTTPHC4Impl.java:331)
        at 
org.apache.jmeter.protocol.http.sampler.HTTPSamplerProxy.sample(HTTPSamplerProxy.java:74)
        at 
org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1146)
        at 
org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1135)
        at 
org.apache.jmeter.threads.JMeterThread.process_sampler(JMeterThread.java:434)
        at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:261)
        at java.lang.Thread.run(Unknown Source)
Caused by: java.net.ConnectException: Connection timed out: connect
        at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method)
        at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
        at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
        at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source)
        at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
        at java.net.PlainSocketImpl.connect(Unknown Source)
        at java.net.SocksSocketImpl.connect(Unknown Source)
        at java.net.Socket.connect(Unknown Source)
        at 
org.apache.http.conn.scheme.PlainSocketFactory.connectSocket(PlainSocketFactory.java:127)
        at 
org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:180)
        ... 14 more


I've been trying to re-configure the Apache to avoid these errors, e.g., 
increasing "MaxClients", and I've also increased the amount of memory for the 
machine (to 4GB) but so far, nothing I have done has improved the situation.

Is there something else that I can do to try to get the Apache so that it can 
accept the larger number of connections?

Thanks,
Jim



-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org




  

Re: [users@httpd] Getting "connection refused" Apache 2.4

2015-11-16 Thread Daniel
migrate to worker or event...
if you have to stick with prefork mpm, increase the number of
MinSpareServers to a very high number, prefork is very slow spawning new
children since it is not threaded, so better spawn most when apache starts.

El lun., 16 nov. 2015 a las 20:58, o haya ()
escribió:

> Hi,
>
> I am trying to do some load testing of Apache 2.4 on Redhat.
>
> Configuration displayed when I run "httpd -V" shows:
>
> Server MPM: prefork
> threaded: no
> forked: yes (variable process count)
>
> I am using Jmeter to test, and when I increase the number of simultaneous
> threads to > 200, I am seeing increasing number of errors, with a lot of
> "connection refused" errors, e.g.:
>
> org.apache.http.conn.HttpHostConnectException: Connection to
> http://10.0.3.10:80 refused
> at
> org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:190)
> at
> org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedClientConnectionImpl.java:294)
> at
> org.apache.jmeter.protocol.http.sampler.MeasuringConnectionManager$MeasuredConnection.open(MeasuringConnectionManager.java:107)
> at
> org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:643)
> at
> org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:479)
> at
> org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:906)
> at
> org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:805)
> at
> org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.executeRequest(HTTPHC4Impl.java:517)
> at
> org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.sample(HTTPHC4Impl.java:331)
> at
> org.apache.jmeter.protocol.http.sampler.HTTPSamplerProxy.sample(HTTPSamplerProxy.java:74)
> at
> org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1146)
> at
> org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1135)
> at
> org.apache.jmeter.threads.JMeterThread.process_sampler(JMeterThread.java:434)
> at
> org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:261)
> at java.lang.Thread.run(Unknown Source)
> Caused by: java.net.ConnectException: Connection timed out: connect
> at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method)
> at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
> at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
> at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown
> Source)
> at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
> at java.net.PlainSocketImpl.connect(Unknown Source)
> at java.net.SocksSocketImpl.connect(Unknown Source)
> at java.net.Socket.connect(Unknown Source)
> at
> org.apache.http.conn.scheme.PlainSocketFactory.connectSocket(PlainSocketFactory.java:127)
> at
> org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:180)
> ... 14 more
>
>
> I've been trying to re-configure the Apache to avoid these errors, e.g.,
> increasing "MaxClients", and I've also increased the amount of memory for
> the machine (to 4GB) but so far, nothing I have done has improved the
> situation.
>
> Is there something else that I can do to try to get the Apache so that it
> can accept the larger number of connections?
>
> Thanks,
> Jim
>
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
> For additional commands, e-mail: users-h...@httpd.apache.org
>
>


Re: [users@httpd] How to force browsers doesn't use cache

2015-11-16 Thread Pete Houston
On Mon, Nov 16, 2015 at 06:19:37PM -0200, Ronaldo Luiz de Carvalho wrote:
> There are a way to setting apache in a way to force the users site browsers
> doesn't use their cache?

You can use the Header directive to set the appropriate value of the
Cache-Control header.

http://httpd.apache.org/docs/2.4/mod/mod_headers.html#header
http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9

Pete
-- 
Openstrike - improving business through open source
http://www.openstrike.co.uk/ or call 01722 770036


pgpuayrUDzaMK.pgp
Description: PGP signature


Re: [users@httpd] Getting "connection refused" Apache 2.4

2015-11-16 Thread o haya
Hi,
Just as a kind of slightly-different sanity check, I did some testing on an 
Apache 2.2.31 instance that I built awhile ago on one of my test CENTOS 
machines:
Server version: Apache/2.2.31 (Unix)Server built:   Oct  7 2015 
11:32:17Server's Module Magic Number: 20051115:40Server loaded:  APR 1.5.2, 
APR-Util 1.5.4Compiled using: APR 1.5.2, APR-Util 1.5.4Architecture:   
64-bitServer MPM:     Prefork  threaded:     no    forked:     yes (variable 
process count)Server compiled with -D APACHE_MPM_DIR="server/mpm/prefork" 
-D APR_HAS_SENDFILE -D APR_HAS_MMAP -D APR_HAVE_IPV6 (IPv4-mapped addresses 
enabled) -D APR_USE_SYSVSEM_SERIALIZE -D APR_USE_PTHREAD_SERIALIZE -D 
SINGLE_LISTEN_UNSERIALIZED_ACCEPT -D APR_HAS_OTHER_CHILD -D 
AP_HAVE_RELIABLE_PIPED_LOGS -D DYNAMIC_MODULE_LIMIT=128 -D 
HTTPD_ROOT="/apps/httpd" -D SUEXEC_BIN="/apps/httpd/bin/suexec" -D 
DEFAULT_PIDLOG="logs/httpd.pid" -D 
DEFAULT_SCOREBOARD="logs/apache_runtime_status" -D 
DEFAULT_LOCKFILE="logs/accept.lock" -D DEFAULT_ERRORLOG="logs/error_log" -D 
AP_TYPES_CONFIG_FILE="conf/mime.types" -D SERVER_CONFIG_FILE="conf/httpd.conf"
Then, I ran essentially the same load test that I had been running earlier, 
and, I get similar errors, e.g., connection refused.
This is with the as-built Apache configuration settings (i.e., I haven't tried 
tweaking them).
This is kind of leading me to think that it may the Apache, built with the 
above MPM model, may just not be able to sustain this kind of load error-free? 
Thanks,Jim
  From: o haya 
 To: "users@httpd.apache.org"  
Cc: O. Haya  
 Sent: Monday, November 16, 2015 3:44 PM
 Subject: Re: [users@httpd] Getting "connection refused" Apache 2.4
   
Hi Daniel,
Unfortunately, the Apache I'm working with is part of a product, so I won't be 
able to change to a different MPM type.
I've been trying what you suggested (increasing MinSpareServers) but I still 
get tons of connections refused, even when I can confirm that, for example, I 
get 500+ httpd instances at startup (e.g., ps -ef shows 500 instances).  Is it 
possible that something else (e.g., the Redhat OS itself) is limiting the 
number of connections?
Thanks,Jim

 

 From: Daniel 
 To: users@httpd.apache.org; o haya  
 Sent: Monday, November 16, 2015 3:07 PM
 Subject: Re: [users@httpd] Getting "connection refused" Apache 2.4
   
migrate to worker or event...if you have to stick with prefork mpm, increase 
the number of MinSpareServers to a very high number, prefork is very slow 
spawning new children since it is not threaded, so better spawn most when 
apache starts.


El lun., 16 nov. 2015 a las 20:58, o haya () escribió:

Hi,

I am trying to do some load testing of Apache 2.4 on Redhat.

Configuration displayed when I run "httpd -V" shows:

Server MPM: prefork
threaded: no
forked: yes (variable process count)

I am using Jmeter to test, and when I increase the number of simultaneous 
threads to > 200, I am seeing increasing number of errors, with a lot of 
"connection refused" errors, e.g.:

org.apache.http.conn.HttpHostConnectException: Connection to 
http://10.0.3.10:80 refused
        at 
org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:190)
        at 
org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedClientConnectionImpl.java:294)
        at 
org.apache.jmeter.protocol.http.sampler.MeasuringConnectionManager$MeasuredConnection.open(MeasuringConnectionManager.java:107)
        at 
org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:643)
        at 
org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:479)
        at 
org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:906)
        at 
org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:805)
        at 
org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.executeRequest(HTTPHC4Impl.java:517)
        at 
org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.sample(HTTPHC4Impl.java:331)
        at 
org.apache.jmeter.protocol.http.sampler.HTTPSamplerProxy.sample(HTTPSamplerProxy.java:74)
        at 
org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1146)
        at 
org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1135)
        at 
org.apache.jmeter.threads.JMeterThread.process_sampler(JMeterThread.java:434)
        at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:261)
        at java.lang.Thread.run(Unknown Source)
Caused by: java.net.ConnectException: Connection timed out: connect
        at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method)
        at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
        at 

[users@httpd] how to compile apache httpd 2.4.17

2015-11-16 Thread David Long
I download Apache httpd 2.4.17 and want compile on Solaris 10 Sparc.

It ask me to install APR.

So I download APR 1.5.2 and try to configure it and following error.



root@kiana# cd /www/apachesrc/apr-1.5.2

root@kiana# ./configure 
--prefix=/www/apachesrc/httpd-2.4.17/srclib/apr/configure

checking build system type... sparc-sun-solaris2.10

checking host system type... sparc-sun-solaris2.10

checking target system type... sparc-sun-solaris2.10

Configuring APR library

Platform: sparc-sun-solaris2.10

checking for working mkdir -p... yes

APR Version: 1.5.2

[…]

config.status: creating include/arch/unix/apr_private.h

config.status: executing libtool commands

libtoolT: No such file or directory

config.status: executing default commands

config.status: include/apr.h is unchanged

config.status: include/arch/unix/apr_private.h is unchanged



I do have libtool package installed but don't know what libtoolT means.



Thanks.

With regards,



David Long


Re: [users@httpd] Getting "connection refused" Apache 2.4

2015-11-16 Thread Yann Ylavic
On Tue, Nov 17, 2015 at 1:11 AM, Yann Ylavic  wrote:
> On Tue, Nov 17, 2015 at 12:23 AM, o haya  wrote:
>>
>> This is with the as-built Apache configuration settings (i.e., I haven't
>> tried tweaking them).
>
> Please share your settings for [...]
> MaxSpareThreads, MinSpareThreads [...]

I meant MaxSpareServers and MinSpareServers here, *Threads are not
relevant for prefork.

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



Re: [users@httpd] Cross-compiled apache 2.4.17/OpenSSL 1.0.2d for SPARC fails to start on mutex error

2015-11-16 Thread Rainer Jung

Am 16.11.2015 um 10:22 schrieb spggwp7q:

Hi guys,

I cross-compiled apache 2.4.17 with APR 1.5.2 and APR Util 1.5.4 along
with OpenSSL 1.0.2d for 64-bit SPARC. I tried running it on one of my
boxes and got the following error in the apache error log (the box was
previously running 2.4.10):

[Mon Nov 16 10:04:52.463583 2015] [core:emerg] [pid 17310:tid 1]
(70023)This function has not been implemented on this platform: AH00023:
Couldn't create the ssl-cache mutex
AH00016: Configuration Failed

I suppose there are no changes between 2.4.10 and 2.4.17 that require
changes to the configuration, so I assume this is happening due to a
compile-time issue.

I was able to get over this error by explicitly setting:

Mutex sem default

However, now apache starts and then quickly dies.

[Mon Nov 16 10:13:59.531153 2015] [mpm_worker:notice] [pid 27481:tid 1]
AH00292: Apache/2.4.17 (Unix) OpenSSL/1.0.2d configured -- resuming
normal operations
[Mon Nov 16 10:13:59.532724 2015] [core:notice] [pid 27481:tid 1]
AH00094: Command line: '/opt/SP/apps/ena_apache/current/bin/httpd -f
/opt/SP/apps/apache/global/vfglfe/conf/httpd.conf'
[Mon Nov 16 10:14:02.533892 2015] [core:notice] [pid 27481:tid 1]
AH00051: child pid 27500 exit signal Bus error (10), possible coredump
in /var/tmp
[Mon Nov 16 10:14:02.534215 2015] [core:notice] [pid 27481:tid 1]
AH00060: seg fault or similar nasty error detected in the parent process

gdb is not installed on this box and I have no access to install
it...but just looking into the core file I see:

*** _THREAD_ERROR_DETECTION: lock usage error detected ***

Looking for this error, I found this:
https://issues.apache.org/jira/browse/STDCXX-1040, which seems to imply
a possible issue with certain versions of Solaris.

On my box, uname -a returns:

SunOS now-ena-fe346 5.10 Generic_150400-20 sun4v sparc
SUNW,SPARC-Enterprise-T5220

I don't know if this is impacted by the issue with the standard C++ library

Should I be using a specific version of the library for compilation?

Thanks in advance for your support.


The Bus error could also be due to this bug in 2.4.17, that was fixed 
after the release:


svn.apache.org/r1712294

Maybe you can try that patch?

Regards,

Rainer

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



Re: [users@httpd] Getting "connection refused" Apache 2.4

2015-11-16 Thread Yann Ylavic
On Tue, Nov 17, 2015 at 12:23 AM, o haya  wrote:
>
> This is with the as-built Apache configuration settings (i.e., I haven't
> tried tweaking them).

Please share your settings for ServerLimit, MaxRequestWorkers (was
MaxClients in 2.2.x), MaxSpareThreads, MinSpareThreads and
MaxConnectionsPerChild (was MaxRequestsPerChild in 2.2.x).

These are probably from CentOS if you did not tweek them, and some
tuning may be necessary to fit your needs.

Regards,
Yann.

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



Re: [users@httpd] Getting "connection refused" Apache 2.4

2015-11-16 Thread o haya
This is what is in the extra/httpd-mpm.conf:
# prefork MPM# StartServers: number of server processes to start# 
MinSpareServers: minimum number of server processes which are kept spare# 
MaxSpareServers: maximum number of server processes which are kept spare# 
MaxClients: maximum number of server processes allowed to start# 
MaxRequestsPerChild: maximum number of requests a server process 
serves    StartServers          5    
MinSpareServers       5    MaxSpareServers      10    MaxClients          150   
 MaxRequestsPerChild   0



  From: Yann Ylavic 
 To: users@httpd.apache.org; o haya  
 Sent: Monday, November 16, 2015 7:57 PM
 Subject: Re: [users@httpd] Getting "connection refused" Apache 2.4
   
On Tue, Nov 17, 2015 at 1:11 AM, Yann Ylavic  wrote:


> On Tue, Nov 17, 2015 at 12:23 AM, o haya  wrote:
>>
>> This is with the as-built Apache configuration settings (i.e., I haven't
>> tried tweaking them).
>
> Please share your settings for [...]
> MaxSpareThreads, MinSpareThreads [...]

I meant MaxSpareServers and MinSpareServers here, *Threads are not
relevant for prefork.


  

[users@httpd] Cross-compiled apache 2.4.17/OpenSSL 1.0.2d for SPARC fails to start on mutex error

2015-11-16 Thread spggwp7q

Hi guys,

I cross-compiled apache 2.4.17 with APR 1.5.2 and APR Util 1.5.4 along 
with OpenSSL 1.0.2d for 64-bit SPARC. I tried running it on one of my 
boxes and got the following error in the apache error log (the box was 
previously running 2.4.10):


[Mon Nov 16 10:04:52.463583 2015] [core:emerg] [pid 17310:tid 1] 
(70023)This function has not been implemented on this platform: AH00023: 
Couldn't create the ssl-cache mutex

AH00016: Configuration Failed

I suppose there are no changes between 2.4.10 and 2.4.17 that require 
changes to the configuration, so I assume this is happening due to a 
compile-time issue.


I was able to get over this error by explicitly setting:

Mutex sem default

However, now apache starts and then quickly dies.

[Mon Nov 16 10:13:59.531153 2015] [mpm_worker:notice] [pid 27481:tid 1] 
AH00292: Apache/2.4.17 (Unix) OpenSSL/1.0.2d configured -- resuming 
normal operations
[Mon Nov 16 10:13:59.532724 2015] [core:notice] [pid 27481:tid 1] 
AH00094: Command line: '/opt/SP/apps/ena_apache/current/bin/httpd -f 
/opt/SP/apps/apache/global/vfglfe/conf/httpd.conf'
[Mon Nov 16 10:14:02.533892 2015] [core:notice] [pid 27481:tid 1] 
AH00051: child pid 27500 exit signal Bus error (10), possible coredump 
in /var/tmp
[Mon Nov 16 10:14:02.534215 2015] [core:notice] [pid 27481:tid 1] 
AH00060: seg fault or similar nasty error detected in the parent process


gdb is not installed on this box and I have no access to install 
it...but just looking into the core file I see:


*** _THREAD_ERROR_DETECTION: lock usage error detected ***

Looking for this error, I found this: 
https://issues.apache.org/jira/browse/STDCXX-1040, which seems to imply 
a possible issue with certain versions of Solaris.


On my box, uname -a returns:

SunOS now-ena-fe346 5.10 Generic_150400-20 sun4v sparc 
SUNW,SPARC-Enterprise-T5220


I don't know if this is impacted by the issue with the standard C++ library

Should I be using a specific version of the library for compilation?

Thanks in advance for your support.

Regards,
K.

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org