Architecture Overview
DM Data Shared Cluster (DMDSC) is a shared-disk architecture that allows multiple database instances to read and write the same database concurrently while providing fault-tolerance and load-balancing. Core components:
- Database instances – multi-threaded server processes plus shared memory.
- Shared storage – data, control, redo and clusterware files reside on disks visible to every node.
- Local storage – instance-specific configuration, archived logs, backups.
- Networks – private (MAL traffic) and public (client access).
- DMCSS – clusterware that starts/stops services, handles failures and re-joins.
Clusterware Objects
| Object | Purpose | Placemant | Notes |
|---|---|---|---|
| DCR | Registry of cluster topology | Shared raw LUN | Exactly one per cluster |
| Voting Disk | Heart-beat & split-brain arbitration | Shared raw LUN | Exactly one per cluster |
| DMASM disks | User data, redo, temp | Shared raw LUNs | Grouped into disk-groups |
Preparing the Environment
Host layout
| Node | Public IP | Private IP | OS |
|---|---|---|---|
| dmdb01 | 192.168.10.201 | 172.168.0.201 | Kylin V10 |
| dmdb02 | 192.168.10.202 | 172.168.0.202 | Kylin V10 |
Storage layout
| ASM group | Size | ASM disks |
|---|---|---|
| DCR | 1 GB | /dev/dmasm/dcr |
| VOTE | 1 GB | /dev/dmasm/vote |
| DMLOG | 10 GB | /dev/dmasm/log |
| DMDATA | 500 GB × n | /dev/dmasm/data* |
OS prerequisites (run on both nodes as root)
# hostnames
hostnamectl set-hostname dmdb01 # node 1
hostnamectl set-hostname dmdb02 # node 2
cat >> /etc/hosts <<EOF
192.168.10.201 dmdb01
172.168.0.201 dmdb01-priv
192.168.10.202 dmdb02
172.168.0.202 dmdb02-priv
EOF
# security
cat > /etc/selinux/config <<EOF
SELINUX=disabled
EOF
setenforce 0
systemctl disable --now firewalld
# user & directories
useradd -g dinstall -m -d /home/dmdba -s /bin/bash dmdba
echo "dmdba ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers
mkdir -p /dm/{dbms,dbconf,arch,backup}
chown -R dmdba:dinstall /dm
# udev rules for shared disks
cat > /etc/udev/rules.d/99-dmasm.rules <<'EOF'
KERNEL=="sd*", ENV{DEVTYPE}=="disk", \
PROGRAM=="/lib/udev/scsi_id -g -u -d /dev/%k", \
RESULT=="36000c29df8b346cd16bc4f82414dc2b9", \
SYMLINK+="dmasm/dcr", OWNER="dmdba", GROUP="dinstall", MODE="0660"
# repeat for vote, log, data001, data002 …
EOF
udevadm control --reload-rules && udevadm trigger
Installing DM8
# mount ISO and copy installer
mount -o loop dm8_*.iso /mnt
cp /mnt/DMInstall.bin /dm/soft/
chown dmdba:dinstall /dm/soft/DMInstall.bin
# silent install
su - dmdba -c "
cat > auto.xml <<EOF
<DATABASE>
<LANGUAGE>en</LANGUAGE>
<INSTALL_PATH>/dm/dbms</INSTALL_PATH>
<INIT_DB>n</INIT_DB>
</DATABASE>
EOF
/dm/soft/DMInstall.bin -q auto.xml"
# run root script
/dm/dbms/script/root/root_installer.sh
Clusterware Configuration
1. DCR & Voting disk layout file (/dm/dbconf/dmdcr_cfg.ini – identical on both nodes)
DCR_N_GRP = 3
DCR_VTD_PATH = /dev/dmasm/vote
DCR_OGUID = 63635
[GRP]
DCR_GRP_TYPE = CSS
DCR_GRP_NAME = GRP_CSS
DCR_GRP_N_EP = 2
[GRP_CSS]
DCR_EP_NAME = CSS01
DCR_EP_HOST = 172.168.0.201
DCR_EP_PORT = 9341
[GRP_CSS]
DCR_EP_NAME = CSS02
DCR_EP_HOST = 172.168.0.202
DCR_EP_PORT = 9341
[GRP]
DCR_GRP_TYPE = ASM
DCR_GRP_NAME = GRP_ASM
DCR_GRP_N_EP = 2
[GRP_ASM]
DCR_EP_NAME = ASM01
DCR_EP_SHM_KEY = 93360
DCR_EP_SHM_SIZE = 10
DCR_EP_HOST = 172.168.0.201
DCR_EP_PORT = 9351
DCR_EP_ASM_LOAD_PATH = /dev/dmasm
[GRP_ASM]
DCR_EP_NAME = ASM02
DCR_EP_SHM_KEY = 93361
DCR_EP_SHM_SIZE = 10
DCR_EP_HOST = 172.168.0.202
DCR_EP_PORT = 9351
[GRP]
DCR_GRP_TYPE = DB
DCR_GRP_NAME = GRP_DSC
DCR_GRP_N_EP = 2
[GRP_DSC]
DCR_EP_NAME = DSC01
DCR_EP_SEQNO = 0
DCR_EP_PORT = 5237
DCR_CHECK_PORT = 9741
[GRP_DSC]
DCR_EP_NAME = DSC02
DCR_EP_SEQNO = 1
DCR_EP_PORT = 5237
DCR_CHECK_PORT = 9741
2. Format clusterware disks
Create /dm/dbconf/init_dcr_vote.sql:
#asm script file
create dcrdisk '/dev/dmasm/dcr' 'DCR'
create votedisk '/dev/dmasm/vote' 'VOTE'
create asmdisk '/dev/dmasm/log' 'LOG'
create asmdisk '/dev/dmasm/data001' 'DATA001'
create asmdisk '/dev/dmasm/data002' 'DATA002'
init dcrdisk '/dev/dmasm/dcr' from '/dm/dbconf/dmdcr_cfg.ini' identified by 'StrongP@ss!'
init votedisk '/dev/dmasm/vote' from '/dm/dbconf/dmdcr_cfg.ini'
Run once from any node:
/dm/dbms/bin/dmasmcmd script_file=/dm/dbconf/init_dcr_vote.sql
3. Node-specific dmdcr.ini
dmdb01 (/dm/dbconf/dmdcr.ini):
DMDCR_PATH = /dev/dmasm/dcr
DMDCR_MAL_PATH = /dm/dbconf/dmasvrmal.ini
DMDCR_SEQNO = 0
DMDCR_ASM_RESTART_INTERVAL = 10
DMDCR_ASM_STARTUP_CMD = "/dm/dbms/bin/dmasmsvr dcr_ini=/dm/dbconf/dmdcr.ini"
DMDCR_DB_RESTART_INTERVAL = 30
DMDCR_DB_STARTUP_CMD = "/dm/dbms/bin/dmserver path=/dm/dbconf/dsc01/dm.ini dcr_ini=/dm/dbconf/dmdcr.ini"
dmdb02 – identical except:
DMDCR_SEQNO = 1
DMDCR_DB_STARTUP_CMD = "/dm/dbms/bin/dmserver path=/dm/dbconf/dsc02/dm.ini dcr_ini=/dm/dbconf/dmdcr.ini"
4. MAL configuration
ASM MAL (/dm/dbconf/dmasvrmal.ini – identical):
[MAL_INST1]
MAL_INST_NAME = ASM01
MAL_HOST = 172.168.0.201
MAL_PORT = 7236
[MAL_INST2]
MAL_INST_NAME = ASM02
MAL_HOST = 172.168.0.202
MAL_PORT = 7236
DB MAL (/dm/dbconf/dsc01/dmmal.ini and /dm/dbconf/dsc02/dmmal.ini):
[MAL_INST1]
MAL_INST_NAME = DSC01
MAL_HOST = 172.168.0.201
MAL_PORT = 9236
[MAL_INST2]
MAL_INST_NAME = DSC02
MAL_HOST = 172.168.0.202
MAL_PORT = 9236
Creating ASM Disk-Groups
Start CSS and ASM on both nodes (foreground for first time):
# terminal 1
dmcss DCR_INI=/dm/dbconf/dmdcr.ini
# terminal 2
dmasmsvr DCR_INI=/dm/dbconf/dmdcr.ini
When both are running, from one node:
dmasmtool DCR_INI=/dm/dbconf/dmdcr.ini
ASM> create diskgroup 'DMLOG' asmdisk '/dev/dmasm/log'
ASM> create diskgroup 'DMDATA' asmdisk '/dev/dmasm/data001'
ASM> alter diskgroup 'DMDATA' add asmdisk '/dev/dmasm/data002'
Database Creation
dminit.ini (run once on dmdb01)
db_name = prod
system_path = +DMDATA/data
system = +DMDATA/data/prod/system.dbf
system_size = 128
roll = +DMDATA/data/prod/roll.dbf
roll_size = 128
main = +DMDATA/data/prod/main.dbf
main_size = 128
ctl_path = +DMDATA/data/prod/dm.ctl
log_size = 1024
dcr_path = /dev/dmasm/dcr
dcr_seqno = 0
auto_overwrite = 1
[DSC01]
config_path = /dm/dbconf/dsc01
port_num = 5237
mal_host = 172.168.0.201
mal_port = 9236
log_path = +DMLOG/log/dsc01_01.log
log_path = +DMLOG/log/dsc01_02.log
[DSC02]
config_path = /dm/dbconf/dsc02
port_num = 5237
mal_host = 172.168.0.202
mal_port = 9236
log_path = +DMLOG/log/dsc02_01.log
log_path = +DMLOG/log/dsc02_02.log
Create and distribute:
/dm/dbms/bin/dminit control=/dm/dbconf/dminit.ini
scp -r /dm/dbconf/dsc02 dmdba@dmdb02:/dm/dbconf/
Service Registration
# CSS
/dm/dbms/script/root/dm_service_installer.sh -t dmcss -dcr_ini /dm/dbconf/dmdcr.ini -p CSS
# ASM
/dm/dbms/script/root/dm_service_installer.sh -t dmasmsvr -dcr_ini /dm/dbconf/dmdcr.ini -p ASM -y DmCSSServiceCSS
# DB instances
/dm/dbms/script/root/dm_service_installer.sh -t dmserver -dm_ini /dm/dbconf/dsc01/dm.ini -dcr_ini /dm/dbconf/dmdcr.ini -p DSC01 -y DmASMSvrServiceASM
ssh dmdb02 '/dm/dbms/script/root/dm_service_installer.sh -t dmserver -dm_ini /dm/dbconf/dsc02/dm.ini -dcr_ini /dm/dbconf/dmdcr.ini -p DSC02 -y DmASMSvrServiceASM'
Start services:
systemctl enable --now DmCSSServiceCSS
systemctl enable --now DmASMSvrServiceASM
systemctl enable --now DmServiceDSC01
ssh dmdb02 'systemctl enable --now DmServiceDSC02'
Client Connectivity
Create /etc/dm_svc.conf on client hosts:
prod_dsc=(192.168.10.201:5237,192.168.10.202:5237)
SWITCH_TIME=(10000)
SWITCH_INTERVAL=(100)
Connect string:
jdbc:dm://prod_dsc
Enabling Archiving
Node 1
-- after mounting
alter database archivelog;
alter database add archivelog 'DEST=/dmarch/local, TYPE=LOCAL, FILE_SIZE=1024, SPACE_LIMIT=102400';
alter database add archivelog 'DEST=DSC02, TYPE=REMOTE, FILE_SIZE=1024, SPACE_LIMIT=102400, INCOMING_PATH=/dmarch/remote';
alter database open;
Node 2
alter database archivelog;
alter database add archivelog 'DEST=/dmarch/local, TYPE=LOCAL, FILE_SIZE=1024, SPACE_LIMIT=102400';
alter database add archivelog 'DEST=DSC01, TYPE=REMOTE, FILE_SIZE=1024, SPACE_LIMIT=102400, INCOMING_PATH=/dmarch/remote';
alter database open;
Monitoring
CSS Monitor
Create /dm/dbconf/dmcssm.ini:
CSSM_OGUID = 63635
CSSM_CSS_IP = 172.168.0.201:9341
CSSM_CSS_IP = 172.168.0.202:9341
CSSM_LOG_PATH = /dm/dbms/log
CSSM_LOG_FILE_SIZE = 1024
Launch:
dmcssm INI_PATH=/dm/dbconf/dmcssm.ini
CSSM> show
Useful SQL views
-- cluster topology
select * from v$dsc_ep_info;
select * from v$dcr_info;
-- ASM space
select group_name, disk_name, total_mb, free_mb
from v$asm_diskgroup d join v$asm_disk g using(group_number);
-- redo layout
select group_id, file_id, path from v$rlogfile order by 1,2;