Skip to main content

Can glassfish lose packets ?

Please note these java.net forums are being decommissioned and use the new and improved forums at https://community.oracle.com/community/java.
12 replies [Last post]
kipioca
Offline
Joined: 2010-11-17

Hi,
I encounter a problem with a JSP page running on glassfish.
I have a JSP page that just send the current date with the "IAMUP" pattern.
My problem is that sometimes, I've no response... So I've done a tcpdump on the machine runnning glassfish and I can see the request (GET /status.jsp HTTP/1.1...) but I don't see any response ( HTTP 200 OK)....Yet, my page is requested by glassfish (I log to a file all call to this page). This case happends approximatively 1 times / 500...
Please, someone understand why ? Does glassfish can not transmit the answer ?
Thanks for help !

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
oleksiys
Offline
Joined: 2006-01-25

Is there an easy way to reproduce this issue?

kipioca
Offline
Joined: 2010-11-17

Mmmmm, sorry, but I'd use glassfish many times and this is the first time I encounter this problem... So I can't tell you what you can do to reproduce.... But if needed, I can transmit my pcap and log files... If I could reproduce, I think I'll be near from the solution ...
Thanks for reply

mgainty
Offline
Joined: 2004-05-21

please retransmit the original problem and attach any logs detailing exceptions which suggest this is a problem with GF

thanks,
Martin Gainty
______________________________________________
Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité

Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen.
Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le destinataire prévu, nous te demandons avec bonté que pour satisfaire informez l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci est interdite. Ce message sert à l'information seulement et n'aura pas n'importe quel effet légalement obligatoire. Étant donné que les email peuvent facilement être sujets à la manipulation, nous ne pouvons accepter aucune responsabilité pour le contenu fourni.

> To: users@glassfish.dev.java.net
> From: forums@java.net
> Date: Thu, 18 Nov 2010 05:19:02 -0800
> Subject: Mmmmm, sorry, but I'd use
>
> Mmmmm, sorry, but I'd use glassfish many times and this is the first time I
> encounter this problem... So I can't tell you what you can do to
> reproduce.... But if needed, I can transmit my pcap and log files... If I
> could reproduce, I think I'll be near from the solution ...
>
> Thanks for reply
>
>

kipioca
Offline
Joined: 2010-11-17

OK, my problem is very simple to explain (more simple than to diagnose... Unfortunatly): I call a page to minotor my application, but sometimes, I haven't any response... So here is the logs from my app :
[#|2010-11-17T12:53:57.690+0100|INFO|sun-appserver2.1|javax.enterprise.system.stream.out|_ThreadID=419;_ThreadName=httpSSLWorkerThread-8081-29;|[12:53:57] TRACE _005fstatus_jsp - BEAUREGARDUP 17 novembre 2010 12:53:57 CET
[#|2010-11-17T12:54:27.690+0100|INFO|sun-appserver2.1|javax.enterprise.system.stream.out|_ThreadID=575;_ThreadName=httpSSLWorkerThread-8081-45;|[12:54:27] TRACE _005fstatus_jsp - BEAUREGARDUP 17 novembre 2010 12:54:27 CET
[#|2010-11-17T12:54:57.690+0100|INFO|sun-appserver2.1|javax.enterprise.system.stream.out|_ThreadID=92;_ThreadName=httpSSLWorkerThread-8081-12;|[12:54:57] TRACE _005fstatus_jsp - BEAUREGARDUP 17 novembre 2010 12:54:57 CET
We can see that it is called... But... I don't receive any response.. So my monitoring creates an alert...
The tcpdump capture is available here: http://dl.free.fr/fT6jgd1nD
As you can see, pcap file doesn't see any response (HTTP 200 OK) for the first two elements but only for the third... So I get to alert from monitor system...
Thanks for help !

oleksiys
Offline
Joined: 2006-01-25

Does you request look like:

GET /_status.jsp HTTP/1.1 ?

From your tcp dump I see just one 0xd 0xa following the request line,
but there is no additional 0xd 0xa, which specifies the end of request.

WBR,
Alexey.

On Nov 18, 2010, at 17:18 , forums@java.net wrote:

> OK, my problem is very simple to explain (more simple than to
> diagnose...
> Unfortunatly): I call a page to minotor my application, but
> sometimes, I
> haven't any response... So here is the logs from my app :
>
> [#|2010-11-17T12:53:57.690+0100|INFO|sun-appserver2.1|
> javax.enterprise.system.stream.out|
> _ThreadID=419;_ThreadName=httpSSLWorkerThread-8081-29;|[12:53:57]
> TRACE _005fstatus_jsp - BEAUREGARDUP 17 novembre 2010 12:53:57 CET
>
> [#|2010-11-17T12:54:27.690+0100|INFO|sun-appserver2.1|
> javax.enterprise.system.stream.out|
> _ThreadID=575;_ThreadName=httpSSLWorkerThread-8081-45;|[12:54:27]
> TRACE _005fstatus_jsp - BEAUREGARDUP 17 novembre 2010 12:54:27 CET
>
> [#|2010-11-17T12:54:57.690+0100|INFO|sun-appserver2.1|
> javax.enterprise.system.stream.out|
> _ThreadID=92;_ThreadName=httpSSLWorkerThread-8081-12;|[12:54:57]
> TRACE _005fstatus_jsp - BEAUREGARDUP 17 novembre 2010 12:54:57 CET
>
> We can see that it is called... But... I don't receive any
> response.. So my
> monitoring creates an alert...
>
> The tcpdump capture is available here: http://dl.free.fr/fT6jgd1nD [1]
>
> As you can see, pcap file doesn't see any response (HTTP 200 OK)
> for the
> first two elements but only for the third... So I get to alert from
> monitor
> system...
>
> Thanks for help !
>
>
>
>
> [1] http://dl.free.fr/fT6jgd1nD
>

kipioca
Offline
Joined: 2010-11-17

oleksiys, first, many thanks for taking time for helping me ;)
Yes, my requested page is _status.jsp (GET /_status.jsp HTTP/1.1)... Do you think my problem can be caused by this laking 0xd 0xa ? If so, how can I find from where my problem is coming ? Is this the host sending request ? How is it possible that the host 'forget' this 0xd 0xa ? And why is this working with the last packet ?
Many many thanks !

oleksiys
Offline
Joined: 2006-01-25

> Yes, my requested page is _status.jsp (GET /_status.jsp HTTP/1.1)...
> Do you
> think my problem can be caused by this laking 0xd 0xa ?
It's very possible, if you don't send final 0xd 0xa - Glassfish parser
may still wait for the end of request.

> If so, how can I find from where my problem is coming ? Is this the
> host sending request ? How is
> it possible that the host 'forget' this 0xd 0xa ?
I don't know how it can forget :) What kind of HTTP client are you
using?

WBR,
Alexey.

>
> Many many thanks !
>
>

kipioca
Offline
Joined: 2010-11-17

Again, thanks for reply...
My client is a homemade script... I can send you sources if needed... But I can't understand why it is not working SOMETIMES and not all the time ??!

kipioca
Offline
Joined: 2010-11-17

I've asked to the constructor of the LB that doing this check, and he tells me that the script just does a telnet :
GET /_status.jsp HTTP/1.1\r\nHost: \r\nConnection: Close\r\n\r\n
And then, if no response is received, it considers host is down and generate a monitoring alert...
Have you another idea to look forward ?

kipioca
Offline
Joined: 2010-11-17

Mmmm OK, nobody have any idea about what happend? Thanks for help... But any idea will be welcome

oleksiys
Offline
Joined: 2006-01-25

resending using forum
please add this jvm option declaration [1] to domain.xml.
in the server.log you'll see the HTTP packet dumps.

This way we can make sure HTTP request comes, but no response following.

WBR,
Alexey.

[1] <jvm-options>-Dcom.sun.grizzly.enableSnoop=true</jvm-options>

kipioca
Offline
Joined: 2010-11-17

I know it should seems to be a stupid question ... You'll probably answer glassfish DOES NOT lose packets... But I have a real problem with this, I can't monitor my application because of that... So please, someone have an idea of the way to investigate ?
Please help me...
Thanks !