How to Install eLabFTW on Ubuntu Server Latest?
eLabFTW is an open source electronic lab notebook that helps researchers keep track of their experiments, protocols, and research data. In this tutorial, we will show you how to install eLabFTW on Ubuntu Server latest edition.
Requirements
- Ubuntu 18.04 LTS (or higher) Server Edition
- SSH access to your server
- sudo privileges
Step 1: Update Ubuntu
Before we start installing eLabFTW, let's update our Ubuntu instance:
sudo apt update
sudo apt upgrade
Step 2: Install Apache, PHP, and MySQL
eLabFTW requires Apache, PHP, and MySQL to be installed on your server. Use the following commands to install the necessary packages:
sudo apt install apache2 mysql-server php libapache2-mod-php php-mysql php-xml
Step 3: Create a MySQL Database
Next, we need to create a MySQL database and user for eLabFTW. We will use the following commands to log in to the MySQL shell and create a new database:
sudo mysql -u root -p
CREATE DATABASE elabftw;
GRANT ALL PRIVILEGES ON elabftw.* TO 'elabftw_user'@'localhost' IDENTIFIED BY 'password_here';
FLUSH PRIVILEGES;
exit
Make sure to replace password_here with a secure password you can remember.
Step 4: Download eLabFTW
Now, let’s download the latest version of eLabFTW from the official website:
cd /var/www/html/
sudo wget https://github.com/elabftw/elabftw/releases/download/1.9.5/elabftw-1.9.5.zip
sudo apt install unzip
sudo unzip elabftw-1.9.5.zip
Step 5: Configure Apache
We need to make sure that Apache is pointing to the correct directory for eLabFTW. Use the following command to open the Apache configuration file:
sudo nano /etc/apache2/sites-available/000-default.conf
Add the following lines to this file:
<Directory /var/www/html/elabftw>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
DocumentRoot /var/www/html/elabftw
Save and close the file. Then, reload Apache for the changes to take effect:
sudo systemctl restart apache2
Step 6: Finish the Installation
Open your web browser and go to http://your_server_ip/elabftw/. You will be greeted with the eLabFTW installation screen. Fill in the details for the MySQL database we created earlier:
- Database server address: localhost
- Database name: elabftw
- Database username: elabftw_user
- Database password: the password you set earlier
Click on the Install button to finish the installation process.
Conclusion
Congratulations! You have successfully installed eLabFTW on your Ubuntu Server. You can now use it to manage your research data and experiments.