Perl & cgi tracking visitors?

Hi there, I was curious to know if there is a way to track visitors for instance, obtaining almost everything about them, like how long a certain page was viewed for. Of course as in the title, I would very much like to find something using cgi and perl if necessary. Any help?

The webserver log will record every request for a page or one of its components (stylesheet, images, javascript files) and there are ways of analysing the log. The information is very limited but that is where I would start.

If you do not have the concept of a user then you only have the ip address to go with and this is a very inaccurate identification mechanism.

You can never tell how long a page of yours was viewed only the time between page requests from a user. They might never come back to you or go an view another site or make a cup of coffee in the interim.