# Update in browser vs Terminal

**URL:** https://meta.discourse.org/t/update-in-browser-vs-terminal/358717
**Category:** Support
**Created:** [March 25, 2025, 7:55am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717 "2025-03-25T07:55:28Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 7:55am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/1 "2025-03-25T07:55:28Z")

</div>

Is it the same process to update Discourse via the browser, or via Terminal using the `./launcher rebuild app`?  
If so, any advantages of one over the other, other than being able to update plugins individually?

I’m no expert in this, so I’m sorry if I’m saying something that doesn’t make sense.

I’m asking this, because it’s the second time I try to update via the browser and it gets stuck. The first time it started and got stuck in the middle of the updating process, and then last night (2nd time) I hit the update button, went to bed, and this morning it hadn’t even begin. I had to Cancel and restart.

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [March 25, 2025, 8:11am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/3 "2025-03-25T08:11:25Z")

</div>

> [@Manually update Discourse and Docker image to latest](https://meta.discourse.org/t/manually-update-discourse-and-docker-image-to-latest/23325):
>
> bookmark This guide provides step-by-step instructions for manually updating Discourse, the Docker container, and the Ubuntu operating system on a self-hosted setup. person_raising_hand Required user level: System Administrator warning SSH access to the server. If you self-host Discourse, you occasionally need to run a manual update via the command line to get the latest security releases and newest libraries. These updates are not picked up in admin/upgrade, which is why you’ll occa…

Use the UI when possible to minimise downtime (few seconds)

Occasionally some forms of update (e.g. update postgres version) require a command line update. This is necessary on those occasions but does lead to some downtime on [standard install](https://meta.discourse.org/t/142537?silent=true). Usually about 20 minutes. Pick an off-peak period.

Those occasions should be obvious from the UI.

If you want to add or remove a plugin, you will need to use the console rebuild.

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 8:20am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/4 "2025-03-25T08:20:36Z")

</div>

> [@merefield](#):
>
> Use the UI when possible to minimise downtime (few seconds)

As I’m updating now, I noticed that the forum is still working, but sometimes a bit slower. This is good compared to using Terminal, which seems to completely make the forum not work. Thanks for clarifying this.

> [@merefield](#):
>
> Those occasions should be obvious from the UI.

Even for a non-expert like myself? I mean, will it say something that shows me I should use Terminal instead?

> [@merefield](#):
>
> If you want to add or remove a plugin, you will need to use the console rebuild.

Technologically speaking, do you think this will eventually change one day where we can do everything in the browser? I don’t know the technicalities of this process, that’s why I’m asking.

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 8:24am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/5 "2025-03-25T08:24:08Z")

</div>

It crashed again…  
`Spinning up 1 Unicorn worker(s) that were stopped initially`

`ERR_PNPM_RECURSIVE_EXEC_FIRST_FAIL Command was killed with SIGKILL (Forced termination): ember build -prod Docker Manager: FAILED TO UPGRADE`

Is this something I will face often? What could be causing this and how to fix it?

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [March 25, 2025, 8:24am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/6 "2025-03-25T08:24:11Z")

</div>

> [@alltiagocom](#):
>
> Technologically speaking, do you think this will eventually change one day where we can do everything in the browser? I don’t know the technicalities of this process, that’s why I’m asking.

I suspect it will always be like this on the [standard install](https://meta.discourse.org/t/142537?silent=true).

You can find resources on here to configure a “we’re offline, come back later screen” to mitigate those 20 minutes, but it’s not the [standard install](https://meta.discourse.org/t/142537?silent=true) and I would suggest you keep things simple and easily supported.

> [@Add an offline page to display when Discourse is rebuilding or starting up](https://meta.discourse.org/t/add-an-offline-page-to-display-when-discourse-is-rebuilding-or-starting-up/45238):
>
> warning This guide is intended for advanced users, who are already using nginx outside the docker container. By following this guide you make your setup more complicated and will lose some speed benefits like HTTP2 if you’re not running Ubuntu 16.04 or later. Proceed with caution! When Discourse is rebuilding or starting up, your users will usually either see an error message from their browser… …or a not-so-nice 502 error message from Nginx: If you’re a perfectionist …

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 8:27am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/7 "2025-03-25T08:27:15Z")

</div>

> [@merefield](#):
>
> You can find resources on here to configure a “we’re offline, come back later screen”

I saw that a few days ago, but it was indeed very complex for me.

I just posted the errors I’m seeing when trying to update now. It crashed again. It’s on my previous reply.

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 8:31am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/8 "2025-03-25T08:31:23Z")

</div>

So after it [crashed](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/5), I clicked the button to restart updating and it’s stuck on this again, which is what happened last night:

 ![image](https://global.discourse-cdn.com/meta/original/4X/0/4/0/0402692cfdb8eaadbb36713bf15865fb4fbdc34b.png)

Here’s what I noticed, but don’t know if it’s a coincidence: when it gets stuck on that state where nothing happens, I click Reset Update. Try to restart, nothing happens. Then I go back to the page with all the updates, and click the Update button. This time, it starts the update. Not sure if there’s something broken in the code that after a reset, the button to restart, doesn’t actually do anything? I have no clue, but I’m just sharing my experience.

Now it’s updating again, after I did what I just described.

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 8:48am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/9 "2025-03-25T08:48:26Z")

</div>

I’m confused now… it crashed again, but when I refreshed the browser it said that Discourse was at the newest version…  
When I went to the main updates page where the plugins are, it indeed showed Discourse as being updated 🤔

---

<div class="post-metadata">

### Author: ![Canapin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/canapin/32/119591_2.png) [@Canapin](https://meta.discourse.org/u/Canapin)
#### Post date: [March 25, 2025, 9:04am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/10 "2025-03-25T09:04:40Z")

</div>

> [@alltiagocom](#):
>
> Command was killed with SIGKILL

Try creating a swap:

> [@Create a swapfile for your Linux server](https://meta.discourse.org/t/create-a-swapfile-for-your-linux-server/13880):
>
> bulb For servers with \<= 4GB of RAM, running ./discourse-setup will prompt for and automatically create a 2GB swapfile. Most cloud virtual machine providers do not set up swapfiles as part of their server provisioning. In particular, upgrading Discourse produces a lot of memory pressure. With a swap file, rather than randomly terminating processes with an out of memory error, things will slow down instead. Having a swap file is a cheap insurance policy that protects you from many other lo…

It seems that this error message has been very common lately, and was always fixed by creating swap. I don’t know why since Discourse’s official requirements have not changed.

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 9:14am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/11 "2025-03-25T09:14:45Z")

</div>

> [@Canapin](#):
>
> Try creating a swap

I’ve seen this word before, but I have no idea what it is and what it is for.

Thank you for sharing that link. I will definitely do that and if I encounter any issue, I will share it.

When I go to DigitalOcean, I see this for my droplet:  
 ![image](https://global.discourse-cdn.com/meta/original/4X/c/0/b/c0b75c9c680e39f894fbecea6853d1270ece7299.png)

So I “qualify” for that swapfile process you shared, right? Because my server is \<= 2GB of RAM.

---

<div class="post-metadata">

### Author: ![NateDhaliwal](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/natedhaliwal/32/313494_2.png) [@NateDhaliwal](https://meta.discourse.org/u/NateDhaliwal)
#### Post date: [March 25, 2025, 9:16am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/12 "2025-03-25T09:16:15Z")

</div>

If it’s less than 2GB, I would recommended creating a swapfile. Mine is 1GB so I definitely needed one.

From my understanding, swap basically takes some storage and converts it to use as more memory.

---

<div class="post-metadata">

### Author: ![Canapin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/canapin/32/119591_2.png) [@Canapin](https://meta.discourse.org/u/Canapin)
#### Post date: [March 25, 2025, 9:17am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/13 "2025-03-25T09:17:11Z")

</div>

Then `./discourse-setup` should have created a swap automatically. I’m not well versed in the arcanes of system administration so I’ll let others tell more about this.

That said, even with more than the requirements, users have come across this issue, so there’s something fishy.

As for the update from the interface, I’ve found it a bit unreliable over the years. I’m not sure why, it seems it sometimes fails without obvious reason when a rebuild works.

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 9:21am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/14 "2025-03-25T09:21:50Z")

</div>

> [@Canapin](#):
>
> Then `./discourse-setup` should have created a swap automatically

Is there a way, via Terminal, to see if there is one already? (Maybe this answers my question? `I’m not well versed in the arcanes of system administration`)

> [@Canapin](#):
>
> even with more than the requirements, users have come across this issue, so there’s something fishy

Ok, so I guess I’m not alone here.

> [@Canapin](#):
>
> As for the update in the terminal, I’ve found it a bit unreliable over the years. I’m not sure why, it seems it sometimes fails without obvious reason when a rebuild works.

I’m a bit confused… using Terminal are those 2 different things? Update and Rebuild? Because I’ve been using just `./launcher rebuild app` and that always works.

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 9:24am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/15 "2025-03-25T09:24:01Z")

</div>

> [@NateDhaliwal](#):
>
> From my understanding, swap basically takes some storage and converts it to use as more memory.

Ok thank you. That helps!

---

<div class="post-metadata">

### Author: ![Canapin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/canapin/32/119591_2.png) [@Canapin](https://meta.discourse.org/u/Canapin)
#### Post date: [March 25, 2025, 9:24am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/16 "2025-03-25T09:24:10Z")

</div>

Sorry, I meant from the interface, I’ve corrected my post. 🙂

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 9:29am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/17 "2025-03-25T09:29:35Z")

</div>

Oh ok, now it makes sense 🙂  
Yes, that’s my experience as well.  
The downside is that the rebuild completely shuts down the forum, which is not ideal, but oh well… we gotta do what we gotta do.

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 9:35am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/18 "2025-03-25T09:35:38Z")

</div>

I asked Claude about my question if there’s a way to check if there’s a swap file and this is what I got:

 ![image](https://global.discourse-cdn.com/meta/original/4X/3/d/7/3d7603af5c680cc5a0e2fae1e18ee3e4f27c3c34.png)

---

<div class="post-metadata">

### Author: ![alltiagocom](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/alltiagocom/32/492709_2.png) [@alltiagocom](https://meta.discourse.org/u/alltiagocom)
#### Post date: [March 25, 2025, 10:13am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/19 "2025-03-25T10:13:45Z")

</div>

**UPDATE**

Without expertise in this, I used Claude and ChatGPT to help me figure things out. So, as suggested, I went the swapfile route, but as it was pointed out, maybe I had already a swapfile based on how I installed Discourse. To make sure I did, I ran

```bash
sudo swapon --show

```

in Terminal and I got this:

![image](https://global.discourse-cdn.com/meta/original/4X/0/4/8/048fe6d9b4097925e05be431a2ff09d25fcb6d17.png)

So I looked at the “USED” column and thought: “_well, if the swapfile is used to help things run smoother when RAM is not enough, but it says the swapfile is using 1.9GB out of 2GB, that will not help_”

So I asked ChatGPT if I could just clear/empty the swapfile and I got this command:

```bash
sudo swapoff -a && sudo swapon -a

```

Ran it, let it do its thing and ran the other one again:

```bash
sudo swapon --show

```

Now I see this:  
 ![image](https://global.discourse-cdn.com/meta/original/4X/5/e/3/5e301ac040a2c5d935fea351c6197cecefd0411b.png)

So I guess that it’s good to go through this process of cleaning/emptying the swapfile once in a while?

---

<div class="post-metadata">

### Author: ![Canapin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/canapin/32/119591_2.png) [@Canapin](https://meta.discourse.org/u/Canapin)
#### Post date: [March 25, 2025, 10:24am UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/20 "2025-03-25T10:24:24Z")

</div>

Worth trying to increase your swap:

> [@Rebuild fails with exit 1: ERR\_PNPM\_RECURSIVE\_EXEC\_FIRST\_FAIL](https://meta.discourse.org/t/rebuild-fails-with-exit-1-err-pnpm-recursive-exec-first-fail/351862/12):
>
> Well, I changed swap from 2G to 4G, and rebuilding went thru. So mayby it was again matter of amount of RAM. Or it was a fluke. And then we are back in FAQ-topic: how much RAM does Discourse really need — because swapfile is de facto part of total amount RAM, and now it looks like the actual need is 11+ GB for small forum flushed_face

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [March 25, 2025, 11:38pm UTC](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717/21 "2025-03-25T23:38:30Z")

</div>

Rebuild from the command line takes less ram.

With a two container install, you can build a new container while the old one continues to work (if you have enough ram). That gives you little downtime.

You have to do a command line rebuild sometimes because underlying libraries need to be updated and those can’t be done from the ux.

You can

```plaintext
cd /var/discourse
grep swap discourse-setup

```

to see the commands that it does to create the swap. If you run `swapoff` (so that the file is no longer busy) you can then run the commands that create the file `(fsallocate)` making it bigger, if desired, and format it as swap `(mkswap)` and then `swapon -a` to turn it back on.

If you’ve got many plugins you likely need a total of 5 or 6gb.

[Next page](https://meta.discourse.org/t/update-in-browser-vs-terminal/358717.md?page=2)
