Quick Guide to Install Kubernetes Cluster on RHEL 7 / Centos 7

Leave a Comment

Problem with Monolithic Application:

Integration and Deployment are not easy as there are lot of inter dependency, if all the services are running on  a single OS, then there might be conflicting libraries versions and application components. Even if Virtual Machines are used for applications, still there will be conflict, but what if each process could somehow be built to  made to run  on its own with its libraries and dependencies packaged within, thus each of these micro service can be debugged, deployed individually without causing harm to entire project. This is achieved using containers. However containers alone are not sufficient to manage containers in production at scale, where Orchestration system like Kubernetes eases the task.

Kubernetes is an open source Orchestration system for containers. It handles scheduling onto nodes in a compute cluster and actively manages them.

  • Kubernetes is inspired by Borg that is internal system used by Google 
  • Abbreviated as K8s
  • It is given to Open Source in June 2014 with apache license and having thousand of contributors worldwide.
  • Google donated K8s to Linux Foundation in 2015 under Cloud Native Computing Foundation.
  • Runs anywhere
  • There are lot of companies using and contributing to Kubernetes:

Architecture of  Kubernetes :

Below is the architecture of Kubernetes :

Kubernetes Pod:

Pod is group of one or more containers that are always co related, co scheduled and run in shared context, that makes the app.

Kubernetes doesn’t run containers directly; instead it is combination of one or more containers that is higher-level structure called pod.

Each Pod is isolated by

  • Process ID namespace
  • Network namespace
  • Unix Time sharing namespace
  • Inter Process communication namespace
kubectl get pods                                                                  - Get information about all running pods
kubectl describe pod <pod>                                                - Describe one pod
kubectl expose pod <pod> --port=444  --name=frontend   - Expose the port of a pod
kubectl port-forward <pod>  8080                                      - Port forward the exposed pod port to your local machine.
kubectl attach pod <podname> -i                                        - Attach to the pod
kubectl exec <pod> --command                                          - Execute a command on pod
kubectl label pods <pod> mylabel=bravo                           - Add a label to pod

Installation steps:

In this blog, i will list down the steps and commands for setting up a two node Kubernetes Cluster with one master and a worker node.

We need two Virtual Machine for this demo, one for Master node and one for worker node.

POD communication will be done using flannel network.

Create two Virtual Machine with RHEL or Centos 7 installed on them, i have used RHEL 7.5 for this demo.

Below steps are to be followed for installation of Kubernetes

Master Server  steps:

1. Make entry of master and worker VM/node in /etc/hosts file. 

#hostnamectl set-hostname 'k8s-master'

cat /etc/hosts k8s-master worker-1

2. Disable Selinux

# setenforce 0

# vi /etc/selinux/config

3. Stop and Disable firewalld 

# systemctl stop firewalld
# systemctl disable firewalld

4. Create the /etc/sysctl.d/k8s.conf file and add the following:

net.bridge.bridge-nf-call-ip6tables = 1
net.bridge.bridge-nf-call-iptables = 1
sysctl -p /etc/sysctl.d/k8s.conf
Run above command to make the kernel parameters persistent. In case you are getting any error after running  sysctl -p command, make sure bridge modules is loaded in the kernel using lsmod command. Use modprobe to load the missing modules

5.  Disable Swap memory by editing /etc/fstab file and commenting the swap memory entry.

6. Create the repository kubernetes.repo using below

cat <<EOF > /etc/yum.repos.d/kubernetes.repo

7. Install Docker and kubeadm 

yum install docker kubeadm -y 

8. Enable and start the docker and kubelet service.

 systemctl restart docker
 systemctl enable docker

 systemctl  restart kubelet
 systemctl enable kubelet
9.  Create Cluster using below command

We are using flannel network for this demo

Run below command to create cluster along with CIDR

kubeadm init --pod-network-cidr=
Once,it is done, you need to run below commands.

Your Kubernetes master has initialized successfully!

To start using your cluster, you need to run the following as a regular user:

  mkdir -p $HOME/.kube
  sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
  sudo chown $(id -u):$(id -g) $HOME/.kube/config

Make a note of the kubeadm join command that will be used for adding the worker nodes to the cluster

10.  Use below command to apply the flannel network 

kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/v0.9.1/Documentation/kube-flannel.yml

[root@k8s-master ~]# kubectl get cs
NAME                 STATUS    MESSAGE              ERROR
scheduler            Healthy   ok
controller-manager   Healthy   ok
etcd-0               Healthy   {"health": "true"}
[root@k8s-master ~]#

[root@k8s-master ~]# kubectl get nodes
k8s-master   NotReady   master   5m47s   v1.12.3

[root@k8s-master ~]# kubectl get pods --all-namespaces
NAMESPACE     NAME                                 READY   STATUS    RESTARTS   AGE
kube-system   coredns-576cbf47c7-8ndcd             1/1     Running   0          44m
kube-system   coredns-576cbf47c7-rqd2l             1/1     Running   0          44m
kube-system   etcd-k8s-master                      1/1     Running   0          7s
kube-system   kube-apiserver-k8s-master            1/1     Running   0          9s
kube-system   kube-controller-manager-k8s-master   1/1     Running   0          11s
kube-system   kube-proxy-tjn29                     1/1     Running   0          44m
kube-system   kube-scheduler-k8s-master            1/1     Running   0          12s
kube-system   weave-net-wv64p                      2/2     Running   0          36s
[root@k8s-master ~]#

Adding nodes to Cluster 

Use the same steps as done in Master node and install docker and kubeadm to worker node/VM

Get the  Node join command from the master node and run the same on the worker nodes. In case you don't have join command same can be retrieved using below

kubeadm token create --print-join-command

Once  worker node  is added to cluster, run below command to check the cluster status.

[root@k8s-master ~]# kubectl get nodes
k8s-master   Ready      master   2d18h   v1.12.3
worker-1     NotReady   <none>   27s     v1.12.3
[root@k8s-master ~]#


What are the plagiarism tools available for Hindi Blogging ?

Leave a Comment
For bloggers, Content is very important  aspect and every blogger always ensure that their content is not copied or stolen by any other blogger. Copying the  whole content or a blog post  or few paragraphs is termed as Plagiarism.  There are many tools available online to check Copied content, however not all are compatible with Hindi Language. In this post, we will list some of the popular tools available online for Hindi Bloggers.

Plagiarism is very important thing to  keep in mind if you are concerned about SEO and your blog's search engine rankings. If the website or blog's content is unique and not posted anywhere else, then its good for your blogs SEO. If you have enabled Guest blogging for your blog then, make sure you must scan the guest posts before publishing them on your blog.

Smartseo tools offers very good tool for checking Copied content for both Hindi and English Language. Interface is simple, Just paste the content to be checked and Click on Check Plagiarism button. Also, you can upload a document or file from Cloud storage like Dropbox or google drive.
URL based plagiarism check is also supported.

Copyscape is one of the oldest website to check for duplicate content. On the home page of this website, you will see a box where you can paste  the website link or your blog URL that need to be checked. In return, it will show the websites that are using or have copied your content.

Copyscape premium  which is paid tool offers the more advanced  option to check copied content offline by copying and
pasting the content to be searched. It can check upto 1000 pages in a single go.

Plagiarisma is another tool to check for duplicate content online.

 Check for more tools available Online  - Check out this post.


Top 7 UPI Apps for Fast Money Transfer - Send and Receive Money Instantly

Leave a Comment
UPI (Unified Payments Interface) Apps have made the money transfer process very simple these days. Launched back in 2017 and became much popular after the demonetization, they have shown tremendous growth and have revolutionized the way of making payments.

Unlike Mobile Wallets that holds money, UPI is a mechanism that allows instant money transfer between two accounts. Also, you can check your balance using UPI apps easily anytime. For using UPI apps make sure that your mobile number is linked to your bank account.

Here is the List of UPI Apps available

1. BHIM App

It is the first UPI app that was launched back in  December 2016, Bhim App is developed by National Payments Corporation of India. It is compatible for Android 4.2 and above and IOS 8.1 and above. User interface is simple with white background. This app also offers service like Bill Payment, DTH, Utility bills etc. This app aims at promoting Cashless and e-payments transfer and it is really successful.

Also read : Best Food Delivery apps 

2. Google Pay (Formerly Tez)

My Personal Favorite app, developed by Google. Earlier it was known as Tez and on completion of one year it was renamed as Google Pay.

Interface is really nice with Tez mode for sending or receiving money and the best part is reward earned with the transactions done using this app. After every transaction, you will get a scratch card that will we reward going straight to your bank account.

Also, you can pay your utility bill, recharges, payments to merchants using Google Pay.

They also have referral program by which you and your friend can earn Rs 51  by signing up using referral code and doing first successful transaction.

Join me on Google Pay, a payments app by Google. Enter my code (7G33u) and then make a payment. We'll each get ₹51!  https://g.co/payinvite/7G33u

3. PhonePe

PhonePe is growing at a great pace and founded back in 2015 and later accquired by Flipkart. Phonepe is another great UPI alternative that can be used for e-payments, money transfer , Utility bills, prepaid and postpaid bill payments.

You can earn Rs 100 cashback on signing up and after first money transfer.

Sign up now : https://phon.pe/ru_himatb2gj

4. SBI Pay

Bhim SBI Pay is dedicated app by SBI that  can help you to send, receive, transfer money, online bill payments, recharges and payment for shopping. SBI pay is offering cashbacks on Flights, hotel and bus bookings

5 . Paytm : 

Paytm is very much popular among Indians, Wallet and e-commerce website launched their UPI in November 2017. Operates like all other UPI apps, UPI id looks like mobile-number@paytm. You can send upto 1 Lakh using Paytm UPI.

6. Mobikwik

Mobikwik also offers UPI and was rolled out in May 2018, Mobikwik Users can use their default phone numbers as VPA  that is like <mobile-number>@ikwik.

7. FreeCharge :

Works like all other UPI apps, Freecharge started BHIM UPI S service  in 2018.


How to Hotlist or Block your HDFC Debit card / ATM Card Online using Netbanking

Leave a Comment
In case you have lost your HDFC  Debit Card / ATM Card or the same is damaged or you don't need the same anymore. There is an option to Block/ Hotlist your debit card. It can be done using Phonebanking but Phonebanking process is not so smooth, I found Netbanking method can help you to do the same in minutes, In this post,i will show you the process to Block or Hotlist your debit card online using Netbanking. Netbanking is a necessary requirement to block/hotlist Debit Card.

There are three methods to Block HDFC Debit Card

A.  By using Netbanking
B.  By using Phonebankinh
C.  By visiting HDFC bank Branch,

This blog post covers the steps to  block HDFC debit card using method A  (by using Netbanking)

Steps to Block or Hotlist your HFC Debit Card Online using Netbanking

Below is the process of Blocking your HDFC Debit Card.

1. Login to Netbanking using your Netbanking ID/ Customer ID and password.

2. At the top menu, there is a Cards option, Click on Cards.

3. At the left side menu, there will be Debit Card section. In that go to Request -- then Choose Debit Card hotlisting.

4. It will display all the Debit Cards linked to your account.

4.  Select and click on the Card number that you want to block/Hotlist.

5. Choose the reason and click on Confirm and you will be get below notification on your screen.

So, by using above steps you can easily block your HDFC debit cards in a minute, hassle free. There are another options to Block Debit Card using Phonebanking and personally visiting the bank branch.

Also read :  Online Transaction failed, but amount debited/deducted from account. What to do?


IPv6 Address Format

Leave a Comment
IPv6  or Internet Protocal Version 6 is the next generation protocol for Internet communication. INTERNET - World's largest public data network is doubling in size every 9 months.The internet have seen tremendous growth in terms of devices accessing the Internet, due to which IPv4 address are running out and IPv6 which provide huge number of address space came to rescue to cope up with rising IP demands of growing Internet and network devices. 

Many methods were adopted to ease and diminish the depletion of IPv4 like NAT, Subnetting, CIDR and these methods are not sufficient to ensure scalability for future demands.

So, the major advantage of IPv6 is it has larger IP address space. IPv6 has 128 bit address space compared to 32 bit address space of IPv4. IPv6 offers 3.4 x 10^38 addresses compared to 4.3 billion addresses of IPv4

Ip address in Ipv6 is separated in two parts:

1. Network Prefix
2. Interface /Host ID

Format and Length of IPv6:

8 sections of 4 hex number separated by colon

Full Address: 1224:1532:26B1:CC14:123:1111:2222:3333/64
Network Prefix ID:  1224:1532:26B1:CC14:
Host ID/  Interface id :    123:1111:2222:3333

The /64 indicates that the first 64 bits of this address identify the prefix.


How to generate ambigrams online or offline using these Free Websites

Leave a Comment
In our earlier post, we have mentioned What is Ambigram and how we can generate cools Ambigrams online easily. You can read previous post by clicking here.

Earlier we mentioned top tools like Flipscript and Ambimatic to generate cool ambigrams absolutely free.

Please check out our previous post as well.

A bit of imagination, creativity and lot of doodling can help you get started with creating Cool ambigrams, Calligraphy and  Font selection are very important tools  that can help you create amazing ambigrams.

Some other tools to Make Ambigrams online :

graffiti-alphabet.net :

This is Online graffiti generator, choose your words and type them in the text box, After that select your graffiti fonts and color and click on Generate Graffiti and you are done. There are several cool fonts to choose from and you can use these creative font styles for making tattoos or download them.

Font meme :

This is another superb website.Enter the text that you want to convert in the form of ambigram, Select a font, Select Font size and Select an effect, color and click on Generate and it will create beautiful ambigram for you. They have collected several ambigram fonts that you can try . They have two fonts Lake reflection and One 80, both are good and must try.

You can access the website by visit at  Fontmeme


It can be used by newbies and professionals and results in ambigram for texts in a second. You can try trulyscience online as well download it for offline use.

Visit the Website

Do comment below some other useful tools that can be used for generating Cool Ambigram styles.


How to Create LUKS encrypted partition in Centos 7 / RHEL 7 Linux

Leave a Comment
In this post, i will tell how to encrypt data stored on your Linux machine partitions using cryptsetup utility.

Firstly, Install the cryptsetup binary (LUKS) package using yum on your Centos 7 or RHEL 7 Linux machine.

[root@techbuzz ~]# yum install -y cryptsetup

Loaded plugins: product-id, search-disabled-repos, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
Skipping unreadable repository '/etc/yum.repos.d/rhel7_errata.repo'
Package cryptsetup-1.7.2-1.el7.x86_64 already installed and latest version
Nothing to do
[root@techbuzz ~]#

Activate LUKS module by running  modprove dm_crypt and after that check that module is loaded in the kernel.

[root@techbuzz ~]#  modprobe dm_crypt

[root@techbuzz ~]# lsmod | grep dm_crypt

dm_crypt               27403  0
dm_mod                114430  25 dm_log,dm_persistent_data,dm_mirror,dm_bufio,dm_crypt,dm_thin_pool
[root@techbuzz ~]#

Run below command to check free space in Volume group 

[root@techbuzz ~]# vgs

  VG   #PV #LV #SN Attr   VSize  VFree
  rhel   1   5   0 wz--n- 99.51g 3.82g

Create a Logical Volume of 100 mb using below command 

[root@techbuzz ~]# lvcreate --size 100M --name lv_vol rhel

Sample outputs:

  Logical volume "lv_vol" created.
[root@techbuzz ~]# lvs | grep lv_vol
  lv_vol    rhel -wi-a----- 100.00m
[root@techbuzz ~]#

Run below command to convert the newly created Logical volume into LUKS format. Enter the passphrase that should not be weak one and must contain Upper case / alphanumeric characters.

[root@techbuzz ~]# cryptsetup luksFormat /dev/rhel/lv_vol
Sample outputs:

This will overwrite data on /dev/rhel/lv_vol irrevocably.

Are you sure? (Type uppercase yes): YES
Enter passphrase:
Verify passphrase:

Open and give the LUKS format LV name as volume. You can given any name you want.

[root@techbuzz ~]# cryptsetup luksOpen /dev/rhel/lv_vol volume
Enter passphrase for /dev/rhel/lv_vol:
[root@techbuzz ~]#

Create any File system you want ext4 or xfs here using mkfs command.

[root@techbuzz ~]#  mkfs.xfs /dev/mapper/volume
Sample outputs:
meta-data=/dev/mapper/volume     isize=512    agcount=4, agsize=6272 blks
         =                       sectsz=512   attr=2, projid32bit=1
         =                       crc=1        finobt=0, sparse=0
data     =                       bsize=4096   blocks=25088, imaxpct=25
         =                       sunit=0      swidth=0 blks
naming   =version 2              bsize=4096   ascii-ci=0 ftype=1
log      =internal log           bsize=4096   blocks=855, version=2
         =                       sectsz=512   sunit=0 blks, lazy-count=1
realtime =none                   extsz=4096   blocks=0, rtextents=0
[root@techbuzz ~]#

Create below file and add below entry in the same :

[root@techbuzz ~]# vi /etc/crypttab

VOLUME_NAME  /dev/vg/lv_name /root/luks.key

[root@techbuzz ~]# cat /etc/crypttab
volume /dev/rhel/lv_vol /root/luks.key
[root@techbuzz ~]#

Create the /root/luks.key file and store the passphrase.

[root@techbuzz ~]# vi /root/luks.key

[root@techbuzz ~]# cryptsetup luksAddKey /dev/rhel/lv_vol /root/luks.key

Enter any existing passphrase:

Modify the /etc/fstab as below. last two options in fstab are for backup dumps and file system check at the time of boot.

/dev/mapper/volume     /vol     xfs    defaults   0  0

[root@techbuzz ~]# mkdir -p /vol
[root@techbuzz ~]# mount /vol

[root@techbuzz ~]# df -h /vol
Filesystem          Size  Used Avail Use% Mounted on
/dev/mapper/volume   95M  5.1M   90M   6% /vol
[root@techbuzz ~]#