Using the ASP.NET B / S application, when the database joint string uses Integrated Security = SSPI, logging in to SQLServer will fail, and the error message is not available for the user $ MachineName / Aspnet.
The reason is the default, logging in to the ASPNET when logging in to SQL Server using ASP.NET, and this login name does not exist in SQL Server, so this error.
solution:
1. Use User ID and Password to log in, do not use Windows Trust Mechanism
2. Still use the trust mechanism, just add the ASPNET login name in SQL Server, then the ASP.NET wants to operate to create a user, log in to the ASPNET, and set permissions for the user