how to check how many users are currently logged in Sharepoint foundation 2010
This is a complicated question. HTTP is stateless, so it's difficult to know how many people are using the platform at a precise moment.
A really complete article is standing at the following URL : Check it out Here
I doubt if the above solution would work for Anonymous web site? may be at IIS level you can find find the user count.