x3y4z5 回复于:2002-11-28 14:48:39 |
没有做过封装rootdg,不能帮你,建议在存储备份法个贴子,或许会有帮助。 对解决办法很感兴趣,是否可以解决后公布? |
goldeneye 回复于:2002-11-29 09:37:55 |
????? |
kindy 回复于:2002-11-29 10:12:12 |
vxvm根盘封装的这个问题还真没见过,如果你用的是测试机器,可以试用以下方法, 仅供学习,不适用于生产环境。 运行以下命令创建rootdg(前题是c0t0d0s4在系统安装是就已经预留,10m左右即可,不用浪费一个盘,rootdg在装机中不能切换到其他机器) # vxctl disable 先关闭vxconfigd进程。 # vxdctl init # vxdg init rootdg # vxdctl add disk c0t0d0s4 type=simple # vxdisk -f init c0t0d0s4 type=simple # vxdg adddisk c0t0d0s4 # vxdctl enable # rm /etc/vx/reconfig.d/state.d/install-db 这样是把c0t0d0s4当作一整块硬盘来封装。可以试一下。 |
YT 回复于:2002-11-30 01:50:09 |
最好不要用根盘做封装。。。 用vxadmin好使。 |
goldeneye 回复于:2002-12-02 10:08:47 |
我是想封装了根盘,然后做成镜像! |
goldeneye 回复于:2002-12-02 10:22:43 |
不封装跟盘也提示:c0上没有硬盘! |
milan 回复于:2002-12-02 10:33:33 |
here is the problem: <excluding root disk c0t0d0> No disks were found attached to controller c0 ! Hit RETURN to continue. 在/etc/vx/disks.exclude是不是包括了c0上的硬盘,这个文件把列出的设备排除出vxvm的控制。 |
x3y4z5 回复于:2002-12-02 12:15:09 |
如果disks.exclude包括了c0硬盘,楼主应该知道得呀? |
zhuzhug 回复于:2002-12-02 12:35:54 |
SUN公司建议最好用disksuit做系统镜象,如用vm要特别设置 |
yououy 回复于:2002-12-02 12:46:07 |
没错建议你用SDS做系统镜象。但是如果你觉得花了money买了VxVM,一定要用VxVM做根盘景象。也很简单。 1. 空余出S3,S4.留出部分空间。 2. vxinstall。 |
yououy 回复于:2002-12-02 12:48:17 |
milan说的对。检查/etc/vx/disks.exclude文件。 |
YT 回复于:2002-12-02 12:50:55 |
This procedure shows the necessary steps to encapsulate and mirror your root disk if you choose to do it after vxinstall has already been run. The options in vxdiskadm may vary slightly between Volume Manager versions, however the procedure should be the virtually the same in all currently supported 2.x and 3.x Sun Enterprise Volume Manager[TM] (SEVM) and Veritas Volume Manager (VxVM) versions. The examples below assume that the primary rootdisk is c0t0d0 and the mirror of root is c0t1d0. It also assumes that we choose to name c0t0d0 rootdisk and c0t1d0 rootmir. Other names can be selected if desired. SOLUTION SUMMARY: STEP 1---------------------------------------- Need patch: 111413-08 111904-05 111909-06 (2,8,6,4,5,3,7,1) Run the following commands if the file doesn't exist under /etc/vx/slib: # cp /usr/lib/liba5k.so.2 /etc/vx/slib # cp /usr/lib/libdevice.so.1 /etc/vx/slib # cp /usr/lib/libsocket.so.1 /etc/vx/slib # cp /usr/lib/libdevinfo.so.1 /etc/vx/slib # cp /usr/lib/libmp.so /etc/vx/slib # cp /usr/lib/libthread.so.1 /etc/vx/slib # cp /usr/lib/libc.so.1 /etc/vx/slib # cp /usr/lib/libg_fc.so.2 /etc/vx/slib # cp /usr/lib/libnsl.so.1 /etc/vx/slib # cp /usr/lib/libnvpair.so.1 /etc/vx/slib # cp /usr/lib/libdevid.so.1 /etc/vx/slib # vxinstall VxVM uses license keys to control access. If you have a SPARCstorage Array (SSA) controller or a Sun Enterprise Network Array (SENA) controller Are you prepared to enter a license key [y,n,q,?] (default: y) y Please enter your key: 1234 5678 …. Do you wish to enter another license key [y,n,q,?] (default: n) n Do you want to use enclosure based names for all disks ? [y,n,q,?] (default: n) n Hit RETURN to continue. 1 Quick Installation 2 Custom Installation 3 Prevent multipathing/Suppress devices from VxVM's view ? Display help about menu ?? Display help about the menuing system q Exit from menus Select an operation to perform: 1 Encapsulate Boot Disk [y,n,q,?] (default: n) y Enter disk name for [<name>,q,?] (default: rootdisk) rootdisk Hit RETURN to continue. The following is a summary of your choices. C0t0d0 Encapsulate c0t1d0 New Disk Is this correct [y,n,q,?] (default: y) y The system now must be shut down and rebooted in order to continue the reconfiguration. Shutdown and reboot now [y,n,q,?] (default: n) y We will encapsulate the primary root disk using vxdiskadm. # vxdiskadm Volume Manager Support Operations Menu: VolumeManager/Disk 1 Add or initialize one or more disks 2 Encapsulate one or more disks 3 Remove a disk 4 Remove a disk for replacement 5 Replace a failed or removed disk 6 Mirror volumes on a disk 7 Move volumes from a disk 8 Enable access to (import) a disk group 9 Remove access to (deport) a disk group 10 Enable (online) a disk device 11 Disable (offline) a disk device 12 Mark a disk as a hot-spare for a disk group 13 Turn off the hot-spare flag on a disk list List disk information ? Display help about menu ?? Display help about the menuing system q Exit from menus Select an operation to perform: 2 Encapsulate one or more disks Menu: VolumeManager/Disk/Encapsulate Use this operation to convert one or more disks to use the Volume Manager. This adds the disks to a disk group and replaces existing partitions with volumes. Disk encapsulation requires a reboot for the changes to take effect. More than one disk or pattern cab be entered at the prompt. Here are some disk selection examples: all: all disks c3 c4t2: all disks on both controller 3 and controller 4, target 2 c3t4d2: a single disk Select disk devices to encapsulate: [<pattern-list>,all,list,q,?] c0t0d0 Here is the disk selected. Output format: [Device_Name] c0t0d0 Continue operation? [y,n,q,?] (default: y) y You can choose to add this disk to an existing disk group or to a new disk group. To create a new disk group, select a disk name that does not yet exist. Which disk group [<group>,list,q,?] (default: rootdg) rootdg Use a default disk name for the disk? [y,n,q,?] (default: y) n NOTE: Make sure you select "n"; we need to call the drive rootdisk. The selected disks will be encapsulated and added to the rootdg disk group with disk names that will be specified interactively. c0t0d0 Continue with operation? [y,n,q,?] (default: y) y The following disk has been selected for encapsulation. Output format: [Device_Name] c0t0d0 Continue with encapsulation? [y,n,q,?] (default: y) y Enter disk name for [<name>,q,?] (default: disk01) rootdisk The disk device c0t0d0 will be encapsulated and added to the disk group rootdg with the disk name rootdisk. The c0t0d0 disk has been configured for encapsulation. The first stage of encapsulation has completed successfully. You should now reboot your system at the earliest possible opportunity. The encapsulation will require two or three reboots, which will happen automatically after the next reboot. To reboot, execute the command: shutdown -g0 -y -i6 This will update the /etc/vfstab file so that volume devices are used to mount the file systems on this disk device. You will need to update any other references such as backup scripts, databases, or manually created swap devices. Encapsulate other disks? [y,n,q,?] (default: n) n Volume Manager Support Operations Menu: VolumeManager/Disk 1 Add or initialize one or more disks 2 Encapsulate one or more disks 3 Remove a disk 4 Remove a disk for replacement 5 Replace a failed or removed disk 6 Mirror volumes on a disk 7 Move volumes from a disk 8 Enable access to (import) a disk group 9 Remove access to (deport) a disk group 10 Enable (online) a disk device 11 Disable (offline) a disk device 12 Mark a disk as a hot-spare for a disk group 13 Turn off the hot-spare flag on a disk list List disk information ? Display help about menu ?? Display help about the menuing system q Exit from menus Select an operation to perform: q NOTE: We need to reboot for the encapsulation to take effect: # Init 6 This will create volumes around the root partitions. Generally these volumes will be rootvol, swapvol, var, usr, and export but this will vary depending on how the rootdisk was originally created/partitioned. Rebooting will also edit the /etc/system and /etc/vfstab to reflect that the boot disk is now encapsulated. STEP 2---------------------------------------- Now we need to prepare the mirror drive by initializing it into Volume Manager control using vxdiskadm. If you already have the disk initialized skip this step. You can determine if the disk is already initialized by doing a 'vxdisk list'. If the disk is online in the farthest right hand column, that means it has already been initialized. If the disk shows as error, you will need to initialize it. # vxdiskadm Volume Manager Support Operations Menu: VolumeManager/Disk 1 Add or initialize one or more disks 2 Encapsulate one or more disks 3 Remove a disk 4 Remove a disk for replacement 5 Replace a failed or removed disk 6 Mirror volumes on a disk 7 Move volumes from a disk 8 Enable access to (import) a disk group 9 Remove access to (deport) a disk group 10 Enable (online) a disk device 11 Disable (offline) a disk device 12 Mark a disk as a hot-spare for a disk group 13 Turn off the hot-spare flag on a disk list List disk information ? Display help about menu ?? Display help about the menuing system q Exit from menus Select an operation to perform: 1 Add or initialize disks Menu: VolumeManager/Disk/AddDisks Use this operation to add one or more disks to a disk group. You can add the selected disks to an existing disk group or to a new disk group that will be created as a part of the operation. The selected disks can also be added to a disk group as hot spares. The selected disks can also be initialized without adding them to a disk group leaving the disks available for use as replacement disks. More than one disk or pattern may be entered at the prompt. Here are some disk selection examples: all: all disks c3 c4t2: all disks on both controller 3 and controller 4, target 2 c3t4d2: a single disk Select disk devices to add: [<pattern-list>,all,list,q,?] c0t1d0 Here is the disk selected. Output format: [Device_Name] c0t1d0 Continue operation? [y,n,q,?] (default: y) y You can choose to add this disk to an existing disk group, a new disk group, or leave the disk available for use by future add or replacement operations. To create a new disk group, select a disk group name that does not yet exist. To leave the disk available for future use, specify a disk group name of "none". Which disk group [<group>,none,list,q,?] (default: rootdg) rootdg Use a default disk name for the disk? [y,n,q,?] (default: y) n Add disk as a hot-spare disk for rootdg? [y,n,q,?] (default: n) n Exclude disk from hot-relocation use ? [y,n,q,?] (default: n) n The selected disks will be added to the disk group rootdg with disk names that you will specify interactively. c0t1d0 Continue with operation? [y,n,q,?] (default: y) y Add or initialize other disks? [y,n,q,?] (default: n) n Volume Manager Support Operations Menu: VolumeManager/Disk 1 Add or initialize one or more disks 2 Encapsulate one or more disks 3 Remove a disk 4 Remove a disk for replacement 5 Replace a failed or removed disk 6 Mirror volumes on a disk 7 Move volumes from a disk 8 Enable access to (import) a disk group 9 Remove access to (deport) a disk group 10 Enable (online) a disk device 11 Disable (offline) a disk device 12 Mark a disk as a hot-spare for a disk group 13 Turn off the hot-spare flag on a disk list List disk information ? Display help about menu ?? Display help about the menuing system q Exit from menus Select an operation to perform: 6 Mirror volumes on a disk Menu: VolumeManager/Disk/Mirror This operation can be used to mirror volumes on a disk. These volumes can be be mirrored onto another disk or onto any available disk space. Volumes will not be mirrored if they are already mirrored. Also, volumes that are comprised of more than one subdisk will not be mirrored. Mirroring volumes from the boot disk will produce a disk that can be used as an alternate boot disk. At the prompt below, supply the name of the disk containing the volumes to be mirrored. Enter disk name [<disk>,list,q,?] rootdisk You can choose to mirror volumes from disk rootmirror onto any available disk space, or you can choose to mirror onto a specific disk. To mirror to a specific disk, select the name of that disk. To mirror to any available disk space, select "any". Enter destination disk [<disk>,list,q,?] (default: any) disk01 The requested operation is to mirror all volumes on disk rootdisk in disk group rootdg onto available disk space on disk rootmirror. NOTE: This operation can take a long time to complete. Continue with operation? [y,n,q,?] (default: y) y Mirror volume rootvol ... This message will be repeated for all volumes that are mirrored until it is complete. Run: # vxprint -htg rootdg To verify that the mirroring is set up when vxdiskadm is complete. 这个是偶自己做的,呵呵。 mmmmn,你要不加精,偶就suicide -f! |
goldeneye 回复于:2002-12-02 14:52:15 |
现在很奇怪,我的系统是安装在c0t0d0上的,c0上就这么一块硬盘,在c1上原来有一块它的镜像盘,现在我重新做了c0t0d0,然后安装VM,我想是不是重做了,但是它的镜像盘还在,那么,这样的话,盘里面就有了一个rootdg,所以,我在封装c0t0d0的时候报错。但是更怪的是:我停掉了c0t0d0的镜像盘,在vxinstall,还是报我贴出的错误,大家说说,这可能是什么原因? |
YT 回复于:2002-12-02 15:06:45 |
把c1t0d0做了 format newfs 然后再试。 |
goldeneye 回复于:2002-12-02 15:44:14 |
做了,我都把c1t0d0都poweroff了也不行!!!! |
x3y4z5 回复于:2002-12-02 16:08:13 |
建议加精。但是有个问题需要请问yt老大:你介绍的封装root disk是在做了rootdg之后的吧?在root disk上选一个分区作了rootdg,启动了volume manager然后封装整个root disk。不知道我的理解是否正确,老大指正。如果是这样的,楼主的问题好像是开始安装volume manager就将整个root disk进行封装。步骤一样否? |
三少爷 回复于:2002-12-02 16:19:20 |
大家可能把这个问题搞复杂了,主要问题是VM找不到硬盘,我想是漏了patch,要先给系统打一些要求的patch,这在安装要求里有,有几个是关于硬盘的,特别是9G以上的硬盘,更要注意。 |
goldeneye 回复于:2002-12-02 17:26:26 |
我想patch的问题不会有。我的solaris8的版本是(2002/2),patch虽然不是最新的,但是也足够安装VM了,我以前也在这个版本上安装过,没问题,可是就是这次出个小问题 |
YT 回复于:2002-12-02 21:10:19 |
[quote][b]下面引用由[u]x3y4z5[/u]在 [i]2002/12/02 04:08pm[/i] 发表的内容:[/b] 建议加精。但是有个问题需要请问yt老大:你介绍的封装root disk是在做了rootdg之后的吧?在root disk上选一个分区作了rootdg,启动了volume manager然后封装整个root disk。不知道我的理解是否正确,老大指正。 ... [/quote] 是的,我留了1个slice,20MB空间的。 建议这样做,否则以后有问题,要动rootdg就得动整个/了。。 |
sunmarmot 回复于:2002-12-02 22:22:23 |
楼上,偶问你要你都不给偶,现在就直接贴出来了,过分啊~~~~~~~~~~~~![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
laoxia 回复于:2002-12-03 02:10:33 |
> <excluding root disk c0t0d0> No disks were found attached to controller c0 ! Hit RETURN to continue. 如果在C0 上只有一个物理盘的话,就没有错。机器也没说是出错信息,它只是说 “ <excluding root disk c0t0d0>”, 即在探测时不包括c0t0d0。 C0 上几个物理盘? |
goldeneye 回复于:2002-12-03 09:31:33 |
c0上就有一个硬盘阿,就是c0t0d0(系统盘,scsi盘),昨天晚上我按照YT老哥的建议,把原来c0t0d0镜像盘c1t0d0给格式化了,这样再在c0t0d0重新安装VM,但是还是没有成功,还是老毛病。我们老板为了省钱,不卖SUN的服务,以为花1000多块钱雇我就什么事都ok了,我又不是万能的,气人,还挑我的毛病。 好了,不发牢骚了,还请大家多帮忙,要是我解决了,一定把原因,结果贴出来。 要是还有招工的,告诉兄弟一声!!! 感谢楼上各位的热心帮助,谢谢! |
YT 回复于:2002-12-03 10:38:39 |
兄弟,你在c0t0d0上面不是已经做了一次mirror了吗? 要再来一次得把前边的mirror给弄掉了再说啊 |
doubt 回复于:2002-12-03 11:03:39 |
[quote][b]下面引用由[u]zhuzhug[/u]在 [i]2002/12/02 12:35pm[/i] 发表的内容:[/b] SUN公司建议最好用disksuit做系统镜象,如用vm要特别设置 [/quote] 别听SUN公司的人瞎说,光纤盘上用disksuit会害死你的,爆慢! |
doubt 回复于:2002-12-03 11:07:45 |
[quote][b]下面引用由[u]goldeneye[/u]在 [i]2002/12/02 02:52pm[/i] 发表的内容:[/b] 现在很奇怪,我的系统是安装在c0t0d0上的,c0上就这么一块硬盘,在c1上原来有一块它的镜像盘,现在我重新做了c0t0d0,然后安装VM,我想是不是重做了,但是它的镜像盘还在,那么,这样的话,盘里面就有了一个root ... [/quote] 有这个可能,如果有盘曾经被vm做过一定要把它干掉,否则什么错都可能出来。我给他害惨了一次,深刻教训啊! |
doubt 回复于:2002-12-03 11:10:15 |
111413-08打了吗? |
YT 回复于:2002-12-03 11:16:53 |
偶前面的SOLUTION SUMMARY上面说了。 呵呵 |
goldeneye 回复于:2002-12-03 12:06:05 |
这个问题不才小弟解决了,但是问题的原因还是不太清楚,但我想是磁盘阵列里面还有一个rootdg,先说说小弟的解决方法: 当我把系统安装在c0t0d0上的时候,封装它时,提示c0上没有硬盘,我检查过,不是补丁、分区、的问题,format原来的镜像盘,也不行;但是他给出了c1上的所有的硬盘,于是,我就把系统安装在c1d0t0上,封装它没有问题。然后把c0t0d0作为c1d0t0的镜像盘,同步,(要是c1d0t0比c0t0d0大要小心),然后修改eeprom的波boot-devices=c0t0d0,reboot就搞定了!!! 等我查出c0t0d0不能封装的原因,才告诉大家! |
goldeneye 回复于:2002-12-03 12:10:40 |
感谢一直帮助我的老兄们:YT,doubt,laoxia,sunmarmot,三少爷,x3y4z5,yououy,zhuzhug,milan等!谢谢你们的帮助! |
yououy 回复于:2002-12-03 16:33:00 |
doubt: SDS + Fcal HD 慢吗?你自己的问题吧. |
lisuit 回复于:2002-12-03 18:07:21 |
检查下/dev/dmp /dev/rdmp下的设备文件对不对啊? |
byuq 回复于:2002-12-03 23:35:28 |
哎,是你没把c1t0d0做干净!残留了VM的信息在上面!3,4分区一定要做掉才能把做过的DG信息驱除!你在c1t0d0重装了系统,而你的c0t0d0也没封装成功,整个内置的盘中就没有了ROOTDG的信息了,当然就没问题了! |
goldeneye 回复于:2002-12-04 09:36:20 |
现在想想,问题也是很奇怪的,我曾经把c1t0d0关掉以后封装c0t0d0,但是还是提示c0上没有硬盘,如果说原来的c1t0d0盘上有rootdg的信息会影响封装,这又怎么解释呢? |
liuhust 回复于:2002-12-04 11:27:03 |
为什么非要在VM下装solaris,毛病很多 |
doubt 回复于:2002-12-04 16:06:44 |
yououy : 是很慢,在880上试的,mkfile 2g要10多分钟,用vm做的raid5只要2分钟,原因不清,但事实如此,我也想不出我什么地方做的不对,你可以试一下 |
无 回复于:2002-12-04 16:45:55 |
mkfile和做raid 5是一个概念吗? |
doubt 回复于:2002-12-04 17:16:01 |
yououy : 是很慢,在880上试的,mkfile 2g要10多分钟,用vm做的raid5只要2分钟,原因不清,但事实如此,我也想不出我什么地方做的不对,你可以试一下 |
无 回复于:2002-12-04 17:58:33 |
同一个信息为什么要发2遍啊? |
byuq 回复于:2002-12-04 21:38:20 |
楼主所谓的关掉硬盘是怎么关的呢??? |
YT 回复于:2002-12-05 01:08:26 |
断电吧? |
doubt 回复于:2002-12-05 15:12:22 |
[quote][b]下面引用由[u]无[/u]在 [i]2002/12/04 04:45pm[/i] 发表的内容:[/b] mkfile和做raid 5是一个概念吗? [/quote] 是在raid 5上用mkfile测试速度,make同样大小的文件时间短的当然速度就快,还可以算出在这个raid上每秒钟的写速度。发两遍是因为我以为第一次没发出去,所以又按了一下:) |
doubt 回复于:2002-12-05 15:13:54 |
[quote][b]下面引用由[u]byuq[/u]在 [i]2002/12/04 09:38pm[/i] 发表的内容:[/b] 楼主所谓的关掉硬盘是怎么关的呢??? [/quote] 3800上大概可以单独关掉硬盘的电源吧…… |
YT 回复于:2002-12-05 20:12:54 |
哦,是3800的机器啊。。 |
中原一片红 回复于:2002-12-05 22:23:15 |
hao |
lisuit 回复于:2002-12-06 09:35:20 |
能不能关硬盘是由阵列来决定的而不是主机决定的。 |
goldeneye 回复于:2002-12-06 09:37:34 |
我是手动关掉硬盘的,我的阵列是sun A5200,可以从液晶屏幕上开关硬盘,和机器没有什么关系吧! |
byuq 回复于:2002-12-06 16:49:09 |
那只是使硬盘offline,VERATIS仍然能认到。我还以为你把硬盘拔掉了呢!哈哈 |
smcyfl 回复于:2002-12-06 18:02:54 |
你把c0t0d0加入到排除设备文件里把 ,这样他就不能疯装了呀,你看你 的 信息 <excluding root disk c0t0d0> No disks were found attached to controller c0 ! Hit RETURN to continue. 系统在excludeing c0t0d0这个设备呀, |
lisuit 回复于:2002-12-06 18:58:51 |
也可以用命令行来关的。 luxadm power_off BoxName,f/rSlotNumber. f, for front, r for rear. |
YT 回复于:2002-12-06 22:23:12 |
什么事情啊? |
goldeneye 回复于:2002-12-07 09:24:16 |
power-off 掉硬盘VM就看不见了,不是现世offline,而是就看不见这块硬盘;我也没有把c0t0d0加入到排除设备文件里,excludeing c0t0d0这个设备是什么意思? |
YT 回复于:2002-12-07 21:09:11 |
!!! c0t0d0不是本机的disk吗? |
goldeneye 回复于:2002-12-09 09:37:30 |
是啊! |
Lost in spy 回复于:2002-12-09 10:08:09 |
那你不是耍我们吗? |
goldeneye 回复于:2002-12-09 10:15:50 |
???? 我是说c0t0d0不在excludeing devices里面,但是,不能封装 |
Lost in spy 回复于:2002-12-09 10:30:32 |
哦,明白了 |
YT 回复于:2002-12-09 14:38:02 |
偶前面不是有写的吗? |
dou221 回复于:2002-12-09 15:16:16 |
111909-06 111904-05 是VM的PATCH打上看看再说了,SUN 的东西有些时候是没有理由的! |
zzsir 回复于:2003-02-21 14:06:10 |
gg |
helixor 回复于:2003-02-21 16:39:05 |
[quote:61a02d72c0="goldeneye"]这个问题不才小弟解决了,但是问题的原因还是不太清楚,但我想是磁盘阵列里面还有一个rootdg,先说说小弟的解决方法:
当我把系统安装在c0t0d0上的时候,封装它时,提示c0上没有硬盘,我检查过,不是补丁、分区、的?.........[/quote:61a02d72c0] 恭喜。 吐血推荐 ![]() 根盘镜像方法(中文版) http://www.chinaunix.net/bbsjh/3/18371.html 大哥解决了根封装镜像的问题。有没有担心如果以后出现问题,如何解除根镜像和封装呢?要知道,kernel patch和vxvm的 patch对根封装对会有影响。打kernel patch之前的准备工作就是将vxvm的根盘镜像解除掉。 再一次吐血推荐http://www.chinaunix.net/bbsjh/3/18371.html。就我个人而言,强烈反对vxvm的根封装. ![]() |
johnyou 回复于:2003-02-21 18:05:59 |
用命令行做就不受限制了。 |