๋กœ์ผ“๐Ÿพ
article thumbnail

 

์Šคํ† ๋ฆฌ์ง€์™€ ๊ด€๋ จ๋œ ์ฟ ๋ฒ„๋„คํ‹ฐ์Šค ๋ฆฌ์†Œ์Šค์—๋Š” StorageClass, PersistentVolume ์ด ์žˆ์Šต๋‹ˆ๋‹ค.

๋ณดํ†ต ๋™์ ์ธ ์Šคํ† ๋ฆฌ์ง€๋Š” ์›ํ•œ๋‹ค๋ฉด StorageClass (์ดํ•˜ SC) ๋ฅผ, ์ •์ ์ธ ์Šคํ† ๋ฆฌ์ง€๋ฅผ ์›ํ•œ๋‹ค๋ฉด PersistentVolume (์ดํ•˜ PV) ์„ ์‚ฌ์šฉํ•ฉ๋‹ˆ๋‹ค.

 

ํ•œํŽธ, ํŒŒ๋“œ์—์„œ ์Šคํ† ๋ฆฌ์ง€ ์—ฐ๊ฒฐ์„ ํ•˜๋ ค๋ฉด PersistentVolumeClaim (์ดํ•˜ PVC) ์„ ์ด์šฉํ•ด์„œ SC ๋‚˜ PV ๋ฅผ Bound ํ•ด์ฃผ์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.

AWS EBS ๋ฅผ ์‚ฌ์šฉํ•˜๊ฒŒ ๋  ํ…๋ฐ, EBS ๋งŒ์œผ๋กœ๋Š” ํ•œ๊ณ„๊ฐ€ ์žˆ์Šต๋‹ˆ๋‹ค. 

 

๋ฐ”๋กœ ํ•˜๋‚˜์˜ EBS ๋Š” ๋‹ค์ค‘ ์ธ์Šคํ„ด์Šค ์—ฐ๊ฒฐ์ด ๋˜์ง€ ์•Š๋Š”๋‹ค๋Š” ์ ์ด์ฃ .

 

์˜ˆ๋ฅผ ๋“ค์–ด EBS ์— ๋ฐ์ดํ„ฐ๋ฅผ ์ €์žฅํ•˜๋Š” ์• ํ”Œ๋ฆฌ์ผ€์ด์…˜์„ Deployment Replica 2 ๋กœ ๋ฐฐํฌํ•œ๋‹ค๊ณ  ๊ฐ€์ •ํ•ด๋ณด์ฃ .

๊ทธ๋ฆฌ๊ณ  ํŒŒ๋“œ๋“ค์€ ์„œ๋กœ ๋‹ค๋ฅธ ์›Œ์ปค ๋…ธ๋“œ์— ๋ฐฐ์น˜๋ฉ๋‹ˆ๋‹ค.

EBS ๋Š” ๋‹จ์ผ ๋…ธ๋“œ์™€๋งŒ ์—ฐ๊ฒฐ์ด ๊ฐ€๋Šฅํ•˜๋ฏ€๋กœ ๋‹ค๋ฅธ ๋…ธ๋“œ์— ๋ฐฐํฌ๋œ ํŒŒ๋“œ๋Š” EBS ๋ฅผ ์‚ฌ์šฉํ•  ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค.

EBS gp2, gp3 ๋Š” ๋‹จ์ผ ์—ฐ๊ฒฐ๋งŒ ๊ฐ€๋Šฅํ•˜๊ณ , EBS io1, io2 ๋Š” ๋‹ค์ค‘ ์—ฐ๊ฒฐ์ด ๊ฐ€๋Šฅํ•จ
ํ•˜์ง€๋งŒ io1, io2 ๋Š” ๋›ฐ์–ด๋‚œ IOPS ์„ฑ๋Šฅ์„ ํ•„์š”๋กœ ํ•˜๋Š” ๊ณณ์— ์‚ฌ์šฉ๋˜๊ณ , ๊ฐ€๊ฒฉ์ด ํ›จ์”ฌ ๋น„์‹ธ๊ธฐ์—” ๋‹ค์†Œ ๋ฌด๋ฆฌ๊ฐ€ ์žˆ์–ด ๋ณด์ž„

 

์ฆ‰, Pod2 ๋Š” ๊ณ„์†ํ•ด์„œ Pending ์ƒํƒœ์— ๋น ์ง€๊ฒŒ ๋  ๊ฒ๋‹ˆ๋‹ค.

 

์ด๋Ÿฐ ๋ฌธ์ œ๋ฅผ ํ•ด๊ฒฐํ•˜๊ธฐ ์œ„ํ•ด์„  ๋ฐ”๋กœ AWS EFS ๋ฅผ ์‚ฌ์šฉํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค. AWS ์˜ ์™„์ „ ๊ด€๋ฆฌํ˜• NFS ์„œ๋น„์Šค๋ผ๊ณ  ์ƒ๊ฐํ•˜์‹œ๋ฉด ๋ฉ๋‹ˆ๋‹ค.

EFS ์— ๋Œ€ํ•ด์„  ๋”ฐ๋กœ ์„ค๋ช…ํ•˜์ง€ ์•Š๊ฒ ์Šต๋‹ˆ๋‹ค. ๊ถ๊ธˆํ•˜๋‹ค๋ฉด ์—ฌ๊ธฐ ํด๋ฆญ

 

๊ทธ๋Ÿผ ๋ฐ”๋กœ ์–ด๋–ป๊ฒŒ ์ฟ ๋ฒ„๋„คํ‹ฐ์Šค์—์„œ EFS ๋ฅผ ๊ฐ€์ ธ๋‹ค ์“ฐ๋Š” ์ง€ ์•Œ์•„๋ณด๋„๋ก ํ•˜์ฃ !

 

๋ ›์ธ ๋‘๋”์ฝ”๋“œ~

 

 

EFS CSI Driver 


์ฟ ๋ฒ„๋„คํ‹ฐ์Šค์—์„œ EFS ๋ฅผ ์‚ฌ์šฉํ•˜๊ธฐ ์œ„ํ•ด์„  ํ•„์ˆ˜ ์„ ํ–‰ ์ž‘์—…์ด ์žˆ์Šต๋‹ˆ๋‹ค.

๋ฐ”๋กœ efs-csi-driver ์„ค์น˜ ์ž‘์—… ์ž…๋‹ˆ๋‹ค.

 

Amazon EBS Container Storage Interface(CSI) ๋“œ๋ผ์ด๋ฒ„๋Š” AWS์—์„œ ์‹คํ–‰๋˜๋Š” Kubernetes ํด๋Ÿฌ์Šคํ„ฐ๊ฐ€ Amazon EFS ํŒŒ์ผ ์‹œ์Šคํ…œ์˜ ์ˆ˜๋ช… ์ฃผ๊ธฐ๋ฅผ ๊ด€๋ฆฌํ•  ์ˆ˜ ์žˆ๊ฒŒ ํ•ด์ฃผ๋Š” CSI ์ธํ„ฐํŽ˜์ด์Šค๋ฅผ ์ œ๊ณตํ•ฉ๋‹ˆ๋‹ค.

 

์„ค์น˜ ํ•˜๋Š” ๋ฐฉ๋ฒ•์ด ์–ด๋ ต์ง„ ์•Š์œผ๋‚˜ ๋‹ค์†Œ ํ•ด์•ผํ•˜๋Š” ์ž‘์—…์ด ๋งŽ์œผ๋ฏ€๋กœ ์ด๋ฒˆ ๊ธ€์—์„œ๋Š” ์ด๋ฏธ ์„ค์น˜๋ฅผ ํ–ˆ๋‹ค๊ณ  ๊ฐ€์ •ํ•˜๊ฒ ์Šต๋‹ˆ๋‹ค.

 

์„ค์น˜ํ•˜๋Š” ๋ฐฉ๋ฒ•์€ ์—ฌ๊ธฐ๋ฅผ ์ฐธ๊ณ ํ•ด์ฃผ์„ธ์š”!

 

์ €๋Š” Helm ์„ ์ด์šฉํ•ด์„œ ์„ค์น˜ํ–ˆ๊ณ , ๋ฒ„์ „์€ 2.3.6 ๋ฒ„์ „์ž…๋‹ˆ๋‹ค.

 

์ด๋ฒˆ ๊ธ€์—์„  EFS ๋ฃจํŠธ ๋””๋ ‰ํ„ฐ๋ฆฌ๋ฅผ ์‚ฌ์šฉํ•˜์ง€ ์•Š๊ณ , Access Point ๋ฅผ ํ†ตํ•ด ํŒŒ๋“œ์™€ ๋งˆ์šดํŠธ๋ฅผ ์ง„ํ–‰ํ•  ๊ฒ๋‹ˆ๋‹ค.

EFS ๋ฃจํŠธ ๋””๋ ‰ํ„ฐ๋ฆฌ๋ฅผ ์‚ฌ์šฉํ•˜๊ฒŒ ๋˜๋ฉด, ๋ณด์•ˆ์ƒ ๋งŽ์ด ์ข‹์ง€ ์•Š์ฃ . ๊ถŒํ•œ์ด๋ผ๋„ ํš๋“ํ•˜๋Š” ๋‚ ์—๋Š” EFS ์— ์žˆ๋Š” ๋ฐ์ดํ„ฐ๋ฅผ ์ „๋ถ€ ๋‚ ๋ฆด ์ˆ˜ ์žˆ์ฃ .

 

Access Point ๋Š” ๋Œ€๋žต ์ด๋ ‡๊ฒŒ ์ƒ๊ฒผ์Šต๋‹ˆ๋‹ค. (์ž์„ธํ•˜๊ฒŒ ์•Œ๊ณ  ์‹ถ๋‹ค๋ฉด ์—ฌ๊ธฐ ์ฐธ์กฐ, Access Point ๋Š” ๋‹ค์Œ ๊ธ€์—์„œ ์ž์„ธํžˆ ๋‹ค๋ค„๋ณด๊ฒ ์Šต๋‹ˆ๋‹ค.)

 

์ •์  ํ”„๋กœ๋น„์ €๋‹์ด๋ผ๊ณ  ํ•˜๋ฉด ๋ฏธ๋ฆฌ ์ƒ์„ฑ๋œ Access Point ๋ฅผ ์‚ฌ์šฉํ•˜๋Š” ๊ฒƒ์ด๊ณ , ๋™์  ํ”„๋กœ๋น„์ €๋‹์ด๋ผ๊ณ  ํ•˜๋ฉด Access Point ๋ฅผ SC ๊ฐ€ ์ƒ์„ฑํ•œ ๊ฒƒ์„ ์‚ฌ์šฉํ•ฉ๋‹ˆ๋‹ค.

 

๋™์  ํ”„๋กœ๋น„์ €๋‹์ด๋ผ๊ณ  ํ•ด์„œ EFS ๋ฅผ ์ƒ์„ฑํ•˜๋Š” ๊ฒƒ์ด ์•„๋‹˜
Access Point ๋งŒ ๋™์ ์œผ๋กœ ๊ด€๋ฆฌํ•ด์คŒ 

๊ณต์‹ ๋ฌธ์„œ์—์„œ Access Point ๋งŒ ๋™์ ์œผ๋กœ ๊ฐ€๋Šฅ ์ด๋ผ๊ณ  ๋ช…์‹œ๋˜์–ด ์žˆ๋Š” ๊ฑธ ๋ณด๋ฉด ์ถ”ํ›„ EFS ๋„ ๊ฐ€๋Šฅํ• ์ง€๋„?

์ถ”ํ›„ EFS ๋„ ๋™์ ์œผ๋กœ ๊ด€๋ฆฌ?

 

 

๊ฐ์ž ํ™˜๊ฒฝ์— ๋งž๊ฒŒ ์‚ฌ์šฉํ•˜๋ฉด ๋˜์ง€๋งŒ, ๊ฐœ์ธ์ ์œผ๋กœ ๋™์  ํ”„๋กœ๋น„์ €๋‹์„ ๋” ์„ ํ˜ธํ•ฉ๋‹ˆ๋‹ค. ์™œ๋ƒ๋ฉด Access Point ๋ฅผ ์ƒ์„ฑํ•˜๋Š” ๊ฒƒ์ด ์ด๋งŒ ๊ท€์ฐฎ์€ ์ž‘์—…์ด ์•„๋‹™๋‹ˆ๋‹ค ใ…œใ…œ

 

๋งŒ์•ฝ ์„œ๋กœ ์—ฐ๊ด€ ์—†๋Š” ํŒŒ๋“œ 10๊ฐœ์—์„œ Access Point ๋ฅผ ํ†ตํ•œ ์Šคํ† ๋ฆฌ์ง€๋ฅผ ์‚ฌ์šฉํ•œ๋‹ค๊ณ  ํ–ˆ์„ ๋•Œ, 

์ •์  ํ”„๋กœ๋น„์ €๋‹์„ ์‚ฌ์šฉํ•œ๋‹ค๋ฉด, 10๊ฐœ์˜ Access Point ๋ฅผ ํ…Œ๋ผํผ์ด๋‚˜ AWS CLI, Console ๋กœ ์ƒ์„ฑํ•ด์ค˜์•ผ ํ•ฉ๋‹ˆ๋‹ค.

ํ•˜์ง€๋งŒ ๋™์  ํ”„๋กœ๋น„์ €๋‹์€ SC ๊ฐ€ ์•Œ์•„์„œ ์ƒ์„ฑํ•ด์ฃผ๊ณ  ๊ด€๋ฆฌํ•ด์ค๋‹ˆ๋‹ค.

 

๊ทธ๋Ÿผ ์—ฌ๊ธฐ์„œ ์ด๋Ÿฐ ์ƒ๊ฐ์ด ๋“ค ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.
ํ•˜๋‚˜์˜ ๊ณตํ†ต๋œ Access Point ๋งŒ๋“ค์–ด์„œ 10๊ฐœ์˜ ํŒŒ๋“œ์—์„œ ์‚ฌ์šฉํ•˜๋ฉด ๋˜์ง€ ์•Š๋‚˜?

 

๋‚˜์˜์ง€ ์•Š์ง€๋งŒ, ๋‹ค์Œ๊ณผ ๊ฐ™์€ ๋ฌธ์ œ๊ฐ€ ์žˆ์–ด์š”. 

 

์•„๋ž˜ ํŒŒ๋“œ 3๊ฐœ๋Š” ์„œ๋กœ ์™„์ „ํžˆ ๋‹ค๋ฅธ ์• ํ”Œ๋ฆฌ์ผ€์ด์…˜์ด์ง€๋งŒ ํ•˜๋‚˜์˜ Access Point ์“ฐ๊ณ  ์žˆ์–ด์š”.
๊ทธ๋ฆฌ๊ณ  3๊ฐœ ๋ชจ๋‘ data.txt ์— ์ค‘์š”ํ•œ ์ •๋ณด๋ฅผ ๋‹ด๊ณ  ์žˆ์ฃ . 

 

ํ•˜์ง€๋งŒ ์ด๋ ‡๊ฒŒ ํ•˜๋ฉด ๊ฒฐ๊ตญ ๊ฐ€์žฅ ๋งˆ์ง€๋ง‰ ์‹คํ–‰๋œ ํŒŒ๋“œ๊ฐ€ ๊ฐ€์ง€๊ณ  ์žˆ๋Š” data.txt ๊ฐ€ overwrite ๋  ๊ฑฐ์—์š”.

์ฆ‰, ํŒŒ๋“œ1 ๊ณผ ํŒŒ๋“œ2 ๋Š” ์˜๋„์น˜ ์•Š๊ฒŒ ํŒŒ๋“œ3์˜ data.txt ๋ฅผ ๊ฐ€์ง€๊ฒŒ ๋˜๋Š” ๊ฑฐ์ฃ .

 

์‹ค์ œ๋กœ /data ๋ผ๋Š” ํด๋”๋ฅผ ๋งŽ์ด ์‚ฌ์šฉํ•˜๋ฏ€๋กœ ์ž์นซํ–ˆ๋‹ค๊ฐ€ ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค๊ฐ€ ๊ทธ๋ผํŒŒ๋‚˜์˜ data ๋ฅผ ๊ฐ€์ง€๊ฒŒ ๋˜๋Š” ๋ถˆ์ƒ์‚ฌ๊ฐ€ ์ƒ๊ธฐ๊ฒŒ ๋˜๋Š”๊ฑฐ์ฃ .

 

๊ทธ๋Ÿผ ์ด์ œ ์ •์  ํ”„๋กœ๋น„์ €๋‹๊ณผ ๋™์  ํ”„๋กœ๋น„์ €๋‹์„ ์ด์šฉํ•ด์„œ ํŒŒ๋“œ์™€ Access Point ๋ฅผ ์—ฐ๊ฒฐํ•ด๋ณด์ฃ .

 

 

์ •์  ํ”„๋กœ๋น„์ €๋‹


์˜ˆ์ œ๋Š” ์—ฌ๊ธฐ์„œ ๋ณผ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

# Static Provisioning
---
apiVersion: v1
kind: PersistentVolume
metadata:
  name: efs-pv1
spec:
  capacity:
    storage: 5Gi
  volumeMode: Filesystem
  accessModes:
    - ReadWriteOnce
  persistentVolumeReclaimPolicy: Retain
  storageClassName: ""
  csi:
    driver: efs.csi.aws.com
    volumeHandle: fs-0556::fsap-0312
---
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
  name: efs-pvc
spec:
  storageClassName: ""
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 5Gi
---
kind: Pod
apiVersion: v1
metadata:
  name: my-pod
spec:
  serviceAccountName: sd-dev-efs-common-irsa
  containers:
    - name: my-container
      image: amazon/aws-cli
      command: [ "/bin/sh" ]
      args: [ "-c", "while true; do echo hello; sleep 1d;done" ]
      securityContext:
        runAsUser: 1000
        runAsGroup: 1000
      volumeMounts:
        - name: my-pv
          mountPath: /efs/fs
  volumes:
    - name: my-pv
      persistentVolumeClaim:
        claimName: efs-pvc

 

๋งŒ์•ฝ efs-csi-driver ๋ฅผ ์„ฑ๊ณต์ ์œผ๋กœ ์„ค์น˜ํ–ˆ๋‹ค๋ฉด, ์œ„ yaml ๋กœ ์ƒ์„ฑํ–ˆ์„ ๋•Œ pvc ๊ฐ€ pv ์™€ Bound ๋œ ๊ฒƒ์„ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

 

๊ทธ๋ฆฌ๊ณ  ์‚ฌ์šฉํ•œ Access Point ์˜ ์ •๋ณด์ž…๋‹ˆ๋‹ค. 

 

ํŒŒ๋“œ์—์„œ ์‚ฌ์šฉํ•˜๋Š” ๋””์Šคํฌ ๋ชฉ๋ก์ž…๋‹ˆ๋‹ค. /efs/fs ๊ฐ€ EFS Access Point ์™€ ๋งˆ์šดํŠธ ๋˜์–ด ์žˆ๋‹ค๋Š” ๊ฑธ ์•Œ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

PVC ์—์„œ Request Capacity ๋ฅผ 5Gi ๋กœ ํ–ˆ๋Š”๋ฐ ์œ„ ์ด๋ฏธ์ง€๋ฅผ ๋ณด๋ฉด 8E(์—‘์‚ฌ) ์ธ ๊ฒƒ์„ ์•Œ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.
EFS ์˜ ์šฉ๋Ÿ‰์ด๋ฉฐ, PVC ์—์„œ์˜ Request Capacity ๋Š” ์—ฌ๊ธฐ์„œ ์ „ํ˜€ ์ค‘์š”ํ•˜์ง€ ์•Š๋‹ค๋Š” ๊ฑธ ์•Œ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

๋‹จ์ง€ PV ์™€ PVC ๊ฐ€ ์„œ๋กœ์˜ Request Capacity ๋ฅผ ๋ณด๊ณ  Bound ์—ญํ• ์„ ํ•ด์ฃผ๋Š” ๊ฒƒ ๋ฟ์ด์ฃ .

 

 

ํŒŒ๋“œ์— ์ ‘๊ทผํ•ด์„œ mountPath ๋ฅผ ์‚ดํŽด๋ณด๋ฉด ํ•ด๋‹น Path ๋Š” ํŒŒ๋“œ์˜ uid:gid ๊ฐ€ root:root ์ž„์—๋„ ๋ถˆ๊ตฌํ•˜๊ณ , 2001:2001 ์ธ ๊ฒƒ์„ ํ™•์ธ ํ•  ์ˆ˜ ์žˆ์ฃ .

 

Access Point ๋ฅผ ์ด์šฉํ•œ path ์— ํŒŒ์ผ์„ ์ƒ์„ฑํ•˜๋”๋ผ๊ณ  root:root ๊ฐ€ ์•„๋‹ˆ๊ณ  2001:2001 ๋กœ ์ƒ์„ฑ๋ฉ๋‹ˆ๋‹ค.

 

my-pod2 ๋ฅผ ์ƒ์„ฑํ•˜๊ณ  ๋˜‘๊ฐ™์€ Access Point ๋กœ ์—ฐ๊ฒฐ ํ•ด๋ณด๊ฒ ์Šต๋‹ˆ๋‹ค. ๊ทธ๋Ÿผ my-pod2 ์—์„œ๋„ test.txt ํŒŒ์ผ์„ ๋ณผ ์ˆ˜ ์žˆ์–ด์•ผ๊ฒ ์ฃ ?

 

์•„์ฃผ ์ข‹์Šต๋‹ˆ๋‹ค.

 

๋™์  ํ”„๋กœ๋น„์ €๋‹์€ ๋” ์‰ฌ์›Œ์š”. ๋ฐ”๋กœ ์•Œ์•„๋ณด์ฃ .

 

๋™์  ํ”„๋กœ๋น„์ €๋‹


์˜ˆ์ œ๋Š” ์—ฌ๊ธฐ์„œ ๋ณผ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

# Dynamic Provisioning
kind: StorageClass
apiVersion: storage.k8s.io/v1
metadata:
  name: efs-sc
provisioner: efs.csi.aws.com
parameters:
  provisioningMode: efs-ap # ํ˜„์žฌ access point ๋งŒ ํ”„๋กœ๋น„์ €๋‹ ์ง€์›๋จ
  fileSystemId: fs-0556
  directoryPerms: "775"
  basePath: "/dynamic_provisioning/my-pod" 
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: efs-pvc
spec:
  accessModes:
    - ReadWriteMany
  storageClassName: efs-sc
  resources:
    requests:
      storage: 5Gi
---
kind: Pod
apiVersion: v1
metadata:
  name: my-pod
spec:
  containers:
    - name: my-container
      image: amazon/aws-cli
      command: [ "/bin/sh" ]
      args: [ "-c", "while true; do echo hello; sleep 1d;done" ]
      securityContext:
        runAsUser: 1000
        runAsGroup: 1000
      volumeMounts:
        - name: my-pv
          mountPath: /efs/fs
  volumes:
    - name: my-pv
      persistentVolumeClaim:
        claimName: efs-pvc

 

SC ๋ฅผ ์‚ฌ์šฉํ•˜๊ธฐ ๋•Œ๋ฌธ์— PVC ์˜ STORAGECLASS ์— efs-sc ๊ฐ€ ๋ช…์‹œ๋œ ๊ฑธ ํ™•์ธํ•  ์ˆ˜ ์žˆ์œผ๋ฉฐ VOLUME ์ด๋ฆ„์ด ๋‚œ์ˆ˜์ž…๋‹ˆ๋‹ค.

 

๋™์ ์œผ๋กœ ์ƒ์„ฑ๋œ Access Point ์ž…๋‹ˆ๋‹ค. 

 

gid ์™€ uid ๋Š” ์•„๋ž˜์™€ ๊ฐ™์ด ์ž๋™์œผ๋กœ ๋ถ€์—ฌ๋ฉ๋‹ˆ๋‹ค.

 

 

๋ถ€์—ฌ๋˜๋Š” uid ์™€ gid ๋Š” ๋ชจ๋‘ ๋‹ค๋ฅด๊ฒŒ ๋ถ€์—ฌ๋˜๋Š” ๊ฒƒ์€ ์•Œ ์ˆ˜ ์žˆ๋Š”๋ฐ, ๋งŒ์•ฝ uid ์™€ gid ๊ฐ€ ๊ฒน์น˜๊ฒŒ ๋˜๋ฉด ํ•ด๋‹น ๋””๋ ‰ํ„ฐ๋ฆฌ์— ์ ‘๊ทผํ•  ์ˆ˜ ์žˆ๋Š” ๊ถŒํ•œ์„ ์–ป์„ ์ˆ˜ ์žˆ๊ธฐ ๋•Œ๋ฌธ์— ์ „๋ถ€ ๋‹ค๋ฅด๊ฒŒ ๋ถ€์—ฌ๋ฉ๋‹ˆ๋‹ค.

 


์ด์™ธ ๋ถ€๋ถ„์€ ์ •์  ํ”„๋กœ๋น„์ €๋‹๊ณผ ๋‹ค๋ฅด์ง€ ์•Š์Šต๋‹ˆ๋‹ค.

 

๋งˆ๋ฌด๋ฆฌ


์ด๋ ‡๊ฒŒ EFS ์™€ ์ฟ ๋ฒ„๋„คํ‹ฐ์Šค์™€์˜ ๊ถํ•ฉ์„ ์•Œ์•„๋ดค๋Š”๋ฐ ์ •๋ง ์ข‹์€๊ฑฐ ๊ฐ™์•„์š”. ํŠนํžˆ SC ๋ฅผ ์‚ฌ์šฉํ•œ๋‹ค๋ฉด ๋„ˆ๋ฌด ์‰ฝ๊ฒŒ ์Šคํ† ๋ฆฌ์ง€๋ฅผ ์‚ฌ์šฉํ•  ์ˆ˜ ์žˆ์ฃ .

EBS ์˜ ๋‹จ์ ์„ ๋ณด์™„ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

๋‹ค๋งŒ ๋ฌธ์ œ๋Š” EFS ๋Š” EBS ๋ณด๋‹ค ๋น„์Œ‰๋‹ˆ๋‹ค. ์Šคํ† ๋ฆฌ์ง€ ์šฉ๋Ÿ‰ ์ธก๋ฉด์—์„œ EFS ๊ฐ€ 3๋ฐฐ ๋” ๋น„์Œ‰๋‹ˆ๋‹ค.
์˜ˆ๋ฅผ ๋“ค์–ด EBS ๊ฐ™์€ ๊ฒฝ์šฐ 30Gi ๋ฅผ ์ผ์„ ๋•Œ 3000์› ์ฒญ๊ตฌ ๋œ๋‹ค๋ฉด, EFS ๋Š” 9000์›์ด ์ฒญ๊ตฌ๋ฉ๋‹ˆ๋‹ค.

 

๊ทธ๋Ÿฌ๋‹ˆ EFS ๋ฅผ ์‚ฌ์šฉํ•œ๋‹ค๋ฉด, ์•„๋ž˜ ์กฐ๊ฑด์„ ์ž˜ ๋”ฐ์ ธ๋ด์•ผํ•ฉ๋‹ˆ๋‹ค.

  • Multi AZ ๋˜๋Š” One Zone
  • ํ”„๋กœ๋น„์ €๋‹ ๋˜๋Š” ๋ฒ„์ŠคํŠธ
  • IA (Infrequent Access)

๋˜ ์œ„์—์„  ๋ณด์•ˆ ๊ด€๋ จํ•ด์„œ ์ž์„ธํžˆ ๋‹ค๋ฃจ์ง€ ์•Š์•˜์ง€๋งŒ, ํŒŒ๋“œ์— ์„œ๋น„์Šค ์–ด์นด์šดํŠธ๋ฅผ ์ง€์ •ํ•ด์ฃผ์–ด์„œ ํŠน์ • IAM Role ๋งŒ EFS ์˜ Access Point ์— ์ ‘๊ทผํ•˜๊ฒŒ ํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค. ๋˜ํ•œ EFS ํŒŒ์ผ ์‹œ์Šคํ…œ ์ •์ฑ…๋„ ์—„๊ฒฉํ•˜๊ฒŒ ๊ฐ€์ ธ๊ฐˆ ํ•„์š”๋„ ์žˆ๊ณ ์š”.

 

๊ทธ๋Ÿฌ๋ฉด ์˜ค๋Š˜์€ ์—ฌ๊ธฐ๊นŒ์ง€~!

profile on loading

Loading...