建设工作站服务器
[ root @ testdb:/# ]供pvcreate/dev/rdsk/c2t1d4#使用的字符设备
physical volume/dev/rdsk/C2 t1 D4 hasbeensuccessfullycreated。
[ root @ testdb:/# ]使用vgcreatevgora/dev/dsk/c2t1d4#块设备
increasedthenumberofphysicalextentsperphysicalvolumeto 50431。
vgcreate:volume group/dev/vgoracouldnotbecreated :
vgraforthediskistoobigforthespecifiedparameters.increasethe
extentsizeordecreasemax _ PVS/max _ lvsandtryagain。
[ root @ testdb://# ] diskinfo/dev/rdsk/c2t1d 4
SCSI describe of /dev/rdsk/c2t1d4:
vendor: HITACHI
product id: DF600F
类型: direct access
size: 206569472 Kbytes
bytes per sector: 512
一个PE Size的默认大小为4M,so…4m * 50431=201724 m 201728 m ( 206569472/1024 ),因此为了增大PE的大小,设定PE Size=32M。
[ root @ testdb://# ] vgcreate-s32 VG ora/dev/dsk/c2t1d 4
increasedthenumberofphysicalextentsperphysicalvolumeto 6303。
volume group/dev/vgorahasbeensuccessfullycreated。
volumegroupconfigurationfor/dev/vgorahasbeensavedin/etc/LVM conf/VG ora.conf
[ root @ testdb:/# ] lvcreate-l40g-nlvoraclevgora #无法识别G.so.delete
[ root @ testdb:/# ] lvcreate-l80g-nlvoradatavgora
[ root @ testdb://# ] lvremove/dev/VG ora/LV Oracle
[ root @ testdb://# ] lvremove/dev/VG ora/LV oradata
[ root @ testdb://# ] lvcreate-l 40960 m-nlvoraclevgora
[ root @ testdb:/# ] lvcreate-l 81920 m-nlvoradatavgora
[ root @ testdb:/# ]刷新vgdisplay-vv gora #信息。
[ root @ testdb:/# ]必须使用newfs-Fv xfs/dev/VG ora/LV Oracle #字符设备,其中一个字符带有r。 ( (用于带r的原始设备,不带r的用于文件系统。 )
UX:vxfs newfs:error:v-3-21623:/dev/VG ora/lvoracleisnotacharacterdevice
[ root @ testdb://# ] newfs-Fv xfs/dev/VG ora/RLV Oracle
[ root @ testdb://# ] newfs-Fv xfs/dev/VG ora/RLV oradata
[ root @ testdb://# ] mkdir-p/Oracle/testdb/Oracle
[ root @ testdb://# ] mkdir-p/Oracle/testdb/oradata
[ root @ testdb://# ] mount/dev/VG ora/LV Oracle/Oracle/testdb/Oracle
[ root @ testdb://# ] mount/dev/VG ora/LV oradata/Oracle/testdb/oradata
此时,可以确认是否用bdf挂载。
如果要在系统上装载文件系统,则必须在/etc/fstab中添加记录。
在[root@testdb:/#] vi /etc/fstab #中添加以下内容:
/dev/VG ora/LV Oracle/Oracle/testdb/oraclevxfsdelaylog 02
/dev/VG ora/LV oradata/Oracle/testdb/oradatavxfsdelaylog 02
[root@testdb:/#] mount -a
[ root @ testdb://# ]增大lvextend-l 92160 m/dev/VG ora/LV oradata # LV大小
[ root @ testdb://# ] extend fs-Fv xfs/dev/VG ora/LV oradata # file system无法联机操作。 需要umount操作
UX:vxfsextendfs:error:v-3-20144:/dev/VG ora/lvoradataismounted,cannot extend。
[ root @ testdb:/# ] fsadm-Fv xfs-b 92160 m/Oracle/testdb/oradata #使用fsadm联机操作。
UX:vxfs fsadm:info:v-3-25942:/dev/VG ora/rlvoradatasizeincreasedfrom 8386080 sectors to 94371840 sectors
[ root @ testdb://# ] umount/Oracle/testdb/oradata
[ root @ testdb://# ] lvreduce-l 81920 m/dev/VG ora/LV oradata
root @ testdb://# ] mount/dev/VG ora/LV oradata/Oracle/testdb/oradata
UX:vxfs mount:error:v-3-24706:/dev/VG ora/lvoradatanosuchdeviceorfilesystemonitmissingoneormoredevices
[ root @ testdb://# ] newfs-Fv xfs/dev/VG ora/RLV oradata #只能这样了。 但是,这样里面的数据就没有了。
[ root @ testdb:/# ] newfs-olargefiles-Fv xfs/dev/VG ora/RLV oradata #最多支持2G,在不添加-o的情况下支持128G。
[root@testdb:/#] mount -a
[ root @ testdb:/dev/VGA sm # ] pvcreate/dev/rdsk/c2t1d 3
pvcreate:couldnotperformlvmoperationonvxvmdisk/dev/rdsk/c2t1d 3。
使用-f参数强制执行[ root @ testdb:/dev/VGA sm # ] pvcreate-f/dev/rdsk/c2t1d3#
physical volume/dev/rdsk/C2 t1 D3 hasbeensuccessfullycreated。
[ root @ testdb:/dev/VGA sm # ] vgextendvgora/dev/dsk/c2t1d 3
[ root @ testdb:/dev/VGA sm # ] vgreducevgora/dev/dsk/c2t1d 3
详情请访问云服务器、域名注册、虚拟主机的问题,请访问西部数码代理商官方网站: www.chenqinet.cn