Showing posts with label Shell Script. Show all posts
Showing posts with label Shell Script. Show all posts

Tuesday, January 4, 2022

Given User is root user or not.. - Mithun Technologies - +91 99809 23226

 

Mithun Technologies            +91-9980923226              devopstrainingblr@gmail.com

                                                       http://mithuntechnologies.com/
                                                       http://mithuntechnologies.co.in/
 Write a Shellscript to given user is root user or not


#!/bin/bash      
#title                :
#description     :
#author             : Mithun Technologies
#date                : 08112012
#version           : 2.0    
#usage             :
#Copy Rights   : Mithun Technologies
#Contact          : 9980923226


echo "Please enter the user name"
read userName

if [ `id -u $userName` -eq 0 ]
then
echo "Give user is root user"
else
echo "Given user is not root user"
fi



Ansible Installation in Amazon Linux - Mithun Technologies - 9980923226

  Mithun Technologies            +91-9980923226              devopstrainingblr@gmail.com                                                 ...