How to remove hidden files in Linux

n Linux, hidden files are files that begin with a dot (.) character. To remove hidden files in Linux, you can use the rm command with the -r flag to recursively remove the files and the -f flag to force removal. Here is an example command that removes all hidden files in the current directory: … Read more

How to install and setup PostgreSQL on RHEL 8

To install and set up PostgreSQL on RHEL 8, you can follow these steps: Enable the PostgreSQL repository by running: sudo dnf install https://download.postgresql.org/pub/repos/yum/reporpms/EL-8-x86_64/pgdg-redhat-repo-latest.noarch.rpm Install the PostgreSQL server package by running: sudo dnf install postgresql12-server Initialize the database by running: sudo /usr/pgsql-12/bin/postgresql-12-setup initdb Start and enable the PostgreSQL service by running: sudo systemctl start postgresql-12 … Read more

How to set up a firewall using FirewallD on RHEL 8

Setting up a firewall using FirewallD on Red Hat Enterprise Linux 8 (RHEL 8) is a fairly straightforward process. Here’s an overview of the steps you’ll need to take: Start by installing FirewallD by running the following command: sudo dnf install firewalld Once the installation is complete, start the FirewallD service: sudo systemctl start firewalld … Read more

How to install and use Nginx on OpenSUSE Linux server

Installing and using Nginx on OpenSUSE Linux server is a fairly straightforward process. Here’s an overview of the steps you’ll need to take: Start by adding the Nginx repository to your system. You can do this by running the following command: sudo zypper addrepo -f http://download.opensuse.org/repositories/server:/http/openSUSE_Leap_15.2/server:http.repo Update the package list by running the following command: … Read more

How To Install MariaDB on RHEL 8

Installing MariaDB on Red Hat Enterprise Linux 8 (RHEL 8) is a fairly straightforward process. Here’s an overview of the steps you’ll need to take: Start by adding the MariaDB repository to your system. You can do this by running the following command: sudo dnf config-manager –add-repo https://downloads.mariadb.com/MariaDB/mariadb_repo.cfg Install MariaDB by running the following command: … Read more

How to update OpenSUSE Linux software and kernel using CLI

To update OpenSUSE Linux software and kernel using the command line, you can use the “zypper” command. First, update the package index by running: sudo zypper refresh Then, update all installed packages by running: sudo zypper update You can also update specific packages by specifying their names after the “update” command. To update the kernel, … Read more

Define ssh key per host using ansible_ssh_private_key_file

You can define an SSH key per host using the ansible_ssh_private_key_file variable in Ansible. This variable allows you to specify a different private key file for each host or group of hosts. Here is an example of how you can use the ansible_ssh_private_key_file variable in your inventory file: [web-servers] web1 ansible_host=192.168.1.100 ansible_ssh_private_key_file=~/.ssh/web1.pem web2 ansible_host=192.168.1.101 ansible_ssh_private_key_file=~/.ssh/web2.pem … Read more