Jahia in English > Custom install problem

1 (1 Good)
0 (0 Bad)

Custom install problem

by  peterr »  2015/04/26 23:02

Hello,

I've successfully tested Jahia Community with bundled Tomcat and now I'm trying to deploy it to the existing Tomcat server (in jahia folder) to put in production.

I followed the recommendation found in this forum - start jar again and disable the second option (Tomcat server) during install. The install is finished but there is no war file created, there are only two folders in tomcat folder inside installation folder created - lib and webapps. I tried to deploy the content of webapps to my Tomcat but the app is not working (no page displayed). Where is my error? How can I create war file (maybe I'll try to deploy the app to a shared server where I must use war file for deployement)?

 

Peter

  (peterr)

Number of messages  8
Registration date
0 (0 Good)
0 (0 Bad)

Re: Custom install problem

by  root »  2015/04/27 09:26

Hello Peter,

at the end of the installation there is checkbox to open the "How-to install" document.

Otherwise, you should have after installation a file <install-folder>/docs/How-to-install-tomcat.html which will guide you through the process of deploying the artifacts, generated by the installer, and applying required configuration changes to the existig Tomcat instance.

Kind regards

Sergiy

  (root)

Number of messages  5
Registration date Aug 29, 2017
0 (0 Good)
0 (0 Bad)

Custom install problem

by  peterr »  2015/04/27 10:29

The instructions in How-to-install.html are exactly the same as in the forum post I've read:

Once the installer is finished in your install directory you should find a file named ROOT.war [1], a file named shared-libraries.zip and if you chose to externalize the configuration you will also have a jahia-config.jar file.

The problem is that there is NO ROOT.war created during custom install!

As I configured jahia as virtual app during install, I supposed to see JAHIA.war file but there is NO war files created at all.

 

  (peterr)

Number of messages  8
Registration date
0 (0 Good)
0 (0 Bad)

Re: Custom install problem

by  shyrkov »  2015/04/27 10:32

Hello Peter,

which Jahia version are you using? What is the name of the installer file?

 

Kind regards

Sergiy

  • Re: Custom install problem
    2015/04/27 10:32

    shyrkov <p>Hello Peter,</p> <p>which Jahia version are you using? What is the name of the installer file?</p> <p>&nbsp;</p> <p>Kind regards</p> <p>Sergiy</p>

  • Number of messages  407
    Registration date Apr 27, 2015
    0 (0 Good)
    1 (1 Bad)

    Custom install problem

    by  peterr »  2015/04/27 11:13

    I downloaded Jahia-DigitalFactory-CommunityDistribution-7.0.0.0-r49489.jar file.

      (peterr)

    Number of messages  8
    Registration date
    0 (0 Good)
    0 (0 Bad)

    Custom install problem

    by  peterr »  2015/04/27 13:51

    It seems that the problem comes from the path configured in some xml files - it is the path of initial install directory (mentionned in install wizard) and not the real path of the server where I copied the content of tomcat folder. So the simple copy does not work.

    So, the question is - how shoud I proceed to deploy Jahia to an existing Tomcat server (headless)?

      (peterr)

    Number of messages  8
    Registration date
    0 (0 Good)
    0 (0 Bad)

    Re: Custom install problem

    by  shyrkov »  2015/04/27 15:09

    Peter,

    I've double-checked the How-to-install-tomcat.html file, included into Jahia-DigitalFactory-CommunityDistribution-7.0.0.0-r49489.jar, and it has indeed inconsistencies about ZIP and WAR files.

    The installer does not create the WAR and ZIP files, but rather a <install-dir>/tomcat/lib and <install-dir>/tomcat/webapps/jahia folders in your case.

    For the deployment steps 1) to 3), please, do the following instead:

    1. Copy the content of the <install-dir>/tomcat/lib folder into your <tomcat>/lib directory.
    2. In case ROOT was configured as the Web application context name, please, remove or rename the default Tomcat’s ROOT Web application at <tomcat>/webapps/ROOT, if it exists, to e.g. tomcat-root or similar.
    3. Copy the content of the <install-dir>/tomcat/webapps folder into your <tomcat>/webapps directory.

     

    You will need to adjust the JVM options. And also provide a proper path to the database data folder, if you have chosen the embedded Derby as a DBMS type.

    JVM tuning options

    The default JVM options of the Apache Tomcat have to be adjusted to reflect the Digital Factory requirements.
    We recommend creating a setenv.bat (Windows) or setenv.sh (non-Windows OS) script in the <tomcat>/bin folder to put those options.
    An example of the <tomcat>/bin/setenv.bat for Windows OS could be:

    rem --------------------------------------------------------------------
    rem Digital Factory settings
    rem --------------------------------------------------------------------

    set CATALINA_OPTS=%CATALINA_OPTS% -server -Dsun.io.useCanonCaches=false -verbose:gc -XX:+HeapDumpOnOutOfMemoryError -XX:+PrintConcurrentLocks -Djava.net.preferIPv4Stack=true -Xms2048m -Xmx2048m -XX:MaxPermSize=384m
    set CATALINA_OPTS=%CATALINA_OPTS% -Dderby.system.home="%CATALINA_HOME%\webapps\jahia\WEB-INF\var\dbdata"


    In a similar way, the <tomcat>/bin/setenv.sh script for a non-Windows OS can look like:

    #!/bin/sh

    # ----------------------------------------------------------------------
    # Digital Factory settings
    # ----------------------------------------------------------------------

    CATALINA_OPTS="$CATALINA_OPTS -server -Djava.awt.headless=true -verbose:gc -XX:+HeapDumpOnOutOfMemoryError -XX:+PrintConcurrentLocks -Djava.net.preferIPv4Stack=true -Xms2048m -Xmx2048m -XX:MaxPermSize=384m" CATALINA_OPTS="$CATALINA_OPTS -Dderby.system.home=$CATALINA_HOME/webapps/jahia/WEB-INF/var/dbdata"
    export CATALINA_OPTS
    export CATALINA_PID=$CATALINA_HOME/temp/tomcat.pid


    The JVM heap sizes (-Xms and -Xmx) as well as the permanent generation space size (-XX:MaxPermSize) should be adjusted according to your needs. Note that the minimal value of the -Xmx value, required by Digital Factory is 1280m.
    If you have chosen Apache Derby as the target DBMS server during the installation, the value of the -Dderby.system.home in the setenv.bat/setenv.sh script should point to your <df-webapp-dir>/WEB-INF/var/dbdata folder.

     

    We've published also the Configuration and Fine Tuning Guide DF 7.0.0.0 on the "User documentation" page at http://www.jahia.com , so you can check the corresponding section "3.7.1 Apache Tomcat 7.0.x" in that document.

    Kind regards

    Sergiy

  • Re: Custom install problem
    2015/04/27 15:09

    shyrkov <p>Peter,</p> <p>I&#39;ve double-checked the How-to-install-tomcat.html file, included into Jahia-DigitalFactory-CommunityDistribution-7.0.0.0-r49489.jar, and it has indeed inconsistencies about ZIP and WAR files.</p> <p>The installer does not create the WAR and ZIP files, but rather a &lt;install-dir&gt;/tomcat/lib and &lt;install-dir&gt;/tomcat/webapps/jahia folders in your case.</p> <p>For the deployment steps 1) to 3), please, do the following instead:</p> <ol> <li>Copy the content of the <tt>&lt;install-dir&gt;/tomcat/lib</tt> folder into your <tt>&lt;tomcat&gt;/lib</tt> directory.</li> <li>In case ROOT was configured as the Web application context name, please, remove or rename the default Tomcat&rsquo;s ROOT Web application at <tt>&lt;tomcat&gt;/webapps/ROOT</tt>, if it exists, to e.g. <tt>tomcat-root</tt> or similar.</li> <li>Copy the content of the <tt>&lt;install-dir&gt;/tomcat/webapps</tt> folder into your <tt>&lt;tomcat&gt;/webapps</tt> directory.</li> </ol> <p>&nbsp;</p> <p>You will need to adjust the JVM options. And also provide a proper path to the database data folder, if you have chosen the embedded Derby as a DBMS type.</p> <h2>JVM tuning options</h2> <p>The default JVM options of the Apache Tomcat have to be adjusted to reflect the Digital Factory requirements.<br /> We recommend creating a <tt>setenv.bat</tt> (Windows) or <tt>setenv.sh</tt> (non-Windows OS) script in the <tt>&lt;tomcat&gt;/bin</tt> folder to put those options.<br /> An example of the <tt>&lt;tomcat&gt;/bin/setenv.bat</tt> for Windows OS could be:</p> <blockquote><tt>rem --------------------------------------------------------------------<br /> rem Digital Factory settings<br /> rem --------------------------------------------------------------------<br /> <br /> set CATALINA_OPTS=%CATALINA_OPTS% -server -Dsun.io.useCanonCaches=false -verbose:gc -XX:+HeapDumpOnOutOfMemoryError -XX:+PrintConcurrentLocks -Djava.net.preferIPv4Stack=true -Xms2048m -Xmx2048m -XX:MaxPermSize=384m<br /> set CATALINA_OPTS=%CATALINA_OPTS% -Dderby.system.home=&quot;%CATALINA_HOME%\webapps\jahia\WEB-INF\var\dbdata&quot;</tt></blockquote> <p><br /> In a similar way, the <tt>&lt;tomcat&gt;/bin/setenv.sh</tt> script for a non-Windows OS can look like:</p> <blockquote><tt>#!/bin/sh<br /> <br /> # ----------------------------------------------------------------------<br /> # Digital Factory settings<br /> # ----------------------------------------------------------------------<br /> <br /> CATALINA_OPTS=&quot;$CATALINA_OPTS -server -Djava.awt.headless=true -verbose:gc -XX:+HeapDumpOnOutOfMemoryError -XX:+PrintConcurrentLocks -Djava.net.preferIPv4Stack=true -Xms2048m -Xmx2048m -XX:MaxPermSize=384m&quot; CATALINA_OPTS=&quot;$CATALINA_OPTS -Dderby.system.home=$CATALINA_HOME/webapps/jahia/WEB-INF/var/dbdata&quot;<br /> export CATALINA_OPTS<br /> export CATALINA_PID=$CATALINA_HOME/temp/tomcat.pid</tt></blockquote> <p><br /> The JVM heap sizes (<tt>-Xms</tt> and <tt>-Xmx</tt>) as well as the permanent generation space size (<tt>-XX:MaxPermSize</tt>) should be adjusted according to your needs. Note that the minimal value of the <tt>-Xmx</tt> value, required by Digital Factory is <tt>1280m</tt>.<br /> If you have chosen Apache Derby as the target DBMS server during the installation, the value of the <tt>-Dderby.system.home</tt> in the <tt>setenv.bat/setenv.sh</tt> script should point to your <tt>&lt;df-webapp-dir&gt;/WEB-INF/var/dbdata</tt> folder.</p> <p>&nbsp;</p> <p>We&#39;ve published also the <a href="https://www.jahia.com/files/live/sites/jahiacom/files/Resources/docs/7.x/7.0/en/DF7.0_Configuration-and-fine-tuning.pdf">Configuration and Fine Tuning Guide DF 7.0.0.0</a> on the &quot;User documentation&quot; page at http://www.jahia.com , so you can check the corresponding section &quot;3.7.1 Apache Tomcat 7.0.x&quot; in that document.</p> <p>Kind regards</p> <p>Sergiy</p>

  • Number of messages  407
    Registration date Apr 27, 2015
    0 (0 Good)
    0 (0 Bad)

    Custom install problem

    by  peterr »  2015/04/28 11:43

    Thanks for this information, I'll try to follow the instructions.

      (peterr)

    Number of messages  8
    Registration date
    0 (0 Good)
    0 (0 Bad)

    Custom install problem

    by  peterr »  2015/04/30 10:06

    Still no luck to get it working sad

    The error is "javax.naming.NamingException: Connection to localhost:5432 refused"

    The database installed is PostgreSQL 9.3, I can connect to the database from the localhost (command-line client) and from another system (pgAdmin) with the login/password configured in META-INF/context.xml, I can see the tables (I've created the tables manually using the scripts from WEB-INF/var/db/sql). Telnet connection from localhost to 5432/tcp works fine too. Where could be the problem?

      (peterr)

    Number of messages  8
    Registration date
    0 (0 Good)
    0 (0 Bad)

    Re: Custom install problem

    by  shyrkov »  2015/04/30 10:29

    Hello,

    could you, please, share the context.xml file and the part of the startup log with the connection exception?

    Kind regards

    Sergiy

  • Re: Custom install problem
    2015/04/30 10:29

    shyrkov <p>Hello,</p> <p>could you, please, share the context.xml file and the part of the startup log with the connection exception?</p> <p>Kind regards</p> <p>Sergiy</p>

  • Number of messages  407
    Registration date Apr 30, 2015
    Contact
    Share
    Feedback

    Get in touch

    Whether you are a current user or if you are just evaluating Jahia, we are here to help.

    Contact us

    Share this page