top of page

TERRAFORM

  • Writer: Mukesh Chanderia
    Mukesh Chanderia
  • Jan 16, 2023
  • 1 min read

Lab Setup


Create three VMs of CentOS.


One will act as a controller and the rest two as workers.


Install ansible


rpm -qa | grep ansible


yum install ansible* - y


Step1: Ensure all three can communicate with each other.


Step2: Create "nmcli connection" on all three i.e. ansible-controller, worker1 & worker2


nmcli connection add con-name ansible-controller ifname ens33 type ethernet autoconnect yes


nmcli connection show


nmcli connection up ansible-controller


hostnamectl set-hostname ansible-controller


Step 3: Create DNS entry


vim/etc/hosts --> Create host entry for DNS


ansible-controller --> 10.0.0.1/24


Worker1 --> 10.0.0.2/24


Worker2 --> 10.0.0.3/24


Step 4: Find inventory file


ansible --version


config file = /etc/ansible/ansible.cfg


Go in config file to /etc/ansible/hosts and create host entry for worker.


10.0.0.2

10.0.0.3


Also, you may create group


[ web-server ]

10.0.0.2

[App-server]

10.0.0.3


Note: If username and password is defined in inventory file then it's else system will prompt for it.


List hosts present for ansible


ansible all --list --hosts









 
 
 

Recent Posts

See All
Wireshark

1. What is Wireshark? Wireshark is a network packet capture tool . It shows every packet of data moving through your network. Think of it...

 
 
 
MultiCast In ACI

Understanding Multicast in Cisco ACI 1. Multicast Traffic Flow in ACI In ACI, multicast traffic is primarily managed within Bridge...

 
 
 
Quality of Service (QoS) in Cisco ACI

Configuring Quality of Service (QoS)  in Cisco ACI (Application Centric Infrastructure)  involves creating and applying QoS policies that...

 
 
 

留言


Follow me

© 2021 by Mukesh Chanderia
 

Call

T: 8505812333  

  • Twitter
  • LinkedIn
  • Facebook Clean
©Mukesh Chanderia
bottom of page