Skip to content

Instantly share code, notes, and snippets.

@palewire
Created January 24, 2012 10:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save palewire/1669372 to your computer and use it in GitHub Desktop.
Save palewire/1669372 to your computer and use it in GitHub Desktop.
Weird postgres errors
In my Django error messages...
File "/apps/projects/lib/django/db/models/sql/query.py", line 2347, in execute_sql
cursor.execute(sql, params)
OperationalError: could not write block 341 of temporary file: No space left on device
HINT: Perhaps out of disk space?
...
File "/apps/projects/lib/django/db/models/sql/query.py", line 2347, in execute_sql
cursor.execute(sql, params)
OperationalError: could not write block 1 of temporary file: No space left on device
HINT: Perhaps out of disk space?
...
File "/apps/projects/lib/django/db/models/sql/query.py", line 2347, in execute_sql
cursor.execute(sql, params)
OperationalError: could not write to hash-join temporary file: No space left on device
...
In my pgstartup.log...
LOG: logger shutting down
FATAL: could not create semaphores: No space left on device
DETAIL: Failed system call was semget(5432128, 17, 03600).
HINT: This error does *not* mean that you have run out of disk space.
It occurs when either the system limit for the maximum number of semaphore sets (SEMMNI), or the system wide maximum number of semaphores (SEMMNS), would be exceeded. You need to raise the respective kernel parameter. Alternatively, reduce PostgreSQL's consumption of semaphores by reducing its max_connections parameter (currently 2400).
The PostgreSQL documentation contains more information about configuring your system for PostgreSQL.
FATAL: could not create semaphores: No space left on device
DETAIL: Failed system call was semget(5432128, 17, 03600).
HINT: This error does *not* mean that you have run out of disk space.
It occurs when either the system limit for the maximum number of semaphore sets (SEMMNI), or the system wide maximum number of semaphores (SEMMNS), would be exceeded. You need to raise the respective kernel parameter. Alternatively, reduce PostgreSQL's consumption of semaphores by reducing its max_connections parameter (currently 2400).
The PostgreSQL documentation contains more information about configuring your system for PostgreSQL.
LOG: logger shutting down
Stuff I've found online...
http://web.archiveorange.com/archive/v/9FNVlpq1Spe1pxNhzzXD
http://archives.postgresql.org/pgsql-sql/2006-09/msg00142.php
http://grokbase.com/t/postgresql.org/pgsql-general/2009/04/database-corruption/0945zmmgvqpnud7x5du4o43c72ce
On the file system ...
$ df -h
Filesystem Size Used Avail Use% Mounted on
/dev/xvda3 29G 23G 4.8G 83% /
/dev/xvda1 99M 13M 82M 14% /boot
tmpfs 2.0G 0 2.0G 0% /dev/shm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment