Kibana: "Kibana did not load properly. Check the server output for more information." when opening short URLs in Chrome with SessionStorage enabled

Created on 17 Jul 2017  ·  24Comments  ·  Source: elastic/kibana

"Kibana did not load properly. Check the server output for more information." when opening short urls (goto) in Chrome. It works on IE, Edge and Firefox.

Browser stacktrace:
image

Relevant server logs:

{
    "type": "response",
    "@timestamp": "2017-07-17T15:27:35Z",
    "tags": [],
    "pid": 3916,
    "method": "get",
    "statusCode": 404,
    "req": {
        "url": "/bundles/stateSessionStorageRedirect.style.css?v=15382",
        "method": "get",
        "headers": {
            "host": "***************Pii*************:5601",
            "connection": "keep-alive",
            "user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.115 Safari/537.36",
            "accept": "text/css,*/*;q=0.1",
            "referer": "***************Pii*************:5601/goto/0d7c693effd0586eff0f32b1366eef90",
            "accept-encoding": "gzip, deflate",
            "accept-language": "en-US,en;q=0.8"
        },
        "remoteAddress": "***************Pii*************",
        "userAgent": "***************Pii*************",
        "referer": "***************Pii*************:5601/goto/0d7c693effd0586eff0f32b1366eef90"
    },
    "res": {
        "statusCode": 404,
        "responseTime": 0,
        "contentLength": 9
    },
    "message": "GET /bundles/stateSessionStorageRedirect.style.css?v=15382 404 0ms - 9.0B"
}

Kibana version: 5.5

Elasticsearch version: 5.5

Server OS version: Windows Server 2012 R2

Browser version: Chrome 59.0.3071.115 (Official Build) (64-bit)

Browser OS version: Windows 10 and Server 2016

Original install method (e.g. download page, yum, from source, etc.): download

Operations bug feedback_needed not reproducible

Most helpful comment

/usr/share/kibana/optimize/bundles/stateSessionStorageRedirect.style.css is missing in 5.1.1. 5.1.1 is missing the css file

dpkg -L kibana | grep stateSessionStorageRedirect.
/usr/share/kibana/optimize/bundles/stateSessionStorageRedirect.bundle.js
/usr/share/kibana/optimize/bundles/stateSessionStorageRedirect.entry.js

All 24 comments

Just as workaround, when I create an empty "optimize\bundlesstateSessionStorageRedirect.style.css", then the short URLs work. Seems the combination of short URL, SessionStorage and Chrome is not covered.

I can't reproduce this issue using the same version of chrome on macos, so this may be a windows-specific problem.

Using a 5.5.0 Elastic Cloud instance with Chrome on Windows 10;

  • I set the state:storeInSessionStorage to true
  • From an unsaved search in Discover, I got the Short URL for the Snapshot view and opened it in an incognito Chrome window and that worked
  • I saved the search, got the short URL and opened it in an incognito Chrome window and that worked
  • I generated the short URL for an existing saved metricbeat and opened it in an incognito Chrome window and that worked
  • I posted that same short URL in Slack and another Kibana engineer was also able to open it in Chrome (on Mac OSx)
  • I opened a metricbeat dashboard, got the short URL for Share Snapshot Link, and opened it in an incognito Chrome window and that worked

All of my testing above was using Elastic Cloud but using Chrome on my Windows 10 system. If we think the problem is somehow with the Kibana server I could run Kibana on Windows 10 or a W2012 server.

Chrome Version 59.0.3071.115 (Official Build) (64-bit) (same as OP)

@rcrezende please try this link with user/pwd=readonly/readonly
You'll have to look at last 30 days to see data.

https://03d96382e50cab3d70565e53bcd6a23b.us-east-1.aws.found.io/goto/9b14b847ff3fb687adf927fba64a4e30

The same issue under Win10 both FF 54.01 and Chrome, but only on my desktop - other team-members using kibana just fine.
And I want to notice that even via curl I get "Did not load properly" error (Centos 7.3.1611)

Kibana version 5.3.0
Elastic version 5.3.0

Thanks,
Ivan

@Punkoivan can you try opening your FF and/or Chrome in a new Private/Incognito window and see if you still have the same problem? This would just show if it's something cached in your browser.

@LeeDr Yes, I tried in incognito - doesn't work.
But works perfectly from my another laptop under Linux (Fedora/Ubuntu)
Also I tried to clean up cache and cookies - the same story.

@LeeDr can't create short URLs in that instance, when I try I get: "Url Shortener: Error 403 Forbidden: undefined".

The console:

image

@rcrezende that readonly user doesn't have permissions to be able to create a short URL. I just wanted you to check that the Dashboard opened correctly without errors.

Guys, I'm sorry - my issue was in not enough space on the server on /var mount point.
So, as I understand, kibana can't create cache or something for my browser, but works fine with another browser which has been already cached.

Thanks,

Ivan Pun'ko

/usr/share/kibana/optimize/bundles/stateSessionStorageRedirect.style.css is missing in 5.1.1. 5.1.1 is missing the css file

dpkg -L kibana | grep stateSessionStorageRedirect.
/usr/share/kibana/optimize/bundles/stateSessionStorageRedirect.bundle.js
/usr/share/kibana/optimize/bundles/stateSessionStorageRedirect.entry.js

Experiencing this on Kibana 5.5.2. (Chrome 60 OSX)

Getting:

67dfb8bf9831b27d8d6cce8780f778b3:196 GET https://proxy-se-prod-kibana.***.com/bundles/stateSessionStorageRedirect.style.css?v=15443 
next @ 67dfb8bf9831b27d8d6cce8780f778b3:196
next @ 67dfb8bf9831b27d8d6cce8780f778b3:197
window.onload @ 67dfb8bf9831b27d8d6cce8780f778b3:199
VM58:1 Uncaught SyntaxError: Unexpected token u in JSON at position 0
    at JSON.parse (<anonymous>)
    at getState (commons.bundle.js?v=15443:87)
    at Object.2447 (commons.bundle.js?v=15443:87)
    at __webpack_require__ (commons.bundle.js?v=15443:1)
    at Object.2438 (commons.bundle.js?v=15443:87)
    at __webpack_require__ (commons.bundle.js?v=15443:1)
    at Object.0 (stateSessionStorageRedirect.bundle.js?v=15443:1)
    at __webpack_require__ (commons.bundle.js?v=15443:1)
    at window.webpackJsonp (commons.bundle.js?v=15443:1)
    at stateSessionStorageRedirect.bundle.js?v=15443:1

What's weird is that it's working on a different cluster but they both show up with the same results when I search for stateSession:
Not working

[ PRODUCTION ] erik.anderson@se-prod-logmill1:/opt/kibana/current/optimize$ tree | grep stateSession
    ├── stateSessionStorageRedirect.bundle.js
    ├── stateSessionStorageRedirect.entry.js

Working

[ INT ] erik.anderson@sd-int-logmill1:/opt/kibana/current/optimize$ tree | grep stateSession
    ├── stateSessionStorageRedirect.bundle.js
    ├── stateSessionStorageRedirect.entry.js

I've got the same Problem with Kibana 5.6.3. The workaround with adding the empty "optimize\bundlesstateSessionStorageRedirect.style.css" works fine.

Strange is that my problem browser is firefox, in IE it works. (Can't check crome)

We have the same problem with Firefox with Kibana 5.5.1, works with IE.
The workaround with the css works too.

I see the same error with 5.4. Do I need to add the css on all the nodes and restart?

NOTE: I added labels to categorize the issue but I have not reproduced this problem yet.

@elastic/kibana-platform I relabeled that for the platform team, since this seem to be an issue in the optimizer somehow, since it's solvable by adding additional files.

The operations team owns the optimizer along with the rest of the build stuff, but either way I'm going to close this since we haven't been able to reproduce, and there hasn't been further reports on more recent versions of Kibana (including 5.6).

I've encountered the same behaviour, after upgrading Kibana from 5..0.2 to 5.6.14:

Using the shorturl option to share a dashboard, we had a big red screen:
Kibana did not load properly. Check the server output for more information.

In the browser dev tools (both Firefox and Chrome), we have this error:

Uncaught SyntaxError: Unexpected token u in JSON at position 0
    at JSON.parse (<anonymous>)
    at getState (commons.bundle.js?v=15676:91)
    at Object.2459 (commons.bundle.js?v=15676:91)
    at __webpack_require__ (commons.bundle.js?v=15676:1)
    at Object.2450 (commons.bundle.js?v=15676:90)
    at __webpack_require__ (commons.bundle.js?v=15676:1)
    at Object.0 (stateSessionStorageRedirect.bundle.js?v=15676:1)
    at __webpack_require__ (commons.bundle.js?v=15676:1)
    at window.webpackJsonp (commons.bundle.js?v=15676:1)
    at stateSessionStorageRedirect.bundle.js?v=15676:1
getState @ commons.bundle.js?v=15676:91
2459 @ commons.bundle.js?v=15676:91
__webpack_require__ @ commons.bundle.js?v=15676:1
2450 @ commons.bundle.js?v=15676:90
__webpack_require__ @ commons.bundle.js?v=15676:1
0 @ stateSessionStorageRedirect.bundle.js?v=15676:1
__webpack_require__ @ commons.bundle.js?v=15676:1
window.webpackJsonp @ commons.bundle.js?v=15676:1
(anonymous) @ stateSessionStorageRedirect.bundle.js?v=15676:1

As also a 404 Error on stateSessionStorageRedirect.style.css ressource:

GET https://my.local.domain/bundles/stateSessionStorageRedirect.style.css?v=15676 net::ERR_ABORTED 404 (Not Found)

The installation has been done on Centos 7, using the RPMs provided on Elastic Website.

Looking in the bundle folder content, we have only those js files, concerning stateSessionStorageRedirect :

stateSessionStorageRedirect.bundle.js
stateSessionStorageRedirect.entry.js

The stateSessionStorageRedirect.style.css seems to be missing (I don't know why at the moment).

Looking into the rpm content:

#> rpm -ql kibana | grep stateSessionStorageRedirect.
/usr/share/kibana/optimize/bundles/stateSessionStorageRedirect.bundle.js
/usr/share/kibana/optimize/bundles/stateSessionStorageRedirect.entry.js

Only JS files are presents.

So I just created an empty stateSessionStorageRedirect.style.css file into /usr/share/kibana/optimize/bundles, and now the short url is loading fine.

I don't know if this is a bug, or if I miss something during the upgrade...

I forgot to mention that we also have X-Pack installed, with the Monitoring enabled, if it can help.

At least, I have a workaround, thanks to @tueder

We have encountered this same issue. We are using a docker image based on the artifact download from elastic.co.

We have a working docker image with 5.6.3 that did come with the optimize/bundles/stateSessionStorageRedirect.style.css.. Just recently we were rebuilding the image to remove a plugin and the downloaded package for 5.6.3 no longer contains that file.

The working down load shows a package build of

-rw-rw-r-- 1 1000 1000    918 Jul  5  2018 optimize/bundles/stateSessionStorageRedirect.entry.js
-rw-r--r-- 1 root root 218879 Jul  5  2018 optimize/bundles/stateSessionStorageRedirect.style.css
-rw-r--r-- 1 root root   2545 Jul  5  2018 optimize/bundles/stateSessionStorageRedirect.bundle.js

While the broken download has the following

-rw-rw-r-- 1 1000 1000 959 Oct  6  2017 kibana/optimize/bundles/stateSessionStorageRedirect.bundle.js
-rw-rw-r-- 1 1000 1000 895 Oct  6  2017 kibana/optimize/bundles/stateSessionStorageRedirect.entry.js

We need this fixed urgently as it prevents us from rolling out the update.

The HTML that the short code generates has this

  var files = [
    bundleFile('commons.style.css'),
    bundleFile('stateSessionStorageRedirect.style.css'),
    bundleFile('commons.bundle.js'),
    bundleFile('stateSessionStorageRedirect.bundle.js')
  ];

@ArcticSnowman it's unlikely we'll be able to roll an update quick enough at the need to deploy urgency.

There's a few workarounds here. It's not the recent download missing the file, disabling a plugin re-runs optimize, which is failing. I'd first try allocating more memory to docker and node and rebuilding. If that fails you can run a build on bare metal with more hardware, pack it up, and copy that archive over to the docker build. Hopefully that helps, 2 gb of memory is usually a safe choice for this.

First I have worked around this by injecting the missing file from the docker build process.

I would however totally disagree with you that the file is 'not' missing. Our previous docker build does nothing other than downloading the tar kit for archive.elastic.co and unpacking it. And that image has the file in question. So at some point the tar kits HAD that file present. I have also confirmed that the exact same version (5.6.3) of Kibana tar kit downloaded today is missing this file.

I also tried various other versions of the tar kit and they are all have the 'js' files but not the 'css' file.

Having the advanced setting state:storeInSessionStorage turned on
and missing /usr/share/kibana/optimize/bundles/stateSessionStorageRedirect.style.css
cause the pb (Kibana Version: 5.6.5 from apt source-list https://artifacts.elastic.co/packages/5.x/apt )

Creating the css file empty fix the error

This has long since been resolved, closing.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

cafuego picture cafuego  ·  3Comments

LukeMathWalker picture LukeMathWalker  ·  3Comments

tbragin picture tbragin  ·  3Comments

timroes picture timroes  ·  3Comments

stacey-gammon picture stacey-gammon  ·  3Comments