Search This Blog

Thursday, April 8, 2010

How to reboot Linux server



# shutdown [-option] [ +Time [ Message ] ] ## man shutdown to find more the option

HPUX/AIX/SOLARIS/LINUX/TRU64 Pre-checking before reboot





Capture the system details

# bdf > /tmp/bdf.txt ## For HPUX

OR

# df –k > /tmp/df.txt ## For other OS

# netstat –in > /tmp/netstat.in.txt

# netstat –rn > /tmp/netstat.rn.txt

# lanscan > /tmp/lanscan.txt ## For HPUX

# ioscan –fn > /tmp/ioscan.txt ## For HPUX

# ps –ef | grep –i sap ## Double confirm no SAP running

# ps –ef | grep –I oracle ## Double confirm no Database running

AIX, SOLARIS, LINUX, TRU64 How to check disk space:





# df -k /var ## to check disk utilisation for /var filesystem

# find /var -xdev -type f -size +5000000c -exec ls -l {} \; | sort -nk 5 ## to find larger files in /var

HPUX How to check disk space: (using /var as example)





# bdf /var ## to check disk utilisation for /var filesystem

# find /var -xdev -type f -size +5000000c -exec ls -l {} \; | sort -nk 5 ## to find larger files in /var

TRU64 How to check CPU/Memory usage:





# vmstat OR iostat OR top ## to check CPU/Memory utilisation



· Find large processes which currently filled up the CPU/Memory usage.

LINUX How to check CPU/Memory usage:





# sar OR vmstat OR iostat OR top ## to check CPU/Memory utilisation



· Find large processes which currently filled up the CPU/Memory usage.

SOLARIS How to check CPU/Memory usage:





# sar OR vmstat OR iostat ## to check CPU/Memory utilisation



· Find large processes which currently filled up the CPU/Memory usage.

AIX How to check CPU/Memory usage:





# sar OR vmstat OR iostat OR topas ## to check CPU/Memory utilisation



· Find large processes which currently filled up the CPU/Memory usage.

HPUX How to check CPU/Memory usage





# glance OR top OR vmstat OR iostat OR sar

## to check CPU/Memory utilisation



· Find large processes which currently filled up the CPU/Memory usage.

How to check Ignite version in HP-UX


Command below can be used to find what is the version of Ignite installed in our server

shah@nxxx07:(shah)> more /opt/ignite/Version
C.7.1.93

C.7.1.93 is the version of installed Ignite :-)

How to get runlevel information in HP-UX


[hpa50-16]/ >who -r
. run-level 3 Apr 9 06:23 3 0 S

How to check software information in HP-UX


To check software information in HP-UX is simple. Just type swlist or /usr/sbin/swlist

[hpa50-16]/ >swlist
# Initializing...
# Contacting target "hpa50-16"...
#
# Target: hpa50-16:/
#

#
# Bundle(s):
#

B8342AA B.11.11.05 Netscape Communicator 4.75
BUNDLE11i B.11.11.0102.2 Required Patch Bundle for HP-UX 11i, February 2001
Base-VXVM B.03.20.1 Base VERITAS Volume Manager 3.2 for HP-UX
CDE-English B.11.11 English CDE Environment
FDDI-00 B.11.11.02 PCI FDDI;Supptd HW=A3739A/A3739B;SW=J3626AA
FibrChanl-00 B.11.11.09 PCI/HSC FibreChannel;Supptd HW=A6684A,A6685A,A5158A,A6795A
GOLDAPPS11i B.11.11.0112.6 Gold Applications Patches for HP-UX 11i, December 2001
GOLDBASE11i B.11.11.0112.6 Gold Base Patches for HP-UX 11i, December 2001
GigEther-00 B.11.11.14 PCI/HSC GigEther;Supptd HW=A4926A/A4929A/A4924A/A4925A;SW=J1642AA
GigEther-01 B.11.11.02 PCI/PCI-X GigEther;Supptd HW=A6794A
HPUX11i-OE-Ent B.11.11.0203 HP-UX Enterprise Operating Environment Component
HPUXBase64 B.11.11 HP-UX 64-bit Base OS
HPUXBaseAux B.11.11.0203 HP-UX Base OS Auxiliary
HWEnable11i B.11.11.0203.5 Hardware Enablement Patches for HP-UX 11i, March 2002
OnlineDiag B.11.11.06.09 HPUX 11.11 Support Tools Bundle, Mar 2002
RAID-00 B.11.11.01 PCI RAID; Supptd HW=A5856A
TermIO-00 B.11.11.05 PCI MUX; Supptd HW=A6748A/A6749A/J3592A/J35923A; SW=J3596A
b_SOPHOS 2.12 (SOPHOS) Sophos Anti-Virus
perl B.5.6.1.C Perl Programming Language