Running performance tests against local webserver with Apache Bench.

How to install apache bench on RHEL 8

Apache Bench is a useful little tool for testing the response time of a webservice, and thus the performance of the webserver. We can specify the number of requests to send, the target URL, set up concurrency, just to name a few of this tool’s settings.

While such simulated workloads will not result exactly the same data that real world traffic will do, it is always a good idea to test before going to production. Maybe before deploying a new version of the application, we could run the tests on the new version, and compare the results with the previous test data to see if our application will serve slower, or faster than the last version. With well-planned testing, this tool can show the possible bottlenecks of the application, and may provide points of interest where we should look into our code for possible optimization.

In this tutorial we will install Apache Bench on Red Hat Enterprise Linux 8, as well as an Apache Webserver to run some tests against.

In this tutorial you will learn:

  • How to install Apache Bench
  • How to install httpd webserver, and add some basic content
  • How to run simple tests against the webserver

Read more

Querying system tables in Cassandra on RHEL 8

How to install cassandra on RHEL 8

Apache Cassandra is an open-source NoSQL database. One of it’s main features is it’s decentralized nature that gives unique fault tolerance. Having our data replicated across datacenters means our production will not suffer from the loss of one of our sites, something all sysadmins dream of (or really happy to have such setup).

In this tutorial we will install Cassandra on Red Hat Enterprise Linux 8 by adding the Cassandra repository, install the software, and set up all else needed to have our service up and running and easy to manage.

In this tutorial you will learn:

  • How to add Cassandra repository
  • How to install needed packages
  • How to repair systemd unit file
  • How to test Cassandra with cqlsh

Read more

Composer's main help.

How to install composer on RHEL 8

Composer is a dependency management tool for php, much like cpan for perl. If you have read the tutorial about installing cpan, the architecture will be somewhat familiar. Composer, as a command line tool is the client that can fetch and update the php libraries we mark as needed, as well as the libraries these depend on, etc.

The source of these libraries is packagist.org, a large public php package repository. We can browse the repository with a browser to find the packages we’d like to use, then include them in our projects with the help of Composer. And by solving the dependencies itself, Composer can make our lives much easier if we depend on external packages. In turn we can also share our libraries, so the community can access them trough Composer as well.

In this tutorial we will install Composer on Red Hat Enterprise Linux 8, and mark a package as needed dependency for our project, to see the tool working.

In this tutorial you will learn:

  • How to install Composer
  • How to define package as dependency
  • How to install dependencies with Composer

Read more

Installed Webmin on RHEL 8

How to install Webmin on RHEL 8 / CentOS 8

Webmin is web-based administrator’s tool that can manage many aspects of the system. After installation, we can manage our machine’s resources, the server applications running on it, set up cronjobs, just to name a few. It comes with it’s own http server, no additional container or webserver required. The rich function set is accessible trough a web interface, so all we need is a browser to manage our system remotely.

In this tutorial we will install Webmin on RHEL 8 / CentOS 8, add the necessary service file for easy management, and log in to the WUI (Web User Interface).

In this tutorial you will learn:

  • How to install Webmin from tarball
  • How to add and test systemd service file
  • How to access the web interface

Read more

Consuming messages on Kafka topic from the command line.

How to install kafka on RHEL 8

Apache Kafka is a distributed streaming platform. With it’s rich API (Application Programming Interface) set, we can connect mostly anything to Kafka as source of data, and on the other end, we can set up a large number of consumers that will receive the steam of records for processing. Kafka is highly scaleable, and stores the streams of data in a reliable and fault-tolerant way. From the connectivity perspective, Kafka can serve as a bridge between many heterogeneous systems, which in turn can rely on it’s capabilities to transfer and persist the data provided.

In this tutorial we will install Apache Kafka on a Red Hat Enterprise Linux 8, create the systemd unit files for ease of management, and test the functionality with the shipped command line tools.

In this tutorial you will learn:

  • How to install Apache Kafka
  • How to create systemd services for Kafka and Zookeeper
  • How to test Kafka with command line clients

Read more

The unlock page of Jenkins on first startup installation on RHEL 8 / CentOS 8

How to install Jenkins on RHEL 8 / CentOS 8

Jenkins is a widely-used open-source automation server that can be used to automate tasks from building to deploying software. It’s pipelines are easy to understand, and you can simply add tasks the same way you would execute them on the command line.

In this tutorial we will install Jenkins on RHEL 8 / CentOS 8, we’ll run the server by hand from the command line, install it as a standard service, and deploy it into an Apache Tomcat container.

In this tutorial you will learn:

  • How to run Jenkins by hand
  • How to install Jenkins as a service
  • How to deploy Jenkins into an Apache Tomcat container
  • How to unlock Jenkins
  • How to open the port on the firewall Jenkins is serving on

Read more

Stepping trough a for loop with gdb.

How to install gdb in RHEL 8

Gdb or GNU Project Debugger is a great tool when you need to debug a program. You can set breakpoints, watch for value change of a variable, or even change a value for the program while it is halted at a point of it’s state, then continue, just to pick some of the features of gdb.

In this tutorial we will install gdb on RHEL 8, and test how it is working with a simple C application.

In this tutorial you will learn:

  • How to install gdb
  • How to compile a simple C application with debug symbols
  • How to set breakpoints in the running application with gdb
  • How to print actual values of given variables within the application

Read more

Successful cpan perl module install with cpan on RHEL 8

How to install cpan on RHEL 8 / CentOS 8

Perl is a well-known programming language with long development history. The same long history provides the countless modules written in it, and distributed in various channels throughout the World Wide Web. As with most programming languages, if you implement something that you find useful, and maybe write it in a generic way, there are high chances others would find it useful too.

If you share your work with others, they don’t need to re-implement the wheel, they can spend time on other tools, thus making the community as a whole richer, and we have found the spirit of open source with a short walk. But as many people write perl modules, and perl runs on just about anything, it can be hard to find the module you are looking for, let alone build it in your environment. And that’s where cpan comes into play. CPAN itself is a large perl module repository, the cpan tool is a client that is able to fetch and compile needed modules to the local system.

In this tutorial we’ll install cpan on a RHEL 8 / CentOS 8, run the initial configuration, and install a module with this tool’s help.

In this tutorial you will learn:

  • How to install cpan
  • How to run initial configuration
  • How to install a perl module with cpan

Read more

Successful build with Maven.

How to install maven on RHEL 8 / CentOS 8

Maven is a handy project management tool for Java projects. It helps handling multiple projects, can integrate with various IDE (Integrated Development Environment) software, and above all, simplifies build processes. In this tutorial we will install maven on a RHEL 8 / CentOS 8 Linux system, and to test the tool, we’ll build and run a simple example application.

In this tutorial you will learn:

  • How to install Maven
  • How to create a basic project
  • How to build the project with Maven
  • How to test the built application

Read more

Example query in mongodb.

How to install mongodb on RHEL 8 / CentOS 8

MongoDB is a document database, storing data in JSON-like form, which is revolutionary approach in the contrast of traditional relational databases. This does not mean that SQL databases will die out anytime soon; they will be here for a long time when you need to store structured data.

That being said, MongoDB gets more and more use cases; the ability to store data in a form that can change on the fly are things that must be counted with.

In this tutorial we will install the latest community release of this NoSQL database to a RHEL 8 / CentOS 8, using the tarball package. For this to work smoothly we’ll set up the minimal environment, and test our configuration and running service.

In this tutorial you will learn:

  • How to download & extract MongoDB tarball
  • How to set up environment for the service
  • How to manage mongod service
  • How to login to mongo shell, insert and query sample data

Read more

Hello World example with Ruby.

How to install ruby on RHEL 8 / CentOS 8

Ruby is a very flexible scripting language, it’s popularity well-earned by it’s power. In this tutorial we will install Ruby on a RHEL 8 / CentOS 8, and write the famous “Hello World” program to test that our installation is working as intended. Note however, that with all languages, Ruby’s capabilities are far more than simple text printing on the command line.

In this tutorial you will learn:

  • How to install Ruby with dnf
  • How to get Ruby version information
  • How to write and run the “Hello World” example program in Ruby

Read more

Snmpd answer to remote query with snmpwalk.

How to install snmp on RHEL 8 / CentOS 8

SNMP (Simple Network Management Protocol) is widely used for monitoring and central management purposes. In this tutorial we will install the snmpd service to a RHEL 8 / CentOS 8 machine, enable autostart, and after starting the service, we will test the functioning service with snmpwalk running the default settings.

In this tutorial you will learn:

  • How to install snmp service
  • How to start and enable the service with systemd
  • How to open udp port 161 for remote access
  • How to test the service with snmpwalk from localhost and remove machine

Read more