1.关闭Linux防火墙
systemctl stop firewalld.service
systemctl diable firewalld.service
2.修改/etc/systemd/system.conf
添加:
DefaultLimitCORE=infinity
DefaultLimitNOFILE=100000
DefaultLimitNPROC=100000
3.创建用户组和用户
groupadd dinstall;
useradd -g dinstall -m -d /home/dmdba -s /bin/bash dmdba;
4.修改/etc/security/limits.conf
添加
dmdba hard nofile 65536
dmdba soft nofile 65536
dmdba hard stack 65536
dmdba soft stack 65536
dmdba hard nproc 65536
dmdba soft nproc 65536
专业机添加
root hard nofile 65536
root soft nofile 65536
root hard nproc 65536
root soft nproc 65536
5.切换到dmdba 用户查看是否生效
su - dmdba
ulimit –a
6.挂载镜像
mount -o loop /opt/dm8_20211021_x86_rh6_64_ent_8.1.2.84.iso /mnt
7.创建DM8安装目录
mkdir /opt/dm
8.更改目录用户及授权
chown –R dmdba:dinstall /opt/dm
chmod -R 755 /opt/dm
9.命令行安装DM
su – dmdba
cd /mnt
./DMInstall.bin –i
10.安装目录
/opt/dm/dmdbms
创建并启动DmAPService服务
切换成root用户执行
/opt/dm/dmdbms/script/root/root_installer.sh
11.配置环境变量
使用root用户进入/home/dmdba目录,配置对应的环境变量。DM_HOME 变量和动态链接库文件的加载路径在程序安装成功后会自动导入。命令如下:
cd /home/dmdba
vim .bash_profile
export PATH=$PATH:$DM_HOME/bin:$DM_HOME/tool
切换dmdba用户是环境变量生效
su - dmdba
source .bash_profile
12.配置实例化
配置环境变量后:
Dminit help
dminit PATH=/opt/dm/dmdbms/data PAGE_SIZE=32 CHARSET=1
不配置环境变量
cd /opt/dm/dmdbms/bin
./dminit help
./dminit PATH=/opt/dm/dmdbms/data PAGE_SIZE=32 CHARSET=1
13.注册实例服务
cd /opt/dm/dmdbms/script/root
./dm_service_installer.sh –t dmserver –p DMSERVER -dm_ini /opt/dm/dmdbms/data/DAMENG/dm.ini
启动服务
systemctl start DmServiceDMSERVER.service