How To Install tomcat-native on CentOS 8
Introduction
In this tutorial we learn how to install tomcat-native
on CentOS 8.
What is tomcat-native
Tomcat can use the Apache Portable Runtime to provide superior scalability, performance, and better integration with native server technologies. The Apache Portable Runtime is a highly portable library that is at the heart of Apache HTTP Server 2.x. APR has many uses, including access to advanced IO functionality (such as sendfile, epoll and OpenSSL), OS level functionality (random number generation, system status, etc), and native process handling (shared memory, NT pipes and Unix sockets). This package contains the Tomcat native library which provides support for using APR in Tomcat.
We can use yum
or dnf
to install tomcat-native
on CentOS 8. In this tutorial we discuss both methods but you only need to choose one of method to install tomcat-native.
Install tomcat-native on CentOS 8 Using dnf
Update yum database with dnf
using the following command.
sudo dnf makecache --refresh
The output should look something like this:
CentOS Linux 8 - AppStream 43 kB/s | 4.3 kB 00:00
CentOS Linux 8 - BaseOS 65 kB/s | 3.9 kB 00:00
CentOS Linux 8 - ContinuousRelease 43 kB/s | 3.0 kB 00:00
CentOS Linux 8 - Extras 23 kB/s | 1.5 kB 00:00
CentOS Linux 8 - FastTrack 40 kB/s | 3.0 kB 00:00
CentOS Linux 8 - HighAvailability 36 kB/s | 3.9 kB 00:00
CentOS Linux 8 - Plus 24 kB/s | 1.5 kB 00:00
CentOS Linux 8 - PowerTools 50 kB/s | 4.3 kB 00:00
Extra Packages for Enterprise Linux Modular 8 - x86_64 13 kB/s | 9.2 kB 00:00
Extra Packages for Enterprise Linux 8 - x86_64 24 kB/s | 8.5 kB 00:00
Metadata cache created.
After updating yum database, We can install tomcat-native
using dnf
by running the following command:
sudo dnf -y install tomcat-native
Install tomcat-native on CentOS 8 Using yum
Update yum database with yum
using the following command.
sudo yum makecache --refresh
The output should look something like this:
CentOS Linux 8 - AppStream 43 kB/s | 4.3 kB 00:00
CentOS Linux 8 - BaseOS 65 kB/s | 3.9 kB 00:00
CentOS Linux 8 - ContinuousRelease 43 kB/s | 3.0 kB 00:00
CentOS Linux 8 - Extras 23 kB/s | 1.5 kB 00:00
CentOS Linux 8 - FastTrack 40 kB/s | 3.0 kB 00:00
CentOS Linux 8 - HighAvailability 36 kB/s | 3.9 kB 00:00
CentOS Linux 8 - Plus 24 kB/s | 1.5 kB 00:00
CentOS Linux 8 - PowerTools 50 kB/s | 4.3 kB 00:00
Extra Packages for Enterprise Linux Modular 8 - x86_64 13 kB/s | 9.2 kB 00:00
Extra Packages for Enterprise Linux 8 - x86_64 24 kB/s | 8.5 kB 00:00
Metadata cache created.
After updating yum database, We can install tomcat-native
using yum
by running the following command:
sudo yum -y install tomcat-native
How To Uninstall tomcat-native on CentOS 8
To uninstall only the tomcat-native
package we can use the following command:
sudo dnf remove tomcat-native
tomcat-native Package Contents on CentOS 8
/usr/lib/.build-id
/usr/lib/.build-id/46
/usr/lib/.build-id/46/5e512bbf3f0512a448404f5a3a5a3d36ef473e
/usr/lib64/libtcnative-1.so
/usr/lib64/libtcnative-1.so.0
/usr/lib64/libtcnative-1.so.0.2.23
/usr/share/doc/tomcat-native
/usr/share/doc/tomcat-native/CHANGELOG.txt
/usr/share/doc/tomcat-native/TODO.txt
/usr/share/licenses/tomcat-native
/usr/share/licenses/tomcat-native/LICENSE
/usr/share/licenses/tomcat-native/NOTICE
References
Summary
In this tutorial we learn how to install tomcat-native
on CentOS 8 using yum and dnf.