Cannot run any postgis-ram images

I have tried to run 9.6-postgis-ram 9.6.7-postgis-ram and 9.6.10-postis-ram. All of them fail with “no space left on device”:

    Loading PostGIS extensions into circle_test
    ERROR:  could not extend file "base/16384/18767": wrote only 4096 of 8192 bytes at block 184
    HINT:  Check free disk space.
    STATEMENT:  CREATE EXTENSION IF NOT EXISTS postgis;
    PANIC:  could not write to file "pg_xlog/xlogtemp.50": No space left on device
    LOG:  WAL writer process (PID 50) was terminated by signal 6: Aborted
    LOG:  terminating any other active server processes
    WARNING:  terminating connection because of crash of another server process
    DETAIL:  The postmaster has commanded this server process to roll back the current transaction and exit, because another server process exited abnormally and possibly corrupted shared memory.
    HINT:  In a moment you should be able to reconnect to the database and repeat your command.
    WARNING:  terminating connection because of crash of another server process
    DETAIL:  The postmaster has commanded this server process to roll back the current transaction and exit, because another server process exited abnormally and possibly corrupted shared memory.
    HINT:  In a moment you should be able to reconnect to the database and repeat your command.
    WARNING:  terminating connection because of crash of another server process
    DETAIL:  The postmaster has commanded this server process to roll back the current transaction and exit, because another server process exited abnormally and possibly corrupted shared memory.
    HINT:  In a moment you should be able to reconnect to the database and repeat your command.
    ERROR:  could not extend file "base/16384/18767": wrote only 4096 of 8192 bytes at block 184
    HINT:  Check free disk space.

How are you running this? Are you using it as a secondary container? Maybe you need to supply a command to specify start-up options.

I ran it in circleci, then when testing attempted to run them in my local docker.

The parent containers (postgres , postgis) do not require any additional commands, and the postgres-ram container doesn’t require it either.

If you can provide some replication instructions, someone may be able to take a look. The best approach is a small, open example on GitHub.

docker run circleci/postgres:9.6-postgis - works.
docker run circleci/postgres:9.6-postgis-ram - does not work.

Ah, i figured it out. Outside of the normal execution flow (locally or using setup_remote_docker) you have to add --tmpfs /dev/shm/pgdata/data for it to boot properly.

1 Like