We have a PS2021 that works great on localhost, so we tried deploying it to a Win2019 / IIS server. Initially the client deployment went great and we got the launcher and it downloaded a shortcut to the desktop, but it didn't work because the Server APIs weren't deployed. Finally got the server apis deployed, but now we get a 500 error when we put in the website URL.
- You are here:
- Home
- Q&A
- Q&A
- PowerServer
- 500 error for PS2021
- Kevin Ridley
- PowerServer
- Thursday, 24 March 2022 19:38 PM UTC
- Wednesday, 13 April 2022 13:49 PM UTC
- PowerServer
- # Permalink
Hi Kevin,
out of curiosity, what fixed the 2 errors in your setup:
- 500: you said re-installation of .NETCore hosting bundle made the trick right?
- 404: ?
Thanks,
.m
- Thursday, 24 March 2022 19:43 PM UTC
- PowerServer
- # 1
Are the server APIs hosted on a different port from the client app? Some times we have seen there is conflict between regular .NET framework and the .NET core framework that the server APIs uses. So by separating you can avoid that issue.
Also, when you compiled the server APIs, did you have the compile settings as follows? If for example, you are compiling for wrong .NET Core version or wrong bitness (i.e. defaults to x86 change to x64) that could cause such 500 error.
- Kevin Ridley
- Monday, 28 March 2022 19:35 PM UTC
-
Helpful Loading... Helpful 0
- Armeen Mazda @Appeon
- Monday, 28 March 2022 19:38 PM UTC
-
Helpful Loading... Helpful 0
- Kevin Ridley
- Tuesday, 5 April 2022 18:06 PM UTC
-
Helpful Loading... Helpful 0
- Thursday, 24 March 2022 19:58 PM UTC
- PowerServer
- # 2
Hi Kevin,
You might want to check IIS' logs to see if they offer any helpful information. The logs are located on (I'm quoting here)
On a standard Windows Server, IIS log files are found at %SystemDrive%\inetpub\logs\LogFiles by default.
Please let us know if the HTTP 500 error shows up in the logs and what they contain.
Regards,
Francisco
- Wednesday, 30 March 2022 06:57 AM UTC
- PowerServer
- # 3
Hi Kevin,
1) can you access IIS welcome page at http://yourserver:80?
2) if so, what port have you deployed PS API to? See PS project -> Web API -> Web API URL
Say it is 81.
Can you reach IIS on that port
> telnet yourserver 81
You may need to add it to myserver's firewall rules.
3) If 2) also works, you can quickly check if PS is up and running by calling one of its APIs:
http://yourserver:81/api/session/getsessioncount
Best,
.m
- Marco Meoni
- Friday, 1 April 2022 21:26 PM UTC
any progress?
How are you publishing ServerAPI?
- from dev machine via webdeploy (i.e. remote IIS Mgmt service installed and port 8172 accessible) ?
- directly on the server via file system ?
Since ServerAPI is published to dedicated website on port 5009 you should be able to connect
yourserver:5009/api/session/getsessioncount
Alternatively you can also try to access the health status page provided by PS (https://docs.appeon.com/ps2021/Check_the_status_of_Web_APIs.html):
yourserver:5009/health-ui
Regarding web.config mentioned in your error message, I checked on my side and it looks rather standard:
<configuration>
<system.webServer>
<handlers>
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
</handlers>
<aspNetCore processPath="dotnet" arguments=".\ServerAPIs.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="inprocess" />
</system.webServer>
</location>
</configuration>
HTH,
.m
-
Helpful Loading... Helpful 0
- Kevin Ridley
- Monday, 4 April 2022 15:06 PM UTC
Directly from SnapDev Publish
yourserver:5009/health-ui
Not working
yourserver:5009/api/session/getsessioncount
Not working
-
Helpful Loading... Helpful 0
- Kevin Ridley
- Monday, 4 April 2022 15:08 PM UTC
-
Helpful Loading... Helpful 0
- Friday, 1 April 2022 02:16 AM UTC
- PowerServer
- # 4
Hi Kevin
Have you installed .NET Core Hosting Bundle? Not not, you may see this error. Please refer to:
https://docs.microsoft.com/en-us/aspnet/core/test/troubleshoot-azure-iis?view=aspnetcore-3.1#500-internal-server-error
Regards, Logan
- Kevin Ridley
- Monday, 4 April 2022 14:44 PM UTC
-
Helpful Loading... Helpful 0
- Logan Liu
- Wednesday, 6 April 2022 03:03 AM UTC
For how to deploy the PowerServer project, you can also refer to this tutorial:
https://docs.appeon.com/ps2021/Deploying_your_PowerServer_project_to_remote_servers.html
Regards, Logan
-
Helpful Loading... Helpful 0
- Kevin Ridley
- Wednesday, 6 April 2022 13:24 PM UTC
-
Helpful Loading... Helpful 0
- Page :
- 1
However, you are not allowed to reply to this question.
I wonder why we need 3 sites. What are the difference between the "client website" and "for the FTP"? Seems to me they are both the web server site?
Best regards, Julie
Cheers,
.m