Salagir's Blog

Bon le blog est devenu tout simple tout moche, mais j’ai passé 24h à le mettre à jour. Il a peu de visites. Son ancien design n’était pas foufou. On va en rester là, hein. C’est surtout du texte après tout.

List all 404 errors from a Apache server

This is not the only solution to know if your website got dead links.

For example, Awstats will tell you them too, but only from on site at the time.
Also, online dead link finders are you friends, like W3C Link Checker.

My solution works directly on the server, and also find the errors that come from a link in another site going to your site, on a non-existent page. You will also see how most browser ask a lot for « /favicon.ico » on your sites…

Use (command line interface) :

$ sudo php parseLogApacheError.php
$ lynx /tmp/errors404.inc.html

You can download the code here :


Commentaires

2 réponses à “List all 404 errors from a Apache server”

  1. C’est beaucoup plus fun de faire ça avec un (gros) oneliner shell :)

  2. Oui, je sais, je suis un psychopathe en puissance. Même que pour mieux m’inspirer des modèles flamands (Anvers & Termonde), j’ai déménagé (presque) en Flandre.

Laisser un commentaire

Votre adresse e-mail ne sera pas publiée. Les champs obligatoires sont indiqués avec *