Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm running nginx with php as fastcgi. From time to time my website goes down and a restart of nginx is required to get it running again. I find the following in my error log (actual IP's have been replaces for privacy reasons). Would anyone be able to shed some light into what is actually happening? Thank you

2011/05/02 06:41:10 [alert] 1686#0: worker process 1690 exited on signal 9
2011/05/02 06:41:20 [emerg] 25259#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2011/05/02 06:41:20 [emerg] 25259#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2011/05/29 14:01:08 [alert] 25260#0: worker process 25264 exited on signal 9
2011/05/29 14:01:13 [emerg] 24852#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2011/05/29 14:01:13 [emerg] 24852#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2011/06/16 10:10:23 [alert] 24856#0: *14222020 write() to "/var/log/nginx/access.log" was incomplete: 243 of 247 while closing request, client: 123.45.67.89, server: a$
2011/06/16 10:11:27 [alert] 24856#0: *14222228 write() to "/var/log/nginx/access.log" failed (28: No space left on device) while closing request, client: 123.45.67.89,$
2011/06/16 10:12:34 [alert] 24856#0: *14222361 write() to "/var/log/nginx/access.log" failed (28: No space left on device) while closing request, client: 123.45.67.89,$
2011/06/16 10:13:12 [emerg] 7394#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2011/06/16 10:13:12 [emerg] 7394#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2011/06/16 10:13:12 [emerg] 7394#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2011/06/16 10:13:12 [emerg] 7394#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2011/06/16 10:13:12 [emerg] 7394#0: bind() to 0.0.0.0:80 failed (98: Address already in use)
2011/06/16 10:13:12 [emerg] 7394#0: still could not bind()
share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

bind() to 0.0.0.0:80 failed - this means it couldnt bind to port 80, this usually means some other application is using port 80, have you potentially also got apache running on this box at the same time by accident?

14222228 write() to "/var/log/nginx/access.log" failed (28: No space left on device) - generally means the disk is full on the volume it writes logs to, its probably a good idea to check your hard drive space usage and do some cleaning of old files or old log files as required

share|improve this answer
    
Anthony, there's just nginx, php as fastcgi, imagick php extension and mysql. No apache or anything este installed. Disk should still have space: /dev/sda1 ext3 19G 15G 3.3G 82% –  Rado Jun 16 '11 at 11:36
1  
@Rado He's correct, the 'write()' error means the drive is full, you need to get a bigger/better disk and the 'bind()' error means something else is using port 80, most likely zombied NGINX processes, use killall nginx to get rid of them then service nginx start. Also you should use service nginx reload rather than service nginx restart –  sam Jun 16 '11 at 14:10
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.