Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

How to disable logging for a given bot in nginx?
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

How to disable logging for a given bot in nginx?

zserozsero Member
edited August 2013 in Help

Hi, I'm trying to configure nginx such that access requests from Pingbot are not logged in the access log. The pingbot checks every couple of seconds and it just pollutes the log with useless information.

I tried the following methods but they don't work and I have no idea about where should I put an if or map statement and how should a complete config look like.

If I put an if statement and I return something it's wrong, since I don't want to return anything special, I just want to return the site as usual, but without logging.

I've also encountered a lof of 'if cannot be used here' kind of errors.

Do you have a sample conf for this?

Sign In or Register to comment.