티스토리 뷰

# vgchange --addtag @호스트네임 vg네임
예> vgchange —addtag @testserver01 vg01


#vgchange -a y
# vgs -o +tags
태그정보를 위 명령어로 확인 후
서버 리부팅 후 정상 마운트 상태 확인

ha환경이나 linux cluster 환경일때 ha에서볼륨에 락을
걸어버려 마운트가 안되는 경우가 종종 있음 이럴때 유용함


HP Serviceguard for Linux Cluster - Understanding LVM Volume Group Tags

Edit /etc/lvm/lvm.conf , and add the following line:
tags { hosttags = 1 }
Create the file /etc/lvm/lvm_$(uname -n).conf
Add the following line to the file you created in step 2:
activation { volume_list=["@node"] }
... where "node" is the value of uname -n.
Run vgscan as follows:
# vgscan


Add the tag and verify that it is valid, and that the volume group activates as expected, for example:


# vgchange --addtag $(uname -n) vgpkgA
# vgs -o +tags vgpkgA
# vgchange -a y vgpkgA


The VG Tags column in the output should contain the value of uname -n.
Deactivate the volume group and delete the tag:


# vgchange -a n vgpkgA
# vgchange --deltag $(uname -n) vgpkgA


The package control script checks for a volume group tag to verify exclusive activation rights. It performs the following logic via the activation_check{} function:
determine whether lvm1 or lvm2 is in use
if lvm2, get the "hostid" stored in the tag of the VG, if set
get the hostname of this node
status the hostid server to see if that node is failed.
If failed, this node may update the tag to show this node owns the VG

공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
링크
«   2024/05   »
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
글 보관함