First thing that you need to do is to determine what your existing /dev/sd devices you have.
In the step above we can see that we currently have two sd devices.
Then run the following script called forcelip.ksh, below is the contents of this script so that you can create it on your box.
# Force a LIP on all FC ports and scan for new devices. Use with caution!
if [ -z "$*" ]
for HBA in $HBALIST
echo "Sending LIP to $HBA..."
echo "1" > $HBA/issue_lip
for HBA in $HBALIST
echo "Scanning for SCSI devices on $HBA..."
echo "- - -" > $HBA/scan
[root@host1 tmp]# ./forcelip.ksh
Sending LIP to host0…
Sending LIP to host1…
Scanning for SCSI devices on host0…
Scanning for SCSI devices on host1…
Then do the following
# ls /dev/sd*
/dev/sda /dev/sda1 /dev/sdb
Now you see the new disk as /dev/sdb.
You may now proceede.
How to use LVM in Linux
Format the disk by using fdisk and label the partition Linux LVM (hex code 8e)
fdisk /dev/sdb (as in the case above)
Run partprobe & vgscan to scan all disks for volume groups and rebuild caches
Initialize the disk or partition(s) for use with LVM
Create a volume group and include the new partition(s)
vgcreate mydg_dg /dev/cciss/c0d1p1
Create the logical volume(s) in the existing volume group (size 10 GB, name v1)
lvcreate -L 10G -n v1 mydg_dg
Or if you want to use the whole available space
lvcreate -l 100%FREE -n v1 mydg_dg
Build the Linux filesystem on the newly created logical volume(s) (file system type ext3)
mkfs -t ext3 /dev/mydg_dg/v1
Create the mount point directory
mkdir -p /my/mount/v1
Mount the filesystem
mount /dev/mydg_dg/v1 /my/mount/v1
Add the volume(s) information in /etc/fstab
To display attributes of volume groups:
To display attributes of physical volumes
To display attributes of logical volumes
ioscan -fnC disk
How to rename a Volume Group
Deactivate and active Logical Volumes in the VG that you want to rename
lvchange -an /dev/my_dg/v1
Then rename the VG
vgrename my_dg your_dg
Reactivate the new Logical Volume
lvchange -ay /dev/your_dg/v1