# Errno::ENOENT: קובץ או ספרייה לא נמצאו @ rb\_sysopen - /etc/postgresql/15/main/postgresql.conf

**URL:** https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954
**Category:** Support
**Created:** [6 בפברואר,‏ 2025,‏ 9:09pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954 "2025-02-06T21:09:18Z")
**Posts on this page:** 12
**Page:** 1

<div class="post-metadata">

### Author: ![sallypf](https://avatars.discourse-cdn.com/v4/letter/s/c57346/32.png) [@sallypf](https://meta.discourse.org/u/sallypf)
#### Post date: [6 בפברואר,‏ 2025,‏ 9:09pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/1 "2025-02-06T21:09:18Z")

</div>

I tried to update via admin, not sure what happened but admin pages went blank while front was ok. Decided to do update again via command line and got this error

**Errno::ENOENT: No such file or directory @ rb\_sysopen - /etc/postgresql/15/main/postgresql.conf**

```plaintext
cd /var/discourse; ./launcher rebuild app
x86_64 arch detected.
Ensuring launcher is up to date
Fetching origin
Launcher is up-to-date
2.0.20240708-0023: Pulling from discourse/base
Digest: sha256:025e9c1f68
Status: Image is up to date for discourse/base:2.0.20240708-0023
docker.io/discourse/base:2.0.20240708-0023
/usr/local/lib/ruby/gems/3.3.0/gems/pups-1.2.1/lib/pups.rb
/usr/local/bin/pups --stdin
I, [2025-02-06T20:57:43.044950 #1] INFO -- : Reading from stdin
I, [2025-02-06T20:57:43.066724 #1] INFO -- : File > /etc/service/postgres/run chmod: +x chown: 
I, [2025-02-06T20:57:43.072432 #1] INFO -- : File > /etc/service/postgres/log/run chmod: +x chown: 
I, [2025-02-06T20:57:43.077790 #1] INFO -- : File > /etc/runit/3.d/99-postgres chmod: +x chown: 
I, [2025-02-06T20:57:43.083299 #1] INFO -- : File > /root/install_postgres chmod: +x chown: 
I, [2025-02-06T20:57:43.087962 #1] INFO -- : File > /root/upgrade_postgres chmod: +x chown: 

FAILED
--------------------
Errno::ENOENT: No such file or directory @ rb_sysopen - /etc/postgresql/15/main/postgresql.conf
Location of failure: /usr/local/lib/ruby/gems/3.3.0/gems/pups-1.2.1/lib/pups/replace_command.rb:11:in `read'
replace failed with the params {"filename"=>"/etc/postgresql/15/main/postgresql.conf", "from"=>"data_directory = '/var/lib/postgresql/15/main'", "to"=>"data_directory = '/shared/postgres_data'"}
bootstrap failed with exit code 1
**FAILED TO BOOTSTRAP** please scroll up and look for earlier error messages, there may be more than one.
./discourse-doctor may help diagnose the problem.

```

Some other info

```plaintext
cat containers/app.yml | grep postgres

- "templates/postgres.template.yml"

```

How to fix it?

---

<div class="post-metadata">

### Author: ![sallypf](https://avatars.discourse-cdn.com/v4/letter/s/c57346/32.png) [@sallypf](https://meta.discourse.org/u/sallypf)
#### Post date: [6 בפברואר,‏ 2025,‏ 9:13pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/2 "2025-02-06T21:13:53Z")

</div>

יש לי droplet של DigitalOcean, אובונטו, אם זה עוזר.

---

<div class="post-metadata">

### Author: ![sallypf](https://avatars.discourse-cdn.com/v4/letter/s/c57346/32.png) [@sallypf](https://meta.discourse.org/u/sallypf)
#### Post date: [6 בפברואר,‏ 2025,‏ 9:25pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/3 "2025-02-06T21:25:08Z")

</div>

I’ve only one container.

---

<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: [6 בפברואר,‏ 2025,‏ 9:50pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/4 "2025-02-06T21:50:54Z")

</div>

Are those `*`'s really there?

> [@sallypf](#):
>
> ```plaintext
> - "templates/ **postgres**.template.yml"
> 
> ```

Should be

```plaintext
- "templates/postgres.template.yml"

```

---

<div class="post-metadata">

### Author: ![sallypf](https://avatars.discourse-cdn.com/v4/letter/s/c57346/32.png) [@sallypf](https://meta.discourse.org/u/sallypf)
#### Post date: [6 בפברואר,‏ 2025,‏ 9:52pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/5 "2025-02-06T21:52:57Z")

</div>

> [@pfaffman](#):
>
> Are those `*`'s really there?

Sorry, it was copy paste error. I’ve fixed it. No they are not there.

---

<div class="post-metadata">

### Author: ![sallypf](https://avatars.discourse-cdn.com/v4/letter/s/c57346/32.png) [@sallypf](https://meta.discourse.org/u/sallypf)
#### Post date: [6 בפברואר,‏ 2025,‏ 10:14pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/6 "2025-02-06T22:14:21Z")

</div>

רק ניסיתי לעדכן מופע אחר בשרת אחר וזה הצליח. שני השרתים הם droplets של DO עם אותם מפרטים.  
לא בטוח מה קורה.

---

<div class="post-metadata">

### Author: ![sallypf](https://avatars.discourse-cdn.com/v4/letter/s/c57346/32.png) [@sallypf](https://meta.discourse.org/u/sallypf)
#### Post date: [7 בפברואר,‏ 2025,‏ 5:53pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/7 "2025-02-07T17:53:59Z")

</div>

My forum has been down for 2 days, can’t get it work. Moved thread to Support. Hope to get some help.

---

<div class="post-metadata">

### Author: ![mwaniki](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mwaniki/32/313097_2.png) [@mwaniki](https://meta.discourse.org/u/mwaniki)
#### Post date: [10 בפברואר,‏ 2025,‏ 1:01pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/8 "2025-02-10T13:01:20Z")

</div>

> [@sallypf](#):
>
> ```plaintext
> 2.0.20240708-0023: Pulling from discourse/base
> Digest: sha256:025e9c1f68
> Status: Image is up to date for discourse/base:2.0.20240708-0023
> docker.io/discourse/base:2.0.20240708-0023
> 
> ```

That’s a much older Docker image which does _not_ have PostgreSQL 15 packages installed, hence the error:

> [@sallypf](#):
>
> ```plaintext
> Errno::ENOENT: No such file or directory @ rb_sysopen - /etc/postgresql/15/main/postgresql.conf
> 
> ```

Your `launcher` file has probably been modified and locked into using that older Docker image above. You can change it to the latest image highlighted below then try rebuilding again. (Take necessary backups beforehand.)

> <https://github.com/discourse/discourse_docker/blob/efd6bc8ccbd9057c04d909ff48ecf8b704cae3ff/launcher#L95>

---

<div class="post-metadata">

### Author: ![sallypf](https://avatars.discourse-cdn.com/v4/letter/s/c57346/32.png) [@sallypf](https://meta.discourse.org/u/sallypf)
#### Post date: [10 בפברואר,‏ 2025,‏ 2:28pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/9 "2025-02-10T14:28:29Z")

</div>

> [@mwaniki](#):
>
> Your `launcher` file has probably been modified and locked into using that older Docker image above. You can change it to the latest image highlighted below then try rebuilding again. (Take necessary backups beforehand.)

Thanks for the reply. I just checked and in launcher file the base seems to to be latest one

```plaintext
root@host:/var/discourse# cat launcher | grep "base:2.0"
image="discourse/base:2.0.20250129-0720"

```

However during rebuild it is still taking older image, so where does this older image is being picked up from? How do I check it?

---

<div class="post-metadata">

### Author: ![mwaniki](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mwaniki/32/313097_2.png) [@mwaniki](https://meta.discourse.org/u/mwaniki)
#### Post date: [10 בפברואר,‏ 2025,‏ 3:12pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/10 "2025-02-10T15:12:45Z")

</div>

It could also be defined as `base_image` in your `app.yml` file. If you find that, you can simply comment out (or remove) the line.

If that doesn’t help, you can try a recursive search for part of that string instead.

```plaintext
grep --exclude-dir shared -rI 20240708 /var/discourse

```

---

<div class="post-metadata">

### Author: ![sallypf](https://avatars.discourse-cdn.com/v4/letter/s/c57346/32.png) [@sallypf](https://meta.discourse.org/u/sallypf)
#### Post date: [10 בפברואר,‏ 2025,‏ 4:32pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/11 "2025-02-10T16:32:49Z")

</div>

זה עבד. תודה רבה על העזרה.

---

<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: [12 במרץ,‏ 2025,‏ 4:32pm UTC](https://meta.discourse.org/t/errno-no-such-file-or-directory-rb-sysopen-etc-postgresql-15-main-postgresql-conf/350954/12 "2025-03-12T16:32:50Z")

</div>

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