CentrioHost Blog

Stories and News from IT Industry, Reviews & Tips | Technology Blog


Install SaltStack on CentOS

SaltStack is a open source configuration management used remote execution tool. With the use of remote execution system administrators can execute the programs and command from the master system named as salt to the agent system named as minions.Lets start

Requirements:-

Controller Machine (Salt-Master) :-

ip : 10.0.0.209

Node (Minion):-

ip: 10.0.0.206
hostname: minion1

Step 1 : Installing Salt-Master on controller machine:

Install the latest salt-master on your controller machine using YUM.

# yum install salt-master -y

After the installation finishes, modify the configuration file as below:

# vi/etc/salt/master

Find the given line and replace :

# interface: 0.0.0.0

to

interface: 10.0.0.209

Find the given line and replace :

#hash_type: md5

to

hash_type: sha256

Then save and quit using :wq!

Start and enable the salt-master service

# systemctl start salt-master.service
# systemctl enable salt-master.service

Step 2 :

Enable the default port of saltstack 4505-4506 in firewall.

# firewall-cmd --permanent --zone=public --add-port=4505-4506/tcp
# firewall-cmd –reload

Step 3 :
Install and configure the salt-minion on the nodes.

# yum install salt-minion

After the installation finishes, modify the configuration file as below:

# vi /etc/salt/minion

Find the given line and replace :

#master: salt

to

master: 10.0.0.209

Find the given line and replace :

#hash_type: md5

to

hash_type: sha256

Then save and quit using :wq!

Start and enable the salt-minion service

# systemctl start salt-minion.service
# systemctl enable salt-minion.service

Step 4 : Test the Saltstack working

From the SaltStack master server, input the following command to show all available agents:

# salt-key -L

If everything was successful, you will see the agent server “minion1” listed in the “Unaccepted Keys” segment.

Accepted Keys: 
Denied Keys: 
Unaccepted Keys: 
minion1 
Rejected Keys:

After it we need to accept “minion1” using this command:

# salt-key --accept=minion1

Step 5 : Test the Setup

# salt minion1 test.ping

The output show:

minion1: 
True 
Try the command also.
# salt minion1 cmd.run 'df -h'

Thankyou. Now you are successfully installed and configured saltstack

Subscribe Now

10,000 successful online businessmen like to have our content directly delivered to their inbox. Subscribe to our newsletter!

Archive Calendar

SatSunMonTueWedThuFri
 1
2345678
9101112131415
16171819202122
23242526272829
30 

Over 20000 Satisfied Customers!

  • web hosting reviewer
    Valerie Quinn
    CTO, Acteon Group

    Centriohost staff were fantastic, I had a concern with a domain and they got back to me very quickly and they helped me to resolve the issue! ~ . . . Read more

  • Joomla hosting reviewer
    Collin Bryan
    Photographer, Allister Freeman

    I'm using centrio for my portfolio since 2006. The transition was seamless, the support was immediate, and everything works perfectly. ~ . . . Read more

  • dedicated server reviewer
    Harry Collett
    Actor, A&J Artists

    Very easy to understand & use even though I am not very technologically minded. No complications whatsoever & I wouldn't hesitate to recommend it to all. ~ . . . Read more

  • vps web hosting reviewer
    Porfirio Santos
    Technician, Diageo PLC

    Centrio support team have been amazingly responsive and helpful to any of my queries, thank you so much to the Centriohost have been amazingly responsive and helpful to any of my queries 👍👍👍 ~ . . . Read more

  • wordpress hosting plans reviewer
    Catherine Auer
    Doctor, SmartClinics

    Anytime I've had a problem I can't solve, I've found Centriohost to be diligent and persistent. They simply won't let an issue go until the client is happy. ~ . . . Read more

  • reseller hosting reviewer
    Effectivo Social
    Freelancer, Fiverr

    Recommend their shared hosting for all my SME web design clients. Their cloud or VME offerings are too great to deal with. Pricing is perfect and suitable for all users (͠≖ ͜ʖ͠≖) 👌 ~ . . . Read more

Top