구글 프로페셔널 클라우드 아키텍트 자격증 대비 교육자료 (7편) [Google Professional Cloud Architect]
구글 클라우드 자격증 중 하나인 Google Cloud Certified - Professional Cloud Architect 를 취득하였습니다. 공부 자료가 많지 않고 전부 영어로 되어 있어서 클라우드 아키텍트 자격증을 준비하시는 분들께 조금이라도 도움을 드리고자 준비해보았습니다.
관련 내용 :
- Your company wants to reduce cost on infrequently accessed data by moving it to the cloud. The data will still be accessed approximately once a month to refresh historical charts. In addition, data older than 5 years needs to be archived for 5 years for compliance reasons. How should you store and manage the data?
A. In Google Cloud Storage and stored in a Multi-Regional bucket. Set an Object Lifecycle Management policy to delete data older than 5 years.
B. In Google Cloud Storage and stored in a Multi-Regional bucket. Set an Object Lifecycle Management policy to change the storage class to Coldline for data older than 5 years.
C. In Google Cloud Storage and stored in a Nearline bucket. Set an Object Lifecycle Management policy to delete data older than 5 years.
D. In Google Cloud Storage and stored in a Nearline bucket. Set an Object Lifecycle Management policy to change the storage class to Coldline for data older than 5 years.
잘 사용하지 않는 데이터를 클라우드에 보관하고 싶다. 데이터는 한 달에 한번 정도 쓸 것 같고, 5년 이상 데이터는 5년 동안 보관해야한다. 어떻게 하면 될까? 라는 질문입니다. 정답은 D입니다.
Cloud Storage에서 bucket을 만들려고 하면 storage class라는 것을 정해야합니다. Standard냐 Nearline이냐 Coldline이냐 Archive냐에 따라 요금이 다릅니다. 2020년 8월 기준 GCP 웹 콘솔에서 각 storage class에 대해 다음과 같이 소개합니다.
Standard는 가장 일반적이고 자주 이용할 때 사용하면 됩니다. Nearline은 한 달에 한 번 정도 사용하는 데이터를 백업 용도로 쓰기에 좋습니다. 그리고 Coldline은 disaster recovery(DR)용도로 1분기 정도마다 사용할 때 좋습니다. 마지막으로 Archive는 장기 보관용이고 말그대로 archiving 하기 위해서 사용합니다. 위의 내용은 시험의 내용과 조금 다릅니다. GCP 서비스가 계속 바뀌기 때문입니다. 클래스마다 요금제는 당연히 다릅니다. 데이터 보관료와 데이터 retrieval 비용, operation 비용이 서비스마다 다릅니다.
문제에서 데이터를 한 달에 한 번 정도 사용하니 주기로 봐서 Nearline 버킷이 가장 이상적입니다. 그리고 5년 이상 된 데이터는 Coldline으로 옮기면 됩니다. (Archive 클래스가 생기기 이전에 나온 문제) 버킷의 Lifecycle에 규칙을 정하면 자동으로 옮겨지게 됩니다. 그리고 5년이 지나면 자동 삭제되게 하면 됩니다.
아래 이미지처럼 LIFECYCLE (생명주기) 탭에서 규칙을 추가할 수 있습니다. 저는 standard 클래스에 있는 데이터 중에서 10일 이상 보관된 데이터는 coldline 클래스로 이동하게 했고, coldline 클래스 데이터 중에서 하루가 지난 데이터는 삭제하도록 규칙을 정해 테스트했습니다.
아래에 보시면 10일 이상된 데이터의 Storage 클래스는 coldline으로 변경된 것을 확인하실 수 있습니다.
문제에 맞게 규칙을 설정해 보겠습니다. 조건에 맞으면 취할 Action을 선택합니다. 선택한 액션은 조건에 맞으면 storage class를 Coldline으로 변경입니다. 조건은 데이터 수명이 5년 (1825일) 된 경우이고, 5년 지난 모든 데이터가 아닌 Nearline에 저장된 5년된 데이터를 Coldline으로 (Archive 클래스 나오기 전 문제)변경할 것이므로 Storage class matches 조건을 Nearline으로 합니다.
또다른 조건으로 5년 동안 보관해야 합니다. 그 말은 5년이 지나면 지워야 합니다. 5년이 되면 삭제되게 조건을 설정하겠습니다. Action은 삭제이고 조건은 coldline에 있는 데이터 중 5년이 된 데이터입니다.
문제와 똑같은 규칙을 설정하였고 버킷안에 데이터들은 아래의 규칙대로 살아갑니다. (life cycle이니깐)
위의 내용을 잘 이해하셨다면 아래의 문제를 쉽게 풀어보세요.
- Your company has decided to store data files in Cloud Storage. The data would be hosted in a regional bucket to start with. You need to configure Cloud Storage lifecycle rule to move the data for archival after 30 days and delete the data after a year. Which two actions should you take?
A. Create a Cloud Storage lifecycle rule with Age: "30", Storage Class: "Standard", and Action: "Set to Coldline", and create a second GCS life-cycle rule with Age: "365", Storage Class: "Coldline", and Action: "Delete".
B. Create a Cloud Storage lifecycle rule with Age: "30", Storage Class: "Standard", and Action: "Set to Coldline", and create a second GCS life-cycle rule with Age: "275", Storage Class: "Coldline", and Action: "Delete".
C. Create a Cloud Storage lifecycle rule with Age: "30", Storage Class: "Standard", and Action: "Set to Nearline", and create a second GCS life-cycle rule with Age: "365", Storage Class: "Nearline", and Action: "Delete".
D. Create a Cloud Storage lifecycle rule with Age: "30", Storage Class: "Standard", and Action: "Set to Nearline", and create a second GCS life-cycle rule with Age: "275", Storage Class: "Nearline", and Action: "Delete".
Archive Storage class가 나오기 전 문제라 archive(장기보관) 하기 위해 coldline에 저장하면 됩니다. standard에 저장된 데이터가 30일 지나면 coldline에 저장되야하고 coldline에 저장된 데이터 중 1년 지나면 삭제되야합니다. 정답은~~~~ B!!!
* Standard 클래스의 데이터가 Nearline에 저장됐다, Nearline으로 이동됐다는 의미는 Nearline 클래스로 변경됐다고 이해하시면 되겠습니다.
Comments
Post a Comment