Sakai is a little bit hard to install and to config, so I create a Sakai v20.1 system in a Vagrant box.
System Information
- Debian 10.6 Buster: https://app.vagrantup.com/abc101/boxes/debian
- MariaDB v15.1: Debian distribution 10.3.25-mariadb
- Oracle JDK: 1.8.0_261
- Tomcat: 9.0.38
- Sakai: v20.1 binary package
- Installed: Sakai initial database
- sakai properties location: $CATATALINA_HOME/sakai/
VirtualBox Information
- CPUs: 2
- RAM: 2048MB
- HDD: 32GB(Usage: 3.9GB)
How to use
- Install VirtualBox and Vagrant
- Make directory for the Sakai vagrant box
- Create a Vagrantfile
$ vagrant init
4. Edit the ‘Vagrantfile’. The default box uses 2048MB RAM and 2 CPUs. You can increase RAM and CPU size. If you reduce the RAM and CPUs, then the Sakai will start very slowly.
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
config.vm.box = "abc101/sakai"
config.vm.box_version = "20.1"
config.vm.network "forwarded_port", guest: 8080, host: 8080
# config.vm.provider "virtualbox" do |vb|
# # Display the VirtualBox GUI when booting the machine
# vb.gui = true
#
# # Customize the amount of memory on the VM:
# vb.memory = "2048"
# vb.cpus = "2"
# end
# config.vm.provision "shell", inline: <<-SHELL
# apt-get update
# apt-get install -y apache2
# SHELL
end
5. Start up Sakai vagrant. It will download Sakai vagrant box and start. The box size is around 2.9GB. It will take up to an hour to download the package depends on your network speed.
$ vagrant up
6. Sakai will finishing the initial starting around 5 minutes after system boot.
7. Open a site, “127.0.0.1:8080/portal” in your browser, you can see the Sakai front page. Default Sakai id and password are admin for both. If you visit the root, “127.0.0.1:8080”, then you will have 404(no page) tomcat error, because Sakai uses the “portal” subdirectory for the front page. I did not install any tomcat manager app to save the starting time. If you want to use it with a web server, then read https://abc101.medium.com/install-sakai-lms-v20-1-with-nginx-63fa5718f734.
8. If you watch the Sakai logs, you can see it in the default Catalina log file.
$ tail -f $CATALINA_HOME/logs/catalina.out
9. User vagrant is the Sakai system owner. I did not create “tomcat” user because it is a demo system. I don’t recommend to use this as a live system.
10. Sakai system controls
$ sudo systemctl status sakai
$ sudo systemctl start sakai
$ sudo systemctl stop sakai
$ sudo systemctl restart sakai
11. If you have an error to stop “sakai”, the you have to kill the process directly. It will take a time to kill the process completely.
$ ps -ef | grep sakai
$ kill [process number]