You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@jmeter.apache.org by bu...@apache.org on 2015/03/10 10:37:27 UTC

[Bug 57682] New: Windows 8.1 - java.net.SocketException: Permission denied: connect

https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

            Bug ID: 57682
           Summary: Windows 8.1 - java.net.SocketException: Permission
                    denied: connect
           Product: JMeter
           Version: 2.12
          Hardware: PC
            Status: NEW
          Severity: blocker
          Priority: P2
         Component: HTTP
          Assignee: issues@jmeter.apache.org
          Reporter: sorin.patrasoiu@gmail.com

Test environment:
- OS: Windows 8.1 Pro
- Jmeter version: 2.12 r1636949
- Java version: Java(TM) SE Runtime Environment (build 1.7.0_71-b14)

Jmeter test setup:
- Threads: 50
- Ramp-Up period: 1
- Loop: 3

Steps to reproduce:
- I created a Jmeter script for a web application I want to test (can't go into
much details about the app)
- I executed the test first using the following setup: Threads (50), Ramp-Up
(1) and Loop (1) and the test is successfully executed.
- I executed the test using the same setup, except 3 loops instead of 1 and the
test fails with the following error:
java.net.SocketException: Permission denied: connect
    at java.net.TwoStacksPlainSocketImpl.socketConnect(Native Method)
    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 sun.security.ssl.SSLSocketImpl.connect(Unknown Source)
    at sun.security.ssl.SSLSocketImpl.<init>(Unknown Source)
    at sun.security.ssl.SSLSocketFactoryImpl.createSocket(Unknown Source)
    at
org.apache.jmeter.util.HttpSSLProtocolSocketFactory.createSocket(HttpSSLProtocolSocketFactory.java:151)
    at
org.apache.commons.httpclient.HttpConnection.open(HttpConnection.java:707)
    at
org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:387)
    at
org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171)
    at
org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397)
    at
org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:323)
    at
org.apache.jmeter.protocol.http.sampler.HTTPHC3Impl.sample(HTTPHC3Impl.java:265)
    at
org.apache.jmeter.protocol.http.sampler.HTTPSamplerProxy.sample(HTTPSamplerProxy.java:74)
    at
org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1141)
    at
org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1130)
    at
org.apache.jmeter.threads.JMeterThread.process_sampler(JMeterThread.java:431)
    at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:258)
    at java.lang.Thread.run(Unknown Source)

- I also tested the same test on a Linux machine and it worked fine even with
200 threads and 5 loops.
- I also tested the same test on a Windows 7 machine and it worked fine for 50
threads and 3 loops. The thing is that it didn't worked with default settings,
I had to add to jmeter.bat the following line: "set
JVM_ARGS=-Djava.net.preferIPv4Stack=true"
- On Windows 8.1 machine, I also added the following line to jmeter.bat "set
JVM_ARGS=-Djava.net.preferIPv4Stack=true" but the same error occurred.
- I also tested the same test on a different Windows 8.1 machine, but the same
error occurred.

I believe this is a bug of Jmeter, happening only on Windows 8, or at least the
workaround that worked on Windows 7, does not work on Windows 8.

Please advice!

Thank you!

Best regards,
Sorin

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

Sorin <so...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

--- Comment #5 from Philippe Mouawad <p....@ubik-ingenierie.com> ---
If you read the full answers and comment there is one that mentions using
java6.
Did you try this one ?
As a bug in java7 is mentionned.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

Sorin <so...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW

--- Comment #4 from Sorin <so...@gmail.com> ---
Again... as I mentioned in the initial description I tried also
-Djava.net.preferIPv4Stack=true option... and didn't worked...
It worked only on Windows 7.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |WORKSFORME

--- Comment #9 from Philippe Mouawad <p....@ubik-ingenierie.com> ---
Hi,
I tried it with :
Windows 8.1 PRO
Java 1.8_40
Same Test plan


It works for me.
I suggest you check for firewall or some antivirus doing this or a proxy you
are passing through.

Also try hitting another server.

For now closing as WORKSFORME , feel free to reopen with more details.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

Sorin <so...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW

--- Comment #6 from Sorin <so...@gmail.com> ---
I used also Java 6 & Java 8, with -Djava.net.preferIPv4Stack=true but same
result.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 OS|                            |All
                 CC|                            |p.mouawad@ubik-ingenierie.c
                   |                            |om
             Status|NEW                         |NEEDINFO

--- Comment #1 from Philippe Mouawad <p....@ubik-ingenierie.com> ---
Hi,
What Java version are you using ?
See
http://stackoverflow.com/questions/8360913/weird-java-net-socketexception-permission-denied-connect-error-when-running-groo

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

--- Comment #3 from Philippe Mouawad <p....@ubik-ingenierie.com> ---
(In reply to Sorin from comment #2)
> As it was mentioned in the original description:
> Java version: Java(TM) SE Runtime Environment (build 1.7.0_71-b14)
> Do you need something else regarding Java version?
> 
Indeed sorry I missed this information.

> Here is the full java -version result (don't know if it makes any difference
> though):
> java version "1.7.0_71"
> Java(TM) SE Runtime Environment (build 1.7.0_71-b14)
> Java HotSpot(TM) 64-Bit Server VM (build 24.71-b01, mixed mode)


Could you try what is in stackoverflow answer please and say if it worked ?
Thanks

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

--- Comment #2 from Sorin <so...@gmail.com> ---
As it was mentioned in the original description:
Java version: Java(TM) SE Runtime Environment (build 1.7.0_71-b14)
Do you need something else regarding Java version?

Here is the full java -version result (don't know if it makes any difference
though):
java version "1.7.0_71"
Java(TM) SE Runtime Environment (build 1.7.0_71-b14)
Java HotSpot(TM) 64-Bit Server VM (build 24.71-b01, mixed mode)

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 OS|All                         |Windows 8
           Severity|blocker                     |normal

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

Sorin <so...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW
                 OS|                            |All

--- Comment #8 from Sorin <so...@gmail.com> ---
I am admin, therefore no issue because of access rights.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 57682] Windows 8.1 - java.net.SocketException: Permission denied: connect

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=57682

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

--- Comment #7 from Philippe Mouawad <p....@ubik-ingenierie.com> ---
Are you admin on this system ?
Can't it be a rights issue ?

-- 
You are receiving this mail because:
You are the assignee for the bug.