---
title: "Quiz: Cloud Storage: Block, File and Object"
domain: cloud-computing
level: beginner
questions: 10
---

# Quiz: Cloud Storage: Block, File and Object

## Questions

### 1. Which statement correctly compares block storage and file storage?
*Objective: 1. Compare block, file and object storage in access method, performance, sharing and typical use cases.*

- A) Block storage is mounted by many instances at once, while file storage is attached to a single instance.
- B) Block storage gives an instance a raw volume on which its own operating system runs the filesystem, while file storage is a shared filesystem run by the service.
- C) Both are reached through HTTP requests such as `PUT` and `GET` on named buckets.
- D) File storage always has lower latency than block storage because it adds a network protocol.

### 2. Three web servers behind a load balancer must read and write the same `uploads/` folder through ordinary file paths. The application is old and can't be changed. Which storage fits best?
*Objective: 1. Compare block, file and object storage in access method, performance, sharing and typical use cases.*

- A) One block volume formatted with ext4 and attached to all three servers at once.
- B) An object storage bucket, which the application opens as if it were a local folder.
- C) A separate block volume per server, copied between servers every night.
- D) A file share mounted by all three servers over NFS or SMB.

### 3. A provider states 99.999999999% ("eleven nines") durability for its object storage. Which statement is correct?
*Objective: 2. Explain durability versus availability, how replication and erasure coding protect data, and what storage classes trade off.*

- A) It describes the chance of losing data to failures inside the storage system; it does not help if you or an attacker delete or overwrite objects.
- B) It means the service is reachable 99.999999999% of the time, so outages are practically impossible.
- C) It means the provider will restore any object you delete accidentally within a year.
- D) It is a contractual guarantee that no object is ever lost, and the SLA pays the value of the data if one is.

### 4. A team keeps 8 TB of data as three full replicas (24 TB of raw disk). They switch to erasure coding with 6 data fragments and 3 parity fragments. How much raw capacity do they need now, and how many fragments can be lost without losing data?
*Objective: 2. Explain durability versus availability, how replication and erasure coding protect data, and what storage classes trade off.*

- A) 8 TB, and no fragment can be lost.
- B) 9 TB, and any 6 fragments can be lost.
- C) 12 TB, and any 3 fragments can be lost.
- D) 24 TB, and any 2 fragments can be lost.

### 5. Versioning is enabled on a bucket. After `aws s3 rm s3://reports/q3.txt`, you run the two commands below. What is the state of `q3.txt`?
*Objective: 3. Use object storage through the S3 API: create buckets, upload and list objects, enable versioning and add lifecycle rules.*

```text
$ aws s3api list-object-versions --bucket reports --query 'Versions[].[VersionId,IsLatest]' --output text
v2	False
v1	False
$ aws s3api list-object-versions --bucket reports --query 'DeleteMarkers[].[VersionId,IsLatest]' --output text
dm1	True
```

- A) Both versions were erased; the delete marker is only a log entry.
- B) The object is restored automatically after a short delay.
- C) A read of `q3.txt` returns "not found", but `v1` and `v2` still exist; deleting the marker `dm1` would make `v2` current again.
- D) Only `v1` remains, because `v2` was the version that was deleted.

### 6. A finance team reads the objects under `invoices/` every week. Someone adds the lifecycle rule below. What is the most likely consequence?
*Objective: 3. Use object storage through the S3 API: create buckets, upload and list objects, enable versioning and add lifecycle rules.*

```json
{
  "Rules": [
    {
      "ID": "archive-invoices",
      "Status": "Enabled",
      "Filter": { "Prefix": "invoices/" },
      "Transitions": [ { "Days": 30, "StorageClass": "GLACIER" } ]
    }
  ]
}
```

- A) After 30 days the invoices move to an archive tier, where each weekly read needs a restore with fees and a delay: it may cost more than the hot tier it replaced.
- B) After 30 days the invoices are deleted, because every lifecycle rule ends in deletion.
- C) The rule has no effect, because `invoices/` is a folder and lifecycle rules only apply to objects.
- D) The invoices become public, because archive tiers are accessible without credentials.

### 7. A web application lets users upload a profile photo. The bucket must stay private and the browser must never receive your access keys. What is the safest design?
*Objective: 4. Share an object safely with a pre-signed URL and explain why public buckets are risky.*

- A) Embed an access key with write permission in the page's JavaScript.
- B) Allow anonymous writes to the bucket with a policy for the principal `*`.
- C) Generate one pre-signed upload URL valid for 30 days and give it to every user.
- D) Have your server generate a pre-signed `PUT` URL for that user's object key with a short expiry, and let the browser upload to it.

### 8. A bucket has the policy statement below. Who can read what?
*Objective: 4. Share an object safely with a pre-signed URL and explain why public buckets are risky.*

```json
{
  "Effect": "Allow",
  "Principal": "*",
  "Action": "s3:GetObject",
  "Resource": "arn:aws:s3:::acme-data/exports/*"
}
```

- A) Only the account that owns the bucket, because no named principal appears in the statement.
- B) Anyone on the Internet can download objects whose keys start with `exports/`, without credentials; other keys are not covered by this statement.
- C) Anyone on the Internet can download and list every object in the bucket.
- D) Only callers who present a valid pre-signed URL can read `exports/*`.

### 9. A company takes daily snapshots of its database volume, stored in the same cloud account and region. An attacker with stolen administrator credentials deletes the volume and every snapshot. Which change best moves them toward the 3-2-1 rule?
*Objective: 5. Explain snapshots, backups and encryption at rest and in transit, and who manages the keys.*

- A) Keep an extra, restore-tested backup in a separate account and region, ideally with object lock so it can't be deleted before its retention date.
- B) Take the snapshots every hour instead of every day.
- C) Turn on encryption for the existing snapshots.
- D) Increase the provisioned IOPS of the volume.

### 10. A company wants the cloud service to encrypt its objects, to be able to make all of them unreadable at once by disabling one key, and to see every use of that key in an audit log. Which approach fits?
*Objective: 5. Explain snapshots, backups and encryption at rest and in transit, and who manages the keys.*

- A) Provider-managed keys, because the provider already controls them securely.
- B) TLS only: encryption in transit covers stored data too.
- C) Encrypting each object on the client and storing the key in the same bucket.
- D) Customer-managed keys in the provider's key management service (KMS), used for server-side encryption.

---

## Answer key

<details>
<summary>Show answers</summary>

| # | Answer | Explanation |
|---|---|---|
| 1 | B | A block volume is raw capacity that one instance formats and manages, while a file share runs the filesystem for many clients. A swaps the two; C describes object storage; D is wrong because block volumes are built for low latency. |
| 2 | D | A network file share gives many servers the same directory with normal paths and POSIX behaviour, so the application doesn't change. An ordinary filesystem such as ext4 on a block volume would be corrupted by three writers, and an object store isn't mounted like a folder. |
| 3 | A | Durability is about data not being lost to hardware or zone failures. A delete or overwrite with valid credentials is stored just as durably, which is why you need versioning and backups. B confuses it with availability; C and D claim guarantees that SLAs don't give. |
| 4 | C | Raw capacity is 8 TB × (6 + 3) / 6 = 12 TB, half of the 24 TB used by three replicas. Any 6 of the 9 fragments rebuild the data, so any 3 can be lost. |
| 5 | C | A delete on a versioned bucket only adds a delete marker (the line with `True`), which hides the key. Both versions remain until you delete them by version ID or a lifecycle rule expires them. Removing the marker, or copying a version back, restores the object. |
| 6 | A | Archive tiers have low storage cost but charge for retrieval and need a restore step, so data read every week belongs in a hotter tier. The rule moves objects and doesn't delete or expose them, and `Prefix` matches key names, which is all a "folder" is. |
| 7 | D | A short-lived pre-signed `PUT` URL for one key lets the browser upload straight to the bucket with no credentials and no public access. A leaks a key, B opens the bucket to anyone, and C is a long-lived shared capability that can be abused. |
| 8 | B | `Principal: "*"` makes this statement apply to everyone, including unauthenticated callers, but only for `s3:GetObject` on keys under `exports/`. It doesn't grant listing, and a pre-signed URL isn't needed. |
| 9 | A | The copies share one failure domain: the same credentials delete them all. A separate-account, separate-region backup that is immutable and restore-tested satisfies the "off-site" and independence ideas of 3-2-1. More frequent snapshots, encryption and IOPS don't protect against deletion. |
| 10 | D | Customer-managed keys in a KMS let you control the key policy, disable or delete the key to cut access, and audit each use. Provider-managed keys give you no such control, TLS protects data only in transit, and a key stored next to the data protects nothing. |

</details>
