# Launcher rebuild breaks because the database system is starting up

**URL:** https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355
**Category:** Support
**Created:** [5월 28, 2015, 11:00오전 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355 "2015-05-28T11:00:25Z")
**Posts on this page:** 13
**Page:** 1

<div class="post-metadata">

### Author: ![fuerst](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fuerst/32/120729_2.png) [@fuerst](https://meta.discourse.org/u/fuerst)
#### Post date: [5월 28, 2015, 11:00오전 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/1 "2015-05-28T11:00:25Z")

</div>

When doing a `./launcher rebuild` it breaks with

```
RuntimeError: su postgres -c 'psql discourse -c "alter schema public owner to discourse;"' failed with return #<Process::Status: pid 108 exit 2>

```

Looks like the PostgeSQL server is not available because it is starting up.

Complete launcher log is here:

> <https://pastebin.com/3x9TsZA5>

Any ideas how to fix or debug this?

(I use the standalone template.)

---

<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: [5월 28, 2015, 7:06오후 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/2 "2015-05-28T19:06:19Z")

</div>

If you are using different containers for db and web, maybe ensure that the db container is started first and the startup of the web container is delayed to account for that?

---

<div class="post-metadata">

### Author: ![fuerst](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fuerst/32/120729_2.png) [@fuerst](https://meta.discourse.org/u/fuerst)
#### Post date: [5월 28, 2015, 9:01오후 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/3 "2015-05-28T21:01:22Z")

</div>

I do not use different containers but the standalone one. So DB is running within the app container.

---

<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: [5월 28, 2015, 9:04오후 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/4 "2015-05-28T21:04:48Z")

</div>

Did you call the instance “discourse”? the default from our install guide is “app”.

I think this might be a failed install, so I would start over from scratch using our official guide and following it exactly, step by step.

What OS are you installing on? The recommended Ubuntu 14.04 x64 LTS?

---

<div class="post-metadata">

### Author: ![fuerst](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fuerst/32/120729_2.png) [@fuerst](https://meta.discourse.org/u/fuerst)
#### Post date: [5월 28, 2015, 9:55오후 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/5 "2015-05-28T21:55:18Z")

</div>

Yes I call it “discourse” because it is running together with many other containers. Having it named just “app” feels like calling my girl friend something like - “girl friend” 😉 Install went well and it runs well too. Just the rebuild does fail. Should this be because I do not call it “app”?

I’m using CentOS 7 on the host because the host itself is an OpenVZ container. My tests with Ubuntu did not worked well so I went the CentOS road because that’s what OpenVZ supports best. So far no problems using this setup.

---

<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: [5월 28, 2015, 9:56오후 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/6 "2015-05-28T21:56:15Z")

</div>

OpenVZ has been a disaster for Docker.

What does `docker --info` and `docker --version` say?

Version should be 1.6.1+ and docker info should say you are using AUFS. If you are using devicemapper that is broken and unsupported.

---

<div class="post-metadata">

### Author: ![fuerst](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fuerst/32/120729_2.png) [@fuerst](https://meta.discourse.org/u/fuerst)
#### Post date: [5월 28, 2015, 10:00오후 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/7 "2015-05-28T22:00:31Z")

</div>

```
# docker --version
Docker version 1.6.0, build 8aae715/1.6.0

# docker info
...
Storage Driver: vfs

```

Guess I need to reconsider my OS decisions..

---

<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: [5월 28, 2015, 10:01오후 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/8 "2015-05-28T22:01:05Z")

</div>

Hmm don’t know about vfs. But I suspect it’s broken, like devicemapper. Any ideas @sam?

```
// Slice of drivers that should be used in an order
 priority = []string{
 "aufs",
 "btrfs",
 "devicemapper",
 "vfs",
 "overlayfs",

```

---

<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: [5월 28, 2015, 11:06오후 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/9 "2015-05-28T23:06:07Z")

</div>

Never used vfs, I don’t know what the status of it is.

---

<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: [5월 28, 2015, 11:07오후 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/10 "2015-05-28T23:07:19Z")

</div>

Digging into this a little more, the only viable practical options are

- AUFS
- overlayfs

Unfortunately, AUFS is not part of the kernel and will never be, overlayfs looks like it will make it into the kernel, but could be bleeding edge at the moment.

---

<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: [5월 29, 2015, 12:39오전 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/11 "2015-05-29T00:39:22Z")

</div>

@sam is adding better protection for this in the bootstrap step – we really can’t proceed if the filesystem is not one that is known to be compatible with Docker. Too many support issues..

---

<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: [5월 29, 2015, 12:40오전 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/12 "2015-05-29T00:40:30Z")

</div>

Done:

[https://github.com/discourse/discourse\_docker/commit/48f22d14f39496c8df446cbc65ee04b258c5a1a0](https://github.com/discourse/discourse_docker/commit/48f22d14f39496c8df446cbc65ee04b258c5a1a0)

We used to allow people to skip our warning, that was a mistake.

---

<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: [5월 29, 2015, 1:13오전 UTC](https://meta.discourse.org/t/launcher-rebuild-breaks-because-the-database-system-is-starting-up/29355/13 "2015-05-29T01:13:29Z")

</div>


