Get your server issues fixed by our experts for a price starting at just 25 USD/Hour. Click here to register and open a ticket with us now!

Author Topic: Apache Error: No space left on device: Couldn’t create accept lock  (Read 3196 times)

0 Members and 1 Guest are viewing this topic.

jominj

  • Guest
Some time we may enter in a situation where Apache is not starting in the server and the error logs shows the following error:
[emerg] (28)No space left on device: Couldn’t create accept lock (/usr/local/apache/logs/accept.lock.

It’s because the sempahore arrays in system memory is full. Check if there’re any processes in semaphore that are owned nobody in semaphores.
Code: [Select]
[b]# ipcs -s|grep nobody[/b]
If you can see the semaphore processes for nobody, eventhough no apache processes are running, you can remove them safely. It happens when Apache dies without clearing the Semaphore arrays.
We can run the following command to remove it safely:
Code: [Select]
[b]# for semid in `ipcs -s | grep nobody | cut -f2 -d" "`; do ipcrm -s $semid; done [/b]
Now restart the Apache service.
Code: [Select]
[b]# service apache restart [/b]