How to Install Cockpit Web Console on RHEL 9

Cockpit is a web-based interface or GUI for managing Linux servers. It provides a simple and intuitive interface that allows admins to easily perform various system administration tasks, such as managing services, monitoring resource usage, and configuring network settings.

In this post, we will cover how to install Cockpit Web Console on Red Hat Enterprise Linux (RHEL) 9.

Prerequisites

  • Pre-Installed RHEL 9
  • A Regular User with Admin Rights or Root User
  • Locally Configure Yum Repository or Red Hat Subscription

Without any further delay, let’s deep dive into cockpit installation steps.

1) Install Cockpit Package

Cockpit package and its dependencies are available in the default RHEL 9 yum repositories. So, it’s installation is straight forward, open terminal and run following dnf command.

$ sudo dnf install cockpit -y

dnf-install-cockpit-rhel9

If you wish to manage KVM virtual machines using cockpit console then install following,

$ sudo dnf install cockpit-machines -y

In addition, if you want to manage podman containers from cockpit console, then install following,

$ sudo dnf install cockpit-podman -y

Install-cockpit-podman-rhel9

2) Start Cockpit Service

Once the package is installed, we need to enable the Cockpit service so it can automatically start on boot. To do this, run the following command:

$ sudo systemctl start cockpit

Run following systemctl command to verify it’s service

$ sudo systemctl status cockpit

Output,

Cockpit-Service-Status-RHEL9

3) Configure Firewall Rule for Cockpit

Cockpit runs on port 9090 by default. If you have a firewall enabled on your server, you will need to open this port to allow access to the web console. To do this, run the following commands:

$ sudo firewall-cmd --add-port=9090/tcp –permanent
$ sudo firewall-cmd –reload

4) Access Cockpit Web Console

Now that the Cockpit service is enabled and the firewall is configured, you can access the web console by navigating to the following URL in your web browser:

https://<Your-Server-IP>:9090

Access-cockpit-webconsole-rhel9

Click on “Accept the Risk and Continue

You will be prompted to enter your server’s root or a user with sudo privileges credentials.

Cockpit-WebConsole-Login-Screen-RHEL9

Once you are logged in, you will see the Cockpit dashboard which provides an overview of your server’s status and performance.

Cockpit-WebConsole-Dashboard-RHEL9

To perform administrative tasks, click on “Turn on administrative access”, it will prompt you to enter user’s password. After entering the credentials we will get following dashboard.

RHEL9-Cockpit-WebConsole-GUI

From here, you can manage various aspects of your server, including system updates, application, virtual machine, containers, storage, networking, and services.

Conclusion:

Cockpit is a powerful GUI tool that allows you to easily manage and monitor your RHEL 9 server from a web browser. With its user-friendly interface and powerful features, Cockpit can save you time and make it easier to perform common system administration tasks.

Also Read: 16 Quick SCP Command Examples in Linux

Leave a Comment

twelve + thirteen =