RHEL6下安装GPFS 3.5的具体过程


RHEL6下安装GPFS 3.5的具体过程
 
安装gpfs集群文件系统
 
已三台主机为例
1,    安装gpfs软件(三台主机上运行)
本次从db2 purescale安装介质中直接安装,其它安装方法见参考文献
yum install /tmp/gpfs/*.rpm
rpm –qa gpfs验证软件是否已经正确安装
2,编译相关软件,安装并已后的rpm包
cd /usr/lpp/mmfs/src && make Autoconfig && make World && make InstallImages
[root@linux1 src]# make rpm
安装编译完自动生成的RPM 包
yum install /root/rpmbuild/RPMS/x86_64/gpfs.gplbin-2.6.32-131.0.15.el6.x86_64-3.5.0-0.x86_64.rpm
3,    修改PATH路径(三台主机上运行)
 
在3 台主机上修改HOME目录下的。bash_profile文件,在文件末尾增加
export PATH=$PATH:/usr/lpp/mmfs/bin
4,    新建目录,用做GPFS文件系统(三台主机上运行)
mkdir /db2fs
5,    创建gpfs 群集配置文件
[root@wtydb21 tmp]# vi /tmp/gpfsprofile
wtydb21:quorum-manager
wtydb22:quorum-manager
wtydb23:quorum-manager
6,创建集群,注意指定ssh方式
[root@wtydb21 pam.d]# 
[root@wtydb21 gpfs]# mmcrcluster -N /tmp/gpfsprofile  -p wtydb21 -s wtydb22  -C gpfs_cluster -r /usr/bin/ssh -R /usr/bin/scp
Sat Apr  6 12:17:35 CST 2013: mmcrcluster: Processing node wtydb21
Sat Apr  6 12:17:35 CST 2013: mmcrcluster: Processing node wtydb22
Sat Apr  6 12:17:38 CST 2013: mmcrcluster: Processing node wtydb23
mmcrcluster: Command successfully completed
mmcrcluster: Warning: Not all nodes have proper GPFS license designations.
    Use the mmchlicense command to designate licenses as needed.
mmcrcluster: Propagating the cluster configuration data to all
  affected nodes.  This is an asynchronous process.
 
mmcrcluster 命令其中参数含义
-C bgbcrun 设定集群名称
-U bgbc 定义域名
-N /tmp/gpfs/nodefile 指定节点文件名
-p NSD1 指定主NSD 服务器为 NSD1
-s NSD1 指定备NSD 服务器为 NSD1
7,接受许可协议
[root@wtydb21 pam.d]# mmchlicense server --accept -N wtydb21,wtydb22,wtydb23
8,确认创建集群状况
[root@wtydb21 ~]# mmlscluster
[root@wtydb21 gpfs]# mmlscluster
 
GPFS cluster information
========================
  GPFS cluster name:         gpfs_cluster.wtydb21
  GPFS cluster id:           12146727015547904479
  GPFS UID domain:           gpfs_cluster.wtydb21
  Remote shell command:      /usr/bin/ssh
  Remote file copy command:  /usr/bin/scp
 
GPFS cluster configuration servers:
-----------------------------------
  Primary server:    wtydb21
  Secondary server:  wtydb22
 
 Node  Daemon node name  IP address   Admin node name  Designation
-------------------------------------------------------------------
   1   wtydb21           10.4.52.101  wtydb21          quorum-manager
   2   wtydb22           10.4.52.102  wtydb22          quorum-manager
   3   wtydb23           10.4.52.103  wtydb23          quorum-manager
9,生成nsd 盘,使用/dev/dm-3
 
[root@wtydb21 etc]# vi /tmp/nsdprofile
dm-3:::dataAndMetadata::
[root@wtydb21 gpfs]#  mmcrnsd -F /tmp/nsdprofile
mmcrnsd: Processing disk dm-3
mmcrnsd: Propagating the cluster configuration data to all
  affected nodes.  This is an asynchronous process.
 
此时系统自动修改/tmp/gpfsnsdprofile 文件内容如下:
[root@wtydb21 ~]# cat /tmp/nsdprofile
# dm-4:::dataAndMetadata::
gpfs1nsd:::dataAndMetadata:-1::system
 
10,启动集群
[root@wtydb21 /]# mmstartup -a
.
[root@wtydb21 src]# mmgetstate -a -L
 
 Node number  Node name       Quorum  Nodes up  Total nodes  GPFS state  Remarks    
------------------------------------------------------------------------------------
       1      wtydb21            2        2          3       active      quorum node
       2      wtydb22            2        2          3       active      quorum node
       3      wtydb23            2        2          3       active      
11,创建gpfs 文件系统
[root@wtydb21 src]# mmcrfs /db2fs gpfs_lv -F /tmp/nsdprofile -A yes -n 30 -v no
 
The following disks of gpfs_lv will be formatted on node wtydb21:
    gpfs1nsd: size 100829184 KB
Formatting file system ...
Disks up to size 848 GB can be added to storage pool system.
Creating Inode File
Creating Allocation Maps
Creating Log Files
Clearing Inode Allocation Map
Clearing Block Allocation Map
Formatting Allocation Map for storage pool system
Completed creation of file system /dev/gpfs_lv.
mmcrfs: Propagating the cluster configuration data to all
  affected nodes.  This is an asynchronous process.
 
参数含义如下:
/datafs 文件系统 mount 点名
gpfs_lv 指定文件系统 lv 名
-F 指定 NSD 的文件名
-A 自动 mount 选项为 yes
-B 块大小为64K
-n 挂载文件系统的节点估计数30 个
-v 校验建立磁盘是否已有文件系统 为否
12,挂载文件系统
[root@wtydb21 /]# mount /db2fs
[root@wtydb21 /]# df
 
13,设置gpfs 开机自启
[root@wtydb21 /]# mmchconfig autoload=yes
 
14,查询GPFS 配置信息
[root@wtydb21 share]# mmlsconfig
 
[root@wtydb21 share]# mmgetstate -a
 
15,备注:第一次安装gpfs后,版本不对,导致数据库不能正确启动,下载并升级后3.5.0.2后问题解决
[root@sdcmpdb1 ~]# mmstartup -a
mmstartup: Required service not applied. Install GPFS 3.5.0.1 or later.
mmstartup: Command failed.  Examine previous error messages to determine cause.

相关内容

    暂无相关文章