Solaris 系统维护命令大全( 二 )


vxassist -g smpdbdg mirror lv_tempdbs layout=nostripe smpdbdg2
vxassist -g smpdbdg -U gen make lv_svcchunk1 2000m layout=nolog smpdbdg1
vxassist -g smpdbdg mirror lv_svcchunk1 layout=nostripe smpdbdg2
vxassist -g smpdbdg -U gen make lv_svcchunk2 2000m layout=nolog smpdbdg1
vxassist -g smpdbdg mirror lv_svcchunk2 layout=nostripe smpdbdg2
vxassist -g smpdbdg -U gen make lv_svcchunk3 2000m layout=nolog smpdbdg1
vxassist -g smpdbdg mirror lv_svcchunk3 layout=nostripe smpdbdg2
vxassist -g smpdbdg -U gen make lv_recchunk1 2000m layout=nolog smpdbdg1
vxassist -g smpdbdg mirror lv_recchunk1 layout=nostripe smpdbdg2
vxassist -g smpdbdg -U gen make lv_recchunk2 2000m layout=nolog smpdbdg1
vxassist -g smpdbdg mirror lv_recchunk2 layout=nostripe smpdbdg2
vxassist -g smpdbdg -U gen make lv_recchunk3 2000m layout=nolog smpdbdg1
vxassist -g smpdbdg mirror lv_recchunk3 layout=nostripe smpdbdg2
vxassist -g smpdbdg -U gen make lv_recchunk4 2000m layout=nolog smpdbdg1
vxassist -g smpdbdg mirror lv_recchunk4 layout=nostripe smpdbdg2
vxassist -g smpdbdg -U gen make lv_recchunk5 1700m layout=nolog smpdbdg1
vxassist -g smpdbdg mirror lv_recchunk5 layout=nostripe smpdbdg2

C、附逻辑卷的属性
vxedit -g smpdg -v set user=smp group=smp lv_smp
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_rootdbs
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_logdbs
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_phydbs
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_tempdbs
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_svcchunk1
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_svcchunk2
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_svcchunk3
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_recchunk1
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_recchunk2
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_recchunk3
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_recchunk4
vxedit -g smpdbdg -v set user=informix group=informix mode=660 lv_recchunk5

备注:在SUN的机器中在给逻辑卷付属性的时候,等于用chown、chmod来作 。


8、如何删除卷组
其实也就是去激活和倒出的过程,然后再来对物理磁盘重新格式化就完了 。
vxvol -g smpdbdg stopall
vxdg deport smpdbdg
vxdisksetup -i c1t0d0
vxdisksetup -i c2t1d0
......

这样做了之后就不会再有/dev/vx/smpdbdg目录了 。

9、如何建立共享卷组
在第一台机器上先建立卷组,假设已经建设好卷组smpdg,现在要在第二台机器上建立共享卷组smpdg,
则先在的一台机器上将smpdg去激活、并且倒出smpdg:
smcp01>vxvol -g smpdg stopall
smcp01>vxdg deport smpdg

再来在第二台机器上激活、导入smpdg:
smcp02>vxdg import smpdg
smcp02>vxvol -g smpdg startall

切换后对用以下三个命令进行查看是否切换成功:
vxdg list //用于查看逻辑卷组的信息
vxdisk list //用于查物理磁盘的信息
vxprint -vt //用于查看所有卷的信息



10、如何查看磁盘的大小

方法一:
#format
然后选择盘的代号,回车进入下一级菜单,再选inquiry,就得到该盘的大小信
息,比如:
Vendor: FUJITSU
Product: MAN3184M SUN18G
Revision: 1502

注意:format是一个功能强大的磁盘诊断工具 。

方法二:
#cd /opt/SUNWexplo/bin/
运行explorer得到磁盘的信息包,是一个目录,进入该目录,就发现有一个
disks目录,进入该目录发现有一个diskinfo文件,用如下命令看各个磁盘
的大小:

0: rmt/0ln HP C1537A L706 62########
1: c0t0d0 FUJITSU MAJ3182M SUN18G 0804 0041P90050##
2: c1t0d0 SEAGATE ST318203LSUN18G 034A 0025H54125##

推荐阅读