About Us

RSInfoMinds, a web based IT Training and Consultancy firm. It is established with high dreams in training people in IT Infrastructure Field. We provide Online and Class Room training in various fields of IT Infrastructure Management.

Join Us: http://www.facebook.com/RSInfoMinds
Mail Us: rsinfominds@gmail.com
Twitter: @RSInfoMinds

We are specialized in the below courses:

Redhat Linux Admin Redhat Linux Cluster
Redhat Virutualization IBM AIX Admin
IBM AIX Virtualization IBM AIX Cluster
HP Unix Admin HP Unix Cluster
HP Unix Virtualization Shell Scripting
Veritas Volume Manager Veritas Cluster
Oracle Core DBA VMWare


We provide training in such a way, So that you get in depth knowledge on the Courses you look for.

And we ensure you are very confident from each and every Techincal aspect that the IT Industry needs and expects from you.

We also conduct Workshops on the latest technology and the real time faculties sharing their work experiences to make you the best.

Sunday 29 December 2013

LVM Management in HPUX


Create a LUN from storage and present to the server on which you want to assign a new mount point. To detect new LUN on the server use below command, it will show you all disks presented to the server till now.

#ioscan –fnNC disk












Here:
f:- Generate a full listing, displaying the module's class, instance number, hardware path, driver,  software state, hardware type, and a brief description.
n:- Generate a full listing, displaying the module's class, instance number, hardware path, driver, software state, hardware type, and a brief description.
C:- strict the output listing to those devices belonging to the specified class
N:- Display the agile view of the system hardware.

Below command shows the difference between persistent DFS and Legacy DSF. In next steps we are going to use persistent DSF.

#ioscan –m dsf

Persistent DSF           Legacy DSF(s)
========================================
/dev/pt/pt4                         /dev/rscsi/c0t0d0
                                          /dev/rscsi/c2t0d0
                                          /dev/rscsi/c4t0d0
                                          /dev/rscsi/c6t0d0
/dev/rdisk/disk41             /dev/rdsk/c1t0d0
                                          /dev/rdsk/c3t0d0                
                                          /dev/rdsk/c5t0d0
                                          /dev/rdsk/c7t0d0
/dev/rdisk/disk42              /dev/rdsk/c1t0d1
                                          /dev/rdsk/c3t0d1
                                          /dev/rdsk/c5t0d1
                                          /dev/rdsk/c7t0d1

 To find which disks are not used in the LVM.

 #pvdisplay –l  /dev/disk/*

/dev/disk/disk41:LVM_Disk=no
/dev/disk/disk42:LVM_Disk=yes
/dev/disk/disk43:LVM_Disk=yes
/dev/disk/disk44:LVM_Disk=yes
/dev/disk/disk45:LVM_Disk=yes

From the above output we are able to find disk41 is not used in LVM. So we proceed with disk41. And cross check with the size of disk.

#diskinfo /dev/rdisk/disk41

SCSI describe of /dev/rdisk/disk41:
             vendor: HP
         product id: OPEN-V
               type: direct access
               size: 56691712 Kbytes
   bytes per sector: 512

Output suggests that it is the same size of disk for which we are looking for. So proceed to next step.

Create Physical volume(PV)

A disk has to be initialized before LVM can use it.

#pvcreate /dev/rdisk/disk41

Physical volume "/dev/rdisk/disk41" has been successfully created.

 If disk41 already initialized before then you will get below error message

# pvcreate: The Physical Volume already belongs to a Volume Group

If you are sure the disk is free you can force the initialization using the -f option:

#pvcreate –f /dev/rdisk/disk41

Create Volume Group(VG)


Select a unique minor number for the VG:

# ll /dev/*/group

crw-r--r-- 1 root sys 64 0x000000 Apr 4 2010 /dev/vg00/group
crw-r--r-- 1 root sys 64 0x010000 Oct 26 15:52 /dev/vg01/group
crw-r--r-- 1 root sys 64 0x020000 Aug 2 15:49 /dev/vg02/group

Create the VG control file (group file):

# mkdir /dev/vg03

# mknod /dev/vg03/group c 64 0x030000

Create the VG
#vgcreate  -s 256 /dev/vg03 /dev/disk/disk41

Volume group "/dev/vg03" has been successfully created.
Volume Group configuration for /dev/vg03 has been saved in /etc/lvmconf/vg03.conf

 s: Size of physical extend(PE) in MB.

If you have 2 or more PV to add in a VG, you can add them in one go, just adding next to disk41 with a space.
#vgcreate –s 256 /dev/vg03 /dev/disk/disk41 /dev/disk/disk40

To display VG information

#vgdisplay  -v /dev/vg03

--- Volume groups ---
VG Name                           /dev/vg03
VG Write Access                read/write
VG Status                           available
Max LV                             255
Cur LV                              1
Open LV                           1
Max PV                             16
Cur PV                              1
Act PV                              1
Max PE per PV                1727
VGDA                               2
PE Size (Mbytes)             256
Total PE                           216
Alloc PE                           0
Free PE                            216
Total PVG                         0
Total Spare PVs                0
Total Spare PVs in use      0
VG Version                       1.0
VG Max Size                    6908g
VG Max Extents               27632

Create Logical Volume(LV)

To create a LV from a VG (option: L- assigns Size in MB; l - Assigns size in Number of PE, n – assigns name to LV) 

# lvcreate  -L 55040 –n /dev/vg03/lvol1 /dev/vg03

Logical volume "/dev/vg03/lvol1" has been successfully created with character device "/dev/vg03/lvol1"
Logical volume "/dev/vg03/lvol1" has been successfully extended.
Volume Group configuration for /dev/vg03 has been saved in /etc/lvmconf/vg03.conf

 To display LV information

# lvdisplay -v /dev/vg03/lvol1

--- Logical volumes ---
LV Name                          /dev/vg03/lvol1
VG Name                         /dev/vg03
LV Permission                 read/write
LV Status                          available/syncd
Mirror copies                    0
Consistency Recovery     MWC
Schedule                           parallel
LV Size (Mbytes)             55040
Current LE                        215
Allocated PE                     215
Stripes                               0
Stripe Size (Kbytes)          0
Bad block                          on
Allocation                         strict
IO Timeout (Seconds)      default

Create File system

 You can use newfs to put a FS onto the LV:

# newfs  -F vxfs /dev/vg03/rlvol1

F: - File system type either hfs or vxfs. Nowadays it is always recommended to use a VxFS (=JFS) filesystem.

Mount File system

Mounting created File System

#mkdir /data

#mount /dev/vg03/lvol1 /data

Use the bdf command to see the mounted file systems

#bdf

Entries in /etc/fstab file

Make entries in /etc/fstab file to make mount point permanent between reboots. You can do this with below command or open this file with vi editor and add entries at the end.

# echo “/dev/vg03/lvol1  /data vxfs defaults 0 2” >> /etc/fstab

#vi /etc/fstab

# System /etc/fstab file.  Static information about the file systems
# See fstab(4) and sam(1M) for further details on configuring devices.
/dev/vg00/lvol3 / vxfs delaylog 0 1
/dev/vg00/lvol1 /stand vxfs tranflush 0 1
/dev/vg00/lvol4 /home vxfs delaylog 0 2
/dev/vg00/lvol5 /opt vxfs delaylog 0 2
/dev/vg00/lvol6 /tmp vxfs delaylog 0 2
/dev/vg00/lvol7 /var vxfs delaylog 0 2
/dev/vg00/lvol8 /usr vxfs delaylog 0 2
/dev/vg03/lvol1 /data vxfs defaults 0 2

Saturday 28 December 2013

RPM Commands


# rpm -ivh  MySQL-client-3.23.57-1.i386.rpm : Command to instatll the software.

# rpm -qa : Command to Query all the softwares installed.
cdrecord-2.01-10.7.el5
bluez-libs-3.7-1.1
setarch-2.0-1.1

# rpm -qa | grep 'cdrecord'

# rpm -q MySQL-client
MySQL-client-3.23.57-1

# rpm -q MySQL
package MySQL is not installed

# rpm -qa --queryformat '%{name-%{version}-%{release} %{size}\n'
cdrecord-2.01-10.7 12324
bluez-libs-3.7-1.1 5634
setarch-2.0-1.1 235563

# rpm -qf /usr/bin/mysqlaccess
MySQL-client-3.23.57-1


# rpm -qdf /usr/bin/mysqlaccess : Documentation

# rpm -qi MySQL-client : Lot of information about an installed pacakge.

# rpm -qip MySQL-client-3.23.57-1.i386.rpm : Information about the package before installation.

# rpm -qlp ovpc-2.1.10.rpm : List all the Files in a Package using rpm -qlp.

# rpm -qsp MySQL-client-3.23.57-1.i386.rpm : State of the files in a package. installed, replaced or normal

# rpm -qRp MySQL-client-3.23.57-1.i386.rpm : List the Dependency Packages using rpm -qRP
/bin/sh
/usr/bin/perl 

Lock/Unlock An Account In HPUX

[root] passwd -s test : Retrive the password attributes for an account.
test PS    10/17/13    0  91

[root]passwd -l test : Lock the account.
test LK    12/26/13    0  91

[root]passwd -d test : Unlock the account.
test NP    12/26/13    0  91

PS : Password Set.
LK : Account Locked.
NP : No Password.

Monday 23 December 2013

Cache Memory In Linux

Whenever a user process performs a read/write operation to a file. The original file will not be modified.

A copy of the file will be created and stored in a temporary location to facilitate the read/write operation.

The memory (temporary location) called as Cache Memory.

Saturday 21 December 2013

Restart RPC in HPUX

# /sbin/init.d/Rpcd stop
RPC daemon rpcd stopped

# /sbin/init.d/Rpcd start

starting the DCE RPC Daemon
        /opt/dce/sbin/rpcd

Linux LVM Configuration Files


/etc/lvm                : Default lvm directory location
/etc/lvm/backup         : Where the automatic backups go
/etc/lvm/cache          : Persistent filter cache
/etc/lvm/archive        : Where automatic archives go after a volume group change
/var/lock/lvm           : Lock files to prevent metadata corruption
/etc/lvm/lvm.conf       : Main lvm configuration file
$HOME/.lvm              : LVM history

Sunday 15 December 2013

Changing The Password In Linux Without Prompting

[root@node1 /]# echo -e "password" | (passwd --stdin rajasekar)
Changing password for user rajasekar.
passwd: all authentication tokens updated successfully.
[root@node1 /]#

Identify The Timezone In Linux


[root@node1 rhel5_x86_64]# cat /etc/sysconfig/clock
# The ZONE parameter is only evaluated by system-config-date.
# The timezone of the system is defined by the contents of /etc/localtime.
ZONE="America/New_York"
UTC=true
ARC=false
[root@node1 rhel5_x86_64]#

AIX Disk Mapping To LPAR

First the disk has to presented to the VIOS and then it will presented to the LPAR.

We look first at which VIO the LPAR belongs.

aixlpar01# lsrsrc IBM.ManagementServer
Resource Persistent Attributes for IBM.ManagementServer
resource 1:
        Name             = "10.0.0.1"
        Hostname         = "10.0.0.1"
        ManagerType      = "HMC"
        LocalHostname    = "10.0.0.2"
        ClusterTM        = "9078-160"
        ClusterSNum      = ""
        ActivePeerDomain = ""
        NodeNameList     = {"aixlpar01"}
aixlpar01#


We connect the VIO with padmin and scan the HBA’s.


$ ssh padmin@10.0.0.1
padmin@10.0.0.1's password:
Last unsuccessful login: Wed Dec 19 16:42:17 GMT+01:00 2012 on ssh
Last login: Wed Dec 19 16:42:47 GMT+01:00 2012 on /dev/pts/0

aixvio01$ cfgdev

Some error messages may contain invalid information
for the Virtual I/O Server environment.

Method error (/usr/lib/methods/cfgqlfscsi -l fscsi2 ):
        0514-061 Cannot find a child device.
Method error (/usr/lib/methods/cfgqlfscsi -l fscsi3 ):
        0514-061 Cannot find a child device.
aixvio01$


Now check for free disks:

aixvio01$ lspv -free
NAME            PVID                                SIZE(megabytes)
hdisk5          none                                153600
aixvio01$

hdisk5 is free but no PVID is assigned.

aixvio01$ chdev -dev hdisk5 -attr pv=yes
hdisk5 changed
aixvio01$

Now we need to find to which LPAR we have to assign (make a note of the LPAR ID).

aixvio01$ lssyscfg -r lpar -F lpar_id,name,state
1,aixvio01,Running
2,aixlpar01,Running
3,aixlpar02,Running
5,aixlpar03,Running
aixvio01$

Now assign the disk to the LPAR:

aixvio01$ lsmap -all | grep 0002
vhost3          U7778.23X.106DA2A-V1-C17              0x00000002
aixvio01$

aixvio01$ mkvdev -vdev hdisk5 -vadapter vhost3
vtscsi9 Available
aixvio01$

Run the cfgmgr on the LPAR:

aixlpar01# cfgmgr
aixlpar01# lspv
hdisk0          0006da2a3cdd9771                 rootvg     active
hdisk1          0006da0ab3df2fa6                 None

Linux Interview Question



1) Linux Booting Process.

2) What is swap memory ?

3) What is Multipath ?

4) How to scan a LUN ?

5) How to find WWN of HBA ?

6) How to create a FTP user ?

7) How to build a Kernel ?

8) What is MBR Reset ?

9) How to add a scrpit to default run level ?

10) What is tune2fs ?

Interface Speed Change In Linux


1) cp /etc/sysconfig/network-scripts/ifcfg-eth0 /tmp/

2) vi /etc/sysconfig/network-scripts/ifcfg-eth0

Append following line:
ETHTOOL_OPTS="speed 1000 duplex full autoneg on"

3)/etc/init.d/network restart

Verify the changes:

ethtool eth0

Boot Into On HPUX


HPUX > boot vmunuix : Comman to boot from a kernel.
HPUX > boot -is : Single User Mode: -i# : # Init Level.
HPUX > boot -tm : Tuneable Maintenance Mode (Fail Safe Mode)
HPUX > boot -lm : LVM Maintenance Mode.
HPUX > boot -mv : VxVM Maintenance Mode.

Saturday 14 December 2013

NIC Speed Change on AIX


chdev -l en0 -a state=detach
chdev -l ent0 -a media_speed=1000_Full_Duplex
chdev -l en0 -a state=up
mkdev -l inet0

Command to find the HBA LUN connection details


cd /usr/DynamicLinkManager/bin
./dlnkmgr view -path
./dlnkmgr view -hba
./dlnkmgr view -lu

Step 1: Execute below command to find the offline path id
         
           /usr/DynamicLinkManager/bin/dlnkmgr view -lu
       

Step 2:  Find the offline pathId and execute below command.

          dlnkmgr online -pathid   <pathid>

Step 3:  Execute below command to verify if the path is back online
                       
           /usr/DynamicLinkManager/bin/dlnkmgr view -lu  (or)  /usr/DynamicLinkManager/bin/dlnkmgr view -path

How To fix the timeout Issues on AIX for a User


Put the following in /etc/profile otherwise add it to users $HOME/.profile

TMOUT=10800

(or)
export TMOUT=10800 (the session will be not be closed for 3 (3*60*60) hour)

TIMEOUT=10800 (for bash)
TMOUT=10800 (for ksh)

To Stop/Start the LPD(print Queue) in AIX


stopsrc -s qdaemon
startsrc -s qdaemon

Commnads to start the XManager in AIX

lslpp -l | grep -i x11
export DISPLAY=10.129.4.133:0
xterm
lslpp -l X11.base.lib
exit
ps -ef | grep -i x

Wednesday 11 December 2013

Start And Stop A Oracle Cluster

Oracle Cluster Service is called as CRS.

The CRS has to be started using the binary called crsctl.

You have login with the Oracle ID and execute the command:

# crsctl start crs

# crsctl check crs

# crsctl stop crs

Successful start of crs can be seen with the check crs command:

Cluster Synchronization Services appears healthy
Cluster Ready Services appears healthy
Event Manager appears healthy



Monday 9 December 2013

Uptime Explained

Figure 1

It shows you the system time in 24 hours format.

Numbers of Users Logged In.

Load Average.

While the sequence 0.25, 0.25, 0.19 represent for the past 1 minutes, 5 minutes and 15 minutes.


Check the current attached disks

#cat /proc/scsi/scsi | egrep -i ‘Host:’ | wc -l

#fdisk -l 2>/dev/null | egrep ‘^Disk’ | egrep -v ‘dm-’ | wc -l

Sunday 8 December 2013

LUN Detection in Linux

Before Scanning the LUN, take the output of fdisk-l

Execute the command:

echo "- - -" > /sys/class/scsi_host/host#/scan

host : Refers to the HBA Device Name.

Run the # fdisk -l and look for the newly assigned LUN.

NTP Sync Manually

1. Use the "xntpd -x" command to slowly bring the clocks
into sync. ( +/- 2 seconds per minute )

NOTE: Starting time cannot be more than 1000 seconds
out of sync with the server or the xntpd daemon
will terminate and the error messages referenced
above will be logged to syslog. Also note that
the system's clock is never set BACKWARDS.
Instead, the clock is slowed down and the server
is allowed to catch up.

2. Use the "ntpdate -B" command to adjust the clocks into
sync. ( +/- 20 seconds per minute )

3. Set the time/date manually.

4. Reboot.

Saturday 7 December 2013

HPUX: vxfs fsadm: attempt to resize {} failed with errno 28

Error number 28 means ENOSPC from /usr/include/sys/errno.h
#define ENOSPC          28      /* No space left on device      */


Why is the ENOSPC error while running fsadm even though there is enough free space on the filesystem?

Solution:

NOTE: If a file system is full, busy or too fragmented, the resize operation may fails.

HPUX : stty: : Not a typewriter

If you see the message "stty: : Not a typewriter" while login to the server using SSH.

If means the PTS is exhausted and you have increase the value to PTS.

kmtune -q npty
Parameter             Current Dyn Planned                    Module     Version
===============================================================================
npty                       60  -  60

Linux Dmesg: kernel: Your time source seems to be instable or some driver is hogging interupts

If the Liunx Machine Demsg says:

syslog-ng[5244]: STATS: dropped 0

kernel: warning: many lost ticks.

kernel: Your time source seems to be instable or some driver is hogging interupts

kernel: rip __do_softirq+0x4a/0xd2

Solution:

When network load is very high or time source is instable, these messages will be logged.

If NTP is synchronized to NTP server, these messages can be ignored.


What NTP Command Says?

“+” – Good and a preferred remote peer or server (included by the combine algorithm)

“*” – The remote peer or server presently used as the primary reference;

poll : NTP polls each peer every “poll” seconds.

when : is relative time of last poll.

reach : track of last successful polls, 377 is best.

Delay : is network delay, this is fine

offset : offset between local and peer clock (ms) and it should be low.

jitter : Mean deviation (jitter) in the time reported for that remote peer or server.

Friday 6 September 2013

Boot Sequence: Quick Reference

PA-RISC:

1. ISL (Initial System Loader)

2. hpux (secondary system loader)

3. /stand/vmunix (kernel)

Integrity:

1. EFI (Extensible Firmware Interface)

2. hpux.efi

3. /stand/vmunix

Fragmentation And Defragmentation In HPUX

# fsadm -b new_size <mount_point> : Increase the size of the FS.

# fsadm -D <mount_point> : Determine if directory fragmentation affects performance.

# fsadm -E <mount_point> : Determine if file system fragmentation affects performance.

# fsadm -d <mount_point> : Reorganize the directories to reduce fragmentation and reclaim waste space.

# fsadm -e <mount_point> : Reorganize the filesystem extents to reduce fragmentation and reclaim waste space.

# fsadm -E -e <mount_point> : Reports on fragmentation before and after the actual defragmentation.

Granting Users Limited Access to SAM

# sam -r  : To give limited access to super user access to non super user.

This activates the Restricted SAM Builder, which allows you to enable or disable selected SAM areas for users.

For each user given restricted access, SAM creates a file /etc/sam/custom/login_name.cf that defines the user's SAM privileges.

SAM uses this file to give users access to the indicated areas.

Using SAM with an X Window System In HPUX

Make sure X11-RUN fileset is installed.

To view the current settings of the environment variables, enter:

env | more

The DISPLAY environment variable is usually set in the .profile file for Korn and POSIX shells and in the .login file for the C shell as follows:

DISPLAY=hostname:0.0 (Korn and POSIX shell)
export DISPLAY
setenv DISPLAY hostname:0 (C Shell)

WWID In Linux

Here is a file from where you can get the WWID Information for the LUN's assigned to your Linux Server.

Provided Multipath is in place:

RHEL 5 : /var/lib/multipath/bindings

RHEL 6 : /etc/multipath/bindings

Setting Up Non Expiry Password In HPUX

For non-trusted system:

passwd -x -1 username

You can simply give the nonexpiry passwords as below

#passwd -x -1 username

and see the change after

#passwd -s username

/usr/lbin/modprpw -m exptm=0,lftm=0,mintm=0,expwarn=0,llog=0 

Access is denied by the AUTH_MAXTRIES option in security(4).

#userdbset -d -u username auth_failures

Thursday 29 August 2013

HP-UX SSHD System Startup and Shutdown script

HP-UX Secure Shell uses Pluggable Authentication Module for password authentication.

Server configuration file is located at /opt/ssh/etc/sshd_config.

/sbin/init.d/secsh {start|stop}

System startup configuration file

/etc/rc.config.d/sshd

Stop HP UX SSH Service

Type the command:
# /sbin/init.d/secsh stop

Start HP UX SSH Service

Type the command:
# /sbin/init.d/secsh start

Tuesday 27 August 2013

Disable IPv6 In Linux

/etc/sysctl.conf  :  net.ipv6.conf.all.disable_ipv6 = 1

/etc/sysconfig/network  : NETWORKING_IPV6=no

 /etc/sysconfig/network-scripts/ifcfg-eth0 : IPV6INIT=”no”

disable iptables6 – chkconfig –level 345 ip6tables off

Reboot the server.

Linux Speed Change Of An Interface

Take the output of # ethtool eth#

1) cp /etc/sysconfig/network-scripts/ifcfg-eth0 /tmp/

2) vi /etc/sysconfig/network-scripts/ifcfg-eth0

Append following line:

ETHTOOL_OPTS="speed 1000 duplex full autoneg on"

3)/etc/init.d/network restart

Verify the changes:

ethtool eth0

Type of Booting in HPUX


HPUX > boot vmunuix : Comman to boot from a kernel.

HPUX > boot -is : Single User Mode: -i# : # Init Level.

HPUX > boot -tm : Tuneable Maintenance Mode (Fail Safe Mode)

HPUX > boot -lm : LVM Maintenance Mode.

HPUX > boot -mv : VxVM Maintenance Mode.

Setting Long User, Group, Host, and File Names - HPUX

By default, user names are restricted to eight characters and group names to 16 characters.

To set long (up to 254-character) user and group names, see lugadmin(1M).

If the kernel tunable expanded_node_host_names is off (0), the maximum host node name length is eight characters (for example, hprdc185) and the maximum full host name length is 64 characters (for example, hprdc185.example.com).

If it is on (1), the maximum for both is 255 characters. By default, this tunable is off.

Preventing Users from Logging In _ HPUX

One of the issues for system administrators is how to keep non-superusers from logging
in to a system while system configuration or system maintenance is underway.

/etc/nologin file and the NOLOGIN variable in the /etc/default/security file.

If /etc/nologin exists and NOLOGIN=1, nonsuperusers are barred from logging in.
What they will see is a system-generated message (Only...security) followed by the contents of /etc/nologin.

1) Create or edit the file /etc/nologin. It can be empty, but users might appreciate some information on why the system is unavailable.

2) Edit the file /etc/default/security and set the NOLOGIN line to NOLOGIN=1.

Thursday 25 July 2013

Handly LVM Commands

CommandDescription
cfgmgrDiscover and configure new devices on the target LPAR.
dfDisplay file systems.
exportvgRemove the volume group definition from the system.
fsckCheck the file system consistency.
importvgImport a volume group definition from the system and activate the volume group.
lspvList physical volume.
lsvgfsList the file systems belonging to a volume group.
mountMount a file system.
rmdevRemove the physical volume definitions from the source LPAR.
umountUnmount a file system.
varyoffvgDeactivate a volume group.
varyonvgActivate a volume group.

Disable IPv6 In RHEL

1) # vi /etc/modprobe.conf

install ipv6 /bin/true

Save and close the file.

2) # vi /etc/sysconfig/network

NETWORKING_IPV6=no
IPV6INIT=no

Save and close the file.

3) Reboot the server.

4) Verify the IP Address.

Thursday 30 May 2013

Patch Information In HPUX

1. Patch names always start with the characters PH.
2. Next 2 characters show the patch type.
   Here are the types ...
   a. Command Patches - CO
   b. Kernel Patches       - KL
   c. Network Patches    - NE
   d. Subsystem Patches - SS
3. After this, there is an underscore and a 4 or 5 digit patch number
4. You have to reboot the system after the kernel patch installation.

Network Configuration in HP-UX

Configuration File :
/etc/rc.config.d/netconf        -  Contains the hostname, ip address, default route
/etc/hosts                            -  Contains the hsotname to IP address mapping
/etc/resolv.conf                   -  Contains DNS server details
/etc/inetd.conf                     - Internet daemon configuration file

Configuration Files used for DNS Client:
/etc/nsswitch.compat
/etc/nsswitch.nis
/etc/nsswitch.ldap
/etc/nsswitch.conf
/etc/nsswitch.files
/etc/nsswitch.hp_defaults

Scripts :
/sbin/init.d/net start  - To start network services
/sbin/init.d/net stop  - To stop network services

Backup And Recovery

1. To backup a filesystem :
# fbackup -f /dev/rmt/0m -i /home

2. To list the contents of the tape media and store it in a file :
# frecover -I /tmp/indexfile -f /dev/rmt/0m

3. To do level 0 (full) backup of a filesystem and also update the file /var/adm/fbackupfiles/dates :
# fbackup -f /dev/rmt/0m -0 -u /home

4. To do a level 1 backup using a graph file to specify which files will be included/excluded :
# fbackup -f /dev/rmt/2m -1 -u -g /var/adm/fbackupfiles/graphs/g0

Graph file content may look like
i /data
e /data/tmp

5. To backup to the tape drive on the remote server :
# fbackup -f host1:/dev/rmt/0m -v -i /home

6. To backup data to two tape drives (one by one) :
# fbackup -f /dev/rmt/0m -f /dev/rmt/1m -i /data

7. To restore all the files from the tape media
# frecover -v -r -f /dev/rmt/0m

8. To show the tape drive status :
# mt -f /dev/mt/0mnb status

9. To eject a tape :
# mt -f /dev/mt/0mnb offline

10. To rewind the tape media :
# mt -f /dev/rmt/0mnb rewind

Tuesday 2 April 2013

Getting Console Log in AIX and HPUX

AIX:

# alog -L : Command to get the log types on the server.

# alog -o -t boot : Command to get the boot log.

# alog -o -t console : Command to get  the console log.

HPUX:

# dmesg

# cat /etc/rc.log

HPUX HBA Firmware Upgradation

HBA which stands for Host Burst Adapter to facilitate SAN connection.

In HPUX, HBA firmware can be upgraded in 2 ways (both the method require server reboot).

1) Performing Upgradation from the EFI shell.

2) Performing from the OS level.

AIX Savecore


The default location for AIX crash dump is at /var/adm/ras with the name "vmcore.#.bz"

# represents the sequence number of the crash dump.

# sysdumpstart -p : Command to initiate a system dump and dump the crash in the primary dump device.

But the user initiated dump will not be stored in /var/adm/ras directory. To do so, We need execute the # savecore -d.

# savecore -d : Command copies the latest dump to the /var/adm/ras directory.

# sysdumpdev -t : Command to get the latest dump device name and its size.