Occasional 5xx on RoR Kibana 5.6.3/5.6.4

We are seeing inconsistent 5xx errors with Kibana that look like the following:

{“type”:“response”,"@timestamp":“2017-12-08T18:22:44Z”,“tags”:[],“pid”:104,“method”:“post”,“statusCode”:500,“req”:{“url”:"/login",“method”:“post”,“headers”:{“x-forwarded-for”:“172.29.26.29”,“x-forwarded-proto”:“https”,“x-forwarded-port”:“443”,“host”:“url”,“x-amzn-trace-id”:“Root=1-5a2ad874-67109bc477b7baa57962921d”,“content-length”:“41”,“user-agent”:“Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:57.0) Gecko/20100101 Firefox/57.0”,“accept”:“application/json, text/javascript, /; q=0.01”,“accept-language”:“en-US,en;q=0.5”,“accept-encoding”:“gzip, deflate, br”,“referer”:“https://url/login?nextUrl=%2F",“content-type”:"application/x-www-form-urlencoded; charset=UTF-8”,“kbn-version”:“5.6.3”,“kbn-xsrf”:“5.6.3”,“x-requested-with”:“XMLHttpRequest”,“dnt”:“1”},“remoteAddress”:“172.19.243.25”,“userAgent”:“172.19.243.25”,“referer”:“https://url/login?nextUrl=%2F"},“res”:{“statusCode”:500,“responseTime”:32,“contentLength”:9},“message”:"POST /login 500 32ms - 9.0B”}
Error: Uncaught error: “value” required in setHeader(“x-ror-current-group”, value)
at ClientRequest.OutgoingMessage.setHeader (_http_outgoing.js:355:11)
at new ClientRequest (_http_client.js:85:14)
at Object.exports.request (http.js:31:10)
at Object.exports.request (https.js:199:15)
at internals.Client.request (/usr/share/kibana/plugins/readonlyrest_kbn/node_modules/wreck/lib/index.js:158:24)
at getIdentity (/usr/share/kibana/plugins/readonlyrest_kbn/server/routes/lib/auth.js:1:1992)
at login (/usr/share/kibana/plugins/readonlyrest_kbn/server/routes/lib/auth.js:6:1441)
at Object.internals.handler (/usr/share/kibana/node_modules/hapi/lib/handler.js:96:36)
at request._protect.run (/usr/share/kibana/node_modules/hapi/lib/handler.js:30:23)
at internals.Protect.run (/usr/share/kibana/node_modules/hapi/lib/protect.js:64:5)
at exports.execute (/usr/share/kibana/node_modules/hapi/lib/handler.js:24:22)
at each (/usr/share/kibana/node_modules/hapi/lib/request.js:384:16)
at iterate (/usr/share/kibana/node_modules/hapi/node_modules/items/lib/index.js:36:13)
at done (/usr/share/kibana/node_modules/hapi/node_modules/items/lib/index.js:28:25)
at Hoek.once (/usr/share/kibana/node_modules/hapi/lib/protect.js:52:16)
at wrapped (/usr/share/kibana/node_modules/hoek/lib/index.js:875:20)
at done (/usr/share/kibana/node_modules/hapi/node_modules/items/lib/index.js:31:25)
at Function.wrapped [as _next] (/usr/share/kibana/node_modules/hoek/lib/index.js:875:20)
at Function.internals.continue (/usr/share/kibana/node_modules/hapi/lib/reply.js:108:10)
at postAuth (/usr/share/kibana/plugins/readonlyrest_kbn/server/routes/lib/postAuth.js:1:775)
at Items.serial (/usr/share/kibana/node_modules/hapi/lib/request.js:403:22)
at iterate (/usr/share/kibana/node_modules/hapi/node_modules/items/lib/index.js:36:13)

Has anyone else run into something like this?

It seems to occur whenever I:

  1. Log in to Kibana (successfully)
  2. Close the browser window
  3. Open a new browser window (in the same session)
  4. Log in again

Hi @johnseekins!

This is a known “bug”. The master code already has dealt with this.

The gist is that it is actually OK for that header to have no value, at that stage of the session. And we now just null check and move on.

Ah cool. Well…I’ll look forward to the fix. Thanks!

1 Like