How to Setup SaltStack Master and Minion on Rocky Linux

 

 

SaltStack is a powerful configuration management and orchestration tool used to manage servers and applications. In this guide, we will walk you through the steps to set up a SaltStack Master and Minion on Rocky Linux. Whether you are deploying it on a local server or using a Windows VPS UK, this tutorial covers all the necessary steps.

Step 1: Update Your System

Before installing SaltStack, ensure your system is up to date. Run the following commands:

sudo dnf update -y

Keeping your system updated is crucial for security and performance, whether you're setting it up locally or on a VPS Windows Servers platform.

Step 2: Install SaltStack Master

To install the SaltStack Master, run the following command:

sudo dnf install salt-master -y

This command will download and install the Salt Master along with its dependencies.

Step 3: Configure Salt Master

Open the Salt Master configuration file for editing:

sudo nano /etc/salt/master

You can adjust the configuration according to your needs. For example, set the file_roots section to define where your Salt states will be stored:


file_roots:
  base:
    - /srv/salt
            

Save and exit the file.

Step 4: Start the Salt Master Service

Start the Salt Master service and enable it to run on boot:

sudo systemctl start salt-master
sudo systemctl enable salt-master

Step 5: Install SaltStack Minion

Now, you need to install the Salt Minion on the client machines that you want to manage. Run the following command on each Minion:

sudo dnf install salt-minion -y

Step 6: Configure Salt Minion

Open the Salt Minion configuration file for editing:

sudo nano /etc/salt/minion

Set the master option to the IP address or hostname of your Salt Master:

master: 

Save and exit the file.

Step 7: Start the Salt Minion Service

Start the Salt Minion service and enable it to run on boot:

sudo systemctl start salt-minion
sudo systemctl enable salt-minion

Step 8: Accept the Minion Key on the Master

On the Salt Master, you need to accept the Minion's key to allow it to communicate. Run the following command on the Master:

sudo salt-key -A

This will accept all pending Minion keys. You can also accept keys individually if you prefer.

Step 9: Test the Setup

To test if the Minion is communicating with the Master, run the following command on the Master:

sudo salt '*' test.ping

You should see a response from all connected Minions indicating that they are reachable.

You have successfully set up a SaltStack Master and Minion on Rocky Linux, allowing you to manage your servers effectively. For reliable and scalable hosting solutions, consider using Windows VPS UK. They offer a variety of hosting options, including windows virtual private servers, windows vps hosting, and windows virtual dedicated server hosting. Whether you're looking for windows vps italy or uk vps windows solutions, their hosting services provide the performance and flexibility needed to support your automation needs.

  • 0 A felhasználók hasznosnak találták ezt
Hasznosnak találta ezt a választ?

Kapcsolódó cikkek

Boost Your Ubuntu System's Performance with a Swap File: A Step-by-Step Guide

What is a Swap File? A swap file in Ubuntu serves as dedicated virtual memory on your hard...

How to Migrate ISPConfig 2, ISPConfig 3.x, Confixx, CPanel or Plesk to ISPConfig 3.2 (single server)

Introduction Migration from other control panels like ISPConfig 2, ISPConfig 3.x, Confixx,...

How to Install and Configure Zabbix Server and Client on Rocky Linux 9

Introduction Zabbix is an open-source monitoring solution that provides real-time...

How to Install CockroachDB Cluster on Debian 12

Introduction CockroachDB is a distributed SQL database built to handle large-scale,...

How to Install Joomla with Apache and Let's Encrypt SSL on AlmaLinux 9

Introduction Joomla is a popular open-source content management system (CMS) used to build...