Commit 47ab079c authored by JooHan Hong's avatar JooHan Hong

system/db backup modify2

parent fc77e196
Pipeline #7011 passed with stages
in 1 minute and 4 seconds
...@@ -11,8 +11,9 @@ ...@@ -11,8 +11,9 @@
먼저 시스템 백업은 Bash Script 기반으로 구성되어 있으며, 다음과 같이 구성되어 있다. 먼저 시스템 백업은 Bash Script 기반으로 구성되어 있으며, 다음과 같이 구성되어 있다.
- STEP 1 : Rsync (Netowkr)를 이용하여, 원격지의 설정 파일을 백업 받는다. - STEP 1 : 백업할 서버의 rsyncd.conf 파일을 설정하고, TCP/873 포트를 허용한다.
- STEP 2 : 증분백업이 필요한 시스템의 경우 STEP 1이 완료되면, 내부적으로 `증분 백업(cp -al 링크 옵션)`으로 진행한다. - STEP 2 : Rsync (Netowkr)를 이용하여, 원격지의 설정 파일을 백업 받는다.
- STEP 3 : 증분백업이 필요한 시스템의 경우 STEP 1이 완료되면, 내부적으로 `증분 백업(cp -al 링크 옵션)`으로 진행한다.
또한 백업 스크립트의 경우도 다음과 같이 두 가지로 분기 처리된다. 또한 백업 스크립트의 경우도 다음과 같이 두 가지로 분기 처리된다.
...@@ -20,6 +21,55 @@ ...@@ -20,6 +21,55 @@
- 백업 스크립트 : `remotebackup_type2` - 백업 스크립트 : `remotebackup_type2`
## /etc/rsyncd.conf 설정 내역
```bash
# cat /etc/rsyncd.conf
[etc]
path = /etc
comment = pds dir
uid = root
gid = root
use chroot = yes
read only = yes
hosts allow = 192.168.1.8
max connections = 3
timeout = 300
[home]
path = /home
comment = home dir
uid = root
gid = root
use chroot = yes
read only = yes
hosts allow = 192.168.1.8
max connections = 3
timeout = 300
[usrlocal]
path = /usr/local
comment = /usr/local dir
uid = root
gid = root
use chroot = yes
read only = yes
hosts allow = 192.168.1.8
max connections = 3
timeout = 300
[root]
path = /root
comment = root dir
uid = root
gid = root
use chroot = yes
read only = yes
hosts allow = 192.168.1.8
max connections = 3
timeout = 300
```
## 백업정책 스크립트 ## 백업정책 스크립트
```bash ```bash
...@@ -65,17 +115,6 @@ echo "Hongs Dev NETWORK BACKUP END" >> $log ...@@ -65,17 +115,6 @@ echo "Hongs Dev NETWORK BACKUP END" >> $log
echo "###########################################################################" >> $log echo "###########################################################################" >> $log
....중략 ....중략
echo "###########################################################################" >> $log
echo "DBMS NETWORK BACKUP START" >> $log
echo "###########################################################################" >> $log
$epath $BACKUP etc 180.180.180.250 NOT NOT >> $log
$epath $BACKUP home 180.180.180.250 NOT NOT >> $log
$epath $BACKUP usrlocal 180.180.180.250 NOT NOT >> $log
$epath $BACKUP root 180.180.180.250 NOT NOT >> $log
echo "###########################################################################" >> $log
echo "DBMS NETWORK BACKUP END" >> $log
echo "###########################################################################" >> $log
echo "###########################################################################" >> $log echo "###########################################################################" >> $log
echo "TB3-K8S NETWORK BACKUP START" >> $log echo "TB3-K8S NETWORK BACKUP START" >> $log
echo "###########################################################################" >> $log echo "###########################################################################" >> $log
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment