Redirect loop

I configured kibana with a server.basePath: "/kibana" in the config file. That worked fine before installing the x-pack plugin.

After installing xpack, I got stuck in a redirect loop. See the logs for the details.

When I remove the server.basePath statement in the config, I can login (without the reversed proxy).

{"type":"response","@timestamp":"2017-03-08T19:19:13Z","tags":[],"pid":76697,"method":"get","statusCode":302,"req":{"url":"/","method":"get","headers":{"accept":"text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,/;q=0.8","accept-language":"nl-NL,nl;q=0.8,en-US;q=0.6,en;q=0.4","x-cnection":"close","host":"kibana","iv-user":"xxx","user-agent":"Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36","via":"HTTP/1.1 nl020isam018.ad.intra:443","upgrade-insecure-requests":"1","iv_server_name":"xxx","x-forwarded-for":"10.40.13.20"},"remoteAddress":"10.74.81.107","userAgent":"10.74.81.107"},"res":{"statusCode":302,"responseTime":8,"contentLength":9},"message":"GET / 302 8ms - 9.0B"}
{"type":"response","@timestamp":"2017-03-08T19:19:13Z","tags":[],"pid":76697,"method":"get","statusCode":302,"req":{"url":"/kibana/login?next=%2F","method":"get","headers":{"accept":"text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,/;q=0.8","accept-language":"nl-NL,nl;q=0.8,en-US;q=0.6,en;q=0.4","x-cnection":"close","host":"kibana","iv-user":"xxx","user-agent":"Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36","via":"HTTP/1.1 nl020isam018.ad.intra:443","upgrade-insecure-requests":"1","iv_server_name":"xxx","x-forwarded-for":"10.40.13.20"},"remoteAddress":"10.74.81.107","userAgent":"10.74.81.107"},"res":{"statusCode":302,"responseTime":4,"contentLength":9},"message":"GET /kibana/login?next=%2F 302 4ms - 9.0B"}
{"type":"response","@timestamp":"2017-03-08T19:19:13Z","tags":[],"pid":76697,"method":"get","statusCode":302,"req":{"url":"/kibana/login?next=%2Fkibana%2Flogin%3Fnext%3D%252F","method":"get","headers":{"accept":"text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,/;q=0.8","accept-language":"nl-NL,nl;q=0.8,en-US;q=0.6,en;q=0.4","x-cnection":"close","host":"kibana","iv-user":"xxx","user-agent":"Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36","via":"HTTP/1.1 nl020isam018.ad.intra:443","upgrade-insecure-requests":"1","iv_server_name":"xxx","x-forwarded-for":"10.40.13.20"},"remoteAddress":"10.74.81.107","userAgent":"10.74.81.107"},"res":{"statusCode":302,"responseTime":3,"contentLength":9},"message":"GET /kibana/login?next=%2Fkibana%2Flogin%3Fnext%3D%252F 302 3ms - 9.0B"}
{"type":"response","@timestamp":"2017-03-08T19:19:13Z","tags":[],"pid":76697,"method":"get","statusCode":302,"req":{"url":"/kibana/login?next=%2Fkibana%2Flogin%3Fnext%3D%252Fkibana%252Flogin%253Fnext%253D%25252F","method":"get","headers":{"accept":"text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,/;q=0.8","accept-language":"nl-NL,nl;q=0.8,en-US;q=0.6,en;q=0.4","x-cnection":"close","host":"kibana","iv-user":"xxx","user-agent":"Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36","via":"HTTP/1.1 nl020isam018.ad.intra:443","upgrade-insecure-requests":"1","iv_server_name":"xxx","x-forwarded-for":"10.40.13.20"},"remoteAddress":"10.74.81.107","userAgent":"10.74.81.107"},"res":{"statusCode":302,"responseTime":3,"contentLength":9},"message":"GET /kibana/login?next=%2Fkibana%2Flogin%3Fnext%3D%252Fkibana%252Flogin%253Fnext%253D%25252F 302 3ms - 9.0B"}
{"type":"response","@timestamp":"2017-03-08T19:19:13Z","tags":[],"pid":76697,"method":"get","statusCode":302,"req":{"url":"/kibana/login?next=%2Fkibana%2Flogin%3Fnext%3D%252Fkibana%252Flogin%253Fnext%253D%25252Fkibana%25252Flogin%25253Fnext%25253D%2525252F","method":"get","headers":{"accept":"text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,/;q=0.8","accept-language":"nl-NL,nl;q=0.8,en-US;q=0.6,en;q=0.4","x-cnection":"close","host":"kibana","iv-user":"xxx","user-agent":"Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36","via":"HTTP/1.1 nl020isam018.ad.intra:443","upgrade-insecure-requests":"1","iv_server_name":"xxx","x-forwarded-for":"10.40.13.20"},"remoteAddress":"10.74.81.107","userAgent":"10.74.81.107"},"res":{"statusCode":302,"responseTime":2,"contentLength":9},"message":"GET /kibana/login?next=%2Fkibana%2Flogin%3Fnext%3D%252Fkibana%252Flogin%253Fnext%253D%25252Fkibana%25252Flogin%25253Fnext%25253D%2525252F 302 2ms - 9.0B"}

I've seen this happen if kibana can't connect to elasticsearch, or the session cookie path is wrong. Are you able to connect load Kibana in an incognito window/with cookies cleared? Is elasticsearch being brought up after Kibana?

Incogito or with cookies cleared makes no difference.

First starting elastic or first starting kibana makes no difference.

What causses this issue?

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.