I am following the instructions to install discourse. There is plenty of space in the machine, so I don’t understand why does the installation fail.
x86_64 arch detected.
Ensuring launcher is up to date
Fetching origin
Launcher is up-to-date
/usr/local/lib/ruby/gems/2.7.0/gems/pups-1.1.1/lib/pups.rb
/usr/local/bin/pups --stdin
I, [2022-04-02T15:52:39.697036 #1] INFO -- : Reading from stdin
I, [2022-04-02T15:52:39.702390 #1] INFO -- : > locale-gen $LANG && update-locale
I, [2022-04-02T15:52:39.733464 #1] INFO -- : Generating locales (this might take a while)...
Generation complete.
I, [2022-04-02T15:52:39.733795 #1] INFO -- : > mkdir -p /shared/postgres_run
I, [2022-04-02T15:52:39.737797 #1] INFO -- :
I, [2022-04-02T15:52:39.737932 #1] INFO -- : > chown postgres:postgres /shared/postgres_run
I, [2022-04-02T15:52:39.740245 #1] INFO -- :
I, [2022-04-02T15:52:39.740430 #1] INFO -- : > chmod 775 /shared/postgres_run
I, [2022-04-02T15:52:39.743139 #1] INFO -- :
I, [2022-04-02T15:52:39.743292 #1] INFO -- : > rm -fr /var/run/postgresql
I, [2022-04-02T15:52:39.745920 #1] INFO -- :
I, [2022-04-02T15:52:39.746113 #1] INFO -- : > ln -s /shared/postgres_run /var/run/postgresql
I, [2022-04-02T15:52:39.748826 #1] INFO -- :
I, [2022-04-02T15:52:39.749009 #1] INFO -- : > socat /dev/null UNIX-CONNECT:/shared/postgres_run/.s.PGSQL.5432 || exit 0 && echo postgres already running stop container ; exit 1
2022/04/02 15:52:39 socat[20] E connect(6, AF=1 "/shared/postgres_run/.s.PGSQL.5432", 36): No such file or directory
I, [2022-04-02T15:52:39.755028 #1] INFO -- :
I, [2022-04-02T15:52:39.755329 #1] INFO -- : > rm -fr /shared/postgres_run/.s*
I, [2022-04-02T15:52:39.759007 #1] INFO -- :
I, [2022-04-02T15:52:39.759160 #1] INFO -- : > rm -fr /shared/postgres_run/*.pid
I, [2022-04-02T15:52:39.761649 #1] INFO -- :
I, [2022-04-02T15:52:39.761753 #1] INFO -- : > mkdir -p /shared/postgres_run/13-main.pg_stat_tmp
I, [2022-04-02T15:52:39.764155 #1] INFO -- :
I, [2022-04-02T15:52:39.764354 #1] INFO -- : > chown postgres:postgres /shared/postgres_run/13-main.pg_stat_tmp
I, [2022-04-02T15:52:39.766597 #1] INFO -- :
I, [2022-04-02T15:52:39.771178 #1] INFO -- : File > /etc/service/postgres/run chmod: +x chown:
I, [2022-04-02T15:52:39.775520 #1] INFO -- : File > /etc/service/postgres/log/run chmod: +x chown:
I, [2022-04-02T15:52:39.780150 #1] INFO -- : File > /etc/runit/3.d/99-postgres chmod: +x chown:
I, [2022-04-02T15:52:39.787459 #1] INFO -- : File > /root/upgrade_postgres chmod: +x chown:
I, [2022-04-02T15:52:39.788516 #1] INFO -- : > chown -R root /var/lib/postgresql/13/main
I, [2022-04-02T15:52:40.473746 #1] INFO -- :
I, [2022-04-02T15:52:40.474202 #1] INFO -- : > [ ! -e /shared/postgres_data ] && install -d -m 0755 -o postgres -g postgres /shared/postgres_data && sudo -E -u postgres /usr/lib/postgresql/13/bin/initdb -D /shared/postgres_data || exit 0
I, [2022-04-02T15:52:40.477125 #1] INFO -- :
I, [2022-04-02T15:52:40.477219 #1] INFO -- : > chown -R postgres:postgres /shared/postgres_data
I, [2022-04-02T15:52:40.486100 #1] INFO -- :
I, [2022-04-02T15:52:40.486352 #1] INFO -- : > chown -R postgres:postgres /var/run/postgresql
I, [2022-04-02T15:52:40.488833 #1] INFO -- :
I, [2022-04-02T15:52:40.489078 #1] INFO -- : > /root/upgrade_postgres
I, [2022-04-02T15:52:40.492944 #1] INFO -- :
I, [2022-04-02T15:52:40.493085 #1] INFO -- : > rm /root/upgrade_postgres
I, [2022-04-02T15:52:40.495214 #1] INFO -- :
I, [2022-04-02T15:52:40.495535 #1] INFO -- : Replacing data_directory = '/var/lib/postgresql/13/main' with data_directory = '/shared/postgres_data' in /etc/postgresql/13/main/postgresql.conf
I, [2022-04-02T15:52:40.496011 #1] INFO -- : Replacing (?-mix:#?listen_addresses *=.*) with listen_addresses = '*' in /etc/postgresql/13/main/postgresql.conf
I, [2022-04-02T15:52:40.496486 #1] INFO -- : Replacing (?-mix:#?synchronous_commit *=.*) with synchronous_commit = $db_synchronous_commit in /etc/postgresql/13/main/postgresql.conf
I, [2022-04-02T15:52:40.496888 #1] INFO -- : Replacing (?-mix:#?shared_buffers *=.*) with shared_buffers = $db_shared_buffers in /etc/postgresql/13/main/postgresql.conf
I, [2022-04-02T15:52:40.497209 #1] INFO -- : Replacing (?-mix:#?work_mem *=.*) with work_mem = $db_work_mem in /etc/postgresql/13/main/postgresql.conf
I, [2022-04-02T15:52:40.497544 #1] INFO -- : Replacing (?-mix:#?default_text_search_config *=.*) with default_text_search_config = '$db_default_text_search_config' in /etc/postgresql/13/main/postgresql.conf
I, [2022-04-02T15:52:40.497840 #1] INFO -- : > install -d -m 0755 -o postgres -g postgres /shared/postgres_backup
I, [2022-04-02T15:52:40.500782 #1] INFO -- :
I, [2022-04-02T15:52:40.501121 #1] INFO -- : Replacing (?-mix:#?checkpoint_segments *=.*) with checkpoint_segments = $db_checkpoint_segments in /etc/postgresql/13/main/postgresql.conf
I, [2022-04-02T15:52:40.501372 #1] INFO -- : Replacing (?-mix:#?logging_collector *=.*) with logging_collector = $db_logging_collector in /etc/postgresql/13/main/postgresql.conf
I, [2022-04-02T15:52:40.501752 #1] INFO -- : Replacing (?-mix:#?log_min_duration_statement *=.*) with log_min_duration_statement = $db_log_min_duration_statement in /etc/postgresql/13/main/postgresql.conf
I, [2022-04-02T15:52:40.502059 #1] INFO -- : Replacing (?-mix:^#local +replication +postgres +peer$) with local replication postgres peer in /etc/postgresql/13/main/pg_hba.conf
I, [2022-04-02T15:52:40.502326 #1] INFO -- : Replacing (?-mix:^host.*all.*all.*127.*$) with host all all 0.0.0.0/0 md5 in /etc/postgresql/13/main/pg_hba.conf
I, [2022-04-02T15:52:40.502663 #1] INFO -- : Replacing (?-mix:^host.*all.*all.*::1\/128.*$) with host all all ::/0 md5 in /etc/postgresql/13/main/pg_hba.conf
I, [2022-04-02T15:52:40.503023 #1] INFO -- : > HOME=/var/lib/postgresql USER=postgres exec chpst -u postgres:postgres:ssl-cert -U postgres:postgres:ssl-cert /usr/lib/postgresql/13/bin/postmaster -D /etc/postgresql/13/main
I, [2022-04-02T15:52:40.504697 #1] INFO -- : > sleep 5
2022-04-02 15:52:40.605 UTC [43] LOG: starting PostgreSQL 13.6 (Debian 13.6-1.pgdg110+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 10.2.1-6) 10.2.1 20210110, 64-bit
2022-04-02 15:52:40.605 UTC [43] LOG: listening on IPv4 address "0.0.0.0", port 5432
2022-04-02 15:52:40.605 UTC [43] LOG: listening on IPv6 address "::", port 5432
2022-04-02 15:52:40.607 UTC [43] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2022-04-02 15:52:40.610 UTC [46] LOG: database system was shut down at 2022-04-02 15:41:15 UTC
2022-04-02 15:52:40.614 UTC [43] LOG: database system is ready to accept connections
I, [2022-04-02T15:52:45.507830 #1] INFO -- :
I, [2022-04-02T15:52:45.508198 #1] INFO -- : > su postgres -c 'createdb discourse' || true
2022-04-02 15:52:45.562 UTC [56] postgres@postgres ERROR: database "discourse" already exists
2022-04-02 15:52:45.562 UTC [56] postgres@postgres STATEMENT: CREATE DATABASE discourse;
createdb: error: database creation failed: ERROR: database "discourse" already exists
I, [2022-04-02T15:52:45.564128 #1] INFO -- :
I, [2022-04-02T15:52:45.564530 #1] INFO -- : > su postgres -c 'psql discourse -c "create user discourse;"' || true
2022-04-02 15:52:45.613 UTC [60] postgres@discourse ERROR: role "discourse" already exists
2022-04-02 15:52:45.613 UTC [60] postgres@discourse STATEMENT: create user discourse;
ERROR: role "discourse" already exists
I, [2022-04-02T15:52:45.616039 #1] INFO -- :
I, [2022-04-02T15:52:45.616483 #1] INFO -- : > su postgres -c 'psql discourse -c "grant all privileges on database discourse to discourse;"' || true
I, [2022-04-02T15:52:45.664962 #1] INFO -- : GRANT
I, [2022-04-02T15:52:45.665420 #1] INFO -- : > su postgres -c 'psql discourse -c "alter schema public owner to discourse;"'
I, [2022-04-02T15:52:45.711994 #1] INFO -- : ALTER SCHEMA
I, [2022-04-02T15:52:45.712718 #1] INFO -- : > su postgres -c 'psql template1 -c "create extension if not exists hstore;"'
NOTICE: extension "hstore" already exists, skipping
I, [2022-04-02T15:52:45.763337 #1] INFO -- : CREATE EXTENSION
I, [2022-04-02T15:52:45.763727 #1] INFO -- : > su postgres -c 'psql template1 -c "create extension if not exists pg_trgm;"'
NOTICE: extension "pg_trgm" already exists, skipping
I, [2022-04-02T15:52:45.811148 #1] INFO -- : CREATE EXTENSION
I, [2022-04-02T15:52:45.811604 #1] INFO -- : > su postgres -c 'psql discourse -c "create extension if not exists hstore;"'
NOTICE: extension "hstore" already exists, skipping
I, [2022-04-02T15:52:45.860908 #1] INFO -- : CREATE EXTENSION
I, [2022-04-02T15:52:45.861252 #1] INFO -- : > su postgres -c 'psql discourse -c "create extension if not exists pg_trgm;"'
NOTICE: extension "pg_trgm" already exists, skipping
I, [2022-04-02T15:52:45.916601 #1] INFO -- : CREATE EXTENSION
I, [2022-04-02T15:52:45.916896 #1] INFO -- : > sudo -u postgres psql discourse
I, [2022-04-02T15:52:45.923402 #1] INFO -- : update pg_database set encoding = pg_char_to_encoding('UTF8') where datname = 'discourse' AND encoding = pg_char_to_encoding('SQL_ASCII');
I, [2022-04-02T15:52:45.976960 #1] INFO -- : File > /var/lib/postgresql/take-database-backup chmod: +x chown: postgres:postgres
I, [2022-04-02T15:52:45.979632 #1] INFO -- : File > /var/spool/cron/crontabs/postgres chmod: chown:
I, [2022-04-02T15:52:45.979720 #1] INFO -- : > echo postgres installed!
I, [2022-04-02T15:52:45.981659 #1] INFO -- : postgres installed!
I, [2022-04-02T15:52:45.986510 #1] INFO -- : File > /etc/service/redis/run chmod: +x chown:
I, [2022-04-02T15:52:45.993146 #1] INFO -- : File > /etc/service/redis/log/run chmod: +x chown:
I, [2022-04-02T15:52:45.997735 #1] INFO -- : File > /etc/runit/3.d/10-redis chmod: +x chown:
I, [2022-04-02T15:52:45.997900 #1] INFO -- : Replacing daemonize yes with in /etc/redis/redis.conf
I, [2022-04-02T15:52:45.998373 #1] INFO -- : Replacing (?-mix:^pidfile.*$) with in /etc/redis/redis.conf
I, [2022-04-02T15:52:46.015498 #1] INFO -- : > install -d -m 0755 -o redis -g redis /shared/redis_data
I, [2022-04-02T15:52:46.018440 #1] INFO -- :
I, [2022-04-02T15:52:46.019127 #1] INFO -- : Replacing (?-mix:^logfile.*$) with logfile "" in /etc/redis/redis.conf
I, [2022-04-02T15:52:46.019741 #1] INFO -- : Replacing (?-mix:^bind .*$) with in /etc/redis/redis.conf
I, [2022-04-02T15:52:46.020129 #1] INFO -- : Replacing (?-mix:^dir .*$) with dir /shared/redis_data in /etc/redis/redis.conf
I, [2022-04-02T15:52:46.020727 #1] INFO -- : Replacing (?-mix:^protected-mode yes) with protected-mode no in /etc/redis/redis.conf
I, [2022-04-02T15:52:46.021144 #1] INFO -- : Replacing # io-threads 4 with io-threads $redis_io_threads in /etc/redis/redis.conf
I, [2022-04-02T15:52:46.021523 #1] INFO -- : > echo redis installed
I, [2022-04-02T15:52:46.026032 #1] INFO -- : redis installed
I, [2022-04-02T15:52:46.026300 #1] INFO -- : > cat /etc/redis/redis.conf | grep logfile
I, [2022-04-02T15:52:46.031069 #1] INFO -- : logfile ""
I, [2022-04-02T15:52:46.031450 #1] INFO -- : > exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf
I, [2022-04-02T15:52:46.034586 #1] INFO -- : > sleep 10
104:C 02 Apr 2022 15:52:46.039 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
104:C 02 Apr 2022 15:52:46.039 # Redis version=6.2.6, bits=64, commit=00000000, modified=0, pid=104, just started
104:C 02 Apr 2022 15:52:46.039 # Configuration loaded
104:M 02 Apr 2022 15:52:46.040 * monotonic clock: POSIX clock_gettime
104:M 02 Apr 2022 15:52:46.040 * Running mode=standalone, port=6379.
104:M 02 Apr 2022 15:52:46.040 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128.
104:M 02 Apr 2022 15:52:46.040 # Server initialized
104:M 02 Apr 2022 15:52:46.040 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
104:M 02 Apr 2022 15:52:46.041 * Loading RDB produced by version 6.2.6
104:M 02 Apr 2022 15:52:46.041 * RDB age 691 seconds
104:M 02 Apr 2022 15:52:46.041 * RDB memory usage when created 0.77 Mb
104:M 02 Apr 2022 15:52:46.041 # Done loading RDB, keys loaded: 0, keys expired: 0.
104:M 02 Apr 2022 15:52:46.041 * DB loaded from disk: 0.000 seconds
104:M 02 Apr 2022 15:52:46.041 * Ready to accept connections
I, [2022-04-02T15:52:56.037154 #1] INFO -- :
I, [2022-04-02T15:52:56.037408 #1] INFO -- : > thpoff echo "thpoff is installed!"
I, [2022-04-02T15:52:56.042684 #1] INFO -- : thpoff is installed!
I, [2022-04-02T15:52:56.043143 #1] INFO -- : > /usr/local/bin/ruby -e 'if ENV["DISCOURSE_SMTP_ADDRESS"] == "smtp.example.com"; puts "Aborting! Mail is not configured!"; exit 1; end'
I, [2022-04-02T15:52:56.105740 #1] INFO -- :
I, [2022-04-02T15:52:56.106083 #1] INFO -- : > /usr/local/bin/ruby -e 'if ENV["DISCOURSE_HOSTNAME"] == "discourse.example.com"; puts "Aborting! Domain is not configured!"; exit 1; end'
I, [2022-04-02T15:52:56.169145 #1] INFO -- :
I, [2022-04-02T15:52:56.169517 #1] INFO -- : > /usr/local/bin/ruby -e 'if (ENV["DISCOURSE_CDN_URL"] || "")[0..1] == "//"; puts "Aborting! CDN must have a protocol specified. Once fixed you should rebake your posts now to correct all posts."; exit 1; end'
I, [2022-04-02T15:52:56.234968 #1] INFO -- :
I, [2022-04-02T15:52:56.235333 #1] INFO -- : > rm -f /etc/cron.d/anacron
I, [2022-04-02T15:52:56.240081 #1] INFO -- :
I, [2022-04-02T15:52:56.243834 #1] INFO -- : File > /etc/cron.d/anacron chmod: chown:
I, [2022-04-02T15:52:56.250049 #1] INFO -- : File > /etc/runit/1.d/copy-env chmod: +x chown:
I, [2022-04-02T15:52:56.256290 #1] INFO -- : File > /etc/service/unicorn/run chmod: +x chown:
I, [2022-04-02T15:52:56.262240 #1] INFO -- : File > /etc/service/nginx/run chmod: +x chown:
I, [2022-04-02T15:52:56.269390 #1] INFO -- : File > /etc/runit/3.d/01-nginx chmod: +x chown:
I, [2022-04-02T15:52:56.274005 #1] INFO -- : File > /etc/runit/3.d/02-unicorn chmod: +x chown:
I, [2022-04-02T15:52:56.274108 #1] INFO -- : Replacing # postgres with sv start postgres || exit 1 in /etc/service/unicorn/run
I, [2022-04-02T15:52:56.274326 #1] INFO -- : > exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf
I, [2022-04-02T15:52:56.276941 #1] INFO -- : > cd /var/www/discourse && git reset --hard
131:C 02 Apr 2022 15:52:56.281 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
131:C 02 Apr 2022 15:52:56.281 # Redis version=6.2.6, bits=64, commit=00000000, modified=0, pid=131, just started
131:C 02 Apr 2022 15:52:56.281 # Configuration loaded
131:M 02 Apr 2022 15:52:56.282 * monotonic clock: POSIX clock_gettime
131:M 02 Apr 2022 15:52:56.282 # Warning: Could not create server TCP listening socket *:6379: bind: Address already in use
131:M 02 Apr 2022 15:52:56.282 # Failed listening on port 6379 (TCP), aborting.
fatal: Unable to create '/var/www/discourse/.git/index.lock': Disk quota exceeded
I, [2022-04-02T15:52:56.287140 #1] INFO -- :
I, [2022-04-02T15:52:56.287581 #1] INFO -- : Terminating async processes
I, [2022-04-02T15:52:56.287626 #1] INFO -- : Sending INT to HOME=/var/lib/postgresql USER=postgres exec chpst -u postgres:postgres:ssl-cert -U postgres:postgres:ssl-cert /usr/lib/postgresql/13/bin/postmaster -D /etc/postgresql/13/main pid: 43
2022-04-02 15:52:56.287 UTC [43] LOG: received fast shutdown request
104I, [2022-04-02T15:52:56.287845 #1] INFO -- : Sending TERM to exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf pid: 104
:signal-handler (1648914776) Received SIGTERM scheduling shutdown...
2022-04-02 15:52:56.288 UTC [43] LOG: aborting any active transactions
2022-04-02 15:52:56.293 UTC [43] LOG: background worker "logical replication launcher" (PID 52) exited with exit code 1
2022-04-02 15:52:56.294 UTC [47] LOG: shutting down
2022-04-02 15:52:56.356 UTC [43] LOG: database system is shut down
104:M 02 Apr 2022 15:52:56.373 # User requested shutdown...
104:M 02 Apr 2022 15:52:56.373 * Saving the final RDB snapshot before exiting.
104:M 02 Apr 2022 15:52:56.374 * DB saved on disk
104:M 02 Apr 2022 15:52:56.374 # Redis is now ready to exit, bye bye...
FAILED
--------------------
Pups::ExecError: cd /var/www/discourse && git reset --hard failed with return #<Process::Status: pid 133 exit 128>
Location of failure: /usr/local/lib/ruby/gems/2.7.0/gems/pups-1.1.1/lib/pups/exec_command.rb:117:in `spawn'
exec failed with the params {"cd"=>"$home", "hook"=>"code", "cmd"=>["git reset --hard", "git clean -f", "git remote set-branches --add origin main", "git remote set-branches origin $version", "git fetch --depth 1 origin $version", "git checkout $version", "mkdir -p tmp", "chown discourse:www-data tmp", "mkdir -p tmp/pids", "mkdir -p tmp/sockets", "touch tmp/.gitkeep", "mkdir -p /shared/log/rails", "bash -c \"touch -a /shared/log/rails/{production,production_errors,unicorn.stdout,unicorn.stderr,sidekiq}.log\"", "bash -c \"ln -s /shared/log/rails/{production,production_errors,unicorn.stdout,unicorn.stderr,sidekiq}.log $home/log\"", "bash -c \"mkdir -p /shared/{uploads,backups}\"", "bash -c \"ln -s /shared/{uploads,backups} $home/public\"", "bash -c \"mkdir -p /shared/tmp/{backups,restores}\"", "bash -c \"ln -s /shared/tmp/{backups,restores} $home/tmp\"", "chown -R discourse:www-data /shared/log/rails /shared/uploads /shared/backups /shared/tmp", "find public/plugins/ -maxdepth 1 -xtype l -delete"]}
bootstrap failed with exit code 128
** 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.