Operating System - HP-UX
1834285 Members
2281 Online
110066 Solutions
New Discussion

Help on Adding Harddrive to System and vgchange error

 
SOLVED
Go to solution
Jon Le
Advisor

Help on Adding Harddrive to System and vgchange error

Hello everyone. This is probably an easy question for you guys. There is a ds2100 on the system with 3 hard drives. Each hard drives are 18.2 gig. I would like to configure these hard drive so I can start using it.

Here are some info when I do a ioscan -fnC disk:

H/W Path : Driver S/W State: H/W Type: Description:

0/3/0/0.0.0:sdisk CLAIMED:Device:HP 18.2GB
/dev/dsk/c7t0d0 /dev/rdsk/c7t0d0

0/3/0/0.2.0:sdisk CLAIMED:Device: HP 18.2 GB
/dev/dsk/c7t2d0 /dev/rdsk/c7t2d0

0/3/0/0.4.0:sdisk CLAIMED:Device: HP 18.2 GB
/dev/dsk/c7t4d0 /dev/rdsk/c7t4d0

Tried to setup c7t0d0. It didn't work so I want to erased and start over but can't. How do I go about starting over?

The volume group that I tried to create is called test

in /dev/test

group and lvol1 (its missing rlvol1)

I tried to do a vgchange -a n /dev/test
I get the following:
vgchange: couldn't deactivate volume group "/dev/test":
device busy

i did a pvdisplay -v /dev/dsk/c7t0d0 and here is what I get:

PV name: /dev/dsk/c7t0d0
VG Name: /dev/test
PV Status: available
Allocatable: yes
VGDA: 2
Cur LV: 0
PE Size: 4
Total PE: 4340
Free PE: 0
Allocated PE: 4340
Stale PE: 0
IO Timeout: Default
Autoswitch: on

Physical Extents:
PE Status LV LE

0000 current ??? 00000
.
.
.
04339 current ??? 04339

Anyways thats one of the problem. If you can help me resolve that so I can reuse that disk. The other question would be, what are the steps I need to take in order to get the other 2 disk configure. I would like to use one disk just for storage. So one volume group. Any help is appreciated.







8 REPLIES 8
psreedhar
Frequent Advisor

Re: Help on Adding Harddrive to System and vgchange error

Hi,
It looks like one more LVOL special files are deleted. Because of that reason LVM is not able to show the LV names in pvdisplay output.

You can create the lvol and rlvol special files based on vgdisplay output.

later ensure none of the LVOLs are stale. I mean no resync operation is going on.

Then try doing vgchange -a n it should succedd.

But my doubt is when the PV status is "available" for /dev/dsk/c7t0d0
why do you want to remove it from the volume group?
whiteknight
Honored Contributor

Re: Help on Adding Harddrive to System and vgchange error

Hi
It seems your disk /dev/dsk/c7t0d0 having problem, please log case to HP for HW assistance.

WK
Problem never ends, you must know how to fix it
psreedhar
Frequent Advisor

Re: Help on Adding Harddrive to System and vgchange error

pvdisplay is showing that the disk is fine.
Siju Vadakkan
Trusted Contributor

Re: Help on Adding Harddrive to System and vgchange error

Provide the following details

1. vgdisplay -v /dev/test
2. strings /etc/lvmtab
3. ll /dev/test
Jon Le
Advisor

Re: Help on Adding Harddrive to System and vgchange error

#pvdisplay -v /dev/test

vg name: /dev/test
vg write access: read/write
vg status: available
max lv: 255
cur lv: 1
open lv: 0
max pv: 16
cur pv: 1
act pv: 1
max pe per pv: 4341
vgda: 2
pe size: 4
total pe: 4340
alloc pe: 4340
free pe: 0
total pvg: 0
total spare pvs: 0
total spare pvs in use: 0

Physical volume:
pv name: /dev/dsk/c7t0d0
pv status: available
total pe: 4340
free pe: 0
autoswitch: on

--------------------------------------------
#strings /etc/lvmtab

/dev/vg01
/dev/dsk/c1t0d0
/dev/dsk/c2t0d0
/dev/dsk/c2t2d0
/dev/vg00
/dev/dsk/c1t2d0
/dev/test
/dev/dsk/c7t0d0

--------------------------------------------
#ll /dev/test

crw-rw-rw 1 root sys 64 0x030000 Feb 21 group

-------- 1 root sys 146876146 Mar 3 lvol1

--------------------------------------------

The contain in /dev/test, I tried to do a restore from backup and i'm sure thats not what you are suppose to do. Thanks for you guys help.

Can you also let me know the procedure to create a disk starting from scratch (assuming i want to use all of one of the 18.2 disk). Just want to make sure what I am doing is correct. Thank you.



psreedhar
Frequent Advisor
Solution

Re: Help on Adding Harddrive to System and vgchange error

Hi,
No need to recreated the VG again.
Just create the LV special files.

I think, while restoring the /dev/test/ directory contents you restored the lvol1 as a regular instead of LV special file.
So just delete /dev/vgtest/lvol and recreated it using the following commands.

mknod /dev/test/lvol1 b 64 0x030001
mknod /dev/test/rlvol1 c 64 0x030001

I am sure recreating the LV DSF will solve your problem.
Jon Le
Advisor

Re: Help on Adding Harddrive to System and vgchange error

recreating the lvol and rvol worked out however when I tried to do a mount

#mount -F vxfs /dev/test/lvol1 /test

and do a bdf. It shows the following:

/dev/test/lvol1
kbytes: 4444160
used: 2193
avail: 4164352
% used: 0
mounted on: /test

how come it isn't showing the entire space of 18.2 gig? am I missing something. Let me know. Thank you.
psreedhar
Frequent Advisor

Re: Help on Adding Harddrive to System and vgchange error

Hi,
i doubt....
you have created the file system when the LVOL size is 4GB, later you extended the lvol to the full size.

To correct the problem,
umount /test
extendfs /dev/test/lvol1
mount /dev/test/lvol1 /test

I hope this will solve your problem.