6

I have installed postgres 8.4.9 database in my fedora core 14 and deployed an application. It was working fine until today before I tried to restart the system. Now I am unable to start the pgsql. When I am trying to start I am getting the following error

FATAL: could not write lock file "postmaster.pid": No space left on device

I googled but was not able to find the solution for this issue.

Could someone please help in solving this issue?

This is the output of df -kh command:

Filesystem            Size  Used Avail Use% Mounted on
/dev/vda              9.9G  9.5G     0 100% /
tmpfs                 2.0G   88K  2.0G   1% /dev/shm
Daniel Roethlisberger
  • 6,958
  • 2
  • 41
  • 59
udi
  • 501
  • 2
  • 8
  • 14
  • 2
    weelll... is your filesystem full as the error states? ( `df -k ` ). Mostly '/' should be interesting – Najzero Jan 25 '13 at 10:59
  • yes. this is the output : Filesystem Size Used Avail Use% Mounted on /dev/vda 9.9G 9.5G 0 100% / tmpfs 2.0G 88K 2.0G 1% /dev/shm – udi Jan 25 '13 at 11:03
  • Your disk has 0 bytes free, so you can't write to it. The difference between 9.9G and 9.5G is because of system reserved space. – Wolph Jan 25 '13 at 11:17
  • This is not postgresul problem. You have no disk space available. Things will shortly become very hard for the OS. You need to remove files somewhere or add some other extra space. Then you will have to reboot and prey that nothing wat hurted too bad. – regilero Jan 25 '13 at 11:18
  • The only solution is to free disk space (or add a new disk) –  Jan 25 '13 at 13:34
  • Thank u all for your vauable suggestion. I just free up some disk space. Now the problem is solved :) – udi Feb 04 '13 at 12:16

1 Answers1

10

This is not really a programming question so it should be on superuser.

Short answer -

reboot the system.

If the system comes back up, try:

find / -mtime -3 -size +100000 -exec ls -ls {} \; | sort -n

The largest newest files will be at the bottom of the list. If you can see that the file is not part of an app- a data file for example- remove it. You need at least 5% free space on /.

Long term you must add more disk space, like double or triple what you have.

jim mcnamara
  • 16,005
  • 2
  • 34
  • 51