QuizzesDocker Volumes & Persistence — Concept Check
intermediate
docker

Docker Volumes & Persistence — Concept Check

Questions on Docker Volumes & Persistence. Container filesystems are ephemeral — data is lost when a container is removed. Docker volumes and bind mounts persist data outside the container lifecycle.

8 minutes 8 questions Pass at 70%
Time Limit
8 minutes - timer starts when you begin
Change Answers Freely
Revisit and change any answer before submitting
Full Review After Submit
Correct answers and explanations shown for every question
Auto-submit on timeout
Quiz submits automatically when time runs out

Questions in this quiz

8 questions on Docker Volumes & Persistence — Concept Check. Work through them here, then start the quiz to answer them and see your score.

  1. 1.A developer wants to ensure that their database data persists even after container removal. Which storage option should they use?

    • AContainer's writable layer
    • BNamed Volume
    • CBind Mount
    • Dtmpfs Mount
  2. 2.You are working on a development project and need to frequently update code with immediate effect inside a container. Which storage option is best suited for this scenario?

    • ANamed Volume
    • BBind Mount
    • Ctmpfs Mount
    • DContainer's writable layer
  3. 3.A team is using a bind mount for their production database to ensure data persistence. What potential issue might they face?

    • ADocker-managed backup difficulty
    • BTies container to host path
    • CData loss on container removal
    • DIn-memory storage limitation
  4. 4.Which command would you use to back up a Docker volume?

    • Adocker volume prune
    • Bdocker volume create backup-volume
    • Cdocker run --rm -v volume:/data -v $(pwd):/backup alpine tar czf /backup/backup.tar.gz -C /data .
    • Ddocker run --rm -v $(pwd):/backup alpine tar czf /backup/backup.tar.gz
  5. 5.A developer mistakenly believes that tmpfs mounts are suitable for persistent data storage. Why is this incorrect?

    • Atmpfs mounts require Docker management
    • Btmpfs mounts are in-memory and do not persist data to disk
    • Ctmpfs mounts are slower than named volumes
    • Dtmpfs mounts are only for Linux systems
  6. 6.A Docker container is removed, but the data written to a specific directory persists. What storage method is likely being used?

    • ANamed Volume
    • BBind Mount
    • Ctmpfs Mount
    • DContainer's writable layer
  7. 7.Which storage option is most likely to cause permission issues due to UID mismatch on Linux?

    • ANamed Volume
    • BContainer's writable layer
    • CBind Mount
    • Dtmpfs Mount
  8. 8.What is the primary advantage of using named volumes over bind mounts in production environments?

    • ADocker manages their location and they are portable
    • BEasier to inspect from the host
    • CIn-memory storage for faster access
    • DDirect access to host filesystem