3

When I set of a CentOS Apache server, I get these errors in the apache logs.

[Tue Feb 28 12:18:10 2012] [error] [client xxx.xxx.xxx.xxx] File does not exist: /var/www/html/favicon.ico

touch /var/www/html/favicon.ico would likely solve the problem, but can't favicon.ico be disabled in the apache config somehow?

Sandra
  • 10,711
  • 41
  • 120
  • 173

2 Answers2

7

but can't favicon.ico be disabled in the apache config somehow

No, because the users browser is trying to download the file.

Well, it's certainly possible to get rid of the log entries with specifically configured logging, but touch is the easiest fix for that problem, IMHO.

Sven
  • 100,763
7

can do something like these? in apache conf, above your log entry lines:

SetEnvIf Request_URI "^/favicon\.ico$" dontlog

or this:

Redirect 404 /favicon.ico

or this:

<Location /favicon.ico>
    Order Deny,Allow
    Deny from all
    ErrorDocument 404 "No favicon
</Location>