Jump to content

[Solved] An error I got from the server


Amoss

Recommended Posts

Hi

 

I got the following error in one of my calls to the server:

502 Proxy Error

The proxy server received an invalid response from an upstream server

The proxy server could not handle the request

Reason: Error reading from remote server

Additionally, a 502 Bad Gateway error was encountered while trying to use an ErrorDocument to handle the request.

 

What did I do wrong?

Also, I have a cache in my WAR, is there a way to restart Java when/if I get a general error of some kind in order to "start things fresh"?

 

Thanks

 

 

 

 

 

Link to comment
Share on other sites

That’s usually an indication that tomcat died or hung.

 

502 bad gateway basically means “Apache passed a request to something else that should fulfill it, but that thing isn’t returning a useful response for Apache to pass back to the user”

Link to comment
Share on other sites

Thanks, is there a way to know what has caused this? Requests that came afterwards passed with no problem. I wonder if it's something I did.

Also, is there a way to "restart" java except for redeploying the war?

Thanks

Link to comment
Share on other sites

You can request us to restart Tomcat if you need. Please be aware that you will get these sorts of errors while Tomcat is restarting, and it needs to restart occasionally for various reasons like adding new users. Since Tomcat is one of our most popular features it is so overloaded on all of our servers that it can take 5 minutes to restart fully. If you need better Tomcat uptime than our shared hosting can provide we recommend getting a vps https://www.heliohost.org/vps/

Link to comment
Share on other sites

For now I'm in a testing phase. After that, I might go with the VPS option. I just wanted to make sure it is not something I did.

 

BTW: The user interface, cpanel, Java deployments and SSL support are the same when using the VPS?

 

Regarding manual restarting: instead of asking you to restart it again and again, does re-deploying it does the same effect?

 

Thanks

Edited by Amoss
Link to comment
Share on other sites

You get no UI at all if you go for the standard Linux VPS, it's all command line. If you do Windows, you'll get Remote Desktop instead, so easie to use, but the windows server license is not included (it comes with a 180 day trial, but once that's up, the license is not cheap at around $700).

Link to comment
Share on other sites

All I need is a simple server that is running Java. What I like about heliohost hosting is the simplicity to deploy the war and make it work.

Unless I misunderstood, the VPS is not like that. Is there a way to make it as simple as the current heliohost hosting?

Thanks

Link to comment
Share on other sites

If you get a vps you can have a desktop if you want. I recently installed xubuntu on a 1GB vps which comes with xfce. You can then connect through vnc. It works pretty well unless you do something silly like try to open firefox like this particular user did. Browsers use a lot of memory, and if you have a small vps everything comes screeching to a crawl when you use up all your memory.

 

Tomcat actually comes with a web ui that you can use for deploying your .war files, and it's pretty easy to use. The reason we can't let users on shared hosting use it is because you would have access to delete everyone else's .wars and access a lot of settings and information that you shouldn't have access to. If you run tomcat on a vps you could use that default web ui since you'll be the only user on the server. You could also have more than one .war deployed at once which is nice for having a production servlet and a development servlet.

 

If you want to try it out let me know and I can get it set up for you. If you don't like it you can just keep using your shared hosting account.

Link to comment
Share on other sites

I understood from wolstech that Windows license will cost money so I guess Windows is out of the question.

 

So to conclude, I should select ubuntu (I saw this in the list, not xubuntu) and I will have a browser (I guess the VPS should be at least 2gb) from which I can connect to tomcat's webui in order to deploy my WAR. Will it also have HTTPS?

Can I use the vps also as a hosting to my site (not Java)? I guess I can it's just I don't know how to actually do that using the VPS.

 

Krydos, I'm in the middle of testing so for now I will use the shared hosting. Soon I hope to finish the testing phase so I will keep your "If you want to try it out let me know and I can get it set up for you" proposal for when that happens, I appreciate it very much!

Link to comment
Share on other sites

Generally VPS don't have desktops because they use a lot of memory and are kind of pointless. Most VPS are just command line ssh to control everything. When I say webui I mean that you'll be able to go to yourdomain.com:8080 and deploy your .war files through your browser. Xubuntu isn't listed on the vps page because it's not technically a server operating system, it's desktop operating system designed to be installed on your home pc or laptop. I just mentioned it because another VPS user really wanted to have a desktop. It took a lot more work to set up because Xubuntu doesn't come with standard server software like sshd.

 

Yes, your VPS can have SSL. Yes, you can host your entire website on the VPS. I can install apache for you on the VPS if you want to host your website there. You won't have cpanel on your VPS though unless you want to pay $15 per month for it. A lot of our VPS owners use a free control panel like VestaCP instead of cPanel.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...