# Few NGINX questions



## Anon (Oct 5, 2011)

```
2011/10/02 12:11:22 [info] 76068#0: *1534 kevent() reported that client X.X.X.X closed keepalive connection
2011/10/02 12:12:33 [info] 76068#0: *1554 client closed prematurely connection (54: Connection reset by peer) while sending
 response to client, client: X.X.X.X, server: i$
```

Specifically the above? I'd also like to ignore what Googlebot does (66.249.71.210) in the log, since it usually tries to open ancient parts of the site which don't exist anymore. The closed prematurely stuff isn't bad, right?

Also, is this normal?


```
2011/10/05 13:02:34 [warn] 36420#0: *9409 a client request body is buffered to a temporary file
 /var/tmp/nginx/client_body_temp/0000000040, client: x.x.x.x, server: XXX.org, request: "POST /post.php HTTP/1.1",
 host: "www.XXX.org", referrer: "http://www.XXX.org/"
```


----------



## Carpetsmoker (Oct 5, 2011)

Please don't ask spread your questions over multiple threads, it makes stuff hard to follow 

The other question is here, I answered it yesterday:
http://forums.freebsd.org/showthread.php?t=26601


----------



## SirDice (Oct 5, 2011)

Anon said:
			
		

> I'd also like to ignore what Googlebot does (66.249.71.210) in the log, since it usually tries to open ancient parts of the site which don't exist anymore.


Can't help with the NGINX stuff but this bit is easy. It's why robots.txt was created.


----------



## Anon (Oct 5, 2011)

SirDice said:
			
		

> Can't help with the NGINX stuff but this bit is easy. It's why robots.txt was created.



Why would I want to block the googlebot. I just don't want what it does showing up in the log because it doesn't matter to me.


----------



## Alt (Oct 5, 2011)

Anon said:
			
		

> ```
> 2011/10/02 12:11:22 [info] 76068#0: *1534 kevent() reported that client X.X.X.X closed keepalive connection
> 2011/10/02 12:12:33 [info] 76068#0: *1554 client closed prematurely connection (54: Connection reset by peer) while sending
> response to client, client: X.X.X.X, server: i$
> ```


Captain says, this means client closed connection. For example, he pressed "stop" in browser.



			
				Anon said:
			
		

> I'd also like to ignore what Googlebot does (66.249.71.210) in the log, since it usually tries to open ancient parts of the site which don't exist anymore.


He just stored urls and check them. Or you have deadlinks somewhere..



			
				Anon said:
			
		

> ```
> 2011/10/05 13:02:34 [warn] 36420#0: *9409 a client request body is buffered to a temporary file
> /var/tmp/nginx/client_body_temp/0000000040, client: x.x.x.x, server: XXX.org, request: "POST /post.php HTTP/1.1",
> host: "www.XXX.org", referrer: "http://www.XXX.org/"
> ```


I think you must increase client_body_buffer_size


----------



## Anon (Oct 5, 2011)

Thanks Alt, but how would I stop logging the closing of KeepAlive? It gets annoying to see 99% of my log file is info on keepalive closings... you know what I am trying to say?


----------



## Alt (Oct 5, 2011)

Thats nginx developer's answer:
http://nginx.2469901.n2.nabble.com/Keep-alive-connection-errors-in-my-logs-td3385507.html
So you should set something like
	
	



```
error_log  /var/log/nginx.error_log notice;
```


----------



## Anon (Oct 5, 2011)

Alt said:
			
		

> Thats nginx developer's answer:
> http://nginx.2469901.n2.nabble.com/Keep-alive-connection-errors-in-my-logs-td3385507.html
> So you should set something like
> 
> ...



Thank you very much, Alt!


----------



## SirDice (Oct 6, 2011)

Anon said:
			
		

> Why would I want to block the googlebot. I just don't want what it does showing up in the log because it doesn't matter to me.



You don't block Googlebot, you just tell it not to index pages/directories that don't exist anymore. Thereby preventing the requests.


----------



## Anon (Oct 10, 2011)

SirDice said:
			
		

> You don't block Googlebot, you just tell it not to index pages/directories that don't exist anymore. Thereby preventing the requests.



Oh, cool.

What's the robots code for that, please?


----------



## Carpetsmoker (Oct 10, 2011)

Anon said:
			
		

> Oh, cool.
> 
> What's the robots code for that, please?



http://lmgtfy.com/?q=block+googlebot


----------

