Installing iDempiere

Level: Beginner Module: General Foundation 20 min read Lesson 3 of 47

Overview

  • What you’ll learn:
    • System requirements and how to prepare your environment for iDempiere installation
    • Step-by-step installation on Linux from source, including database setup, server configuration, and initial seeding
    • How to use the Docker-based installation as a faster alternative, and how to verify your installation works correctly
  • Prerequisites: Lesson 2 — iDempiere Architecture Overview
  • Estimated reading time: 20 minutes

Introduction

There is no substitute for hands-on experience when learning an ERP system. Reading about architecture and features provides a necessary foundation, but true understanding comes from working with a live installation. In this lesson, you will set up your own iDempiere instance — a personal sandbox where you can safely explore, experiment, and learn without any risk to production data.

We will cover two installation approaches: a traditional installation on Linux (which gives you full control and deeper understanding of the system’s components) and a Docker-based installation (which gets you up and running in minutes with minimal configuration). By the end of this lesson, you will have a working iDempiere system running on your machine and will have logged in for the first time.

System Requirements

Before you begin, ensure your system meets the following minimum requirements:

Hardware Requirements

Resource Minimum Recommended
RAM 4 GB 8 GB or more
CPU 2 cores 4 cores or more
Disk Space 10 GB free 20 GB or more
Network Internet access (for downloads) Broadband connection

These are requirements for a development or learning environment. Production deployments should be sized based on the number of concurrent users, transaction volume, and data growth expectations — typically requiring significantly more resources.

Software Requirements

  • Operating System: Linux (Ubuntu 22.04+ or CentOS/RHEL 8+ recommended), macOS, or Windows (Linux is recommended for production and for following this guide)
  • Java Development Kit (JDK): OpenJDK 17 or later (iDempiere 12 requires Java 17 as the minimum)
  • PostgreSQL: Version 14 or later (we will use PostgreSQL in this guide as it is the community standard)
  • Web Browser: Any modern browser — Chrome, Firefox, Edge, or Safari

For the Docker approach, you will additionally need:

  • Docker Engine: Version 20.10 or later
  • Docker Compose: Version 2.0 or later (usually included with Docker Desktop)

Method 1: Traditional Installation on Linux

This method walks you through every step of a manual installation. It takes more time but gives you a thorough understanding of how iDempiere is assembled and configured.

Step 1: Install Java 17

First, install the OpenJDK 17 development kit. On Ubuntu or Debian-based systems:

sudo apt update
sudo apt install openjdk-17-jdk -y

On CentOS, RHEL, or Fedora:

sudo dnf install java-17-openjdk-devel -y

Verify the installation:

java -version

You should see output indicating OpenJDK version 17 or later. If you have multiple Java versions installed, you can set the default using:

sudo update-alternatives --config java

Also set the JAVA_HOME environment variable by adding the following line to your ~/.bashrc or /etc/environment:

export JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64

Adjust the path based on your actual JDK installation location. Source the file to apply changes:

source ~/.bashrc

Step 2: Install and Configure PostgreSQL

Install PostgreSQL:

sudo apt install postgresql postgresql-contrib -y

Start and enable the PostgreSQL service:

sudo systemctl start postgresql
sudo systemctl enable postgresql

Create a database user for iDempiere. The default expected username is adempiere:

sudo -u postgres psql -c "CREATE ROLE adempiere WITH LOGIN SUPERUSER PASSWORD 'adempiere';"

Security note: In a production environment, you should never use adempiere as the password or grant SUPERUSER privileges. For a learning environment, this simplified setup is acceptable. The SUPERUSER role is needed during initial database seeding to install functions and extensions.

Verify that PostgreSQL is accepting connections:

psql -U adempiere -h localhost -c "SELECT version();"

If prompted for a password, enter adempiere. You may need to edit pg_hba.conf to allow password-based authentication for local connections. The file is typically located at /etc/postgresql/14/main/pg_hba.conf (adjust the version number). Change the local connection method from peer to md5:

# IPv4 local connections:
host    all    all    127.0.0.1/32    md5

After editing, restart PostgreSQL:

sudo systemctl restart postgresql

Step 3: Download iDempiere

Download the latest iDempiere release from GitHub. Navigate to github.com/idempiere/idempiere/releases and download the server package for your operating system.

Alternatively, download directly from the command line (replace the version number with the latest release):

cd /opt
sudo wget https://github.com/idempiere/idempiere/releases/download/v12.0.0/idempiereServer12.zip
sudo unzip idempiereServer12.zip

This creates a directory called idempiere.server (or similar, depending on the release). The directory contains:

  • setup.sh / setup-console.sh — Configuration scripts
  • idempiere-server.sh — The startup script
  • plugins/ — Directory for OSGi plugin bundles
  • data/seed/ — Database seed files for initial setup
  • lib/ — Java libraries and dependencies

Step 4: Run the Setup Console

The setup process configures iDempiere to work with your specific environment (Java location, database connection, ports, etc.). Run the console-based setup:

cd /opt/idempiere.server
sudo sh setup-console.sh

The setup wizard will prompt you for several configuration values. For a standard learning environment, use these settings:

Parameter Value Notes
Java Home /usr/lib/jvm/java-17-openjdk-amd64 Path to your JDK installation
iDempiere Home /opt/idempiere.server Where you extracted iDempiere
Key Store Password myPassword Password for the SSL keystore (choose your own)
Host Name localhost Or your server’s hostname/IP
Application Server Web Port 8080 HTTP port for the web client
Application Server SSL Port 8443 HTTPS port for the web client
Database Server Host localhost Where PostgreSQL is running
Database Server Port 5432 Default PostgreSQL port
Database Name idempiere The database to create
Database User adempiere PostgreSQL user created earlier
Database Password adempiere PostgreSQL user password

The setup process will:

  1. Validate your Java installation
  2. Test the database connection
  3. Generate the idempiereEnv.properties configuration file
  4. Create an SSL certificate keystore

Step 5: Import the Seed Database

The seed database contains the initial Application Dictionary, default chart of accounts, and the demo “Garden World” client data. Import it using the provided script:

cd /opt/idempiere.server/utils
sudo sh RUN_ImportIdempiere.sh

This script creates the idempiere database and loads the seed data. The process typically takes 5–15 minutes depending on your hardware. You will see progress messages as tables and data are loaded.

After the import completes, run the database migration scripts to apply any post-release updates:

cd /opt/idempiere.server/utils
sudo sh RUN_SyncDB.sh

This step ensures your database schema is fully synchronized with the application code.

Step 6: Start the iDempiere Server

You are now ready to start the iDempiere application server:

cd /opt/idempiere.server
sudo sh idempiere-server.sh &

The & runs the server in the background. Watch the console output for startup messages. The server typically takes 30–90 seconds to fully start. Look for a message like:

=== Server started ===
Web UI: http://localhost:8080/webui/

To view the log output at any time:

tail -f /opt/idempiere.server/log/idempiere_*.log

To stop the server gracefully:

cd /opt/idempiere.server
sudo sh idempiere-server.sh stop

The iDempiere Properties File

The setup process generates a configuration file called idempiereEnv.properties in the iDempiere home directory. This file stores all the connection parameters, file paths, and server settings. Key properties include:

# Application Server
ADEMPIERE_HOME=/opt/idempiere.server
ADEMPIERE_APPS_TYPE=jetty
ADEMPIERE_APPS_SERVER=localhost
ADEMPIERE_WEB_PORT=8080
ADEMPIERE_SSL_PORT=8443

# Database
ADEMPIERE_DB_TYPE=PostgreSQL
ADEMPIERE_DB_SERVER=localhost
ADEMPIERE_DB_PORT=5432
ADEMPIERE_DB_NAME=idempiere
ADEMPIERE_DB_USER=adempiere
ADEMPIERE_DB_PASSWORD=adempiere

# Java
JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64

If you need to change any configuration after initial setup (for example, changing the database password or port), you can either re-run the setup console or carefully edit this file directly.

Method 2: Docker Installation (Recommended for Quick Start)

If you want to get iDempiere running quickly without manually installing Java, PostgreSQL, and configuring everything from scratch, Docker is the ideal approach. The iDempiere community maintains official Docker images.

Step 1: Install Docker

If Docker is not already installed, follow the official Docker installation guide for your platform at docs.docker.com/engine/install. On Ubuntu, the quick install is:

curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh
sudo usermod -aG docker $USER

Log out and back in for the group change to take effect, then verify Docker is working:

docker --version
docker compose version

Step 2: Create the Docker Compose File

Create a project directory and a docker-compose.yml file:

mkdir ~/idempiere-docker && cd ~/idempiere-docker

Create the file docker-compose.yml with the following content:

version: '3.8'

services:
  idempiere:
    image: idempiereofficial/idempiere:12
    container_name: idempiere
    ports:
      - "8080:8080"
      - "8443:8443"
      - "12612:12612"
    environment:
      - DB_HOST=postgres
      - DB_PORT=5432
      - DB_NAME=idempiere
      - DB_USER=adempiere
      - DB_PASS=adempiere
      - DB_ADMIN_PASS=postgres
    depends_on:
      postgres:
        condition: service_healthy
    volumes:
      - idempiere_config:/opt/idempiere/configuration
      - idempiere_plugins:/opt/idempiere/plugins

  postgres:
    image: idempiereofficial/idempiere-postgres:12
    container_name: idempiere-postgres
    ports:
      - "5432:5432"
    environment:
      - POSTGRES_USER=adempiere
      - POSTGRES_PASSWORD=adempiere
      - POSTGRES_DB=idempiere
    volumes:
      - idempiere_data:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -U adempiere -d idempiere"]
      interval: 10s
      timeout: 5s
      retries: 5

volumes:
  idempiere_data:
  idempiere_config:
  idempiere_plugins:

This configuration defines two services: the PostgreSQL database (pre-seeded with iDempiere data) and the iDempiere application server. The depends_on with condition: service_healthy ensures iDempiere does not start until PostgreSQL is ready to accept connections.

Step 3: Start the Containers

docker compose up -d

Docker will download the images (this may take several minutes the first time) and start both containers. Monitor the startup progress with:

docker compose logs -f idempiere

Wait until you see the server started message, then press Ctrl+C to exit the log viewer.

Managing the Docker Environment

Useful Docker Compose commands for managing your iDempiere installation:

# Stop all containers
docker compose stop

# Start containers again
docker compose start

# Stop and remove containers (preserves data volumes)
docker compose down

# Stop and remove containers AND data volumes (complete reset)
docker compose down -v

# View running containers
docker compose ps

# View logs
docker compose logs -f idempiere
docker compose logs -f postgres

Verifying Your Installation

Regardless of which installation method you used, the verification process is the same.

Access the Web Client

Open your web browser and navigate to:

http://localhost:8080/webui/

You should see the iDempiere login screen. If you get a connection refused error, the server may still be starting — wait another minute and try again.

Log In with the Default Credentials

iDempiere ships with a demo company called “Garden World” that provides sample data for learning and testing. Log in using these default credentials:

Field Value
User GardenAdmin
Password GardenAdmin

After entering the username and password, you will see a role selection dialog with the following fields:

  • Client: Select “Garden World” — this is the demo tenant
  • Organization: Select “HQ” or “*” (asterisk means all organizations)
  • Role: Select “GardenWorld Admin” — this gives you full administrative access
  • Warehouse: Select “HQ Warehouse” — this sets the default warehouse context

Click OK to log in. You should now see the iDempiere main menu — a tree structure on the left side showing all available windows, reports, and processes organized by functional area.

Important: The default “System” client (used for global administration) has the credentials SuperUser/System. The GardenAdmin account is for the demo company and is what you should use for learning. Never use the System client for day-to-day business operations.

Quick Smoke Test

To confirm that the system is fully operational, perform these quick tests:

  1. Open a window: In the menu tree, navigate to Material Management → Purchase Order. The window should open and display the Purchase Order entry form.
  2. Query records: Click the magnifying glass (lookup) icon in the toolbar to switch to search mode, then click the green checkmark to execute the query. You should see existing demo purchase orders loaded in the grid.
  3. Run a report: In the menu tree, navigate to Performance Analysis → Financial Report. Select “Balance Sheet” and click OK. A financial report should generate and display.

If all three tests work, your installation is fully functional and ready for learning.

Common Installation Issues and Solutions

Here are the most frequently encountered issues during iDempiere installation and how to resolve them:

Issue: Port 8080 Already in Use

Symptom: The server fails to start with a “port already in use” error.

Solution: Another application (such as Tomcat or another web server) is using port 8080. Either stop the other application or change iDempiere’s port. For the traditional installation, re-run the setup console and specify a different port (such as 8888). For Docker, change the port mapping in docker-compose.yml from "8080:8080" to "8888:8080".

Issue: Database Connection Refused

Symptom: Setup or startup fails with “Connection refused” when trying to reach PostgreSQL.

Solution: Verify that PostgreSQL is running (sudo systemctl status postgresql). Check that pg_hba.conf allows connections from the iDempiere host. Ensure the database port (default 5432) is not blocked by a firewall. For Docker, ensure the postgres container is running and healthy (docker compose ps).

Issue: Java Version Mismatch

Symptom: Setup completes but the server crashes on startup with UnsupportedClassVersionError.

Solution: iDempiere requires Java 17 or later. Run java -version to verify your version. If you have multiple Java versions installed, ensure JAVA_HOME points to Java 17+ and that this version appears first in your PATH.

Issue: Out of Memory Errors

Symptom: The server starts but becomes unresponsive or crashes with OutOfMemoryError.

Solution: Increase the Java heap size by editing the idempiere-server.sh script. Find the line containing -Xmx and increase the value:

# Change from default (e.g., -Xmx1024m) to a larger value
-Xmx2048m

For Docker, add a deploy section to the idempiere service in docker-compose.yml or set the IDEMPIERE_JAVA_OPTIONS environment variable.

Issue: Seed Database Import Fails

Symptom: The RUN_ImportIdempiere.sh script fails partway through.

Solution: The most common cause is the PostgreSQL user not having sufficient privileges. Ensure the adempiere user has SUPERUSER or at least CREATEDB privileges. Also verify that the idempiere database does not already exist from a failed previous attempt — drop it with dropdb -U adempiere idempiere before retrying.

Issue: Login Page Shows But Login Fails

Symptom: The web UI loads but you cannot log in with GardenAdmin/GardenAdmin.

Solution: The password may be case-sensitive — use exactly GardenAdmin (capital G and A). If the seed database was not properly imported, the user may not exist. Check the server log for authentication errors. You can also try the SuperUser/System credentials to access the System client.

Key Takeaways

  • iDempiere requires Java 17+ (JDK, not just JRE), PostgreSQL 14+, and at least 4 GB of RAM for a development or learning environment.
  • The traditional installation involves installing Java and PostgreSQL, downloading the iDempiere release, running the setup console, importing the seed database, and starting the server.
  • The Docker installation provides a simpler and faster alternative using pre-built images that include a seeded database, requiring only Docker and a docker-compose.yml file.
  • The default demo login credentials are GardenAdmin/GardenAdmin for the “Garden World” demo client.
  • The idempiereEnv.properties file stores all configuration parameters and can be modified to change database connections, ports, and Java settings.
  • Most common installation problems relate to port conflicts, database authentication, Java version mismatches, or insufficient memory allocation.

What’s Next

With your iDempiere instance up and running, the next lesson will guide you through the user interface. You will learn how to navigate the menu tree, understand the window and tab structure, use the toolbar buttons, work with different field types, and switch between grid and record views to become comfortable and productive in the iDempiere environment.

繁體中文

概覽

  • 您將學到:
    • 系統需求以及如何準備您的 iDempiere 安裝環境
    • 在 Linux 上從原始碼逐步安裝,包括資料庫設定、伺服器組態和初始資料載入
    • 如何使用基於 Docker 的安裝作為更快速的替代方案,以及如何驗證您的安裝是否正常運作
  • 先備知識:第 2 課 — iDempiere 架構概覽
  • 預估閱讀時間:20 分鐘

簡介

學習 ERP 系統時,沒有什麼能取代親身實作的經驗。閱讀架構和功能介紹提供了必要的基礎,但真正的理解來自於操作一個運行中的系統。在本課中,您將設定自己的 iDempiere 實例 — 一個可以安全探索、實驗和學習的個人沙箱,不會對正式環境資料產生任何風險。

我們將介紹兩種安裝方式:Linux 上的傳統安裝(讓您完全掌控並更深入理解系統組件)和基於 Docker 的安裝(讓您在幾分鐘內以最少的設定啟動運行)。在本課結束時,您將擁有一個在您機器上運行的 iDempiere 系統,並且已經完成首次登入。

系統需求

在開始之前,請確保您的系統滿足以下最低需求:

硬體需求

資源 最低 建議
記憶體 4 GB 8 GB 或更多
CPU 2 核心 4 核心或更多
磁碟空間 10 GB 可用 20 GB 或更多
網路 網際網路存取(用於下載) 寬頻連線

這些是開發或學習環境的需求。正式環境部署應根據並行使用者數量、交易量和資料成長預期來調整大小 — 通常需要顯著更多的資源。

軟體需求

  • 作業系統:Linux(建議 Ubuntu 22.04+ 或 CentOS/RHEL 8+)、macOS 或 Windows(正式環境和遵循本指南建議使用 Linux)
  • Java 開發套件(JDK):OpenJDK 17 或更新版本(iDempiere 12 最低需要 Java 17)
  • PostgreSQL:14 版或更新版本(本指南將使用 PostgreSQL,因為它是社群標準)
  • 網頁瀏覽器:任何現代瀏覽器 — Chrome、Firefox、Edge 或 Safari

對於 Docker 方式,您還需要:

  • Docker Engine:20.10 版或更新版本
  • Docker Compose:2.0 版或更新版本(通常包含在 Docker Desktop 中)

方法一:Linux 上的傳統安裝

此方法引導您完成手動安裝的每個步驟。需要更多時間,但讓您徹底了解 iDempiere 是如何組裝和設定的。

步驟 1:安裝 Java 17

首先,安裝 OpenJDK 17 開發套件。在 Ubuntu 或 Debian 系統上:

sudo apt update
sudo apt install openjdk-17-jdk -y

在 CentOS、RHEL 或 Fedora 上:

sudo dnf install java-17-openjdk-devel -y

驗證安裝:

java -version

您應該看到顯示 OpenJDK 17 版或更新版本的輸出。如果安裝了多個 Java 版本,您可以使用以下命令設定預設版本:

sudo update-alternatives --config java

另外,將以下行新增到 ~/.bashrc/etc/environment 以設定 JAVA_HOME 環境變數:

export JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64

根據您實際的 JDK 安裝位置調整路徑。套用變更:

source ~/.bashrc

步驟 2:安裝並設定 PostgreSQL

安裝 PostgreSQL:

sudo apt install postgresql postgresql-contrib -y

啟動並啟用 PostgreSQL 服務:

sudo systemctl start postgresql
sudo systemctl enable postgresql

為 iDempiere 建立資料庫使用者。預設的使用者名稱為 adempiere

sudo -u postgres psql -c "CREATE ROLE adempiere WITH LOGIN SUPERUSER PASSWORD 'adempiere';"

安全提示:在正式環境中,您絕不應該使用 adempiere 作為密碼或授予 SUPERUSER 權限。對於學習環境,這種簡化的設定是可以接受的。初始資料庫載入需要 SUPERUSER 角色來安裝函式和擴展。

驗證 PostgreSQL 是否接受連線:

psql -U adempiere -h localhost -c "SELECT version();"

如果提示輸入密碼,請輸入 adempiere。您可能需要編輯 pg_hba.conf 以允許本地連線使用密碼驗證。該檔案通常位於 /etc/postgresql/14/main/pg_hba.conf(調整版本號)。將本地連線方法從 peer 改為 md5

# IPv4 local connections:
host    all    all    127.0.0.1/32    md5

編輯後重新啟動 PostgreSQL:

sudo systemctl restart postgresql

步驟 3:下載 iDempiere

從 GitHub 下載最新的 iDempiere 發行版本。前往 github.com/idempiere/idempiere/releases 並下載適合您作業系統的伺服器套件。

或者,直接從命令列下載(將版本號替換為最新版本):

cd /opt
sudo wget https://github.com/idempiere/idempiere/releases/download/v12.0.0/idempiereServer12.zip
sudo unzip idempiereServer12.zip

這會建立一個名為 idempiere.server(或類似名稱,取決於發行版本)的目錄。該目錄包含:

  • setup.sh / setup-console.sh — 設定腳本
  • idempiere-server.sh — 啟動腳本
  • plugins/ — OSGi 外掛 bundle 目錄
  • data/seed/ — 初始設定的資料庫種子檔案
  • lib/ — Java 程式庫和依賴

步驟 4:執行設定控制台

設定過程會將 iDempiere 設定為適合您特定環境(Java 位置、資料庫連線、連接埠等)。執行控制台設定:

cd /opt/idempiere.server
sudo sh setup-console.sh

設定精靈會提示您輸入幾個設定值。對於標準學習環境,使用以下設定:

參數 備註
Java Home /usr/lib/jvm/java-17-openjdk-amd64 您的 JDK 安裝路徑
iDempiere Home /opt/idempiere.server 您解壓縮 iDempiere 的位置
Key Store Password myPassword SSL 金鑰庫密碼(自行選擇)
Host Name localhost 或您伺服器的主機名稱/IP
Application Server Web Port 8080 網頁客戶端的 HTTP 連接埠
Application Server SSL Port 8443 網頁客戶端的 HTTPS 連接埠
Database Server Host localhost PostgreSQL 執行的位置
Database Server Port 5432 預設 PostgreSQL 連接埠
Database Name idempiere 要建立的資料庫
Database User adempiere 先前建立的 PostgreSQL 使用者
Database Password adempiere PostgreSQL 使用者密碼

設定過程將會:

  1. 驗證您的 Java 安裝
  2. 測試資料庫連線
  3. 產生 idempiereEnv.properties 設定檔
  4. 建立 SSL 憑證金鑰庫

步驟 5:匯入種子資料庫

種子資料庫包含初始 Application Dictionary、預設會計科目表和示範「Garden World」客戶端資料。使用提供的腳本匯入:

cd /opt/idempiere.server/utils
sudo sh RUN_ImportIdempiere.sh

此腳本會建立 idempiere 資料庫並載入種子資料。此過程通常需要 5 至 15 分鐘,取決於您的硬體。您會看到表和資料載入的進度訊息。

匯入完成後,執行資料庫遷移腳本以套用任何發行後的更新:

cd /opt/idempiere.server/utils
sudo sh RUN_SyncDB.sh

此步驟確保您的資料庫結構與應用程式程式碼完全同步。

步驟 6:啟動 iDempiere 伺服器

您現在可以啟動 iDempiere 應用程式伺服器了:

cd /opt/idempiere.server
sudo sh idempiere-server.sh &

& 會在背景執行伺服器。觀察控制台輸出中的啟動訊息。伺服器通常需要 30 至 90 秒完全啟動。尋找類似以下的訊息:

=== Server started ===
Web UI: http://localhost:8080/webui/

隨時查看日誌輸出:

tail -f /opt/idempiere.server/log/idempiere_*.log

優雅地停止伺服器:

cd /opt/idempiere.server
sudo sh idempiere-server.sh stop

iDempiere 屬性檔

設定過程會在 iDempiere 主目錄中產生一個名為 idempiereEnv.properties 的設定檔。此檔案儲存所有連線參數、檔案路徑和伺服器設定。主要屬性包括:

# Application Server
ADEMPIERE_HOME=/opt/idempiere.server
ADEMPIERE_APPS_TYPE=jetty
ADEMPIERE_APPS_SERVER=localhost
ADEMPIERE_WEB_PORT=8080
ADEMPIERE_SSL_PORT=8443

# Database
ADEMPIERE_DB_TYPE=PostgreSQL
ADEMPIERE_DB_SERVER=localhost
ADEMPIERE_DB_PORT=5432
ADEMPIERE_DB_NAME=idempiere
ADEMPIERE_DB_USER=adempiere
ADEMPIERE_DB_PASSWORD=adempiere

# Java
JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64

如果您需要在初始設定後更改任何設定(例如更改資料庫密碼或連接埠),您可以重新執行設定控制台或小心地直接編輯此檔案。

方法二:Docker 安裝(推薦用於快速開始)

如果您想快速啟動 iDempiere 而不需要手動安裝 Java、PostgreSQL 並從頭開始設定所有內容,Docker 是理想的方法。iDempiere 社群維護著官方 Docker 映像。

步驟 1:安裝 Docker

如果尚未安裝 Docker,請按照您平台的官方 Docker 安裝指南進行操作,網址為 docs.docker.com/engine/install。在 Ubuntu 上,快速安裝為:

curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh
sudo usermod -aG docker $USER

登出並重新登入以使群組變更生效,然後驗證 Docker 是否正常運作:

docker --version
docker compose version

步驟 2:建立 Docker Compose 檔案

建立一個專案目錄和 docker-compose.yml 檔案:

mkdir ~/idempiere-docker && cd ~/idempiere-docker

使用以下內容建立 docker-compose.yml 檔案:

version: '3.8'

services:
  idempiere:
    image: idempiereofficial/idempiere:12
    container_name: idempiere
    ports:
      - "8080:8080"
      - "8443:8443"
      - "12612:12612"
    environment:
      - DB_HOST=postgres
      - DB_PORT=5432
      - DB_NAME=idempiere
      - DB_USER=adempiere
      - DB_PASS=adempiere
      - DB_ADMIN_PASS=postgres
    depends_on:
      postgres:
        condition: service_healthy
    volumes:
      - idempiere_config:/opt/idempiere/configuration
      - idempiere_plugins:/opt/idempiere/plugins

  postgres:
    image: idempiereofficial/idempiere-postgres:12
    container_name: idempiere-postgres
    ports:
      - "5432:5432"
    environment:
      - POSTGRES_USER=adempiere
      - POSTGRES_PASSWORD=adempiere
      - POSTGRES_DB=idempiere
    volumes:
      - idempiere_data:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -U adempiere -d idempiere"]
      interval: 10s
      timeout: 5s
      retries: 5

volumes:
  idempiere_data:
  idempiere_config:
  idempiere_plugins:

此設定定義了兩個服務:PostgreSQL 資料庫(預載入 iDempiere 資料)和 iDempiere 應用程式伺服器。帶有 condition: service_healthydepends_on 確保 iDempiere 在 PostgreSQL 準備好接受連線之前不會啟動。

步驟 3:啟動容器

docker compose up -d

Docker 會下載映像(第一次可能需要幾分鐘)並啟動兩個容器。使用以下命令監視啟動進度:

docker compose logs -f idempiere

等到看到伺服器啟動訊息,然後按 Ctrl+C 退出日誌檢視器。

管理 Docker 環境

用於管理 iDempiere 安裝的實用 Docker Compose 命令:

# 停止所有容器
docker compose stop

# 再次啟動容器
docker compose start

# 停止並移除容器(保留資料卷)
docker compose down

# 停止並移除容器及資料卷(完全重設)
docker compose down -v

# 查看運行中的容器
docker compose ps

# 查看日誌
docker compose logs -f idempiere
docker compose logs -f postgres

驗證您的安裝

無論您使用哪種安裝方法,驗證過程都是相同的。

存取網頁客戶端

開啟您的網頁瀏覽器並導覽到:

http://localhost:8080/webui/

您應該會看到 iDempiere 登入畫面。如果您收到連線被拒絕的錯誤,伺服器可能仍在啟動中 — 再等一分鐘後重試。

使用預設認證登入

iDempiere 附帶一個名為「Garden World」的示範公司,提供用於學習和測試的範例資料。使用以下預設認證登入:

欄位
使用者 GardenAdmin
密碼 GardenAdmin

輸入使用者名稱和密碼後,您會看到一個角色選擇對話框,包含以下欄位:

  • Client:選擇「Garden World」— 這是示範租戶
  • Organization:選擇「HQ」或「*」(星號表示所有組織)
  • Role:選擇「GardenWorld Admin」— 這會給您完整的管理存取權限
  • Warehouse:選擇「HQ Warehouse」— 這會設定預設倉庫環境

點擊 OK 登入。您現在應該會看到 iDempiere 主選單 — 左側的樹狀結構顯示按功能區域組織的所有可用視窗、報表和流程。

重要:預設的「System」客戶端(用於全域管理)的認證為 SuperUser/System。GardenAdmin 帳號是用於示範公司的,也是您應該用來學習的帳號。永遠不要使用 System 客戶端進行日常業務操作。

快速冒煙測試

要確認系統完全正常運作,請執行以下快速測試:

  1. 開啟視窗:在選單樹中,導覽到 Material Management → Purchase Order。視窗應該會開啟並顯示採購訂單輸入表單。
  2. 查詢記錄:點擊工具列中的放大鏡(查詢)圖示切換到搜尋模式,然後點擊綠色核取標記執行查詢。您應該會看到現有的示範採購訂單載入到網格中。
  3. 執行報表:在選單樹中,導覽到 Performance Analysis → Financial Report。選擇「Balance Sheet」並點擊 OK。應該會產生並顯示財務報表。

如果三個測試都通過,您的安裝就完全正常運作,可以開始學習了。

常見安裝問題和解決方案

以下是 iDempiere 安裝過程中最常遇到的問題及解決方法:

問題:連接埠 8080 已被佔用

症狀:伺服器啟動失敗,顯示「port already in use」錯誤。

解決方案:另一個應用程式(如 Tomcat 或其他網頁伺服器)正在使用連接埠 8080。停止其他應用程式或更改 iDempiere 的連接埠。對於傳統安裝,重新執行設定控制台並指定不同的連接埠(如 8888)。對於 Docker,將 docker-compose.yml 中的連接埠對映從 "8080:8080" 更改為 "8888:8080"

問題:資料庫連線被拒絕

症狀:設定或啟動失敗,嘗試連線 PostgreSQL 時顯示「Connection refused」。

解決方案:驗證 PostgreSQL 是否正在執行(sudo systemctl status postgresql)。檢查 pg_hba.conf 是否允許來自 iDempiere 主機的連線。確保資料庫連接埠(預設 5432)未被防火牆封鎖。對於 Docker,確保 postgres 容器正在執行且健康狀態良好(docker compose ps)。

問題:Java 版本不符

症狀:設定完成但伺服器啟動時崩潰,顯示 UnsupportedClassVersionError

解決方案:iDempiere 需要 Java 17 或更新版本。執行 java -version 驗證您的版本。如果安裝了多個 Java 版本,確保 JAVA_HOME 指向 Java 17+ 且此版本在您的 PATH 中排在最前面。

問題:記憶體不足錯誤

症狀:伺服器啟動但變得無回應或崩潰,顯示 OutOfMemoryError

解決方案:透過編輯 idempiere-server.sh 腳本增加 Java 堆積大小。找到包含 -Xmx 的行並增加值:

# 從預設值(例如 -Xmx1024m)更改為更大的值
-Xmx2048m

對於 Docker,在 docker-compose.yml 中為 idempiere 服務新增 deploy 區段或設定 IDEMPIERE_JAVA_OPTIONS 環境變數。

問題:種子資料庫匯入失敗

症狀:RUN_ImportIdempiere.sh 腳本在中途失敗。

解決方案:最常見的原因是 PostgreSQL 使用者沒有足夠的權限。確保 adempiere 使用者具有 SUPERUSER 或至少 CREATEDB 權限。另外確認 idempiere 資料庫不存在先前失敗嘗試留下的殘留 — 重試前使用 dropdb -U adempiere idempiere 刪除它。

問題:登入頁面顯示但登入失敗

症狀:網頁 UI 載入但無法使用 GardenAdmin/GardenAdmin 登入。

解決方案:密碼可能區分大小寫 — 請使用完全一致的 GardenAdmin(大寫 G 和 A)。如果種子資料庫未正確匯入,使用者可能不存在。檢查伺服器日誌中的認證錯誤。您也可以嘗試使用 SuperUser/System 認證來存取 System 客戶端。

重點摘要

  • iDempiere 需要 Java 17+(JDK,不僅是 JRE)、PostgreSQL 14+ 和至少 4 GB 記憶體用於開發或學習環境。
  • 傳統安裝涉及安裝 Java 和 PostgreSQL、下載 iDempiere 發行版本、執行設定控制台、匯入種子資料庫和啟動伺服器。
  • Docker 安裝使用預建映像(包含已載入的資料庫)提供更簡單快速的替代方案,僅需 Docker 和一個 docker-compose.yml 檔案。
  • 預設示範登入認證為 GardenAdmin/GardenAdmin,用於「Garden World」示範客戶端。
  • idempiereEnv.properties 檔案儲存所有設定參數,可以修改以更改資料庫連線、連接埠和 Java 設定。
  • 大多數常見的安裝問題與連接埠衝突、資料庫認證、Java 版本不符或記憶體分配不足有關。

下一步

隨著您的 iDempiere 實例啟動運行,下一課將引導您瀏覽使用者介面。您將學習如何導覽選單樹、了解視窗和分頁結構、使用工具列按鈕、使用不同的欄位類型,以及在網格和記錄檢視之間切換,讓您在 iDempiere 環境中感到自在和高效。

日本語

概要

  • 学習内容:
    • システム要件と iDempiere インストールのための環境準備方法
    • Linux でのソースからのステップバイステップインストール(データベースセットアップ、サーバー設定、初期シーディングを含む)
    • より高速な代替手段としての Docker ベースのインストール方法と、インストールが正しく動作していることの確認方法
  • 前提条件:第2課 — iDempiereアーキテクチャ概要
  • 推定読了時間:20分

はじめに

ERP システムを学ぶとき、実践に勝る経験はありません。アーキテクチャと機能について読むことは必要な基礎を提供しますが、真の理解は実際に動いているシステムを操作することから得られます。このレッスンでは、自分自身の iDempiere インスタンス — 本番データへのリスクなしに安全に探索、実験、学習できる個人用サンドボックスをセットアップします。

2つのインストール方法を扱います:Linux での従来のインストール(完全な制御とシステムコンポーネントのより深い理解が得られます)と Docker ベースのインストール(最小限の設定で数分で稼働できます)。このレッスンの終わりには、あなたのマシンで動作する iDempiere システムが完成し、初めてのログインを完了しているでしょう。

システム要件

開始する前に、システムが以下の最小要件を満たしていることを確認してください:

ハードウェア要件

リソース 最小 推奨
メモリ 4 GB 8 GB以上
CPU 2コア 4コア以上
ディスク容量 10 GB空き 20 GB以上
ネットワーク インターネットアクセス(ダウンロード用) ブロードバンド接続

これらは開発または学習環境の要件です。本番環境のデプロイメントは、同時接続ユーザー数、トランザクション量、データ成長の予測に基づいてサイジングする必要があります — 通常、大幅に多くのリソースが必要です。

ソフトウェア要件

  • オペレーティングシステム:Linux(Ubuntu 22.04+ または CentOS/RHEL 8+ を推奨)、macOS、または Windows(本番環境およびこのガイドに従う場合は Linux を推奨)
  • Java Development Kit(JDK):OpenJDK 17以降(iDempiere 12 は最低 Java 17 が必要)
  • PostgreSQL:バージョン14以降(このガイドではコミュニティ標準の PostgreSQL を使用)
  • Web ブラウザ:任意のモダンブラウザ — Chrome、Firefox、Edge、Safari

Docker アプローチの場合、さらに以下が必要です:

  • Docker Engine:バージョン20.10以降
  • Docker Compose:バージョン2.0以降(通常 Docker Desktop に含まれています)

方法1:Linux での従来のインストール

この方法では、手動インストールのすべてのステップを案内します。より多くの時間がかかりますが、iDempiere がどのように組み立てられ設定されるかを徹底的に理解できます。

ステップ1:Java 17のインストール

まず、OpenJDK 17 開発キットをインストールします。Ubuntu または Debian ベースのシステムの場合:

sudo apt update
sudo apt install openjdk-17-jdk -y

CentOS、RHEL、または Fedora の場合:

sudo dnf install java-17-openjdk-devel -y

インストールを確認:

java -version

OpenJDK バージョン17以降を示す出力が表示されるはずです。複数の Java バージョンがインストールされている場合は、以下でデフォルトを設定できます:

sudo update-alternatives --config java

また、~/.bashrc または /etc/environment に以下の行を追加して JAVA_HOME 環境変数を設定します:

export JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64

実際の JDK インストール場所に基づいてパスを調整してください。変更を適用するためにファイルを読み込みます:

source ~/.bashrc

ステップ2:PostgreSQL のインストールと設定

PostgreSQL をインストール:

sudo apt install postgresql postgresql-contrib -y

PostgreSQL サービスを起動して有効化:

sudo systemctl start postgresql
sudo systemctl enable postgresql

iDempiere 用のデータベースユーザーを作成します。デフォルトのユーザー名は adempiere です:

sudo -u postgres psql -c "CREATE ROLE adempiere WITH LOGIN SUPERUSER PASSWORD 'adempiere';"

セキュリティに関する注意:本番環境では、adempiere をパスワードとして使用したり SUPERUSER 権限を付与したりすべきではありません。学習環境では、この簡略化されたセットアップは許容されます。SUPERUSER ロールは、初期データベースシーディング時に関数と拡張機能をインストールするために必要です。

PostgreSQL が接続を受け付けていることを確認:

psql -U adempiere -h localhost -c "SELECT version();"

パスワードの入力を求められたら、adempiere と入力してください。ローカル接続のパスワードベース認証を許可するために pg_hba.conf の編集が必要な場合があります。ファイルは通常 /etc/postgresql/14/main/pg_hba.conf(バージョン番号を調整)にあります。ローカル接続の方法を peer から md5 に変更します:

# IPv4 local connections:
host    all    all    127.0.0.1/32    md5

編集後、PostgreSQL を再起動:

sudo systemctl restart postgresql

ステップ3:iDempiere のダウンロード

GitHub から最新の iDempiere リリースをダウンロードします。github.com/idempiere/idempiere/releases にアクセスし、お使いのオペレーティングシステム用のサーバーパッケージをダウンロードしてください。

または、コマンドラインから直接ダウンロードします(バージョン番号を最新リリースに置き換えてください):

cd /opt
sudo wget https://github.com/idempiere/idempiere/releases/download/v12.0.0/idempiereServer12.zip
sudo unzip idempiereServer12.zip

これにより idempiere.server(またはリリースによって類似の名前)というディレクトリが作成されます。ディレクトリには以下が含まれます:

  • setup.sh / setup-console.sh — 設定スクリプト
  • idempiere-server.sh — 起動スクリプト
  • plugins/ — OSGi プラグインバンドル用ディレクトリ
  • data/seed/ — 初期セットアップ用データベースシードファイル
  • lib/ — Java ライブラリと依存関係

ステップ4:セットアップコンソールの実行

セットアッププロセスは、特定の環境(Java の場所、データベース接続、ポートなど)に合わせて iDempiere を設定します。コンソールベースのセットアップを実行:

cd /opt/idempiere.server
sudo sh setup-console.sh

セットアップウィザードが複数の設定値の入力を求めます。標準的な学習環境では、以下の設定を使用してください:

パラメータ 備考
Java Home /usr/lib/jvm/java-17-openjdk-amd64 JDK インストールへのパス
iDempiere Home /opt/idempiere.server iDempiere を展開した場所
Key Store Password myPassword SSL キーストアのパスワード(任意に設定)
Host Name localhost またはサーバーのホスト名/IP
Application Server Web Port 8080 Web クライアントの HTTP ポート
Application Server SSL Port 8443 Web クライアントの HTTPS ポート
Database Server Host localhost PostgreSQL が実行されている場所
Database Server Port 5432 デフォルトの PostgreSQL ポート
Database Name idempiere 作成するデータベース
Database User adempiere 先に作成した PostgreSQL ユーザー
Database Password adempiere PostgreSQL ユーザーパスワード

セットアッププロセスは以下を行います:

  1. Java インストールの検証
  2. データベース接続のテスト
  3. idempiereEnv.properties 設定ファイルの生成
  4. SSL 証明書キーストアの作成

ステップ5:シードデータベースのインポート

シードデータベースには、初期 Application Dictionary、デフォルトの勘定科目表、デモの「Garden World」クライアントデータが含まれています。提供されたスクリプトを使用してインポートします:

cd /opt/idempiere.server/utils
sudo sh RUN_ImportIdempiere.sh

このスクリプトは idempiere データベースを作成し、シードデータをロードします。プロセスはハードウェアに応じて通常5〜15分かかります。テーブルとデータがロードされる進行状況メッセージが表示されます。

インポートが完了したら、データベースマイグレーションスクリプトを実行してリリース後の更新を適用します:

cd /opt/idempiere.server/utils
sudo sh RUN_SyncDB.sh

このステップにより、データベーススキーマがアプリケーションコードと完全に同期されます。

ステップ6:iDempiere サーバーの起動

iDempiere アプリケーションサーバーを起動する準備が整いました:

cd /opt/idempiere.server
sudo sh idempiere-server.sh &

& はサーバーをバックグラウンドで実行します。コンソール出力で起動メッセージを確認してください。サーバーは通常、完全に起動するまで30〜90秒かかります。以下のようなメッセージを探してください:

=== Server started ===
Web UI: http://localhost:8080/webui/

いつでもログ出力を確認:

tail -f /opt/idempiere.server/log/idempiere_*.log

サーバーを正常に停止:

cd /opt/idempiere.server
sudo sh idempiere-server.sh stop

iDempiere プロパティファイル

セットアッププロセスは、iDempiere ホームディレクトリに idempiereEnv.properties という設定ファイルを生成します。このファイルには、すべての接続パラメータ、ファイルパス、サーバー設定が格納されています。主要なプロパティには以下が含まれます:

# Application Server
ADEMPIERE_HOME=/opt/idempiere.server
ADEMPIERE_APPS_TYPE=jetty
ADEMPIERE_APPS_SERVER=localhost
ADEMPIERE_WEB_PORT=8080
ADEMPIERE_SSL_PORT=8443

# Database
ADEMPIERE_DB_TYPE=PostgreSQL
ADEMPIERE_DB_SERVER=localhost
ADEMPIERE_DB_PORT=5432
ADEMPIERE_DB_NAME=idempiere
ADEMPIERE_DB_USER=adempiere
ADEMPIERE_DB_PASSWORD=adempiere

# Java
JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64

初期セットアップ後に設定を変更する必要がある場合(たとえば、データベースパスワードやポートの変更)、セットアップコンソールを再実行するか、このファイルを慎重に直接編集できます。

方法2:Docker インストール(クイックスタートに推奨)

Java、PostgreSQL を手動でインストールし、すべてをゼロから設定せずに iDempiere を素早く稼働させたい場合、Docker が理想的なアプローチです。iDempiere コミュニティは公式 Docker イメージを維持しています。

ステップ1:Docker のインストール

Docker がまだインストールされていない場合は、docs.docker.com/engine/install でプラットフォーム用の公式 Docker インストールガイドに従ってください。Ubuntu での簡易インストール:

curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh
sudo usermod -aG docker $USER

グループ変更を有効にするためにログアウトして再ログインし、Docker が動作していることを確認:

docker --version
docker compose version

ステップ2:Docker Compose ファイルの作成

プロジェクトディレクトリと docker-compose.yml ファイルを作成:

mkdir ~/idempiere-docker && cd ~/idempiere-docker

以下の内容で docker-compose.yml ファイルを作成:

version: '3.8'

services:
  idempiere:
    image: idempiereofficial/idempiere:12
    container_name: idempiere
    ports:
      - "8080:8080"
      - "8443:8443"
      - "12612:12612"
    environment:
      - DB_HOST=postgres
      - DB_PORT=5432
      - DB_NAME=idempiere
      - DB_USER=adempiere
      - DB_PASS=adempiere
      - DB_ADMIN_PASS=postgres
    depends_on:
      postgres:
        condition: service_healthy
    volumes:
      - idempiere_config:/opt/idempiere/configuration
      - idempiere_plugins:/opt/idempiere/plugins

  postgres:
    image: idempiereofficial/idempiere-postgres:12
    container_name: idempiere-postgres
    ports:
      - "5432:5432"
    environment:
      - POSTGRES_USER=adempiere
      - POSTGRES_PASSWORD=adempiere
      - POSTGRES_DB=idempiere
    volumes:
      - idempiere_data:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -U adempiere -d idempiere"]
      interval: 10s
      timeout: 5s
      retries: 5

volumes:
  idempiere_data:
  idempiere_config:
  idempiere_plugins:

この設定は2つのサービスを定義しています:PostgreSQL データベース(iDempiere データで事前シーディング済み)と iDempiere アプリケーションサーバー。condition: service_healthy 付きの depends_on により、PostgreSQL が接続を受け付ける準備ができるまで iDempiere が起動しないことが保証されます。

ステップ3:コンテナの起動

docker compose up -d

Docker がイメージをダウンロードし(初回は数分かかる場合があります)、両方のコンテナを起動します。起動の進行状況を監視:

docker compose logs -f idempiere

サーバー起動メッセージが表示されるまで待ち、Ctrl+C を押してログビューアーを終了します。

Docker 環境の管理

iDempiere インストールを管理するための便利な Docker Compose コマンド:

# すべてのコンテナを停止
docker compose stop

# コンテナを再起動
docker compose start

# コンテナを停止して削除(データボリュームは保持)
docker compose down

# コンテナとデータボリュームを停止して削除(完全リセット)
docker compose down -v

# 実行中のコンテナを表示
docker compose ps

# ログを表示
docker compose logs -f idempiere
docker compose logs -f postgres

インストールの確認

どのインストール方法を使用したかに関係なく、確認プロセスは同じです。

Web クライアントへのアクセス

Web ブラウザを開き、以下にアクセス:

http://localhost:8080/webui/

iDempiere のログイン画面が表示されるはずです。接続拒否エラーが表示された場合、サーバーがまだ起動中の可能性があります — もう1分待ってから再試行してください。

デフォルト認証情報でのログイン

iDempiere には、学習とテスト用のサンプルデータを提供する「Garden World」というデモ会社が付属しています。以下のデフォルト認証情報でログインしてください:

フィールド
ユーザー GardenAdmin
パスワード GardenAdmin

ユーザー名とパスワードを入力すると、以下のフィールドを含むロール選択ダイアログが表示されます:

  • Client:「Garden World」を選択 — これはデモテナントです
  • Organization:「HQ」または「*」を選択(アスタリスクは全組織を意味します)
  • Role:「GardenWorld Admin」を選択 — これにより完全な管理アクセスが得られます
  • Warehouse:「HQ Warehouse」を選択 — これによりデフォルトの倉庫コンテキストが設定されます

OK をクリックしてログインします。iDempiere のメインメニューが表示されるはずです — 左側にツリー構造があり、機能領域別に整理されたすべての利用可能なウィンドウ、レポート、プロセスが表示されます。

重要:デフォルトの「System」クライアント(グローバル管理に使用)の認証情報は SuperUser/System です。GardenAdmin アカウントはデモ会社用であり、学習に使用すべきものです。日常的なビジネス操作に System クライアントを使用しないでください。

簡易動作テスト

システムが完全に動作していることを確認するために、以下の簡単なテストを実行してください:

  1. ウィンドウを開く:メニューツリーで Material Management → Purchase Order に移動します。ウィンドウが開き、発注書入力フォームが表示されるはずです。
  2. レコードを照会:ツールバーの虫眼鏡(ルックアップ)アイコンをクリックして検索モードに切り替え、緑のチェックマークをクリックしてクエリを実行します。既存のデモ発注書がグリッドにロードされるはずです。
  3. レポートを実行:メニューツリーで Performance Analysis → Financial Report に移動します。「Balance Sheet」を選択して OK をクリックします。財務レポートが生成・表示されるはずです。

3つのテストすべてが動作すれば、インストールは完全に機能しており、学習の準備が整っています。

一般的なインストール問題と解決策

以下は、iDempiere インストール中に最も頻繁に遭遇する問題とその解決方法です:

問題:ポート 8080 が既に使用中

症状:サーバーが「port already in use」エラーで起動に失敗する。

解決策:別のアプリケーション(Tomcat や別の Web サーバーなど)がポート 8080 を使用しています。他のアプリケーションを停止するか、iDempiere のポートを変更してください。従来のインストールの場合は、セットアップコンソールを再実行して別のポート(8888など)を指定します。Docker の場合は、docker-compose.yml のポートマッピングを "8080:8080" から "8888:8080" に変更します。

問題:データベース接続拒否

症状:PostgreSQL への接続時に「Connection refused」でセットアップまたは起動が失敗する。

解決策:PostgreSQL が実行中であることを確認します(sudo systemctl status postgresql)。pg_hba.conf が iDempiere ホストからの接続を許可していることを確認します。データベースポート(デフォルト 5432)がファイアウォールでブロックされていないことを確認します。Docker の場合は、postgres コンテナが実行中でヘルシーであることを確認します(docker compose ps)。

問題:Java バージョンの不一致

症状:セットアップは完了するが、サーバーが起動時に UnsupportedClassVersionError でクラッシュする。

解決策:iDempiere には Java 17以降が必要です。java -version を実行してバージョンを確認してください。複数の Java バージョンがインストールされている場合は、JAVA_HOME が Java 17+ を指していること、およびこのバージョンが PATH の最初に表示されることを確認してください。

問題:メモリ不足エラー

症状:サーバーは起動するが、応答しなくなるか OutOfMemoryError でクラッシュする。

解決策:idempiere-server.sh スクリプトを編集して Java ヒープサイズを増やします。-Xmx を含む行を見つけて値を増やします:

# デフォルト値(例:-Xmx1024m)からより大きな値に変更
-Xmx2048m

Docker の場合は、docker-compose.yml の idempiere サービスに deploy セクションを追加するか、IDEMPIERE_JAVA_OPTIONS 環境変数を設定します。

問題:シードデータベースのインポートに失敗

症状:RUN_ImportIdempiere.sh スクリプトが途中で失敗する。

解決策:最も一般的な原因は、PostgreSQL ユーザーに十分な権限がないことです。adempiere ユーザーが SUPERUSER または少なくとも CREATEDB 権限を持っていることを確認してください。また、以前の失敗した試行から idempiere データベースが既に存在していないことを確認してください — 再試行する前に dropdb -U adempiere idempiere で削除してください。

問題:ログインページは表示されるがログインに失敗

症状:Web UI は読み込まれるが、GardenAdmin/GardenAdmin でログインできない。

解決策:パスワードは大文字小文字を区別する場合があります — 正確に GardenAdmin(大文字の G と A)を使用してください。シードデータベースが正しくインポートされなかった場合、ユーザーが存在しない可能性があります。サーバーログで認証エラーを確認してください。SuperUser/System 認証情報を試して System クライアントにアクセスすることもできます。

まとめ

  • iDempiere には、開発または学習環境のために Java 17+(JRE ではなく JDK)、PostgreSQL 14+、および最低4 GBのメモリが必要です。
  • 従来のインストールには、Java と PostgreSQL のインストール、iDempiere リリースのダウンロード、セットアップコンソールの実行、シードデータベースのインポート、サーバーの起動が含まれます。
  • Docker インストールは、シーディング済みデータベースを含む事前構築済みイメージを使用して、より簡単で高速な代替手段を提供し、Docker と docker-compose.yml ファイルのみが必要です。
  • デフォルトのデモログイン認証情報は、「Garden World」デモクライアントの GardenAdmin/GardenAdmin です。
  • idempiereEnv.properties ファイルにはすべての設定パラメータが格納されており、データベース接続、ポート、Java 設定を変更するために修正できます。
  • ほとんどの一般的なインストール問題は、ポートの競合、データベース認証、Java バージョンの不一致、またはメモリ割り当ての不足に関連しています。

次のステップ

iDempiere インスタンスが稼働を開始したら、次のレッスンではユーザーインターフェースを案内します。メニューツリーのナビゲーション方法、ウィンドウとタブの構造の理解、ツールバーボタンの使用方法、さまざまなフィールドタイプの操作、グリッドとレコードビューの切り替えを学び、iDempiere 環境で快適かつ生産的に作業できるようになります。

You Missed