# Admin dashboard won’t load after upgrade to v2.2.0.beta3 +36

**URL:** https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669
**Category:** Support
**Created:** [16.Октябрь.2018 19:10:56 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669 "2018-10-16T19:10:56Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![fearlessfrog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fearlessfrog/32/119653_2.png) [@fearlessfrog](https://meta.discourse.org/u/fearlessfrog)
#### Post date: [16.Октябрь.2018 19:10:56 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/1 "2018-10-16T19:10:56Z")

</div>

We recently updated to “v2.2.0.beta3 +36 tests-passed” and have started getting /admin/dashboard/general.json Server 502 errors.

On a quick search it looks very similar to this one:

> [@Admin dashboard won't load after upgrade to v2.1.0.beta3 +20](https://meta.discourse.org/t/admin-dashboard-wont-load-after-upgrade-to-v2-1-0-beta3-20/93311):
>
> I rebuilt Discourse to [v2.1.0.beta3 +20](https://github.com/discourse/discourse/compare/c74dd2fa0848ac527c4715edb7f50114e00681de...tests-passed) following notification this morning that there was a critical update. There were no errors during the rebuilding. However, the Admin dashboard now returns a 502 after trying to load unsuccessfully for a few minutes. When I SSH into the server and curl https://forum.quartertothree.com/admin/dashboard/general.json, the page seems to be returned. However, when trying to hit it externally, the following is in the Nginx log: 2018/07/27 18:01:50 [e…

..which was solved by @j.jaffeux but no solution given in the closed topic.

Is there anything diagnostic wise I can gather to help out on this, or any recent changes in the area meaning I should just try updating to a more recent?

Thanks for any help. This just seems isolated to the /admin otherwise we’re doing great.

---

<div class="post-metadata">

### Author: ![fearlessfrog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fearlessfrog/32/119653_2.png) [@fearlessfrog](https://meta.discourse.org/u/fearlessfrog)
#### Post date: [16.Октябрь.2018 19:29:18 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/2 "2018-10-16T19:29:18Z")

</div>

Nothing of note in the logs, just the 502 from the admin .json, which looks to be a timeout:

```
/var/discourse/shared/standalone/log/rails# more unicorn.stderr.log
I, [2018-10-16T05:13:36.016595 #80] INFO -- : master done reopening logs
I, [2018-10-16T05:13:36.051096 #206] INFO -- : worker=0 done reopening logs
I, [2018-10-16T05:13:36.071959 #253] INFO -- : worker=2 done reopening logs
I, [2018-10-16T05:13:36.079130 #225] INFO -- : worker=1 done reopening logs
I, [2018-10-16T05:13:36.082894 #1264] INFO -- : worker=3 done reopening logs
E, [2018-10-16T17:02:00.830572 #80] ERROR -- : worker=1 PID:225 timeout (31s &gt; 3
0s), killing
I, [2018-10-16T17:02:08.596101 #26765] INFO -- : worker=1 ready
E, [2018-10-16T17:10:47.306347 #80] ERROR -- : worker=2 PID:253 timeout (31s &gt; 3
0s), killing
From https://github.com/discourse/discourse
e3c6dd2..b23ebf1 tests-passed -&gt; origin/tests-passed
e3c6dd2..b23ebf1 master -&gt; origin/master
 * [new branch] svg-icons -&gt; origin/svg-icons
I, [2018-10-16T17:10:54.901712 #27709] INFO -- : worker=2 ready
D, [2018-10-16T17:11:17.368681 #80] DEBUG -- : waiting 16.0s after suspend/hiber
nation
E, [2018-10-16T18:51:14.634343 #80] ERROR -- : worker=3 PID:1264 timeout (31s &gt; 
30s), killing
I, [2018-10-16T18:51:22.141804 #3833] INFO -- : worker=3 ready
D, [2018-10-16T18:51:44.697230 #80] DEBUG -- : waiting 16.0s after suspend/hiber
nation
E, [2018-10-16T19:07:10.412676 #80] ERROR -- : worker=0 PID:206 timeout (31s &gt; 3
0s), killing
I, [2018-10-16T19:07:17.781331 #5188] INFO -- : worker=0 ready
E, [2018-10-16T19:16:05.922215 #80] ERROR -- : worker=2 PID:27709 timeout (31s &gt;
 30s), killing
I, [2018-10-16T19:16:13.599249 #6114] INFO -- : worker=2 ready
E, [2018-10-16T19:20:28.217211 #80] ERROR -- : worker=2 PID:6114 timeout (31s &gt; 
30s), killing
I, [2018-10-16T19:20:35.408446 #6574] INFO -- : worker=2 ready
D, [2018-10-16T19:20:58.285287 #80] DEBUG -- : waiting 16.0s after suspend/hiber
nation

```

Resources seems all ok?

```
>df -h
Filesystem Size Used Avail Use% Mounted on
udev 2.0G 4.0K 2.0G 1% /dev
tmpfs 396M 408K 395M 1% /run
/dev/disk/by-label/DOROOT 79G 15G 60G 20% /
none 4.0K 0 4.0K 0% /sys/fs/cgroup
none 5.0M 0 5.0M 0% /run/lock
none 2.0G 1.7M 2.0G 1% /run/shm
none 100M 0 100M 0% /run/user
none 79G 15G 60G 20% /var/lib/docker/aufs/mnt/b834156bb92ed60ad3d0683540e279fb90f980abb7625247e43db83f7a3cb640
shm 512M 8.0K 512M 1% /var/lib/docker/containers/1ccedc3b8178735b0e091bbc1f42bbfdc6ba03b2676e81a21f210ff178c12d70/shm

```

* * *

```
>free -h
             total used free shared buffers cached
Mem: 3.9G 3.7G 193M 1.0G 50M 1.5G
-/+ buffers/cache: 2.2G 1.7G
Swap: 2.0G 29M 2.0G

```

 ![28%20PM](https://global.discourse-cdn.com/meta/original/3X/d/a/dacc4eeddb094ec59c568962c92e23fcb1b1da2e.png)

All of these paths work ok, it’s just the main /admin page (plus the moderation page is ok too):

```
admin/reports/signups
admin/reports/topics
admin/reports/posts
admin/reports/dau_by_mau
admin/reports/daily_engaged_users
admin/reports/new_contributors
admin/reports/top_referred_topics
admin/reports/trending_search

```

---

<div class="post-metadata">

### Author: ![fearlessfrog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fearlessfrog/32/119653_2.png) [@fearlessfrog](https://meta.discourse.org/u/fearlessfrog)
#### Post date: [16.Октябрь.2018 22:21:19 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/3 "2018-10-16T22:21:19Z")

</div>

It seems like a pure timing issue, in that we up’d the timeout in

```
config/unicorn.conf.rb

```

from 30 to 60 seconds temporarily and now we can see the admin data ok.

As we’ve been running a few years, is there something we can optimize in our set-up to avoid the data taking a while to fetch? Our next stop is to pg analyze to see if a query is causing this, i.e. a missing index or something.

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [17.Октябрь.2018 00:20:44 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/4 "2018-10-17T00:20:44Z")

</div>

Something for @j.jaffeux to look at maybe?

---

<div class="post-metadata">

### Author: ![j.jaffeux](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/j.jaffeux/32/60297_2.png) [@j.jaffeux](https://meta.discourse.org/u/j.jaffeux)
#### Post date: [17.Октябрь.2018 00:22:31 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/5 "2018-10-17T00:22:31Z")

</div>

Hi,

nothing in /logs ? Don’t have much hope about this as charts are supposed to be ultra resilient now. So it’s probably coming from something else like disk-space, backups, or dashboard problems.

---

<div class="post-metadata">

### Author: ![fearlessfrog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fearlessfrog/32/119653_2.png) [@fearlessfrog](https://meta.discourse.org/u/fearlessfrog)
#### Post date: [17.Октябрь.2018 00:30:31 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/6 "2018-10-17T00:30:31Z")

</div>

Hi,

Nothing in log/rails/production\_error.log and just the timeout (as put above in this topic) in unicorn.stderr.log regarding the timeout.

It’s like the dashboard now takes about 35 seconds or so, so unicorn is killing it before it’s done. It only started happening on the recent update.

As put in the posts above, resources all look ok. A 2 vCPU DigitalOcean instance with 4GB memory, db\_shared\_buffers: “1024MB” and UNICORN\_WORKERS: 4

Only other thing I thought of trying is db\_work\_mem has been left as default, so we could up that - do you think it would help the dashboard queries?

The forum performance is generally great, no issues, it’s just this dashboard page since the update this week.

I could update again, but thought it best to keep this config if it helped you track anything down.

---

<div class="post-metadata">

### Author: ![j.jaffeux](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/j.jaffeux/32/60297_2.png) [@j.jaffeux](https://meta.discourse.org/u/j.jaffeux)
#### Post date: [17.Октябрь.2018 00:31:42 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/7 "2018-10-17T00:31:42Z")

</div>

I was meaning in « [www.example.com/logs](http://www.example.com/logs) » but if you are sure you didnt miss anything ok.

---

<div class="post-metadata">

### Author: ![fearlessfrog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fearlessfrog/32/119653_2.png) [@fearlessfrog](https://meta.discourse.org/u/fearlessfrog)
#### Post date: [17.Октябрь.2018 00:32:33 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/8 "2018-10-17T00:32:33Z")

</div>

Yep, they are good, in that no entries when causing this to 502.

---

<div class="post-metadata">

### Author: ![fearlessfrog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fearlessfrog/32/119653_2.png) [@fearlessfrog](https://meta.discourse.org/u/fearlessfrog)
#### Post date: [17.Октябрь.2018 00:47:30 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/9 "2018-10-17T00:47:30Z")

</div>

> [@codinghorror](#):
>
> Something for @joffreyjaffeux to look at maybe?

Thanks Jeff, Joffrey has reached out via PM and we’re setting up some diagnostics to see what’s up. Cheers.

---

<div class="post-metadata">

### Author: ![jerdog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jerdog/32/122843_2.png) [@jerdog](https://meta.discourse.org/u/jerdog)
#### Post date: [22.Октябрь.2018 13:35:56 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/10 "2018-10-22T13:35:56Z")

</div>

Throwing my hat into the ring as I am seeing the [exact same issue](https://meta.discourse.org/t/after-latest-admin-upgrade-my-admin-dashboard-wont-load/99987/) since `/admin/upgrade` was performed… Still happens in [Safe Mode](https://meta.discourse.org/t/53504?silent=true) with everything disabled.

---

<div class="post-metadata">

### Author: ![jerdog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jerdog/32/122843_2.png) [@jerdog](https://meta.discourse.org/u/jerdog)
#### Post date: [22.Октябрь.2018 18:03:35 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/11 "2018-10-22T18:03:35Z")

</div>

@j.jaffeux - let me know what you need from me to see what’s going on

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [22.Октябрь.2018 22:48:12 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/12 "2018-10-22T22:48:12Z")

</div>

What plugins do you have? Remove all but the official plugin, then do a rebuild.

```plaintext
cd /var/discourse
./launcher rebuild app

```

---

<div class="post-metadata">

### Author: ![jerdog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jerdog/32/122843_2.png) [@jerdog](https://meta.discourse.org/u/jerdog)
#### Post date: [23.Октябрь.2018 00:26:51 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/13 "2018-10-23T00:26:51Z")

</div>

I have all official except for Who’s Online.

---

<div class="post-metadata">

### Author: ![fearlessfrog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fearlessfrog/32/119653_2.png) [@fearlessfrog](https://meta.discourse.org/u/fearlessfrog)
#### Post date: [23.Октябрь.2018 00:43:12 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/14 "2018-10-23T00:43:12Z")

</div>

We reverted just back to official plugins last week only but with the same result (no who’s online plugin etc).

I’m awaiting for @j.jaffeux to ping us back and haven’t wanted to change our environment before he can take a look, as I know recreating these things can sometimes be difficult. If I try a bunch of things then I might fix it but then we lose the opportunity for a common solution to make it back in the product.

Because our workaround is just a longer unicorn timeout then there isn’t a great urgency to try things to fix. My best guess would be there is some log or DB table that needs to be pruned by an update, and the queries for the dashboard just take a long time to complete (more than 30 seconds, so the /admin gets killed by Unicorn timeout). Either than or some sort of Postgres buffer tuning that #meta has that the stand-alone installs don’t have configured.

---

<div class="post-metadata">

### Author: ![jerdog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jerdog/32/122843_2.png) [@jerdog](https://meta.discourse.org/u/jerdog)
#### Post date: [23.Октябрь.2018 01:09:26 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/15 "2018-10-23T01:09:26Z")

</div>

What/where did you tune for unicorn? I can make the adjustment until @j.jaffeux is able to figure this out.

---

<div class="post-metadata">

### Author: ![fearlessfrog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fearlessfrog/32/119653_2.png) [@fearlessfrog](https://meta.discourse.org/u/fearlessfrog)
#### Post date: [23.Октябрь.2018 01:35:17 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/16 "2018-10-23T01:35:17Z")

</div>

There’s an ENV for it here:

container/app.yml

env:  
UNICORN\_TIMEOUT: 60

[https://github.com/discourse/discourse/blob/master/config/unicorn.conf.rb#L36](https://github.com/discourse/discourse/blob/master/config/unicorn.conf.rb#L36)

---

<div class="post-metadata">

### Author: ![jerdog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jerdog/32/122843_2.png) [@jerdog](https://meta.discourse.org/u/jerdog)
#### Post date: [23.Октябрь.2018 02:46:22 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/17 "2018-10-23T02:46:22Z")

</div>

Hmm yeah that didn’t work for me…

---

<div class="post-metadata">

### Author: ![fearlessfrog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fearlessfrog/32/119653_2.png) [@fearlessfrog](https://meta.discourse.org/u/fearlessfrog)
#### Post date: [23.Октябрь.2018 03:33:29 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/18 "2018-10-23T03:33:29Z")

</div>

Our issues might be different then? Just to be more explicit on steps:

1 - Edit containers/app.yml via ssh, placing a new UNICORN\_TIMEOUT: 60 line under the env section

2 - ./launcher rebuild app

---

<div class="post-metadata">

### Author: ![jerdog](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jerdog/32/122843_2.png) [@jerdog](https://meta.discourse.org/u/jerdog)
#### Post date: [23.Октябрь.2018 12:54:10 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/19 "2018-10-23T12:54:10Z")

</div>

Yeah that’s what I did…

```plaintext
env:
  ## How many concurrent web requests are supported?
  ## With 2GB we recommend 3-4 workers, with 1GB only 2
  UNICORN_WORKERS: 4
  UNICORN_TIMEOUT: 60

```

---

<div class="post-metadata">

### Author: ![j.jaffeux](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/j.jaffeux/32/60297_2.png) [@j.jaffeux](https://meta.discourse.org/u/j.jaffeux)
#### Post date: [23.Октябрь.2018 16:38:23 UTC](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669/20 "2018-10-23T16:38:23Z")

</div>

I have some big work to finish for tomorrow. Will have a look at this right after.

[Next page](https://meta.discourse.org/t/admin-dashboard-won-t-load-after-upgrade-to-v2-2-0-beta3-36/99669.md?page=2)
