YUM Configuration in RHEL7/ CentOS 7

YUM Configuration in RHEL7/ CentOS 7

We are going to see YUM Configuration in RHEL7/ CentOS 7 in this post.

In Linux mostly we are using RPM and Yum Package management.

YUM- Yellowdog Updater Modified

Yum is mostly used to install a package without fail by resolving software dependencies.

We can configure yum locally/in network

Required RPM:
1. Yum
2. Createrepo
3. deltarpm
4. python-deltarpm

Configuring YUM in RHEL7

1. Insert RHEL7 media and mount it under /mnt

#mount /dev/cdrom /mnt

2. All the RPM’s available under Packages directory. change to Package Directory and
copy all the RPM’s under any local directory which you have already created.

3. Creating local directory to use as repository

#mkdir /yumpkg

4. Copying RPM’s from media to local directory

#cd /mnt/Packages
#cp *.* /yumpkg

5. Ensure all the required RPM’s installed or not by using below commands

#rpm -qa yum
#rpm -qa createrepo

6. Generate local repository files from yumpkg and create xml file

#cp /mnt/repodata/59eXXXXXX.xml /yumpkg/comps.xml
#cd /yumpkg
#createrepo -g /yumpkg/comps.xml .
7. Create repo file

#vi /etc/yum.repos.d/yum.repo

:wq save and exit from yum.repo file

Note: For using ftp/http as repository, we must enter the concerns path in baseurl field

#yum clean all
#yum makecache

8. Now check yum by listing all available RPM’s

#yum list all

9. Than try to install any package using YUM

# yum install vsftp

Other commands of yum

#yum remove <package_name>
#yum update <package_name>
#yum search <package_name>
#yum info <package_name>
#yum list installed
#yum check-update
#yum update
yum groupinstall <package_name>

Two private IP’s not responding each other in Multicasting – Linux

Will fix Two private IP’s not responding each other in Multicasting – Linux issue in this post

Follow the below steps to fix Two private IP’s not responding each other in Multicasting – Linux:

1) Ping the private IP of node2 from node1
ping <PRV_IP_Node2>
2) Check whether the priv IP is added in /etc/hosts
cat /etc/hosts
3) Check whether the configuration is correct for the NIC device
cat etc/sysconfig/network-scripts/ifcfg-eth?
4) Check whether the routing is correct
route -n; netstat -nr
5) traceroute to the priv IP
traceroute <PRV_IP_Node2>
6) Check whether any Firewall is running
/etc/init.d/iptables status
7) Add routing for the host of PRIV_IP_Node2 & check response
8) Check the kernel parameter value of net.ipv4.conf.default.rp_filter
If it is 1 change it to 2
#net.ipv4.conf.default.rp_filter = 1
net.ipv4.conf.default.rp_filter = 2
net.ipv4.conf.all.rp_filter = 2
Do the above steps in Node 2 as well.
So that both the ways we get the reply

Cloud – Open Stack

Will talk about Cloud – Open Stack in this post.
What is Cloud ?

Cloud is loaded terminal. Cloud is convenient, on demand network access to a share pool of configurable computing service. that include application/services.



Cloud types:

Private cloud
Public cloud
Hybrid cloud

What is private cloud?

Private Cloud will provide all basic benefits of public cloud like below.
Service and scalability, multi-tenancy, ability to provision machines, changing computing resources ondemand and creating multiple machines for complete jobs.
In this cloud type limited people only will able to access web based apps/websites.


We need staffing system and will be handled and managed by third party service.


To reduce implementing Rack space and VMWare by deploying private cloud.

What is Public cloud?

Public cloud is a standard cloud computing. In this method service provider have to provide all the resources like application, Hardware’s,etc.. and
its available in public over the internet.
This service could be a free a service or payable service.


Expense is low because of provider will pay for hardware,application and bandwidth.
Easy to access.
Resources usage is low.

Example: Amazon Elastic Compute Cloud (EC2), Sun Cloud, Google AppEngine, etc…

What is Hybrid Cloud?

In hybrid cloud organizations will deploy their apps in Private and Public cloud both.
So, it’s maintained by both provider internal and external.

Dynamic or changeable applications using this module cloud. Application might be deployed in private cloud and it will access public cloud resources when the computing demand is high. To connect Private and Public cloud resources, hybrid cloud is required.

Other topics will be covered in next post

Configure network interface with multicast address in linux

In this post going to see how to configure network interface with multicast address in linux.
Multicast will send information to a group of destination simultaneously.
Most probably class D( – IP Address used in multicasting

Enable/ Disable Multicast:
Enabling Multicast:

#ifconfig eth0 multicast

once enabled check using #ifconfig eth0 command and you can find a line like below from the output of this command.


Disbaling muticast:

# ifconfig eth0 -multicast
follow the same command to check the status
# ifconfig eth0
UP BROADCAST MTU:1500  Metric:1

We could see there is no word mentioned in this output like “MULTICAST”
Check whether multicast enabled in Kernel or not.

#grep -i multi /boot/config-<Kernel version>
* CONFIG_IP_MULTICAST=y  #if “CONFIG_IP_MULTICAST” value mentioned as “n” then multicast disabled. We should make it as “y” (yes)

Configure Network interface to send muticast traffic over the network:
We should add a default gateway to multicast traffic, to the specific Network Interface. Use the below command to add default route

# route add -net netmask dev eth0

Then check the default route
#  route -n

You will get output like below
#  route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface       U     0      0        0 eth0

Command to check the multicast group in our host
# netstat -g
# cat proc/net/igmp

From the above commans will get output with multicast address for eth0 interface.
Now we configured a network interface with multicast address.

Chef server installation on linux

We are going to see Chef server installation on linux

Configuration options in Chef:


1. Standalone
2. High Availability
3. Tiered


1. Machine with RedHat server operating system with FQDN.
2. Mail agent which will help chef server to send notification.
3. Should know to work with cron jobs to schedule jobs

We are going to see Standalone chef server in this post.

In this method will use single machine for chef server installation.
1. Download “chef-server-core-<ver>” and kept under /tmp directory on a server which will run the server.
2. Install the package as root user using below commands.

#rpm -ivh chef-server-core-xxx.rpm

It will take some minutes to install it.

Execute the following server to start all services.

#chef-server-ctl reconfigure

Now we should create a user to manage the chef server

#chef-server-ctl user-create <username> <firstname> <lastname> <email> ‘Password’ –filename /path/uname.pem

Now we should create organization


#chef-server-ctl org-create short_name ‘full_organization_name’ –association_user user_name –filename ORGANIZATION-validator.pem

Download and install additional packages:
We can use Chef management console to manage the data bags, attributes, run-lists, roles, environments, and cookbooks from a web user interface.

Run below commands on chef server.

#chef-server-ctl install chef-manage
#chef-server-ctl reconfigure
#chef-manage-ctl reconfigure

We can use Chef push jobs to execute the jobs

Run the below commands on chef server.

#chef-server-ctl install opscode-push-jobs-server
#chef-server-ctl reconfigure
#opscode-push-jobs-server-ctl reconfigure

Use reporting will keep track while every client run on full infra.

Run the below commands on chef server:

#chef-server-ctl install opscode-reporting
#chef-server-ctl reconfigure
#opscode-reporting-ctl reconfigure

Update purchase for nodes:

While using more than 25 nodes, configuration should be updated by us for license.
for that, need to edit chef-server.rb file. follow the below steps to edit

#mkdir /etc/opscode && sudo touch /etc/opscode/chef-server.rb

open new chef-server.rb file
#vi /etc/opscode/chef-server.rb

append the below line on that file

#license[‘nodes’] = N (number of licensed nodes you have purchased)

save and exit from the file using :wq

run below command to update the modified changes on chef server

#chef-server-ctl reconfigure