Posts

Showing posts from July, 2013

other way to see LVM --- DMSETUP command

[root@gfscluster1 ~]# dmsetup info Name: VolGroup-lv_swap State: ACTIVE Read Ahead: 256 Tables present: LIVE Open count: 1 Event number: 0 Major, minor: 253, 1 Number of targets: 1 UUID: LVM-bz62bsGCF0kQGQZXZqkuJcm5LXN94FEr5RPQnqBPwRxTupWMYJOFU1w0PIfkPemh Name: VolGroup-lv_root State: ACTIVE Read Ahead: 256 Tables present: LIVE Open count: 1 Event number: 0 Major, minor: 253, 0 Number of targets: 1 UUID: LVM-bz62bsGCF0kQGQZXZqkuJcm5LXN94FErSBYAwCAc9MttPuFK6BgX4hD1NJzSGv1k Name: VolGroup-lv_home State: ACTIVE Read Ahead: 256 Tables present: LIVE Open count: 1 Event number: 0 Major, minor: 253, 2 Number of targets: 1 UUID: LVM-bz62bsGCF0kQGQZXZqkuJcm5LXN94FErvHTieePAhYfZoYArYtqD2ejy5cyMe2SQ Name: vgvol-lv_brick1 State: SUSPENDED Read Ahead: 256 Tables present: None Open count: 0 Event number:...

How to enable logs for LVM.

cat /etc/lvm/lvm.conf # Should we send log messages through syslog? # 1 is yes; 0 is no. syslog = 1 # Should we log error and debug messages to a file? # By default there is no log file. file = "/var/log/lvm2.log" # Should we overwrite the log file each time the program is run? # By default we append. overwrite = 0 # What level of log messages should we send to the log file and/or syslog? # There are 6 syslog-like log levels currently in use - 2 to 7 inclusive. # 7 is the most verbose (LOG_DEBUG). # level = 0 level = 7

LVM showming so many error messages

#lvdisplay /dev/sda: read failed after 0 of 4096 at 0: Input/output error /dev/sda: read failed after 0 of 4096 at 37580898304: Input/output error /dev/sda: read failed after 0 of 4096 at 37580955648: Input/output error /dev/sda: read failed after 0 of 4096 at 4096: Input/output error /dev/sdc: read failed after 0 of 4096 at 0: Input/output error /dev/sdc: read failed after 0 of 4096 at 37580898304: Input/output error /dev/sdc: read failed after 0 of 4096 at 37580955648: Input/output error /dev/sdc: read failed after 0 of 4096 at 4096: Input/output error /dev/sdf: read failed after 0 of 4096 at 0: Input/output error /dev/sdf: read failed after 0 of 4096 at 37580898304: Input/output error /dev/sdf: read failed after 0 of 4096 at 37580955648: Input/output error /dev/sdf: read failed after 0 of 4096 at 4096: Input/output error /dev/sdh: read failed after 0 of 4096 at 0: Input/output error /dev/sdh: read failed after 0 of 4096 at 37580898304: Input/output error /dev/sdh: r...

command for Rescan LUNs

[root@gfscluster1 ~]# rpm -qf /usr/bin/rescan-scsi-bus.sh sg3_utils-1.28-4.el6.x86_64

Find UUID & mount the file system

acb:~ # blkid /dev/sdk1: UUID="57c5a0f3-ba9c-40bb-ab13-1520a7667d5f" SEC_TYPE="ext2" TYPE="ext3" /dev/sda1: UUID="e446ceab-b704-4b22-91d1-b5eb84c4f4b5" TYPE="swap" /dev/sdi1: UUID="1b8c1063-4fdd-4606-859a-44e840935cf4" TYPE="ext3" /dev/sda2: UUID="19e8e2fb-1eb3-4376-8c0f-9b646969c75a" TYPE="ext3" /dev/sdd1: UUID="97f10709-c33e-4232-8235-6b26eb4ec185" SEC_TYPE="ext2" TYPE="ext3" /dev/sdc1: UUID="1b8c1063-4fdd-4606-859a-44e840935cf4" TYPE="ext3" /dev/sdf1: UUID="1b8c1063-4fdd-4606-859a-44e840935cf4" TYPE="ext3" /dev/sdg1: UUID="97f10709-c33e-4232-8235-6b26eb4ec185" SEC_TYPE="ext2" TYPE="ext3" /dev/sdj1: UUID="97f10709-c33e-4232-8235-6b26eb4ec185" SEC_TYPE="ext2" TYPE="ext3" You have new mail in /var/mail/root acb:~ # ls -l ../../sda2 ls: cannot access ../../sda2: No such...

Rescan LUN with command

echo "- - -" > /sys/class/scsi_host/host0/scan to know what will come in place of "host0 or host1" Run the below command to know this [root@fspnfs Nagios]# systool -c fc_host -v Class = "fc_host" Class Device = "host5" Class Device path = "/sys/class/fc_host/host5" fabric_name = "0x100000051ed40e68" issue_lip = node_name = "0x2000001b32901fd0" port_id = "0x010400" port_name = "0x2100001b32901fd0" port_state = "Online" port_type = "NPort (fabric via point-to-point)" speed = "4 Gbit" supported_classes = "Class 3" supported_speeds = "1 Gbit, 2 Gbit, 4 Gbit" symbolic_name = "QLE2460 FW:v5.03.16 DVR:v8.03.07.03.05.07-k" system_hostname = "" tgtid_bind_type = ...

check state of FC link

[root@fspnfs Nagios]# cat /sys/class/scsi_host/host5/state Link Up - F_Port

rescan LUN in linux with script.

create file rescan-scsi-lun.sh & copy below contents. ./rescan-scsi-bus.sh -l -w #!/bin/bash # Skript to rescan SCSI bus, using the # scsi add-single-device mechanism # ( w ) 1998 -03 -19 Kurt Garloff ( c ) GNU GPL # ( w ) 2003 -07 -16 Kurt Garloff ( c ) GNU GPL # $Id : rescan-scsi-bus. sh ,v 1.15 2004 / 05 / 08 14 : 47 : 13 garloff Exp $   setcolor ( ) { red= " \e [0;31m" green= " \e [0;32m" yellow= " \e [0;33m" norm= " \e [0;0m" }   unsetcolor ( ) { red= "" ; green= "" yellow= "" ; norm= "" }   # Return hosts. sysfs must be mounted findhosts_26 ( ) { hosts= if ! ls /sys/class/scsi_host/host* >/dev/null 2 >& 1 ; then echo "No SCSI host adapters found in sysfs" exit 1 ; # hosts= " 0" #return fi for hostdir in /sys/class/scsi_host/host*; do hostno= $ { hostdir #/sys/class/scsi_h...

Login in FTP server with LDAP authentication & create home directory automatically.

Login in FTP server with LDAP authentication & create home directory automatically. vi /etc/pam.d/vsftpd #%PAM-1.0 session optional pam_keyinit.so force revoke auth required pam_listfile.so item=user sense=deny file=/etc/vsftpd/ftpusers onerr=succeed auth required pam_ldap.so auth required pam_shells.so auth include password-auth account sufficient pam_ldap.so account include password-auth session required pam_mkhomedir.so skel=/etc/skel/ umask=0077 session sufficient pam_ldap.so session required pam_loginuid.so session include password-auth ~ Add the below line vsftpd.conf file session_support=YES

Increae the space of "/" partition in AIX

Image
If space is available Then run the below command Increase space in / # chfs -a size=+30G / Filesystem size changed to 65011712