mount -t auto /dev/cdrom /mnt
rm -rf /etc/yum.repos.d/
mkdir -p /etc/yum.repos.d/
cat >> /etc/yum.repos.d/CentOS-Media.repo<
安装好Linux操作系统,这里选择的是Linux 7:
关闭防火墙 和 Selinux:
systemctl status firewalld
systemctl stop firewalld
systemctl disable firewalld
sed -i 's/=enforcing/=disabled/g' /etc/selinux/config
setenforce 0
getenforce
修改/etc/hosts 文件:
[root@dm1 ~]# cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.31.166 dm1
[root@dm1 ~]#
hostnamectl set-hostname
创建DM用户:
groupadd dinstall
useradd -g dinstall -m -d /home/dmdba -s /bin/bash dmdba
passwd dmdba
创建目录:存储dm数据库文件的空间需要提前规划并挂载好,我这里放在/dm目录下:
mkdir -p /dm/dmdbms
mkdir -p /dm/dmarch
mkdir -p /dm/dmbak
chown -R dmdba:dinstall /dm/
chmod -R 775 /dm/
配置系统限制,在/etc/security/limits.conf 文件中添加如下内容:
cat >> /etc/security/limits.conf << EOF
dmdba soft nofile 4096
dmdba hard nofile 65536
EOF
ulimit -a
配置环境变量:在dmdba用户的~/.bash_profile 里添加如下内容:
cat >>/home/dmdba/.bash_profile<
复制安装文件: 将DM的ISO上传到Linux系统,并挂载:
[root@dm1 dm]# mount -o loop dm8_setup_rh7_64_ent_8.1.1.45_20191121.iso /mnt
mount: /dev/loop0 is write-protected, mounting read-only
将安装文件复制到/dm 目录下并修改安装文件权限:
[root@dm1 mnt]# cp DMInstall.bin /dm/.
[root@dm1 dm]# chown -R dmdba:dinstall /dm
用dmdba用户执行./DMInstall.bin 程序,开始图形安装:
一直next,中间有选择安装路径选择/dm/dmdbms
一直到执行脚本
使用root账户执行脚本
[root@dm1 dmdbms]# cd /dm/dmdbms/script/root/
[root@dm1 root]# ./root_installer.sh
Move /dm/dmdbms/bin/dm_svc.conf to /etc
Modify the files' mode of DM Server
Create the DmAPService service
Created symlink from /etc/systemd/system/multi-user.target.wants/DmAPService.service to /usr/lib/systemd/system/DmAPService.service.
Finished to create the service (DmAPService)
Start the DmAPService service
完成安装
连接进入库看看效果:
[dmdba@dm1 ~]$ disql sysdba/Dm1234567@dm1:5236
Server[dm1:5236]:mode is normal, state is open
login used time: 3.849(ms)
disql V8
SQL> select * from v$version;
LINEID BANNER
---------- -------------------------
1 DM Database Server 64 V8
2 DB Version: 0x7000a
used time: 2.668(ms). Execute id is 989.
SQL> desc v$database;
LINEID NAME TYPE$ NULLABLE
---------- -------------- ------------ --------
1 NAME VARCHAR(128) Y
2 CREATE_TIME DATETIME(0) Y
3 ARCH_MODE CHAR(1) Y
4 LAST_CKPT_TIME DATETIME(0) Y
5 STATUS$ TINYINT Y
6 ROLE$ TINYINT Y
7 MAX_SIZE BIGINT Y
8 TOTAL_SIZE BIGINT Y
9 DSC_NODES INTEGER Y
10 OPEN_COUNT INTEGER Y
11 STARTUP_COUNT BIGINT Y
LINEID NAME TYPE$ NULLABLE
---------- ----------------- ----------- --------
12 LAST_STARTUP_TIME DATETIME(0) Y
12 rows got
used time: 7.708(ms). Execute id is 990.
SQL> select name from v$database;
LINEID NAME
---------- ------
1 DAMENG
used time: 1.471(ms). Execute id is 991.
SQL>
至此DM8数据安装完成