Azure Classroomnotes 25/Aug/2023

Versioning in Azure Storage Account Blob Storage

  • Enabling versioning can be done when creating storage account from Data Protection tab and also from Data Protection blade post creation of storage account
    Preview
    Preview
  • Create a container with blob anonymous access and upload a text file
    Preview
  • Now upload the file again after making some changes and you should see a new version added in the versions tab
    Preview

Soft Delete of Containers and Blobs

  • Azure storage account offers soft delete for blobs and containers
  • A blob/container deleted can be restored in 7 days by default but the value can be set anywhere between 1 and 365
    Preview

Activity – Soft delete

  • Create a storage account and ensure a container called as music is created.
  • upload 2 files into music container.
    Preview
  • Now delete any one object (blob)
    Preview
    Preview
  • Recover the blob in next 7 days
    Preview
    Preview
  • Note: if the versioning is enabled post undelete make the undelete object as current version in versions tab.
  • Delete the music container
    Preview
    Preview
  • Recover the container:
    Preview

Recover a Deleted storage account

  • Once the storage is deleted, it can be recovered in 14 days in the following cases
    • The resource group in which storage account was created still exists or in the case if we deleted the resource group, the resource group with same name was not created before we performed the recover option.
  • Delete the storage account & wait for the operation to be complete
    Preview
  • Now restore
    Preview
    Preview
    Preview
    Preview

Snapshots and Point in time restore

  • A snapshot is a read-only version of blob that’s taken at a point of time
  • Point in time restore provides protection againts accidental deletion or corruption by enabling you to restore block blob to its earlier
  • To enable point in time restore
    • soft delete
    • Change feed
    • Blob versioing
  • Enable point int time restore
    Preview
    Preview
  • Refer Here for more info on point in time restore
  • Next steps:
    • Lets make some more changes and perform point in time restore in next session

Activities

  • Create a storage account
  • create a container called as docs
  • upload two files one.txt and two.txt with content this is activity
  • delete two.txt
  • upload a new file called as two.txt with content this is test
  • delete two.txt
  • Now when you recover two.txt what will be the content
  • delete the container docs
  • now create a new container called as docs
  • upload two files three.txt and four.txt
  • Delete the container
  • Now when we recover what will we see in docs
    • one.txt and two.txt
    • three.txt and four.txt
  • Ensure you watch json and yaml tutorial Refer Here for a video on json and yaml

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

About continuous learner

devops & cloud enthusiastic learner