Hi, I found the problem. Is is about Redis. If ABP cannot connect to Redis then it does not write any log. It is wierd , I think it is a bug of ABP Framework.
Offcource I tried to open stdout log but the log cannot be written. My config is right below.
<?xml version="1.0" encoding="utf-8"?> <configuration> <location path="." inheritInChildApplications="false"> <system.webServer> <handlers> <add name="aspNetCore" path="" verb="" modules="AspNetCoreModuleV2" resourceType="Unspecified" /> </handlers> <aspNetCore processPath="dotnet" arguments=".\xxxx.HttpApi.Host.dll" stdoutLogEnabled="true" stdoutLogFile=".\logs\stdout" hostingModel="inprocess" /> </system.webServer> </location> <system.webServer> <httpProtocol> <customHeaders> <remove name="x-powered-by" /> </customHeaders> </httpProtocol> <modules> <remove name="WebDAVModule" /> </modules> </system.webServer> </configuration>
I got the similar problem with another server, and we had fixed it. (Previous issue : https://abp.io/support/questions/8088/ABP-IIS-Hosting-Problem) But now we try to install it another server but we got the IIS 500.30 error (Api project) from iis . Out stdout log cannot write so we do not know the details.
EVENT LOGS Application '/LM/W3SVC/2/ROOT' with physical root 'C:\inetpub\wwwroot\xxxxxApi' has exited from Program.Main with exit code = '1'. Please check the stderr logs for more information.
Application '/LM/W3SVC/2/ROOT' with physical root 'C:\inetpub\wwwroot\xxxxxxApi' failed to load coreclr. Exception message: CLR worker thread exited prematurely
IIS LOGS 2024-12-04 10:14:34 ::1 GET / - 44368 - ::1 Mozilla/5.0+(Windows+NT+10.0;+Win64;+x64)+AppleWebKit/537.36+(KHTML,+like+Gecko)+Chrome/131.0.0.0+Safari/537.36+Edg/131.0.0.0 - 500 30 574 11 2024-12-04 10:14:34 ::1 GET / - 44368 - ::1 Mozilla/5.0+(Windows+NT+10.0;+Win64;+x64)+AppleWebKit/537.36+(KHTML,+like+Gecko)+Chrome/131.0.0.0+Safari/537.36+Edg/131.0.0.0 - 500 30 574 3 2024-12-04 10:14:34 ::1 GET / - 44368 - ::1 Mozilla/5.0+(Windows+NT+10.0;+Win64;+x64)+AppleWebKit/537.36+(KHTML,+like+Gecko)+Chrome/131.0.0.0+Safari/537.36+Edg/131.0.0.0 - 500 30 574 23 2024-12-04 10:14:34 ::1 GET /favicon.ico - 44368 - ::1 Mozilla/5.0+(Windows+NT+10.0;+Win64;+x64)+AppleWebKit/537.36+(KHTML,+like+Gecko)+Chrome/131.0.0.0+Safari/537.36+Edg/131.0.0.0 https://localhost:44368/ 500 30 574 2 2024-12-04 10:14:34 ::1 GET /favicon.ico - 44368 - ::1 Mozilla/5.0+(Windows+NT+10.0;+Win64;+x64)+AppleWebKit/537.36+(KHTML,+like+Gecko)+Chrome/131.0.0.0+Safari/537.36+Edg/131.0.0.0 https://localhost:44368/ 500 30 574 4 2024-12-04 10:14:34 ::1 GET /favicon.ico - 44368 - ::1 Mozilla/5.0+(Windows+NT+10.0;+Win64;+x64)+AppleWebKit/537.36+(KHTML,+like+Gecko)+Chrome/131.0.0.0+Safari/537.36+Edg/131.0.0.0 https://localhost:44368/ 500 30 574 0
Hi, We added a new class library to our ABP project. We call this class library from Application service. We make external http calls from this class library. Then we implemented IAuditingEnabled interface to log [AuditLogActions] table. But it cannot insert to this table.
Can we get the AuditLogId from currenct request context.
How can we fix this problem.
Ok I will check but
we We noticed the following: we created two projects from scratch. For the first one, we did not create a separate auth server, and your default project got a 500.30 error when hosted on IIS. However, when we created the separate auth server, we were able to run it this time. Could there be a different situation here? Could you also check this on your side with this in mind?
abp new AbpDeneme2 -u angular -m none --separate-auth-server --theme leptonx -csf
Yes my app is run on IIS.
Sorry the demo project config is like below
"Default": "Server=(LocalDb)\MSSQLLocalDB;Database=AbpSolution2;Trusted_Connection=True;TrustServerCertificate=true",
Hi again. I tried to create a new demo project from scratch to fix the issue. My connectionstring is like below but I got the sql connection error. I can also connect from the SQL Management Studio.
"Default": "Server=(localdb)\\MSSQLLocalDB;Database=PaymentManagement;Trusted_Connection=True;TrustServerCertificate=false",
2024-10-22 22:52:22.424 +03:00 [INF] - Volo.Abp.Gdpr.AbpGdprEntityFrameworkCoreModule
2024-10-22 22:52:22.424 +03:00 [INF] - Volo.Abp.BlobStoring.Database.EntityFrameworkCore.BlobStoringDatabaseEntityFrameworkCoreModule
2024-10-22 22:52:22.424 +03:00 [INF] - Volo.Abp.Swashbuckle.AbpSwashbuckleModule
2024-10-22 22:52:22.424 +03:00 [INF] - Volo.Abp.AspNetCore.Serilog.AbpAspNetCoreSerilogModule
2024-10-22 22:52:23.677 +03:00 [INF] Saving external localizations...
2024-10-22 22:52:23.829 +03:00 [INF] Initialized all ABP modules.
2024-10-22 22:52:23.892 +03:00 [INF] Initializing UI Database
2024-10-22 22:52:26.025 +03:00 [INF] Saving healthchecks configuration to database
2024-10-22 22:52:26.562 +03:00 [INF] Request starting HTTP/1.1 GET http://localhost:44349/ - null null
2024-10-22 22:52:26.576 +03:00 [WRN] The 'WebRootPath' is not set! The 'CheckLibs' feature is disabled!
2024-10-22 22:52:26.609 +03:00 [ERR] GetHealthReport threw an exception when trying to get report from /health-status configured with name AbpSolution2 Health Status.
System.InvalidOperationException: Could not get endpoint uri from configuration
at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetEndpointUri(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 176
at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetHealthReportAsync(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 118
2024-10-22 22:52:27.080 +03:00 [INF] Application started. Press Ctrl+C to shut down.
2024-10-22 22:52:27.081 +03:00 [INF] Hosting environment: Production
2024-10-22 22:52:27.081 +03:00 [INF] Content root path: C:\inetpub\wwwroot\AbpDeneme2
2024-10-22 22:52:27.211 +03:00 [INF] Completed to save external localizations.
2024-10-22 22:52:27.447 +03:00 [INF] Executing endpoint 'AbpSolution2.Controllers.HomeController.Index (AbpSolution2.HttpApi.Host)'
2024-10-22 22:52:27.487 +03:00 [INF] Route matched with {action = "Index", controller = "Home", area = "", page = ""}. Executing controller action with signature Microsoft.AspNetCore.Mvc.ActionResult Index() on controller AbpSolution2.Controllers.HomeController (AbpSolution2.HttpApi.Host).
2024-10-22 22:52:27.534 +03:00 [INF] Executing RedirectResult, redirecting to /swagger.
2024-10-22 22:52:27.544 +03:00 [INF] Executed action AbpSolution2.Controllers.HomeController.Index (AbpSolution2.HttpApi.Host) in 47.9922ms
2024-10-22 22:52:27.544 +03:00 [INF] Executed endpoint 'AbpSolution2.Controllers.HomeController.Index (AbpSolution2.HttpApi.Host)'
2024-10-22 22:52:27.612 +03:00 [INF] Request starting HTTP/1.1 GET http://localhost:44349/swagger/index.html - null null
2024-10-22 22:52:27.613 +03:00 [INF] Request finished HTTP/1.1 GET http://localhost:44349/ - 302 null null 1052.877ms
2024-10-22 22:52:27.720 +03:00 [INF] Request finished HTTP/1.1 GET http://localhost:44349/swagger/index.html - 200 null text/html;charset=utf-8 108.2377ms
2024-10-22 22:52:28.009 +03:00 [INF] Request starting HTTP/1.1 GET http://localhost:44349/swagger/v1/swagger.json - null null
2024-10-22 22:52:33.336 +03:00 [INF] Request finished HTTP/1.1 GET http://localhost:44349/swagger/v1/swagger.json - 200 null application/json;charset=utf-8 5325.7166ms
2024-10-22 22:52:33.495 +03:00 [INF] Request starting HTTP/1.1 GET http://localhost:44349/api/abp/application-configuration - null null
2024-10-22 22:52:33.510 +03:00 [INF] Executing endpoint 'Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.AbpApplicationConfigurationController.GetAsync (Volo.Abp.AspNetCore.Mvc)'
2024-10-22 22:52:33.533 +03:00 [INF] Route matched with {area = "abp", action = "Get", controller = "AbpApplicationConfiguration", page = ""}. Executing controller action with signature System.Threading.Tasks.Task`1[Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.ApplicationConfigurationDto] GetAsync(Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.ApplicationConfigurationRequestOptions) on controller Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.AbpApplicationConfigurationController (Volo.Abp.AspNetCore.Mvc).
2024-10-22 22:52:33.690 +03:00 [WRN] The cookie 'XSRF-TOKEN' has set 'SameSite=None' and must also set 'Secure'.
2024-10-22 22:52:37.158 +03:00 [ERR] GetHealthReport threw an exception when trying to get report from /health-status configured with name AbpSolution2 Health Status.
System.InvalidOperationException: Could not get endpoint uri from configuration
at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetEndpointUri(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 176
at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetHealthReportAsync(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 118
2024-10-22 22:52:37.168 +03:00 [INF] Notification is sent on same window time.
2024-10-22 22:52:41.393 +03:00 [ERR] An error occurred using the connection to database 'AbpSolution2' on server '(LocalDb)\MSSQLLocalDB'.
2024-10-22 22:52:41.393 +03:00 [ERR] An error occurred using the connection to database 'AbpSolution2' on server '(LocalDb)\MSSQLLocalDB'.
2024-10-22 22:52:41.393 +03:00 [ERR] An error occurred using the connection to database 'AbpSolution2' on server '(LocalDb)\MSSQLLocalDB'.
2024-10-22 22:52:41.410 +03:00 [ERR] An exception occurred while iterating over the results of a query for context type 'Volo.Abp.PermissionManagement.EntityFrameworkCore.PermissionManagementDbContext'.
Microsoft.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 50 - Local Database Runtime error occurred. Cannot create an automatic instance. See the Windows Application event log for error details.
)
---> System.ComponentModel.Win32Exception (0x89C50118): Unknown error (0x89c50118)
at Microsoft.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
at Microsoft.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
at Microsoft.Data.SqlClient.TdsParser.Connect(ServerInfo serverInfo, SqlInternalConnectionTds connHandler, Boolean ignoreSniOpenTimeout, Int64 timerExpire, SqlConnectionString connectionOptions, Boolean withFailover)
at Microsoft.Data.SqlClient.SqlInternalConnectionTds.AttemptOneLogin(ServerInfo serverInfo, String newPassword, SecureString newSecurePassword, Boolean ignoreSniOpenTimeout, TimeoutTimer timeout, Boolean withFailover)
at Microsoft.Data.SqlClient.SqlInternalConnectionTds.LoginNoFailover(ServerInfo serverInfo, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance, SqlConnectionString connectionOptions, SqlCredential credential, TimeoutTimer timeout)
at Microsoft.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(TimeoutTimer timeout, SqlConnectionString connectionOptions, SqlCredential credential, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance)
at Microsoft.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, SqlCredential credential, Object providerInfo, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance, SqlConnectionString userConnectionOptions, SessionData reconnectSessionData, Boolean applyTransientFaultHandling, String accessToken, DbConnectionPool pool)
at Microsoft.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection, DbConnectionOptions userOptions)
at Microsoft.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnectionPool pool, DbConnection owningObject, DbConnectionOptions options, DbConnectionPoolKey poolKey, DbConnectionOptions userOptions)
at Microsoft.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
at Microsoft.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection)
at Microsoft.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
at Microsoft.Data.ProviderBase.DbConnectionPool.WaitForPendingOpen()
--- End of stack trace from previous location ---
By the way
options.AddDevelopmentEncryptionAndSigningCertificate = true;
I also just try true, but i was false