# 429 too many requests

**URL:** https://meta.discourse.org/t/429-too-many-requests/128350
**Category:** Self-hosting
**Created:** [12 בספטמבר,‏ 2019,‏ 1:08am UTC](https://meta.discourse.org/t/429-too-many-requests/128350 "2019-09-12T01:08:54Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![izzy](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/izzy/32/156031_2.png) [@izzy](https://meta.discourse.org/u/izzy)
#### Post date: [12 בספטמבר,‏ 2019,‏ 1:08am UTC](https://meta.discourse.org/t/429-too-many-requests/128350/1 "2019-09-12T01:08:54Z")

</div>

Hey everyone, I know there are “too many requests” topics before, but this one seems to not 100% fit the bill.

I’m getting intermittent 429 errors in discourse (and everything’s fairly slow in general) with this backtrace

```plaintext
Error: Too Many Requests
    at s (https://discourse.looker.com/assets/ember_jquery-d430881a3fb1403871256e5a02423c4b20a78793685e92088613ca9a701baf88.js:9:9188)
    at a (https://discourse.looker.com/assets/ember_jquery-d430881a3fb1403871256e5a02423c4b20a78793685e92088613ca9a701baf88.js:9:9045)
    at o (https://discourse.looker.com/assets/ember_jquery-d430881a3fb1403871256e5a02423c4b20a78793685e92088613ca9a701baf88.js:9:8936)
    at Object.trigger (https://discourse.looker.com/assets/ember_jquery-d430881a3fb1403871256e5a02423c4b20a78793685e92088613ca9a701baf88.js:18:7223)
    at https://discourse.looker.com/assets/ember_jquery-d430881a3fb1403871256e5a02423c4b20a78793685e92088613ca9a701baf88.js:18:9212
    at t.invoke (https://discourse.looker.com/assets/ember_jquery-d430881a3fb1403871256e5a02423c4b20a78793685e92088613ca9a701baf88.js:16:9729)
    at e.t.flush (https://discourse.looker.com/assets/ember_jquery-d430881a3fb1403871256e5a02423c4b20a78793685e92088613ca9a701baf88.js:16:8732)
    at e.t.flush (https://discourse.looker.com/assets/ember_jquery-d430881a3fb1403871256e5a02423c4b20a78793685e92088613ca9a701baf88.js:16:10782)
    at e.n._end (https://discourse.looker.com/assets/ember_jquery-d430881a3fb1403871256e5a02423c4b20a78793685e92088613ca9a701baf88.js:16:15440)
    at e.n.end (https://discourse.looker.com/assets/ember_jquery-d430881a3fb1403871256e5a02423c4b20a78793685e92088613ca9a701baf88.js:16:12110)

```

It’s always that .js link, which is a pretty impressive block of JS that doesn’t really mean anything to me. The instance running discourse seems to be under minimal load— 10% of CPU, everything else seems fairly nominal, so it’s a bit confusing to me that I’d be getting 429 errors.

Are there settings I can up somewhere to change global rate limiting? The instance can handle much more load than discourse seems to think, or I’m missing something greater caused by a plugin or bug.

Thanks!

---

<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: [12 בספטמבר,‏ 2019,‏ 2:13am UTC](https://meta.discourse.org/t/429-too-many-requests/128350/2 "2019-09-12T02:13:17Z")

</div>

Is your site behind a reverse proxy or anything else that would mess with real incoming IP addresses?

---

<div class="post-metadata">

### Author: ![izzy](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/izzy/32/156031_2.png) [@izzy](https://meta.discourse.org/u/izzy)
#### Post date: [12 בספטמבר,‏ 2019,‏ 3:12pm UTC](https://meta.discourse.org/t/429-too-many-requests/128350/3 "2019-09-12T15:12:14Z")

</div>

No, I don’t believe so (and the logs capture IP addresses normally) but it does sit behind an ELB. It definitely did correlate with a significant increase in traffic (looks kind of like a DDOS attack or something)

 ![image](https://global.discourse-cdn.com/meta/original/3X/9/b/9b21e01ddda081cbaa1276783f104cd13cc5569d.png)

But if my understanding of rate limiting is correct, that shouldn’t have affected every user— Only the user trying to visit a million times, right?

I’ll verify re: the network architecture. Thanks!

---

<div class="post-metadata">

### Author: ![Falco](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/falco/32/179432_2.png) [@Falco](https://meta.discourse.org/u/Falco)
#### Post date: [12 בספטמבר,‏ 2019,‏ 6:20pm UTC](https://meta.discourse.org/t/429-too-many-requests/128350/4 "2019-09-12T18:20:45Z")

</div>

I believe the nginx inside the Discourse container is using the ELB IP for the rate limiting bucket instead of the original client IP.

---

<div class="post-metadata">

### Author: ![izzy](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/izzy/32/156031_2.png) [@izzy](https://meta.discourse.org/u/izzy)
#### Post date: [13 בספטמבר,‏ 2019,‏ 10:41pm UTC](https://meta.discourse.org/t/429-too-many-requests/128350/5 "2019-09-13T22:41:36Z")

</div>

That sounds quite possible. Just verified that we do have an ELB setup in aws with nothing particularly special about it— Is is the result of something that I have misconfigured on my end?

Not 100% sure what next steps would be. If you point me in the right direction, I can probably work with my ops team to figure it out. Thanks much!

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [19 באפריל,‏ 2023,‏ 1:49am UTC](https://meta.discourse.org/t/429-too-many-requests/128350/6 "2023-04-19T01:49:39Z")

</div>



---

<div class="post-metadata">

### Author: ![JammyDodger](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jammydodger/32/254611_2.png) [@JammyDodger](https://meta.discourse.org/u/JammyDodger)
#### Post date: [19 באפריל,‏ 2023,‏ 4:34am UTC](https://meta.discourse.org/t/429-too-many-requests/128350/7 "2023-04-19T04:34:10Z")

</div>


