Hi Jochen,

Thanks for the clarification (as per rfc). It just seems intermittent, when 
using echo and piped to nc. I don't always get an answer, via this way.

Cheers,
Marty

On Wednesday, April 13, 2016 at 8:18:49 PM UTC+10, Jochen Schalanda wrote:
>
> Hi Marty,
>
> the second CRLF is required by the HTTP/1.0 and HTTP/1.1 protocols, so 
> it's not broken but simply as specified (see 
> https://tools.ietf.org/html/rfc7230#section-3 for details). If you really 
> want to use netcat for that stuff instead of a proper HTTP client like 
> curl, you'll have success with the following command:
>
> echo -e "GET /system/lbstatus HTTP/1.1\r\nConnection: close\r\n\r\n" | nc 
> 127.0.0.1 12900
>
>
> Cheers,
> Jochen
>
> On Wednesday, 13 April 2016 01:38:35 UTC+2, Marty wrote:
>>
>> Hi Folks,
>>
>> Graylog V1.3.4
>>
>> Just wondering if anyone has integrated the Graylog LB state into the F5 
>> native http health check.
>> I can't get this to work when sending:
>>
>> GET /system/lbstatus HTTP/1.1
>>
>>
>> From the command line (using netcat) on the graylog node, this also 
>> fails. Just get a newline (no output).
>>
>> $ echo -e "GET /system/lbstatus HTTP/1.1\r\n" | nc 127.0.0.1 12900
>>
>> Using nc natively is OK, as seen below. Need to send <cr> twice, as shown.
>>
>> $ nc 127.0.0.1 12900
>> GET /system/lbstatus HTTP/1.1<cr>
>> <cr>
>> HTTP/1.1 200 OK
>> Content-Type: text/plain
>> X-Graylog-Node-ID: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxx
>> X-Runtime-Microseconds: 240 
>> Transfer-Encoding: chunked 
>>  
>> 5
>> ALIVE 
>> 0 
>> <ctrl c>
>>
>> Using curl is fine:
>>
>> S curl -w '\n' http://127.0.0.1:12900/system/lbstatus
>> ALIVE
>>
>> I got around this on the F5, by using curl with an external script.
>>
>> Just wondering if there is an issue or I'm doing something incorrect.
>>
>> Cheers,
>> Martin
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Graylog Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/graylog2/2b61eae4-e35c-4a12-b27e-fabc0441e3e8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to