19cRAC 2Node 기준 설치를 해 보도록 하겠습니다.
웹 사이트에 보시면 많은 분들이 설치 내용을 기입 해 주셔서 올리는것을 고민만 하다가 글을 적어 봅니다.
부족한 설명부분은 메뉴얼 , MOS, 자료실등 참고 부탁 드립니다.
중복성으로 기입 할 필요성이 없을 경우는 내용을 축소 하여 기입 한 점 미리 말씀 드립니다.
예로 ) 1Node 로그는 있으나 2Node 로그는 제외 , fdisk 설정 로그 제외
그리고 사전 Oracle VM 설정이 완료 되어야 하고, OS 설치는 할 줄 알아야 합니다.
그 외 물리적이 하드웨어 스펙인 메모리 , 디스크가 넉넉 하게 있어야 하는 점 미리 말씀 드리고 출발 합니다.
사전준비작업 -> grid 설치 -> db sw 설치 -> 패치적용 -> db 생성
또는
사전준비작업 -> grid 설치 -> db sw 설치 -> db 생성 -> 패치적용
둘중 하나의 방법으로 초기 설치를 하시면 됩니다.
1. 윈도우 OS 또는 리눅스 OS
2. Oracle VirtualBox - 무료
3. Oracle SW ( 리눅스버전) - 회원 가입 필요
4. Linux OS - 오라클에서 인증된 OS
6. 최신 패치 - MOS 인증 된 ID로 로그인 후 다운로드
7. VNC sw - 무료
1. 설치를 위한 사전 구성 작업
물론 그 전에 어떤 os가 선택이 되는지가 더 중요 하겠지만, 현재 OS는 특이 사항이 아니면 X86 리눅스 버전을 설치 하도록 하겠습니다.
메뉴얼을 보고 최소 사이즈는 아래와 같이 가이드를 해 봅니다. ( 정답은 아닌점 미리 말씀 드립니다.)
엔진 설치 가이드 패치 적용까지 : 100G -> 다소 적어도 됨
OCR , VOTE DISK 분리 시 2G ~ 5G 이내
GIMR - MGMT DISK 분리 시 35G 이상
DATA Disk 분리 : 가용 가능한 공간
아카이브 파일 분리 시 : 50GB 이상 , 그 외 FRA 영역 고려 필요.
2. 사전 구성 작업 참고 자료.
Storage Checklist for Oracle Grid Infrastructure
Table 1-6 Oracle Grid Infrastructure Storage Configuration Checks
https://docs.oracle.com/en/database/oracle/oracle-database/19/cwadd/managing-oracle-cluster-registry-and-voting-files.html#GUID-20101C89-B87C-49C9-BA63-634376EDB62E
Oracle Clusterware Storage Space Requirements
https://docs.oracle.com/en/database/oracle/oracle-database/12.2/cwlin/oracle-clusterware-storage-space-requirements.html#GUID-97FD5D40-A65B-4575-AD12-06C491AF3F41
https://docs.oracle.com/en/database/oracle/oracle-database/18/cwlin/oracle-clusterware-storage-space-requirements.html#GUID-97FD5D40-A65B-4575-AD12-06C491AF3F41
https://docs.oracle.com/en/database/oracle/oracle-database/19/cwlin/oracle-clusterware-storage-space-requirements.html#GUID-97FD5D40-A65B-4575-AD12-06C491AF3F41
Minimum Available Space Requirements for Oracle Standalone Cluster Without GIMR Configuration
3. OS 준비 작업
1. 오라클 리눅스 설치 인지 레드헷인지를 결정 하시면 됩니다.
- 오라클 리눅스는 회원가입 후 무료
- 레드헷은 이미지를 따로 구하셔야 합니다.
2. OS설치 영역
/ 영역 : 10기가
swap 영역 : 물리메모리의 1.5 이상
/boot 영역 : 500 메가
/db : db sw 25기가 공간
/dg : grid sw 35기가 공간
3. 공유디스크 준비
20기가 : 5ea
10기가 : 1ea
16기가 : 1ea
2기가 : 1ea
4. os 로컬디스크 추가분
10기가 : 2ea => 각각의 노드에 추가 예정
5. 여유분 공유디스크
8 기가 : 1ea => 공유파일시스템으로 사용 예정
4. os 세팅
2. 네트워크 설정도 완료
-> 네트워크 카드 등록은 최소 두개 이지만 저는 3개를 등록 하였습니다.
Oracle VitualBox 사용에 숙지가 필요한 부분입니다.
==> 1번, 2번 OS 디스크 할당 내용 설명
/ : os 설치영역
/db : db sw
/dg : grid sw
/LOGS : 추가분 디스크 마운트 완료 된 상태
네트웍크 IP는 아래와 같고 저희집은 SKT 통신사를 사용 중이지만 DNS 정보는 우선 제외 하겠습니다.
::::::::::::::
/etc/sysconfig/network-scripts/ifcfg-enp0s3
::::::::::::::
TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=none
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=no
IPV6_AUTOCONF=yes
IPV6_DEFROUTE=yes
IPV6_FAILURE_FATAL=no
IPV6_ADDR_GEN_MODE=stable-privacy
NAME=enp0s3
DEVICE=enp0s3
ONBOOT=yes
IPADDR=192.168.0.55
PREFIX=24
GATEWAY=192.168.0.1
DNS1=xxx.xxx.xxx.xxx
DNS2=xxx.xxx.xxx.xxx
::::::::::::::
/etc/sysconfig/network-scripts/ifcfg-enp0s8
::::::::::::::
HWADDR=08:00:27:2D:17:10
TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=none
IPADDR=10.10.20.55
PREFIX=24
GATEWAY=192.168.0.1
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=no
NAME=enp0s8
ONBOOT=yes
::::::::::::::
/etc/sysconfig/network-scripts/ifcfg-enp0s9
::::::::::::::
HWADDR=08:00:27:00:51:50
TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=none
IPADDR=192.168.20.55
PREFIX=24
GATEWAY=192.168.20.1
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=no
NAME=enp0s9
ONBOOT=yes
[root@db19c1 ~]#
[root@db19c2 ~]# more /etc/sysconfig/network-scripts/ifcfg-enp0s*
::::::::::::::
/etc/sysconfig/network-scripts/ifcfg-enp0s3
::::::::::::::
TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=none
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=no
IPV6_AUTOCONF=yes
IPV6_DEFROUTE=yes
IPV6_FAILURE_FATAL=no
IPV6_ADDR_GEN_MODE=stable-privacy
NAME=enp0s3
DEVICE=enp0s3
ONBOOT=yes
IPADDR=192.168.0.57
PREFIX=24
GATEWAY=192.168.0.1
DNS1=xxx.xxx.xxx.xxx
DNS2=xxx.xxx.xxx.xxx
::::::::::::::
/etc/sysconfig/network-scripts/ifcfg-enp0s3.bk
::::::::::::::
TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=none
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=no
IPV6_AUTOCONF=yes
IPV6_DEFROUTE=yes
IPV6_FAILURE_FATAL=no
IPV6_ADDR_GEN_MODE=stable-privacy
NAME=enp0s3
DEVICE=enp0s3
ONBOOT=yes
IPADDR=192.168.0.57
PREFIX=24
GATEWAY=192.168.0.1
DNS1=xxx.xxx.xxx.xxx
DNS2=xxx.xxx.xxx.xxx
HWADDR=08:00:27:23:90:20
::::::::::::::
/etc/sysconfig/network-scripts/ifcfg-enp0s8
::::::::::::::
HWADDR=08:00:27:6B:8F:60
TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=none
IPADDR=10.10.20.57
PREFIX=24
GATEWAY=192.168.0.1
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=no
NAME=enp0s8
ONBOOT=yes
::::::::::::::
/etc/sysconfig/network-scripts/ifcfg-enp0s9
::::::::::::::
HWADDR=08:00:27:39:D4:9B
TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=none
IPADDR=192.168.20.57
PREFIX=24
GATEWAY=192.168.20.1
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=no
NAME=enp0s9
ONBOOT=yes
[root@db19c2 ~]#
/etc/hosts 파일에 등록
#127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
#::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
127.0.0.1 loopback localhost
###### 1Node #########
192.168.0.55 db19C1 ## public
192.168.0.56 db19C1-vip ## vip
10.10.20.55 db19C1-priv ## private (interconnect)
###### 2Node ##########
192.168.0.57 db19C2 ## public
192.168.0.58 db19C2-vip ## vip
10.10.20.57 db19C2-priv ## private (interconnect)
###### scan
192.168.0.59 db19C-scan ## scan_ip
5. 필수 rpm 설치 확인
설치 도중 부족한 부부은 그때 그때 설치를 하면 되지만, 너무 많으면 곤란 할듯 하니 필수 rpm은 설치를 한 후 진행 하길 바랍니다.
점검 내용
rpm -qa | grep binutils-
rpm -qa | grep compat-
rpm -qa | grep gcc-
rpm -qa | grep gcc-c
rpm -qa | grep glibc-
rpm -qa | grep libaio-
rpm -qa | grep libaio-devel-
rpm -qa | grep libgcc-
rpm -qa | grep libstdc++
rpm -qa | grep libstdc++-
rpm -qa | grep libstdc++-devel-
rpm -qa | grep libstdc++-devel-
rpm -qa | grep libXi-
rpm -qa | grep libXtst-
rpm -qa | grep make-
rpm -qa | grep sysstat-
rpm -qa | grep ksh
rpm -qa | grep unixODBC
없으면 설치 해주세요.
6. OS 유저 생성
그룹을 여러개 넣었습니다. ( 사실 이렇게 까지 하실 필요 없습니다.)
색 넣은 그룹만 넣으셔도 됩니다.
groupadd -g 1010 oinstall
groupadd -g 1011 dba
groupadd -g 1012 asmadmin
groupadd -g 1013 asmdba
groupadd -g 1014 asmoper
groupadd -g 1015 oper
useradd -u 1000 -g oinstall -G asmadmin,asmdba,asmoper,oper,dba -d /db oracle
useradd -u 1001 -g oinstall -G asmadmin,asmdba,asmoper,oper,dba -d /dg grid
7. os 커널 설정
참고로 리눅스 6 와 리눅스7 은 좀 달라서 저는 리눅스7버전용 기반으로 설정 하였습니다.
업무적으로 os 업무를 하는 사람이 아닌지라 전문가분들이 보면 이해가 되지 않을 수 있는 점 먼저 양해 부탁 드립니다.
그리고 여기서는 hugepage 설정을 제외 합니다.
필요 시 차 후 따로 올려 보도록 하겠습니다.
## linux 7 (메모리 10기가 기준 )
vi /usr/lib/sysctl.d/00-system.conf 이곳에서 설정을 하라고 되어 있으나.
가장 확실 하게 처리 하기 위해서는..
vi /etc/sysctl.conf 파일이 가장 좋음 ( 예전 방식 )
# Oracle Parameter
fs.file-max = 6815744
kernel.sem = 250 32000 100 128
kernel.shmmni = 4096
kernel.shmall = 1073741824
#kernel.shmmax = 4398046511104
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048576
net.ipv4.ip_local_port_range = 9000 65500
# Recommended value for kernel.panic_on_oops
kernel.panic_on_oops = 1
# Recommand Values #
fs.aio-max-nr = 4194304
vm.min_free_kbytes = 524288
kernel.shmmax = 5368709120
kernel.randomize_va_space = 0
kernel.exec-shield = 0
kernel.sysrq = 1
/etc/security/limits.conf 설정
### oracle Descripter ###
oracle soft nofile 65534
oracle hard nofile 65536
oracle soft nproc 8192
oracle hard nproc 16384
oracle soft stack 16384
oracle hard stack 32768
### grid Descripter ###
grid soft nofile 65534
grid hard nofile 65536
grid soft nproc 8192
grid hard nproc 16384
grid soft stack 16384
grid hard stack 32768
oracle soft memlock 3145728
[root@db19c1 home]# cd /etc/security/limits.d
[root@db19c1 limits.d]# pwd
/etc/security/limits.d
[root@db19c1 limits.d]# ls -lart
합계 8
-rw-r--r--. 1 root root 191 11월 4 2017 20-nproc.conf
drwxr-xr-x. 2 root root 27 5월 9 2019 .
drwxr-xr-x. 6 root root 4096 3월 28 12:34 ..
[root@db19c1 limits.d]#
vi /etc/security/limits.d/00-system
파일에도 동일하게 위의 내용을 적용 한다.
[root@server-150 limits.d]# more 20-nproc.conf
# Default limit for number of user's processes to prevent
# accidental fork bombs.
# See rhbz #432903 for reasoning.
* soft nproc 4096
root soft nproc unlimited
### oracle Descripter ###
oracle soft nofile 65534
oracle hard nofile 65536
oracle soft nproc 8192
oracle hard nproc 16384
oracle soft stack 16384
oracle hard stack 32768
### grid Descripter ###
grid soft nofile 65534
grid hard nofile 65536
grid soft nproc 8192
grid hard nproc 16384
grid soft stack 16384
grid hard stack 32768
oracle soft memlock 3145728
[root@db19c1 limits.d]# more /etc/default/grub
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
GRUB_DEFAULT=saved
GRUB_DISABLE_SUBMENU=true
GRUB_TERMINAL_OUTPUT="console"
GRUB_CMDLINE_LINUX="crashkernel=auto rd.lvm.lv=rhel/root rd.lvm.lv=rhel/swap rhgb quiet"
GRUB_DISABLE_RECOVERY="true"
[root@db19c1 limits.d]#
## modify --> /etc/default/grub
GRUB_CMDLINE_LINUX="crashkernel=auto rd.lvm.lv=rhel/root rd.lvm.lv=rhel/swap rhgb quiet transparent_hugepage=never"
설정 반영
[root@db19c1 ~]# grub2-mkconfig -o /boot/grub2/grub.cfg
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-3.10.0-957.el7.x86_64
Found initrd image: /boot/initramfs-3.10.0-957.el7.x86_64.img
Found linux image: /boot/vmlinuz-0-rescue-b8357f5e7cdf4d90ae24ee93cadd85f9
Found initrd image: /boot/initramfs-0-rescue-b8357f5e7cdf4d90ae24ee93cadd85f9.img
done
[root@db19c1 ~]#
==> 리붓 후 결과 확인
cat /sys/kernel/mm/transparent_hugepage/enabled
=> 정상 확인 완료
[root@db19c1 ~]# cat /sys/kernel/mm/transparent_hugepage/enabled
always madvise [never]
[root@db19c1 ~]#
[root@db19c1 ~]# fdisk -l | grep "/dev/*"
Disk /dev/sda: 85.9 GB, 85899345920 bytes, 167772160 sectors
/dev/sda1 * 2048 1026047 512000 83 Linux
/dev/sda2 1026048 167772159 83373056 8e Linux LVM
Disk /dev/sdb: 21.5 GB, 21474836480 bytes, 41943040 sectors
Disk /dev/sdc: 21.5 GB, 21474836480 bytes, 41943040 sectors
Disk /dev/sdd: 21.5 GB, 21474836480 bytes, 41943040 sectors
Disk /dev/sde: 21.5 GB, 21474836480 bytes, 41943040 sectors
Disk /dev/sdf: 10.7 GB, 10737418240 bytes, 20971520 sectors
Disk /dev/sdg: 2147 MB, 2147483648 bytes, 4194304 sectors
Disk /dev/sdh: 17.2 GB, 17179869184 bytes, 33554432 sectors
Disk /dev/sdi: 21.5 GB, 21474836480 bytes, 41943040 sectors
Disk /dev/mapper/rhel-root: 12.9 GB, 12880707584 bytes, 25157632 sectors
Disk /dev/mapper/rhel-swap: 11.0 GB, 10997465088 bytes, 21479424 sectors
Disk /dev/mapper/rhel-db: 25.8 GB, 25769803776 bytes, 50331648 sectors
Disk /dev/mapper/rhel-dg: 35.7 GB, 35722887168 bytes, 69771264 sectors
[root@db19c1 ~]#
## 저는 모두 fdisk 이용하여 파티션 처리 하였습니다.
## asm 디스크 관리툴을 따로 사용 안 하므로 그냥 파티션을 해 주겠습니다.
fdisk /dev/sdb -> n -> p -> 1 -> 엔터 -> 엔터 -> w 순으로 입력 하면 됩니다.
[root@db19c1 ~]# fdisk /dev/sdi
Welcome to fdisk (util-linux 2.23.2).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.
Device does not contain a recognized partition table
Building a new DOS disklabel with disk identifier 0x5943fce7.
Command (m for help): n
Partition type:
p primary (0 primary, 0 extended, 4 free)
e extended
Select (default p): p
Partition number (1-4, default 1): 1
First sector (2048-41943039, default 2048):
Using default value 2048
Last sector, +sectors or +size{K,M,G} (2048-41943039, default 41943039):
Using default value 41943039
Partition 1 of type Linux and of size 20 GiB is set
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
[root@db19c1 ~]#
완료 되면.. 확인
[root@db19c1 ~]# fdisk -l
Disk /dev/sda: 85.9 GB, 85899345920 bytes, 167772160 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x0004ee40
Device Boot Start End Blocks Id System
/dev/sda1 * 2048 1026047 512000 83 Linux
/dev/sda2 1026048 167772159 83373056 8e Linux LVM
Disk /dev/sdb: 21.5 GB, 21474836480 bytes, 41943040 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x70f17eb7
Device Boot Start End Blocks Id System
/dev/sdb1 2048 41943039 20970496 83 Linux
Disk /dev/sdc: 21.5 GB, 21474836480 bytes, 41943040 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x2b8150dd
Device Boot Start End Blocks Id System
/dev/sdc1 2048 41943039 20970496 83 Linux
Disk /dev/sdd: 21.5 GB, 21474836480 bytes, 41943040 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x8a8a4465
Device Boot Start End Blocks Id System
/dev/sdd1 2048 41943039 20970496 83 Linux
Disk /dev/sde: 21.5 GB, 21474836480 bytes, 41943040 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x46fb64f8
Device Boot Start End Blocks Id System
/dev/sde1 2048 41943039 20970496 83 Linux
Disk /dev/sdf: 10.7 GB, 10737418240 bytes, 20971520 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x60a379ee
Device Boot Start End Blocks Id System
/dev/sdf1 2048 20971519 10484736 83 Linux
Disk /dev/sdg: 2147 MB, 2147483648 bytes, 4194304 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x972466b6
Device Boot Start End Blocks Id System
/dev/sdg1 2048 4194303 2096128 83 Linux
Disk /dev/sdh: 17.2 GB, 17179869184 bytes, 33554432 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x30f688de
Device Boot Start End Blocks Id System
/dev/sdh1 2048 33554431 16776192 83 Linux
Disk /dev/sdi: 21.5 GB, 21474836480 bytes, 41943040 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
Disk identifier: 0x5943fce7
Device Boot Start End Blocks Id System
/dev/sdi1 2048 41943039 20970496 83 Linux
Disk /dev/mapper/rhel-root: 12.9 GB, 12880707584 bytes, 25157632 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/mapper/rhel-swap: 11.0 GB, 10997465088 bytes, 21479424 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/mapper/rhel-db: 25.8 GB, 25769803776 bytes, 50331648 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/mapper/rhel-dg: 35.7 GB, 35722887168 bytes, 69771264 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
[root@db19c1 ~]#
[root@db19c1 rules.d]# udevadm trigger --action=add
[root@db19c1 rules.d]# raw -qa
/dev/raw/raw1: bound to major 8, minor 17
/dev/raw/raw2: bound to major 8, minor 33
/dev/raw/raw3: bound to major 8, minor 49
/dev/raw/raw4: bound to major 8, minor 65
/dev/raw/raw5: bound to major 8, minor 81
/dev/raw/raw6: bound to major 8, minor 97
/dev/raw/raw7: bound to major 8, minor 113
/dev/raw/raw8: bound to major 8, minor 129
[root@db19c1 rules.d]#
--> VNC 설정 ( OUI를 위한 설치)
[root@db19c1 rules.d]# rpm -qa | grep vnc
tigervnc-license-1.8.0-13.el7.noarch
gtk-vnc2-0.7.0-3.el7.x86_64
gvnc-0.7.0-3.el7.x86_64
tigervnc-server-minimal-1.8.0-13.el7.x86_64
libvncserver-0.9.9-12.el7_5.x86_64
[root@db19c1 rules.d]#
[root@db19c1 RHEL-7.6 Server.x86_64]# cd Packages/
[root@db19c1 Packages]# ls -lart tigervnc*
-r--r--r--. 1 root root 245716 9월 4 2018 tigervnc-1.8.0-13.el7.x86_64.rpm
-r--r--r--. 1 root root 39120 9월 4 2018 tigervnc-icons-1.8.0-13.el7.noarch.rpm
-r--r--r--. 1 root root 29652 9월 4 2018 tigervnc-license-1.8.0-13.el7.noarch.rpm
-r--r--r--. 1 root root 219908 9월 4 2018 tigervnc-server-1.8.0-13.el7.x86_64.rpm
-r--r--r--. 1 root root 1091524 9월 4 2018 tigervnc-server-minimal-1.8.0-13.el7.x86_64.rpm
[root@db19c1 Packages]# pwd
/run/media/root/RHEL-7.6 Server.x86_64/Packages
[root@db19c1 Packages]#
[root@db19c1 Packages]# rpm -Uvh tigervnc-server-1.8.0-13.el7.x86_64.rpm
경고: tigervnc-server-1.8.0-13.el7.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID fd431d51: NOKEY
준비 중... ################################# [100%]
Updating / installing...
1:tigervnc-server-1.8.0-13.el7 ################################# [100%]
[root@db19c1 Packages]#
[root@db19c1 ~]# ls -lart /lib/systemd/system/vncserver@.service
-rw-r--r--. 1 root root 1828 8월 31 2018 /lib/systemd/system/vncserver@.service
[root@db19c1 ~]# cp /lib/systemd/system/vncserver@.service /etc/systemd/system/vncserver@:2.service
[root@db19c1 ~]# cp /lib/systemd/system/vncserver@.service /etc/systemd/system/vncserver@:3.service
[root@db19c1 ~]#
[Service]
Type=forking
# Clean any existing files in /tmp/.X11-unix environment
ExecStartPre=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
ExecStart=/usr/sbin/runuser -l <USER> -c "/usr/bin/vncserver %i"
PIDFile=/home/<USER>/.vnc/%H%i.pid
ExecStop=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
[Install]
WantedBy=multi-user.target
==> grid vnc 설정 (사용목적은 일반적으로 서버실에서 직접 설치를 하는 것이 아니므로 설정 부분을 넣었습니다.)
[Service]
Type=forking
# Clean any existing files in /tmp/.X11-unix environment
ExecStartPre=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
ExecStart=/usr/sbin/runuser -l grid -c "/usr/bin/vncserver %i"
PIDFile=/dg/.vnc/%H%i.pid
ExecStop=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
[Install]
WantedBy=multi-user.target
==> 포트 열기
[root@db19c1 ~]# id
uid=0(root) gid=0(root) groups=0(root) context=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023
[root@db19c1 ~]# systemctl stop firewalld
[root@db19c1 ~]# firewall-cmd --permanent --zone=public --add-port=5901/tcp
FirewallD is not running
[root@db19c1 ~]# firewall-cmd --permanent --zone=public --add-port=5902/tcp
FirewallD is not running
[root@db19c1 ~]# firewall-cmd --permanent --zone=public --add-port=5903/tcp
FirewallD is not running
[root@db19c1 ~]# systemctl start firewalld
[root@db19c1 ~]# firewall-cmd --permanent --zone=public --add-port=5901/tcp
success
[root@db19c1 ~]#
[root@db19c1 ~]# firewall-cmd --permanent --zone=public --add-port=5902/tcp
success
[root@db19c1 ~]# firewall-cmd --permanent --zone=public --add-port=5903/tcp
success
[root@db19c1 ~]#
[root@db19c1 ~]# su - grid
-bash-4.2$ vncserver
You will require a password to access your desktops.
Password:
Password must be at least 6 characters - try again
Password:
Password must be at least 6 characters - try again
Password:
Verify:
Would you like to enter a view-only password (y/n)? y
Password:
Verify:
xauth: file /dg/.Xauthority does not exist
New 'db19c1:1 (grid)' desktop is db19c1:1
Creating default startup script /dg/.vnc/xstartup
Creating default config /dg/.vnc/config
Starting applications specified in /dg/.vnc/xstartup
Log file is /dg/.vnc/db19c1:1.log
-bash-4.2$
-bash-4.2$ ps -ef | grep vnc
grid 6522 1 1 00:31 pts/0 00:00:00 /bin/Xvnc :1 -auth /dg/.Xauthority -desktop db19c1:1 (grid) -fp catalogue:/etc/X11/fontpath.d -geometry 1024x768 -pn -rfbauth /dg/.vnc/passwd -rfbport 5901 -rfbwait 30000
grid 6538 1 0 00:31 pts/0 00:00:00 /bin/sh /dg/.vnc/xstartup
grid 6910 6436 0 00:31 pts/0 00:00:00 grep --color=auto vnc
-bash-4.2$
-bash-4.2$ exit
[root@db19c1 ~]#
vnc 접속 해 보기 다운로드는 아래 주소에서 가능 합니다.
https://www.realvnc.com/en/connect/download/viewer/
8. os 복제하기 ( ovm 메뉴를 이용하여 복사를 이용합니다. )
- os 구동을 완전히 정지 후 수행 해 주세요.
- 2Node OS 복사 완료 후 간단하게 말씀 드리면 VM 메뉴에서 가상시스템 내보내기 -> 가상시스템 가지고 오기 로 진행 했습니다.
완료 후 네트워크 맥 주소 변경을 해야 하고 IP 주소도 변경 해야 합니다.
- 위의 설정이 완벽 하지 않더라도 차 후 각각의 os에서 추가 작업을 해 주어도 가능 합니다.
9. 각각의 os 에서 추가 작업으로 디스크 붙여 보기
Disk /dev/sdj: 8589 MB, 8589934592 bytes, 16777216 sectors --> 추가 예정 된 공유디스크
Disk /dev/sdb: 21.5 GB, 21474836480 bytes, 41943040 sectors
/dev/sdb1 2048 41943039 20970496 83 Linux
Disk /dev/sdk: 10.7 GB, 10737418240 bytes, 20971520 sectors --> 추가할 로컬 디스크
Disk /dev/sdc: 21.5 GB, 21474836480 bytes, 41943040 sectors
/dev/sdc1 2048 41943039 20970496 83 Linux
Disk /dev/sdh: 17.2 GB, 17179869184 bytes, 33554432 sectors
/dev/sdh1 2048 33554431 16776192 83 Linux
Disk /dev/sdd: 21.5 GB, 21474836480 bytes, 41943040 sectors
/dev/sdd1 2048 41943039 20970496 83 Linux
Disk /dev/sdi: 21.5 GB, 21474836480 bytes, 41943040 sectors
/dev/sdi1 2048 41943039 20970496 83 Linux
Disk /dev/sdg: 2147 MB, 2147483648 bytes, 4194304 sectors
/dev/sdg1 2048 4194303 2096128 83 Linux
Disk /dev/sdf: 10.7 GB, 10737418240 bytes, 20971520 sectors
/dev/sdf1 2048 20971519 10484736 83 Linux
Disk /dev/sde: 21.5 GB, 21474836480 bytes, 41943040 sectors
/dev/sde1 2048 41943039 20970496 83 Linux
Disk /dev/sda: 85.9 GB, 85899345920 bytes, 167772160 sectors
/dev/sda1 * 2048 1026047 512000 83 Linux
/dev/sda2 1026048 167772159 83373056 8e Linux LVM
[root@db19c2 ~]#
[root@db19c1 ~]# fdisk -l | grep "/dev/sd*"
Disk /dev/sda: 85.9 GB, 85899345920 bytes, 167772160 sectors
/dev/sda1 * 2048 1026047 512000 83 Linux
/dev/sda2 1026048 167772159 83373056 8e Linux LVM
Disk /dev/sdb: 21.5 GB, 21474836480 bytes, 41943040 sectors
/dev/sdb1 2048 41943039 20970496 83 Linux
Disk /dev/sdc: 21.5 GB, 21474836480 bytes, 41943040 sectors
/dev/sdc1 2048 41943039 20970496 83 Linux
Disk /dev/sdd: 21.5 GB, 21474836480 bytes, 41943040 sectors
/dev/sdd1 2048 41943039 20970496 83 Linux
Disk /dev/sde: 21.5 GB, 21474836480 bytes, 41943040 sectors
/dev/sde1 2048 41943039 20970496 83 Linux
Disk /dev/sdf: 10.7 GB, 10737418240 bytes, 20971520 sectors
/dev/sdf1 2048 20971519 10484736 83 Linux
Disk /dev/sdg: 2147 MB, 2147483648 bytes, 4194304 sectors
/dev/sdg1 2048 4194303 2096128 83 Linux
Disk /dev/sdh: 17.2 GB, 17179869184 bytes, 33554432 sectors
/dev/sdh1 2048 33554431 16776192 83 Linux
Disk /dev/sdi: 21.5 GB, 21474836480 bytes, 41943040 sectors
/dev/sdi1 2048 41943039 20970496 83 Linux
Disk /dev/sdj: 8589 MB, 8589934592 bytes, 16777216 sectors --> 추가예정 된 공유디스크
Disk /dev/sdk: 10.7 GB, 10737418240 bytes, 20971520 sectors --> 추가할 로컬디스크
[root@db19c1 ~]#
공유 디스크던 로컬디스크 던 모두 아래처럼 파티션 처리
1node, 2node 동일하게 처리 해야 함
======= 1Node 로그
[root@db19c1 rules.d]# fdisk /dev/sdj ==> 양쪽 모든 노드에서 수행 되어야 함 , fdisk /dev/sdk 도 진행 필요
Welcome to fdisk (util-linux 2.23.2).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.
Device does not contain a recognized partition table
Building a new DOS disklabel with disk identifier 0xc367c0b7.
Command (m for help): n
Partition type:
p primary (0 primary, 0 extended, 4 free)
e extended
Select (default p): p
Partition number (1-4, default 1):
First sector (2048-41943039, default 2048):
Using default value 2048
Last sector, +sectors or +size{K,M,G} (2048-41943039, default 41943039):
Using default value 41943039
Partition 1 of type Linux and of size 20 GiB is set
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
[root@db19c1 rules.d]
==> 1노느, 2노드 동일하게 수행 한다 ( 양쪽 모두 )
[root@db19c1 /]# blkid | grep /dev/sdk1
[root@db19c1 /]# blkid
/dev/sda1: UUID="a6728ac6-16d3-43a7-8190-aed2507b61c1" TYPE="xfs"
/dev/sda2: UUID="TfZEV5-bdxU-0udf-GRFu-S8oz-B4tV-dJXwXa" TYPE="LVM2_member"
/dev/mapper/rhel-root: UUID="3c215bac-53ce-4263-ab71-90315a07f0ce" TYPE="xfs"
/dev/mapper/rhel-swap: UUID="093abbe6-c380-46d7-8f61-355fcbde11a8" TYPE="swap"
/dev/mapper/rhel-db: UUID="666d6aec-05b8-4190-a730-5d82a9e5dd31" TYPE="xfs"
/dev/mapper/rhel-dg: UUID="2719ff82-5764-4bf9-bf19-de9e6615db7a" TYPE="xfs"
[root@db19c1 /]#
[root@db19c1 /]# mkfs.xfs /dev/sdk1
meta-data=/dev/sdk1 isize=512 agcount=4, agsize=655296 blks
= sectsz=512 attr=2, projid32bit=1
= crc=1 finobt=0, sparse=0
data = bsize=4096 blocks=2621184, imaxpct=25
= sunit=0 swidth=0 blks
naming =version 2 bsize=4096 ascii-ci=0 ftype=1
log =internal log bsize=4096 blocks=2560, version=2
= sectsz=512 sunit=0 blks, lazy-count=1
realtime =none extsz=4096 blocks=0, rtextents=0
[root@db19c1 /]#
[root@db19c1 /]# blkid
/dev/sda1: UUID="a6728ac6-16d3-43a7-8190-aed2507b61c1" TYPE="xfs"
/dev/sda2: UUID="TfZEV5-bdxU-0udf-GRFu-S8oz-B4tV-dJXwXa" TYPE="LVM2_member"
/dev/mapper/rhel-root: UUID="3c215bac-53ce-4263-ab71-90315a07f0ce" TYPE="xfs"
/dev/mapper/rhel-swap: UUID="093abbe6-c380-46d7-8f61-355fcbde11a8" TYPE="swap"
/dev/mapper/rhel-db: UUID="666d6aec-05b8-4190-a730-5d82a9e5dd31" TYPE="xfs"
/dev/mapper/rhel-dg: UUID="2719ff82-5764-4bf9-bf19-de9e6615db7a" TYPE="xfs"
/dev/sdk1: UUID="727f3cc5-8470-4218-b348-b6146245eaeb" TYPE="xfs"
[root@db19c1 /]#
/dev/sdk1: UUID="727f3cc5-8470-4218-b348-b6146245eaeb" TYPE="xfs" => 1Node disk 중요함
/dev/sdk1: UUID="94032b64-87cc-40a7-a6a1-ba027d3ed37d" TYPE="xfs" => 2Node disk 중요함
[root@db19c1 /]# mkdir /LOGS
[root@db19c1 /]# mount /dev/sdk1 /LOGS
[root@db19c1 /]# df
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/mapper/rhel-root 12568576 5179840 7388736 42% /
devtmpfs 5906832 0 5906832 0% /dev
tmpfs 5923668 0 5923668 0% /dev/shm
tmpfs 5923668 9524 5914144 1% /run
tmpfs 5923668 0 5923668 0% /sys/fs/cgroup
/dev/mapper/rhel-db 25153536 6221556 18931980 25% /db
/dev/mapper/rhel-dg 34868600 9107364 25761236 27% /dg
/dev/sda1 508580 173536 335044 35% /boot
tmpfs 1184736 12 1184724 1% /run/user/42
tmpfs 1184736 0 1184736 0% /run/user/0
/dev/sdk1 8377344 32992 8344352 1% /LOGS
[root@db19c1 /]#
==============================================================================
[root@db19c1 /]# blkid | grep /dev/sdk1
/dev/sdk1: UUID="727f3cc5-8470-4218-b348-b6146245eaeb" TYPE="xfs"
[root@db19c1 /]#
==============================================================================
[root@db19c2 ~]# blkid | grep /dev/sdk1
/dev/sdk1: UUID="94032b64-87cc-40a7-a6a1-ba027d3ed37d" TYPE="xfs"
[root@db19c2 ~]#
==============================================================================
/etc/fstab 맨 아래
[root@db19c1 rules.d]# vi /etc/fstab
#
# /etc/fstab
# Created by anaconda on Thu May 9 23:27:20 2019
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
/dev/mapper/rhel-root / xfs defaults 0 0
UUID=a6728ac6-16d3-43a7-8190-aed2507b61c1 /boot xfs defaults 0 0
/dev/mapper/rhel-db /db xfs defaults 0 0
/dev/mapper/rhel-dg /dg xfs defaults 0 0
/dev/mapper/rhel-swap swap swap defaults 0 0
## 1Node add
UUID=727f3cc5-8470-4218-b348-b6146245eaeb /LOGS xfs defaults 1 2
/etc/fstab 맨 아래
## 2Node add
UUID=94032b64-87cc-40a7-a6a1-ba027d3ed37d /LOGS xfs defaults 1 2
[root@db19c1 /]# df
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/mapper/rhel-root 12568576 5179848 7388728 42% /
devtmpfs 5906832 0 5906832 0% /dev
tmpfs 5923668 0 5923668 0% /dev/shm
tmpfs 5923668 9524 5914144 1% /run
tmpfs 5923668 0 5923668 0% /sys/fs/cgroup
/dev/mapper/rhel-db 25153536 6221556 18931980 25% /db
/dev/mapper/rhel-dg 34868600 9107364 25761236 27% /dg
/dev/sda1 508580 173536 335044 35% /boot
tmpfs 1184736 12 1184724 1% /run/user/42
tmpfs 1184736 0 1184736 0% /run/user/0
/dev/sdk1 10474496 32992 10441504 1% /LOGS
[root@db19c1 /]#
==> 리붓을 하여도 정상적으로 마운트 되어서 올라 오는것을 서버마다 확인 가능
여기까지 설치1편을 종료 합니다.