Struggling to set up Frappe/ERPNext on Ubuntu 24.04 LTS? Many users face issues with dependencies, configurations, and installation errors. This guide simplifies the process, providing clear, step-by-step instructions to ensure a hassle-free setup.
Whether you’re new to ERP systems or upgrading to v15, follow this guide to install Frappe/ERPNext seamlessly.
Pre-requisites
Ensure that your system meets the following requirements before proceeding:
- Python 3.11+ (Ubuntu 24.04 comes with Python 3.12 by default)
- Node.js 18+
- Redis 5 (for caching and real-time updates)
- MariaDB 10.3.x / PostgreSQL 9.5.x (for database-driven applications)
- Yarn 1.12+ (JavaScript dependency manager)
- Pip 20+ (Python dependency manager)
- wkhtmltopdf (0.12.5 with patched Qt) (for PDF generation)
- Cron (for scheduled jobs, backups, etc.)
- NGINX (for proxying multi-tenant sites in production)
Note: Ubuntu 24.04 default versions:
- Python: 3.12
- MariaDB: 10.11 (may show compatibility warnings)
Step-by-Step Installation
Step 1: Install Git
sudo apt-get install git
Step 2: Install Python Development Tools
sudo apt-get install python3-dev
Step 3: Install Setuptools and Pip
sudo apt-get install python3-setuptools python3-pip
Step 4: Install Virtual Environment
sudo apt install python3.12-venv
Step 5: Install MariaDB
sudo apt-get install software-properties-common
sudo apt install mariadb-server
sudo systemctl status mariadb
sudo mysql_secure_installation
Follow the prompts to set up the root password and configure security settings.
Step 6: Install MySQL Development Files
sudo apt-get install libmysqlclient-dev
Step 7: Configure MariaDB
Edit MariaDB configuration file:
sudo nano /etc/mysql/mariadb.conf.d/50-server.cnf
Add the following settings
[server]
user = mysql
pid-file = /run/mysqld/mysqld.pid
socket = /run/mysqld/mysqld.sock
basedir = /usr
datadir = /var/lib/mysql
tmpdir = /tmp
lc-messages-dir = /usr/share/mysql
bind-address = 127.0.0.1
query_cache_size = 16M
log_error = /var/log/mysql/error.log
[mysqld]
innodb-file-format=barracuda
innodb-file-per-table=1
innodb-large-prefix=1
character-set-client-handshake = FALSE
character-set-server = utf8mb4
collation-server = utf8mb4_unicode_ci
[mysql]
default-character-set = utf8mb4
Save and exit (Ctrl+X, then Y, then Enter). Restart MariaDB:
sudo service mysql restart
Step 8: Install Redis
sudo apt-get install redis-server
Step 9: Install Node.js 18
sudo apt install curl
curl https://raw.githubusercontent.com/creationix/nvm/master/install.sh | bash
source ~/.profile
nvm install 18
Step 10: Install Yarn
sudo apt-get install npm
sudo npm install -g yarn
Step 11: Install wkhtmltopdf
sudo apt-get install xvfb libfontconfig wkhtmltopdf
Step 12: Install Frappe Bench
sudo -H pip3 install frappe-bench --break-system-packages
bench --version
Step 13: Initialize Frappe Bench
bench init frappe-bench --frappe-branch version-15
cd frappe-bench/
bench start
Step 14: Create a Site in Frappe Bench
bench new-site localhost
Open http://localhost:8000
in your browser to access the site.
Step 15: Install ERPNext
bench get-app erpnext --branch version-15
bench --site localhost install-app erpnext
bench start
Conclusion
Congratulations! You have successfully installed Frappe/ERPNext Version 15 on Ubuntu 24.04 LTS. You can now start configuring your ERPNext instance to suit your business needs.
If you encounter any difficulties during the installation process, feel free to contact us. Our ERPNext implementation services are designed to help you seamlessly set up and optimize Frappe/ERPNext. We’re here to resolve any challenges and ensure a smooth implementation for your business.
FAQ
1. What if I face compatibility issues with MariaDB 10.11?
MariaDB 10.11 is newer than the recommended 10.3.x. If you encounter issues, consider downgrading to MariaDB 10.6 or using PostgreSQL as an alternative.
2. How do I access ERPNext after installation?
Simply navigate to http://dcode.com:8000
in your browser and log in using the admin credentials.
3. How do I keep my installation updated?
Run the following commands periodically to update your setup:
bench update