How to Install XWiki on Ubuntu 22.04
How to Install XWiki on Ubuntu 22.04
Author: Łukasz Bodziony
Published: June 2025
Introduction
XWiki is a powerful, extensible wiki platform written in Java. In this tutorial, Łukasz Bodziony will show you how to install and configure XWiki on Ubuntu 22.04 LTS using Tomcat and MariaDB.
Prerequisites
- Ubuntu 22.04 LTS server
- Sudo/root privileges
- 4 GB RAM (recommended)
- Static IP or DNS name
Step 1: Update System Packages
sudo apt update && sudo apt upgrade -y
Step 2: Install Java (OpenJDK 11)
sudo apt install -y openjdk-11-jdk
java -version
Step 3: Install and Configure MariaDB
sudo apt install -y mariadb-server
sudo mysql_secure_installation
Log into MariaDB and create a database and user for XWiki:
sudo mysql -u root -p
CREATE DATABASE xwikidb CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER 'xwikiuser'@'localhost' IDENTIFIED BY 'strongpassword';
GRANT ALL ON xwikidb.* TO 'xwikiuser'@'localhost';
FLUSH PRIVILEGES;
EXIT;
Step 4: Install Apache Tomcat
sudo apt install -y tomcat9 tomcat9-admin
Ensure Tomcat is running:
sudo systemctl enable tomcat9
sudo systemctl start tomcat9
Step 5: Download and Deploy XWiki WAR
cd /tmp
wget https://releases.xwiki.org/xwiki/13.10/xwiki-web-13.10.11.war -O xwiki.war
sudo mv xwiki.war /var/lib/tomcat9/webapps/
sudo systemctl restart tomcat9
Step 6: Configure XWiki
On first access (http://Your-Server-IP:8080/xwiki
), follow the setup wizard. Choose “MySQL / MariaDB” and enter:
- Database:
xwikidb
- User:
xwikiuser
- Password:
strongpassword
- JDBC URL:
jdbc:mysql://localhost:3306/xwikidb?useUnicode=true&characterEncoding=UTF-8
Conclusion
You now have a fully functional XWiki instance running on Ubuntu 22.04! It’s ready for you to create documentation, knowledge bases, or collaborative intranets.
🚀 Host your XWiki on a fast, reliable Linux VPS: netcloud24.com/servers/vps-linux/
Comments
Post a Comment