Production resin error resin can ' t load

Source: Internet
Author: User

When you restart resin using SSH to perform a remote restart script, an error occurs:

Com.caucho.jsp.jspparseexception: resin can ' t load   usually this means that the jdk tools.jar is missing from  the classpath, possibly because of using a jre instead of  The jdk.  you can either add tools.jar to the classpath  or change the compiler to an external one with <java  compiler= ' Javac '/> or         at com.caucho.jsp.jspcompilerinstance.compile (         at  Com.caucho.jsp.JspManager.compile (         at  Com.caucho.jsp.JspManager.createPage ( &nbsP;       at com.caucho.jsp.jspmanager.createpage (         at com.caucho.jsp.pagemanager.getpage ( : 248)         at com.caucho.jsp.pagemanager.getpage (         at  Com.caucho.jsp.QServlet.getSubPage (         at  Com.caucho.jsp.QServlet.getPage (         at  Com.caucho.server.dispatch.PageFilterChain.compilePage (          at com.caucho.server.dispatch.pagefilterchain.dofilter (          at com.caucho.server.webapp.dispatchfilterchain.dofilter ( &NBSP;&NBSP;&NBSP;&NBSP;&NBSP;&NBSP;&NBSP;&NBsp;at com.caucho.server.dispatch.servletinvocation.service (          at com.caucho.server.webapp.requestdispatcherimpl.forward (         at  Com.caucho.server.webapp.RequestDispatcherImpl.forward (          at com.iheyday.base.cgi.cgiservlet.dispatchpage (          at com.iheyday.base.cgi.cgiservlet.disposeactionresult (         at  Com.iheyday.base.cgi.CGIServlet.invokeAction (          at com.iheyday.base.cgi.cgiservlet.service (          at javax.servlet.http.httpservlet.service (         at com.caucho.server.dispatch.servletfilterchain.dofilter ( : 106)         at  Com.iheyday.web.filter.CampaignPromotionFilter.doFilter (          at com.caucho.server.dispatch.filterfilterchain.dofilter ( FILTERFILTERCHAIN.JAVA:70)         at  Com.iheyday.web.filter.AntiXSSFilter.doFilter (          at com.caucho.server.dispatch.filterfilterchain.dofilter (          at com.iheyday.web.filter.setcharacterencodingfilter.dofilter ( SETCHARACTERENCODINGFILTER.JAVA:54)         at  Com.caucho.server.dispatch.FilterFilterChain.doFilter (          at cOm.caucho.server.webapp.WebAppFilterChain.doFilter (          at com.caucho.server.dispatch.servletinvocation.service (         at com.caucho.server.hmux.hmuxrequest.handlerequest (         at (          at com.caucho.util.threadpool.runtasks (          at (          at ( caused by: resin can ' t load   usually this means that the jdk tools.jar is missing&nbSp;from the classpath, possibly because of using a jre instead  of the JDK.  You can either add tools.jar to the  classpath or change the compiler to an external one with  <java compiler= ' Javac '/> or        at (          at (          ... 1 more

The reason for this problem is simple:

When using SSH to execute a remote script, there is no inherited full environment variable, that is, the JDK environment variable is not loaded!

So just implement the set JDK environment variable:

Vi/etc/profile.d/java.shexport java_home=/usr/java/jdk1.6.0_38export path= $PATH: $JAVA _home/bin

and add it in your restart script:

. /etc/profile.d/

This article is from the "Ops Road" blog, please be sure to keep this source

Production resin error resin can ' t load

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.