文章详情

短信预约-IT技能 免费直播动态提醒

请输入下面的图形验证码

提交验证

短信预约提醒成功

GPFS如何在线添加和删除磁盘

2024-04-02 19:55

关注

这篇文章主要为大家展示了“GPFS如何在线添加和删除磁盘”,内容简而易懂,条理清晰,希望能够帮助大家解决疑惑,下面让小编带领大家一起研究并学习一下“GPFS如何在线添加和删除磁盘”这篇文章吧。

一、在线加盘
1、查看当前NSD磁盘
dbfc:/tmp # mmlsnsd -m


 Disk name    NSD volume ID      Device         Node name                Remarks       
---------------------------------------------------------------------------------------
 gpfs1nsd     0AC8016258A2CCC4   /dev/sdc       dbfc.example.com         
 gpfs2nsd     0AC8016258A2CCF2   /dev/sdd       dbfc.example.com         
 gpfs3nsd     0AC8016258A2CD1B   /dev/sde       dbfc.example.com         
 gpfs4nsd     0AC8016258A3AF5D   /dev/sdf       dbfc.example.com         


dbfc:/tmp # mmlsnsd


 File system   Disk name    NSD servers                                    
---------------------------------------------------------------------------
 db2arch       gpfs4nsd     (directly attached)      
 db2data       gpfs2nsd     (directly attached)      
 db2inst       gpfs1nsd     (directly attached)      
 db2log        gpfs3nsd     (directly attached)      


2、编辑NSD配置文件
vi /tmp/nsdprofile
sdg:::dataAndMetadata::


3、创建NSD盘
dbfc:/tmp # mmcrnsd -F /tmp/nsdprofile
mmcrnsd: Processing disk sdg
mmcrnsd: Propagating the cluster configuration data to all
  affected nodes.  This is an asynchronous process.


4、确认创建情况
dbfc:/tmp # mmlsnsd


 File system   Disk name    NSD servers                                    
---------------------------------------------------------------------------
 db2arch       gpfs4nsd     (directly attached)      
 db2data       gpfs2nsd     (directly attached)      
 db2inst       gpfs1nsd     (directly attached)      
 db2log        gpfs3nsd     (directly attached)      
 (free disk)   gpfs5nsd     (directly attached)      


dbfc:/tmp # mmlsnsd -m


 Disk name    NSD volume ID      Device         Node name                Remarks       
---------------------------------------------------------------------------------------
 gpfs1nsd     0AC8016258A2CCC4   /dev/sdc       dbfc.example.com         
 gpfs2nsd     0AC8016258A2CCF2   /dev/sdd       dbfc.example.com         
 gpfs3nsd     0AC8016258A2CD1B   /dev/sde       dbfc.example.com         
 gpfs4nsd     0AC8016258A3AF5D   /dev/sdf       dbfc.example.com    


dbfc:/tmp # mmlsdisk db2data
disk         driver   sector     failure holds    holds                            storage
name         type       size       group metadata data  status        availability pool
------------ -------- ------ ----------- -------- ----- ------------- ------------ ------------
gpfs2nsd     nsd         512          -1 yes      yes   ready         up           system    
gpfs5nsd     nsd         512          -1 yes      yes   ready         up           system    


5、将新建的NSD盘添加到GPFS集群
dbfc:/tmp # cat /tmp/nsdprofile
# sdg:::dataAndMetadata::
gpfs5nsd:::dataAndMetadata:-1::system


dbfc:/tmp # mmadddisk db2data -F /tmp/nsdprofile


The following disks of db2data will be formatted on node dbfc:
    gpfs5nsd: size 10240 MB
Extending Allocation Map
Checking Allocation Map for storage pool system
Completed adding disks to file system db2data.
mmadddisk: Propagating the cluster configuration data to all
  affected nodes.  This is an asynchronous process.
  
6、确认扩容结果
异步同步,所以需要登录所有节点检查
df -h
dbnode02:~ # mmlsnsd


 File system   Disk name    NSD servers                                    
---------------------------------------------------------------------------
 db2arch       gpfs4nsd     (directly attached)      
 db2data       gpfs2nsd     (directly attached)      
 db2data       gpfs5nsd     (directly attached)      
 db2inst       gpfs1nsd     (directly attached)      
 db2log        gpfs3nsd     (directly attached)   


二、 rebalance文件系统
dbfc:/tmp # mmrestripefs db2data -b
Scanning file system metadata, phase 1 ... 
Scan completed successfully.
Scanning file system metadata, phase 2 ... 
Scan completed successfully.
Scanning file system metadata, phase 3 ... 
Scan completed successfully.
Scanning file system metadata, phase 4 ... 
Scan completed successfully.
Scanning user file metadata ...
 100.00 % complete on Thu Apr 13 16:44:28 2017  (    133376 inodes with total       1969 MB data processed)
Scan completed successfully.

三、 动态减盘
dbfc:/tmp # mmrestripefs db2data -b
Scanning file system metadata, phase 1 ... 
Scan completed successfully.
Scanning file system metadata, phase 2 ... 
Scan completed successfully.
Scanning file system metadata, phase 3 ... 
Scan completed successfully.
Scanning file system metadata, phase 4 ... 
Scan completed successfully.
Scanning user file metadata ...
 100.00 % complete on Thu Apr 13 16:44:28 2017  (    133376 inodes with total       1969 MB data processed)
Scan completed successfully.
dbfc:/tmp # mmlsnsd


 File system   Disk name    NSD servers                                    
---------------------------------------------------------------------------
 db2arch       gpfs4nsd     (directly attached)      
 db2data       gpfs2nsd     (directly attached)      
 db2data       gpfs5nsd     (directly attached)      
 db2inst       gpfs1nsd     (directly attached)      
 db2log        gpfs3nsd     (directly attached)      


dbfc:/tmp # mmdeldisk db2data gpfs2nsd
Deleting disks ...
Scanning file system metadata, phase 1 ... 
  73 % complete on Thu Apr 13 16:51:18 2017
 100 % complete on Thu Apr 13 16:51:19 2017
Scan completed successfully.
Scanning file system metadata, phase 2 ... 
Scan completed successfully.
Scanning file system metadata, phase 3 ... 
Scan completed successfully.
Scanning file system metadata, phase 4 ... 
Scan completed successfully.
Scanning user file metadata ...
 100.00 % complete on Thu Apr 13 16:51:28 2017  (    133376 inodes with total       1969 MB data processed)
Scan completed successfully.
Checking Allocation Map for storage pool system
Attention: A disk being removed reduces the number of failure groups to 1,
           which is below the number required for replication: 2.
           New blocks will be allocated from the remaining disks,
           but files will be unreplicated and hence at risk.
tsdeldisk completed.
mmdeldisk: Propagating the cluster configuration data to all
  affected nodes.  This is an asynchronous process.

以上是“GPFS如何在线添加和删除磁盘”这篇文章的所有内容,感谢各位的阅读!相信大家都有了一定的了解,希望分享的内容对大家有所帮助,如果还想学习更多知识,欢迎关注亿速云行业资讯频道!

阅读原文内容投诉

免责声明:

① 本站未注明“稿件来源”的信息均来自网络整理。其文字、图片和音视频稿件的所属权归原作者所有。本站收集整理出于非商业性的教育和科研之目的,并不意味着本站赞同其观点或证实其内容的真实性。仅作为临时的测试数据,供内部测试之用。本站并未授权任何人以任何方式主动获取本站任何信息。

② 本站未注明“稿件来源”的临时测试数据将在测试完成后最终做删除处理。有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341

软考中级精品资料免费领

  • 历年真题答案解析
  • 备考技巧名师总结
  • 高频考点精准押题
  • 2024年上半年信息系统项目管理师第二批次真题及答案解析(完整版)

    难度     813人已做
    查看
  • 【考后总结】2024年5月26日信息系统项目管理师第2批次考情分析

    难度     354人已做
    查看
  • 【考后总结】2024年5月25日信息系统项目管理师第1批次考情分析

    难度     318人已做
    查看
  • 2024年上半年软考高项第一、二批次真题考点汇总(完整版)

    难度     435人已做
    查看
  • 2024年上半年系统架构设计师考试综合知识真题

    难度     224人已做
    查看

相关文章

发现更多好内容

猜你喜欢

AI推送时光机
位置:首页-资讯-数据库
咦!没有更多了?去看看其它编程学习网 内容吧
首页课程
资料下载
问答资讯