I am running an asp.net website on IIS 7.5 and windows 2008 R2 server.
How do I setup (or what do I need) in order to have an alert if there is a hacking attempt against the website and server,?
How do I know if the server / site was compromised?
If are you are interested in an enterprise solution, we have a web app firewall called ServerDefender VP that will alert via email you when a hack attempt is made and will even allow you to block the IP of the would-be hacker so they cannot continue to hack your site.
You can check out the free trial here: http://www.port80software.com/products/serverdefendervp/ and we are glad to answer any questions. Be sure to check out the demo video on the page linked above - it will give you an idea of the products functionality.
I am afraid this question does not have a straight answer, you will need an Intrusion Detection System and/or Intrusion Prevention System in order to achieve this. There is no such thing under IIS to do it (correct me if I am wrong).
Something that also works great for web applications are the good old file integrity checkers .
You can find free IDS and IPS for both Windows and GNU/Linux.