Deploying the FineBI Project Locally in Tomcat Container on Linux

  • Last update:  2023-03-30
  • Overview

    Version

    Linux System

    Tomcat Version

    JDK Version

    64 bit

    8.0 (not support Tomcat 8.0.32)

    JDK 1.8 and the minor version needs to be JDK 8u102 or higher.

    9.0

    Note: Tomcat 10.0 is not supported.

    Note: Multiple FineBI projects cannot be deployed on the same Tomcat server.

    Effect

    Deploy the FineBI report project to Tomcat on Linux.

    Environment Preparation

    You can search for the specific installation methods to install JDK and Tomcat on Linux in advance. Documents and technical support are not responsible for the environment construction part.

    Note: The installed JDK version needs to match the operating system. In FineBI, a 32-bit JDK cannot be installed on the 64-bit operating system.

    How to Implement

    1. Compress the webroot folder of the local project, upload the compressed package to %TOMCAT_HOME%\webapps of the Tomcat server, and decompress it.

    2. Put the tools.jar file under %TOMCAT_HOME%\lib or %TOMCAT_HOME%\webapps\{project name}\WEB_INF\lib.

    3. Restart the Tomcat server and access the address of the report project.

    Procedure

    This article uses CentOS 7 + JDK 1.8 + Tomcat 9.0.44 as an example for demonstration. The commands of other versions may be slightly different.

    Uploading the File webroot to the Tomcat Environment

    1. Compress the webroot folder of the local FineBI project, and upload the compressed package to %TOMCAT_HOME%\webapps. You can upload it through software such as WinSCP/FTP.

    Note: It is not recommended to upload the folder directly, or there may be something wrong with files.

    2. After uploading, decompress the compressed package, the code is as follows:

    cd /usr/BI/apache-tomcat-9.0.44/webapps
    unzip webroot.zip

    Importing the tools.jar File in the JDK

    Copy the tools.jar file in %JAVA_HOME%\jdk\lib to the deployed server, and copy it to %TOMCAT_HOME%\lib or %TOMCAT_HOME%\webapps\{project name}\WEB_INF\lib.

    The code is as follows:

    cp /usr/java/jdk1.8.0_241-amd64/lib/tools.jar /usr/BI/apache-tomcat-9.0.44/lib

    Checking Whether to Modify the Port Number

    If there are multiple Tomcats running on Linux simultaneously, you need to check whether the default 8080 port number is occupied. If the Linux has not been deployed a project before, you can ignore this section.

    1. Check whether the default 8080 port number is occupied, the figure below shows the occupied situation.

    netstat  -anp  |grep 8080

    2. If it is occupied, you need to modify the Tomcat port number. For details, see Tomcat Port Configuration.

    Configuring Parameters

    Configuring Use Memory Parameters of FineBI

    FineBI has configuration requirements for the server, so memory parameters need to be configured to ensure server stability. For details, see: Modifying FineBI Configuration Parameters.

    Note: If the headless parameter in Modifying FineBI Configuration Parameters is not configured, an error will be reported when the super admin exports Excel: No Export Permission.

    Configuring dump JVM Parameters

    You need to configure the JVM parameters for automatically generating dump logs on project downtime. Configuring this parameter will not erode the project's performance, and it is only used to generate dump logs when the server is down.

    Go to the directory %TOMCAT_HOME%/bin, edit the configuration file catalina.sh, and add the following JVM parameters:

    JAVA_OPTS="$JAVA_OPTS -XX:+HeapDumpOnOutOfMemoryError"
    JAVA_OPTS="$JAVA_OPTS -XX:HeapDumpPath=/opt/"   

    Note: The /opt/ path indicates the path to generate the downtime file. You can modify the file path based on your need. After saving the modification, restart Tomcat to make the configuration take effect.

    Starting Tomcat

    Note: For details about closing and restarting the FineBI project deployed in Tomcat on Linux, see Closing the FineBI Project.

    The execution statement is as follows:

    • Go to the bin directory.

    cd /usr/BI/apache-tomcat-9.0.44/bin
    • Start Tomcat.

    ./startup.sh

    Preview

    Start the browser and enter http://ip:{server port number}/{project name}/decision in the address bar.

    Attachment List


    Theme: デプロイ統合
    前の記事
    次の記事
    • いいね
    • 良くない
    • 閲覧しただけ

    フィードバック

    鼠标选中内容,快速反馈问题

    鼠标选中存在疑惑的内容,即可快速反馈问题,我们将会跟进处理。

    不再提示

    9s后关闭

    反馈已提交

    网络繁忙