Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to restart jpro.one production server automatically? #171

Open
ctoabidmaqbool1 opened this issue Feb 18, 2024 · 1 comment
Open

How to restart jpro.one production server automatically? #171

ctoabidmaqbool1 opened this issue Feb 18, 2024 · 1 comment

Comments

@ctoabidmaqbool1
Copy link

Sometimes I face a problem that my production Jpro App server shutdown. Sometimes like this when I was sleeping.

It's teadious taks to open computer, open termianl, and do stuff something like this, every time:

cd /var/www/myapp/bin
./restart-background.sh

Is there anyway to automatically restart jpor serven when it's shutdown??? I think, if it's possible there shout be script file something like this auto-restart-background.sh.

More over I am still not getup the cause of shutdown of my production ready jpro server, I have applied debugging steps alreay e.g. https://www.jpro.one/docs/current/2.5/DEBUGGING_AND_TESTING

@FlorianKirmaier
Copy link
Contributor

I guess the most straightforward way, would be to configure it as a systemd service for linux.
(Or as a windows service)
We'll try to find time to document it - and find a simple well working configuration.

Some tips about your shutdown problem:

  • Configure some swap - helps to solve short ram peaks of the OS
  • Make sure you have enough RAM configured, maybe check the syslog whether your process was killed by the OS?
  • No System.exit() in the code (due to changes in the JDK, we can't prevent these calls anymore from the JPro code)

Guess we should also add these hints to the documentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants