postgres: Segmentation fault on RPi
If i start any version (debian, alpine, 13, 12, 9) of postgres on my Rasberry PI i get a Segmentation fault
:
postgres_1 | The files belonging to this database system will be owned by user "postgres".
postgres_1 | This user must also own the server process.
postgres_1 |
postgres_1 | The database cluster will be initialized with locale "en_US.utf8".
postgres_1 | The default database encoding has accordingly been set to "UTF8".
postgres_1 | The default text search configuration will be set to "english".
postgres_1 |
postgres_1 | Data page checksums are disabled.
postgres_1 |
postgres_1 | fixing permissions on existing directory /var/lib/postgresql/data ... ok
postgres_1 | creating subdirectories ... ok
postgres_1 | selecting dynamic shared memory implementation ... posix
postgres_1 | selecting default max_connections ... 100
postgres_1 | selecting default shared_buffers ... 128MB
postgres_1 | selecting default time zone ... GMT
postgres_1 | creating configuration files ... ok
postgres_1 | running bootstrap script ... ok
postgres_1 | sh: locale: not found
postgres_1 | 1970-04-25 09:07:44.009 GMT [30] WARNING: no usable system locales were found
postgres_1 | performing post-bootstrap initialization ... ok
postgres_1 | syncing data to disk ... ok
postgres_1 |
postgres_1 | initdb: warning: enabling "trust" authentication for local connections
postgres_1 | You can change this by editing pg_hba.conf or using the option -A, or
postgres_1 | --auth-local and --auth-host, the next time you run initdb.
postgres_1 |
postgres_1 | Success. You can now start the database server using:
postgres_1 |
postgres_1 | pg_ctl -D /var/lib/postgresql/data -l logfile start
postgres_1 |
postgres_1 | waiting for server to start....1970-04-24 12:38:56.009 GMT [35] LOG: starting PostgreSQL 13.1 on arm-unknown-linux-musleabihf, compiled by gcc (Alpine 10.2.1_pre1) 10.2.1 20201203, 32-bit
postgres_1 | 1970-04-24 12:38:56.009 GMT [35] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
postgres_1 | .................1970-04-24 12:38:56.009 GMT [35] LOG: startup process (PID 36) was terminated by signal 11: Segmentation fault
postgres_1 | 1970-04-24 12:38:56.009 GMT [35] LOG: aborting startup due to startup process failure
postgres_1 | 1970-04-24 12:38:56.009 GMT [35] LOG: database system is shut down
postgres_1 | .. stopped waiting
postgres_1 | pg_ctl: could not start server
postgres_1 | Examine the log output.
SOLUTION / CAUSE
The Raspberry PI package sources contains an old version of libseccomp, which causes the time to be at 1970. https://github.com/docker-library/postgres/issues/812#issuecomment-769475062 https://github.com/docker-library/postgres/issues/812#issuecomment-770148482
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Reactions: 4
- Comments: 28 (9 by maintainers)
Links to this issue
Commits related to this issue
- Revert "postgres to alpine and runs on to latest ubuntu (#1576)" This reverts commit 6050dc53f3d026e5c5e771fe1dbb3e799057c6cf. The alpine images don't work on the Raspberry Pi because its package so... — committed to teslamate-org/teslamate by adriankumpf 3 years ago
- Revert "postgres to alpine and runs on to latest ubuntu (#1576)" This reverts commit a74abbbe2b745625c51d5f305ff5f8d14e1f066b. The alpine images don't work on the Raspberry Pi because its package so... — committed to TsuyoshiUshi/teslamate by TsuyoshiUshi 2 years ago
- Revert "postgres to alpine and runs on to latest ubuntu (#1576)" This reverts commit a8a110fbbc8a020d8f070287a22b621636bb7934. The alpine images don't work on the Raspberry Pi because its package so... — committed to flooppmtn/teslamate by flooppmtn 2 years ago
- Revert "postgres to alpine and runs on to latest ubuntu (#1576)" This reverts commit ac6e7f011509a928a26e6003726ba4301f8d8b47. The alpine images don't work on the Raspberry Pi because its package so... — committed to ClarkWalker/wall by deleted user 3 years ago
Ahhhhh crap, that gives me an interesting sense of deja-vu.
If you run the container with
--security-opt seccomp:unconfined
, does it work?(https://github.com/moby/moby/issues/40734)
I am having the same issue on Raspberry Pi 4 with 4 GB of RAM (and 4 GB of swap, but that is almost unused).
@tianon Is this the
strace
output you wanted outp.txt?