ITPub博客

首页 > Linux操作系统 > Linux操作系统 > 硬盘(硬件镜像)方法!

硬盘(硬件镜像)方法!

Linux操作系统 作者:shilei1 时间:2015-06-04 07:59:36 0 删除 编辑
硬盘(硬件镜像)方法! 
以上 方法是本人 亲自实验 。如有什么问题 本人解答。谢谢!    
一、如何创建硬件磁盘镜像  
# raidctl 
No RAID volumes found.  
上面的示例表示尚不存在RAID 卷。另外一种情况:  
# raidctl 
RAID       RAID      RAID      Disk Volume    Status     Disk      Status ---------------------------------------- c1t1d0     OK       c1t1d0      OK                       c1t2d0    OK  
上表示已创建硬件磁盘镜像.   
下面是创建硬件磁盘镜像操作步骤 1. 键入以下命令: 
# raidctl -c 主设备 从设备 例如: 
# raidctl -c c1t1d0 c1t2d0  
创建RAID 镜像之后,从属驱动器(在本例中为c1t2d0)将从Solaris 设备树中消失。  
2. 要检查RAID 镜像的状态,请键入以下命令:  
# raidctl 
RAID     RAID        RAID      Disk Volume   Status      Disk     Status 
-------------------------------------------------------- c1t1d0   RESYNCING   c1t1d0     OK                      c1t2d0     OK  
上面的示例表示RAID 镜像仍然正在与备份驱动器重新同步。 下面的示例表示RAID 镜像已完全恢复并且联机。
# raidctl

RAID  

   

 RAID  

   

 RAID  

   Disk 

Volume  

  

Status  

  

Disk  

  

Status 

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

c1t1d0  

  

OK  

   

   c1t1d0  

  

OK 

  

   

   

   

   

   

   c1t2d0  

  

OK 

 

 

二、如何删除硬件磁盘镜像

 

 

操作步骤

 

1. 

确定镜像卷的名称。键入以下命令:

 

# raidctl -d 

镜像卷

 

例如:

 

# raidctl -d c1t2d0 

RAID 

Volume ’c1t2d0’ deleted

 

 

3. 

要确认已经删除了

RAID 

阵列,请键入以下命令:

 

# raidctl 

例如:

 

# raidctl 

No RAID volumes found 

 

 

三、如何执行镜像磁盘热插拔操作

 

 

# raidctl 

RAID  

   RAID  

   

 RAID  

  

Disk 

Volume  

 Status  

  

Disk  

  

Status 

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

c1t1d0  

 DEGRADED  c1t1d0  

 OK 

  

   

   

   

   

   

  

c1t2d0  

 DEGRADED 

 

 

本示例表示由于磁盘

c1t2d0 

上出现故障而导致磁盘镜像失效。

 

 

操作步骤

 

1. 

要从设备树中删除该磁盘驱动器,请键入以下命令:

 

# cfgadm -x unconfigure /dev/rdsk/c1t2d0 

或

cfgadm -c unconfigure c1::dsk/c1t2d0 

 

如果驱动器失效且

“

可以拆卸

” LED 

已亮,则不必发出软件命令使驱动器脱机。

 

where c1t2d0 is the name of the disk drive to be rem

oved. 

The blue OK-to-Remove disk drive LED lights. 

 

插入新盘

,RAID 

实用程序自动在此磁盘上恢复数据。

RAID      RAID      RAID     Disk Volume    Status    Disk    Status ------------------------------------ c1t1d0    OK        c1t1d0    OK                     c1t2d0    OK   
二、如何删除硬件磁盘镜像  
操作步骤 
1. 确定镜像卷的名称。键入以下命令: # raidctl -d 镜像卷 例如: 
# raidctl -d c1t2d0 
RAID Volume ’c1t2d0’ deleted  
3. 要确认已经删除了RAID 阵列,请键入以下命令: # raidctl 例如: # raidctl 
No RAID volumes found   
三、如何执行镜像磁盘热插拔操作  
# raidctl 
RAID     RAID      RAID    Disk Volume   Status    Disk    Status ---------------------------------------- c1t1d0   DEGRADED  c1t1d0   OK                    c1t2d0   DEGRADED   
本示例表示由于磁盘c1t2d0 上出现故障而导致磁盘镜像失效。  
操作步骤 
1. 要从设备树中删除该磁盘驱动器,请键入以下命令: # cfgadm -x unconfigure /dev/rdsk/c1t2d0 或cfgadm -c unconfigure c1::dsk/c1t2d0  
如果驱动器失效且“可以拆卸” LED 已亮,则不必发出软件命令使驱动器脱机。 where c1t2d0 is the name of the disk drive to be removed. The blue OK-to-Remove disk drive LED lights.  
插入新盘,RAID 实用程序自动在此磁盘上恢复数据。

# cfgadm -x configure /dev/rdsk/c1t2d0 或cfgadm -c unconfigure c1::dsk/c1t2d0  
此时“可以拆卸”LED熄灭,绿色活动灯闪烁,该磁盘加入到设备树 where c1t2d0 is the name of the disk drive to be configured. 
The blue OK-to-Remove LED goes out, and the green Activity LED flashes as the disk drive is added to the device tree.  
要检查已重建的RAID 的状态,请键入以下命令: # raidctl  
# raidctl 
RAID      RAID       RAID      Disk Volume    Status     Disk      Status ---------------------------------------- c1t1d0    RESYNCING  c1t1d0     OK                      c1t2d0     OK  
此示例表示RAID 卷c1t1d0 正在重新同步,同步需几分钟,再执行raidctl。  
# raidctl 
RAID       RAID    RAID    Disk Volume    Status   Disk    Status ---------------------------------------- c1t1d0     OK     c1t1d0    OK                   c1t2d0    OK

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/196700/viewspace-1685749/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2018-10-10

  • 博文量
    548
  • 访问量
    130254