Lucee Startup Sleep

119 views
Skip to first unread message

W. Williams

unread,
Oct 7, 2016, 4:52:55 PM10/7/16
to Lucee
Sometimes when Lucee starts up and our filesystem is not finished mounting, it causes Lucee to crash.  Is there an easy way to just have Lucee wait like 10 seconds.  We are running Lucee in a Linux environment.

Thanks in advance!

Igal @ Lucee.org

unread,
Oct 7, 2016, 4:57:26 PM10/7/16
to lu...@googlegroups.com

Then put the delay in the script that starts up Lucee, e.g. the systemd service script or initd, or whatever you use.

If you're using systemd then you should be able to specify that it should only run after the mount has completed.

Igal Sapir
Lucee Core Developer
Lucee.org

On 10/7/2016 1:52 PM, W. Williams wrote:
Sometimes when Lucee starts up and our filesystem is not finished mounting, it causes Lucee to crash.  Is there an easy way to just have Lucee wait like 10 seconds.  We are running Lucee in a Linux environment.

Thanks in advance!
--
Get 10% off of the regular price for this years CFCamp in Munich, Germany (Oct. 20th & 21st) with the Lucee discount code Lucee@cfcamp. 189€ instead of 210€. Visit https://ti.to/cfcamp/cfcamp-2016/discount/Lucee@cfcamp
---
You received this message because you are subscribed to the Google Groups "Lucee" group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/8fc2c925-cb08-4e3d-b555-07afa6f22344%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

W. Williams

unread,
Oct 7, 2016, 11:33:01 PM10/7/16
to Lucee
So we use chkconfig to start Lucee on boot.  Does that use the /etc/init.d/lucee_ctl file on boot?  We added a sleep command before the $CATALINA_HOME/bin/startup.sh, but that didn't seem to do anything.  Everytime the server boots, we get "* PID not found".  Simply running a "service lucee_ctl start", starts lucee up just fine.

Any  help would be appreciated?

W. Williams

unread,
Oct 10, 2016, 9:58:15 AM10/10/16
to Lucee
So after further investigation, this has nothing to do with our file system.  It has to do with web requests hitting the Lucee server before tomcat is fully initialized and started.  We were able to work around this by doing the following:

1. Remove lucee_ctl and http services from chkconfig

2. Add the following to /etc/rc.d/rc.local

/sbin/service railo_ctl start
/bin/sleep 30s
/sbin/service httpd start

By doing this, it gives lucee enough time to start before any requests can be made.

Why does Lucee die / not complete the startup process if a web request is made during initialization?
Reply all
Reply to author
Forward
0 new messages