Java
Install Java 11 on Kubuntu
sudo apt update
sudo apt install openjdk-11-jdk
java -version
Version
sudo update-alternatives --config java
Set JAVA_HOME
echo $JAVA_HOME
export JAVA_HOME=$(readlink -f /usr/bin/java | sed "s:/bin/java::")
Then, you can set the JAVA_HOME variable in your shell's configuration file (e.g., .bashrc or .zshrc). For example:
export JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64
export PATH=$PATH:$JAVA_HOME/bin
After that, source the configuration file:
source ~/.bashrc # or your shell's configuration file
Webmin
Setup
The simplest and best way to get Webmin is to use automatic webmin-setup-repo.sh script to configure repositories on your RHEL or Debian derivative systems. It can be done in two easy steps:
curl -o webmin-setup-repo.sh https://raw.githubusercontent.com/webmin/webmin/master/webmin-setup-repo.sh
sh webmin-setup-repo.sh
This script will automatically setup our repository and install our GPG keys on your system, and provide webmin package for installation and easy upgrades in the future. The supported and tested systems are Red Hat Enterprise Linux, Alma, Rocky, Oracle, CentOS Stream, Fedora or Debian, Ubuntu, Kali.
Install
If Webmin repository was setup using our webmin-setup-repo.sh as described above then Webmin can be installed as easy as:
apt-get install webmin --install-recommends
Access
https://localhost:10000
Samba Windows File Sharing
webmin-backup-config-on-Satellite-L650-2025-08-07-15-18.tgz
MySQL
Install and configure a MySQL server
sudo apt-get update
sudo apt-get upgrade
sudo apt install mysql-server
sudo service mysql status
The network status of the MySQL service can also be checked by running the ss command at the terminal prompt:
sudo ss -tap | grep mysql
If the server is not running correctly, you can type the following command to start it:
sudo service mysql restart
A good starting point for troubleshooting problems is the systemd journal, which can be accessed from the terminal prompt with this command:
sudo journalctl -u mysql
mysql -V
Configure MySQL
You can edit the files in
/etc/mysql/
to configure the basic settings – log file, port number, etc.
For example, to configure MySQL to listen for connections from network hosts, in the file
/etc/mysql/mysql.conf.d/mysqld.cnf
Percona Xtrabackup
Also supported in Ubuntu 24.04 LTS and later, Percona Xtrabackup is a tool for creating physical backups. It is similar to the commercial offering of MySQL Enterprise Backup.
completely get rid of your MySQL installation
In order to completely get rid of your MySQL installation you could run the following:
Make sure MySQL is not running:
sudo systemctl stop mysql
Then purge all of the MySQL packages:
sudo apt purge mysql-server mysql-client mysql-common mysql-server-core-* mysql-client-core-*
Then delete all of the MySQL files:
sudo rm -rf /etc/mysql /var/lib/mysql /var/log/mysql
Finally clean all packages that are not needed:
sudo apt autoremove
sudo apt autoclean
Tomcat
How can I remove tomcat 9 installation from my ubuntu
1. Remove tomcat
To remove system and config files from Ubuntu.
sudo apt-get update
sudo apt-get upgrade
sudo apt remove --purge tomcat9 tomcat9-docs
sudo apt autoremove
sudo apt autoclean
Locate and remove manually the remaining files if there are some
sudo apt install locate && sudo updatedb
locate tomcat
How to Install Tomcat 9 on Ubuntu 22.04
First, install OpenJDK 11.
Create a new system user and group with a home directory of /opt/tomcat to run the Tomcat service. Enter the following command:
sudo useradd -m -U -d /opt/tomcat -s /bin/false tomcat
Check the Tomcat download page to see if a newer version is available.
After that, use wget to download the Tomcat zip file to the /tmp directory:
VERSION=9.0.108
wget https://downloads.apache.org/tomcat/tomcat-9/v${VERSION}/bin/apache-tomcat-${VERSION}.tar.gz
After downloading, extract the tar file to /opt/tomcat directory.
sudo tar -xf /tmp/apache-tomcat-${VERSION}.tar.gz -C /opt/tomcat/
Tomcat is typically updated regularly for security and to introduce new features. For more control, create a symbolic link called “latest” that points to the Tomcat installation directory.
sudo ln -s /opt/tomcat/apache-tomcat-${VERSION} /opt/tomcat/latest
Unpack the latest version, then update the symlink to point to it. Additionally, change the directory ownership to the user and group tomcat using:
sudo chown -R tomcat: /opt/tomcat
After that, the shell scripts in Tomcat's bin directory need to be made executable.
sudo sh -c 'chmod +x /opt/tomcat/latest/bin/*.sh'
Open the text editor and create a tomcat.service unit file in the /etc/systemd/system/ directory.
sudo nano /etc/systemd/system/tomcat.service
2) After that, paste the following configuration in /etc/systemd/system/tomcat.service:
/etc/systemd/system/tomcat.service
[Unit]
Description=Tomcat 9 servlet container
After=network.target
[Service]
Type=forking
User=tomcat
Group=tomcat
Environment="JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64"
Environment="JAVA_OPTS=-Djava.security.egd=file:///dev/urandom -Djava.awt.headless=true"
Environment="CATALINA_BASE=/opt/tomcat/latest"
Environment="CATALINA_HOME=/opt/tomcat/latest"
Environment="CATALINA_PID=/opt/tomcat/latest/temp/tomcat.pid"
Environment="CATALINA_OPTS=-Xms512M -Xmx1024M -server -XX:+UseParallelGC"
ExecStart=/opt/tomcat/latest/bin/startup.sh
ExecStop=/opt/tomcat/latest/bin/shutdown.sh
[Install]
WantedBy=multi-user.target
Then, save and close the file. Notify systemd that a new file exists.
sudo systemctl daemon-reload
4) Once done, enable the Tomcat service and start it.
sudo systemctl enable --now tomcat
5) You will need to check the service status.
sudo systemctl status tomcat
Configure the Firewall
If you wish to access Tomcat from outside the local network, you must open port 8080. To do so, use the following command:
sudo ufw allow 8080/tcp
Open CMS
Installing OpenCms
Install Java
Install Tomcat 9
Install and configure a MySQL server
max_allowed_packet=256M
In Webmin
create user opencms
password
Do not work with root account on opencms!!
Download and deploy OpenCms 19
internationalization
kate /opt/tomcat/webapps/opencms/WEB-INF/config/opencms-system.xml
<internationalization>
<localehandler class="org.opencms.i18n.CmsDefaultLocaleHandler"/>
<localesconfigured>
<locale>en</locale>
<locale>de</locale>
<locale>pl</locale>
<locale>ru</locale>
</localesconfigured>
<localesdefault>
<locale>en</locale>
<locale>de</locale>
<locale>pl</locale>
<locale>ru</locale>
</localesdefault>
<timezone>GMT+01:00</timezone>
</internationalization>
Solr
Polish language to Solr
https://community.sap.com/t5/crm-and-cx-q-a/polish-language-to-solr/qaq-p/12021384
HunspellStemFilterFactory which the current version supports
https://support.sitecore.com/kb?id=kb_article_view&sysparm_article=KB1001661
To add a new language to solr, you need put additional fields in schema.xml file under yoursolrserver/solr/server/multicore/conf folder. This is achieved by copy-pasting what's already there for existing languages, for example the text fieldtype :
<fieldType name="text_pl" class="solr.TextField" positionIncrementGap="100">
<analyzer>
<tokenizer class="solr.StandardTokenizerFactory" />
<filter class="solr.StandardFilterFactory" />
<filter class="solr.LowerCaseFilterFactory" />
<filter class="de.hybris.platform.solrfacetsearch.ysolr.synonyms.HybrisSynonymFilterFactory" ignoreCase="true" synonyms="pl" coreName="${solr.core.name}"/>
<filter class="solr.WordDelimiterFilterFactory"
generateWordParts="1" generateNumberParts="1" catenateWords="1"
catenateNumbers="1" catenateAll="0" splitOnCaseChange="0" />
<filter class="de.hybris.platform.solrfacetsearch.ysolr.stopwords.HybrisStopWordsFilterFactory" ignoreCase="true" lang="pl" coreName="${solr.core.name}"/>
<filter class="solr.StopFilterFactory" words="stopwords_pl.txt" ignoreCase="true" />
<filter class="solr.ASCIIFoldingFilterFactory" />
<filter class="solr.SnowballPorterFilterFactory" language="Polish" />
</analyzer>
</fieldType>
Implementacja
/opt/tomcat/webapps/opencms/WEB-INF/solr/configsets/default/conf
/opt/tomcat/webapps/opencms/WEB-INF/solr/configsets/default/conf/schema.xml
<!-- Polish -->
<fieldType name="text_pl" class="solr.TextField" positionIncrementGap="100">
<analyzer>
<tokenizer class="solr.StandardTokenizerFactory"/>
<filter class="solr.LowerCaseFilterFactory"/>
<!-- <filter class="solr.StempelPolishStemFilterFactory"/> -->
</analyzer>
</fieldType>
<!-- Russian -->
<fieldType name="text_ru" class="solr.TextField" positionIncrementGap="100">
<analyzer>
<tokenizer class="solr.StandardTokenizerFactory"/>
<filter class="solr.LowerCaseFilterFactory"/>
<!-- <filter class="solr.StempelRussianStemFilterFactory"/> -->
</analyzer>
</fieldType>
<field name="text_pl" type="text_pl" indexed="true" stored="false" multiValued="true"/><!-- Catchall for PL text fields -->
<field name="text_ru" type="text_ru" indexed="true" stored="false" multiValued="true"/><!-- Catchall for RU text fields -->
<dynamicField name="*_pl" type="text_pl" indexed="true" stored="true" />
<dynamicField name="*_ru" type="text_ru" indexed="true" stored="true" />
<copyField source="*_pl" dest="text_pl"/>
<copyField source="*_ru" dest="text_ru"/>