I have an application server APP1 in Domain DOMCORP. Then there is another SQL Server machine in DOMCORP domain. The SQL Service is running with Local system account.
When I run an application from APP1 machine, I get error:
System.Data.SqlClient.SqlException (0x80131904): Login failed for user 'DOMCORP\APP1$'.
at System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject)
The application is using trusted connection. What login I should create in SQL to fix this? And Do I need to create some group/user in active directory?
You don't need an AD account to connect but it is recommended.
Create an Active Directory NT account for SQL server (recommend create another one, different, for SQL agent) and run MSSQL service under that security context. Then update your connection string at app level.
The key is, whether SQL service service runs locally or with a Domain based account, grant necessary permissions at SQL server level. You need to create a valid login for your account.
CREATE LOGIN [DOMCORP\APP1$] FROM WINDOWS