Docker Certified Associate (DCA) Practice Exams Set 13

Which of the following is NOT true about Raft (docker consensus algorithm)?


Options are :

  • Raft tolerates up to (N-2)/2 failures
  • Raft requires a majority or quorum of (N/2) + 1 members
  • If a quorum is not reached, the system will not process any more requests to schedule additional tasks
  • If a quorum is not reached, the existing tasks will keep running

Answer : Raft tolerates up to (N-2)/2 failures

What is the docker command to add or update a mount on a service?


Options are :

  • docker service update --mount-add
  • docker service set --add-update-mount
  • docker service --add-update-mount
  • docker service --mount-volume

Answer : docker service update --mount-add

What is the docker command to update an existing service?


Options are :

  • docker service config
  • docker service change
  • docker service update
  • docker service modify

Answer : docker service update

Docker Certified Associate (DCA) Practice Exams Set 18

What is the docker command to add or update a node label?


Options are :

  • docker node modify --set-label
  • docker node add --label
  • docker node update --set-label
  • docker node update --label-add

Answer : docker node update --label-add

What is the docker command to roll back to the previous version of a service?


Options are :

  • docker service update --rollback
  • docker service update --rollback-version
  • docker service --rollback-version
  • docker service --rollback

Answer : docker service update --rollback

What is the docker command to increase number of replicas?


Options are :

  • docker service replica
  • docker service increase
  • docker service build
  • docker service scale

Answer : docker service replica

Docker Certified Associate (DCA) Practice Exams Set 7

What is the docker command to add or update a published port?


Options are :

  • docker service modify --add-update-port
  • docker service update --publish-port
  • docker service set --add-port
  • docker service update --publish-add

Answer : docker service update --publish-add

What is the docker command to add a placement preference?


Options are :

  • docker service update --placement-pref-add
  • docker service update --constraint-add
  • docker service update --placement-constraint-add
  • docker service update --pref-add

Answer : docker service update --placement-pref-add

Which of the following commands wifi automatically create a volume when a container is started?


Options are :

  • docker container run --name nginxtest --volumes=/app nginx'
  • docker container run --name nginxtest -v /app:mount nginx'
  • docker container run --name nginxtest --volumes myvol:/app:new nginx'
  • docker container run --name nginxtest -v myvol:/app nginx'

Answer : docker container run --name nginxtest --volumes=/app nginx'

Docker Certified Associate (DCA) Practice Exams Set 20

Which one of the following commands will show a list of volumes for a specific container?


Options are :

  • docker container logs nginx --volumes'
  • docker container inspect nginx'
  • docker volume inspect nginx'
  • docker volume logs nginx --containers'

Answer : docker container inspect nginx'

Which of the following constitutes a production-ready devicemapper configuration for the Docker engine?


Options are :

  • Create a volume group in devicemapper and utilize the '--dm.thinpooldev' Docker daemon option, specifying the volume group
  • Format a partition with xfs and mount it at '/var/lib/docker'
  • Utilize the '--storage-opt dm.directlvm_device' Docker daemon option, specifying a block device
  • Nothing, devicemapper comes ready for production usage out of the box

Answer : Utilize the '--storage-opt dm.directlvm_device' Docker daemon option, specifying a block device

Which one of the following commands will result in the volume being removed automatically once the container has exited?


Options are :

  • docker run --del -v /foo busybox'
  • docker run --read-only -v /foo busybox'
  • docker run --rm -v /foo busybox'
  • docker run --remove -v /foo busybox'

Answer : docker run --rm -v /foo busybox'

Docker Certified Associate (DCA) Practice Exams Set 8

A container named "analytics" that stores results in a volume called "data" was created. docker run -d --name=analytics -v data:/data app1 How are the results accessed in "data" with another container called "app2"?


Options are :

  • docker run -d --name=reports --volume=data app2
  • docker run -d --name=reports --volumes-from=analytics app2
  • docker run -d --name=reports --volume=app1 app2
  • docker run -d --name=reports --mount=app1 app2

Answer : docker run -d --name=reports --volumes-from=analytics app2

What Dockerfile option EXPOSE does?


Options are :

  • Adds metadata to an image
  • Informs Docker that the container listens on the specified network ports at runtime
  • Expose defaults for an executing container
  • Label a container that will run as an executable

Answer : Informs Docker that the container listens on the specified network ports at runtime

Which of the following Dockerfile options creates a mount point with the specified name and marks it as holding externally mounted volumes from native host or other containers?


Options are :

  • RUN
  • VOLUME
  • ONBUILD
  • WORKDIR

Answer : VOLUME

Docker Certified Associate (DCA) Practice Exams Set 26

Dockerfile option EXPOSE publish the port to external systems. True or false?


Options are :

  • FALSE
  • TRUE

Answer : FALSE

What Dockerfile option LABEL does?


Options are :

  • Label a container that will run as an executable
  • Adds metadata to an image
  • Provide defaults for an executing container
  • Tells Docker how to test a container to check that it is still working

Answer : Adds metadata to an image

When changes are made to a Docker image and are ready to be made available for containers to be instantiated on, which of the following commands would make that new image available, called 'httpd:v2'?


Options are :

  • docker commit -m "Notes made here" myweb httpd:v2
  • docker checkin httpd:v2
  • docker tag httpd:latest httpd:v2
  • Mutual Transport Layer Security
  • None of the above.

Answer : docker tag httpd:latest httpd:v2

Docker Certified Associate (DCA) Practice Exams Set 22

Which Docker variable determines whether a host will ONLY download Docker trusted images?


Options are :

  • DOCKER_TRUST=1
  • DOCKER_TLS_IMAGE=1
  • DOCKER_CONTENT_TRUST=1
  • DOCKER_TRUSTED_CONTENT=1

Answer : DOCKER_CONTENT_TRUST=1

Which of the following is NOT a swarm resource?


Options are :

  • containers
  • networks
  • dockerfiles
  • volumes

Answer : dockerfiles

Docker Certified Associate (DCA) Practice Exams Set 7

True of False :

Containers on user-defined bridge network can communicate only via IP addresses. 


Options are :

  • False
  • True

Answer : False

Which docker network is used to connect one or more docker daemons of participating nodes in swarm cluster? 


Options are :

  • overlay
  • ingress
  • bridge
  • docker_gwbridge

Answer : docker_gwbridge

Which of the following Dockerfile instructions confirms Dockerís core concepts of source control and cheap commits? 


Options are :

  • CMD
  • FROM
  • RUN
  • ARG

Answer : RUN

Docker Certified Associate (DCA) Practice Exams Set 9

You have created your company's website with visitor counts and hosted it using containerized web-servers. Which of the following provisions can potentially make you lose the track of your visitor count? 


Options are :

  • volumes
  • tmpfs
  • bind mounts
  • all of the above

Answer : tmpfs

Which of the following is the default network driver for docker containers? 


Options are :

  • docker_gwbridge
  • host
  • overlay
  • bridge

Answer : bridge

Which of the following is NOT a part of the grant permission in UCP)?


Options are :

  • certificates
  • subject
  • resource sets
  • role

Answer : certificates

Docker Certified Associate (DCA) Practice Exams Set 5

Which of the following commands is used to remove dangling docker images? 


Options are :

  • docker rm
  • docker image remove
  • docker image prune
  • docker rmi

Answer : docker image prune

Which of the following is not an object of The Container Network Model ? 


Options are :

  • End-point
  • Network Controller
  • Services
  • Sandbox

Answer : Services

What is the final outcome of a container created from the following Dockerfile? 


Options are :

  • Container will remain in created state.
  • Container will get stuck in infinite pinging loop.
  • Container will ping localhost for 6 times and will return to its shell.
  • Container will ping the localhost for 6 times and will stop running.

Answer : Container will ping the localhost for 6 times and will stop running.

Docker Certified Associate (DCA) Practice Exams Set 2

Which of the following is the correct order of service creation process in swarm mode? 


Options are :

  • docker API > orchestrator > allocator > dispatcher > scheduler
  • docker API > allocator > scheduler > dispatcher > orchestrator
  • docker API > scheduler > allocator > dispatcher > orchestrator
  • docker API > orchestrator > dispatcher > allocator > orchestrator

Answer : docker API > orchestrator > allocator > dispatcher > scheduler

Docker containers are the running instances of Ö  ?


Options are :

  • Docker Image
  • both (a) and (b)
  • Dockerfile
  • none of the above
  • Dockerfile

Answer : Docker Image

Which of the following Dockerfile instructions will configure a starting point for the executable container? 


Options are :

  • ENV
  • ENTRYPOINT
  • CMD
  • EXEC

Answer : ENTRYPOINT

Docker Certified Associate (DCA) Practice Exams Set 21

You want to run an nginx web-server container as a background process. Make sure that the container's port 80 is mapped to port 8080 on local host machine. As the final output, you should be able to access the default landing page of nginx web-server. Which of the following is the correct command for it? 


Options are :

  • docker run -itd --name web-server -p 8080:80 nginx:latest
  • docker run -itd --name web-server -P nginx:latest
  • docker run -itd --name web-server -p 80:8080 nginx:latest
  • docker run --name web-server -p 8080:80 nginx:latest

Answer : docker run -itd --name web-server -p 8080:80 nginx:latest

Which of the following commands does not associate with docker volumes? 


Options are :

  • docker volume inspect
  • docker volume create
  • docker volume backup
  • docker volume prune

Answer : docker volume backup

Which of the following is the default logging driver of Docker for Linux distributions? 


Options are :

  • json-file
  • none
  • syslog
  • fluentd

Answer : json-file

Docker Certified Associate (DCA) Practice Exams Set 9

Which of the following is responsible for merging hostís already present cached image layers with pulled image layers? 


Options are :

  • ext4
  • aufs
  • NTFS
  • swap

Answer : aufs

Which of the following network drivers utilizes VXLAN data plane to decouple docker network from the underlay physical network? 


Options are :

  • host
  • bridge
  • overlay
  • macvlan

Answer : overlay

You have a running Ubuntu Container with bash as its default command. Copy a file called "services.txt" to the tmp directory of the container. Navigate inside the container and delete the /tmp directory. Exit from the container and run docker diff command. Which of the following would be the output of it (docker diff command)?


Options are :

  • A /root/.bash_history C /root D /tmp
  • C /tmp A /tmp/service.txt D /tmp
  • C /root A /root/.bash_history D /tmp
  • None of the above

Answer : C /root A /root/.bash_history D /tmp

Docker Certified Associate (DCA) Practice Exams Set 5

Which of the following is not managed by Docker hub? 


Options are :

  • organizations
  • containers
  • docker images
  • repositories

Answer : containers

Which of the following units of the swarm instructs worker to run a task?


Options are :

  • Allocator
  • Scheduler
  • Orchestrator
  • Dispatcher

Answer : Scheduler

Which of the following commands is used to isolate manager node from further scheduling of service tasks? 


Options are :

  • docker node stop manager
  • none of the above
  • docker node update --availability drain manager
  • docker node update --available drain manager

Answer : docker node update --availability drain manager

Docker Certified Associate (DCA) Practice Exams Set 9

Which of the following units of the swarm determines on which node a task will be scheduled? 


Options are :

  • Dispatcher
  • Scheduler
  • Orchestrator
  • Allocator

Answer : Dispatcher

True or False:

The more number of managers in a swarm cluster, The more chances of better performance and scalability 


Options are :

  • True
  • False

Answer : False

Which of the following provisions of Docker supports host networking? 


Options are :

  • Docker for Linux Distributions
  • Docker Desktop for Windows
  • Docker Desktop for Mac
  • Docker EE for Windows Server

Answer : Docker for Linux Distributions

Docker Certified Associate (DCA) Practice Exams Set 7

What does following error indicate?

x509: certificate signed by unknown authority


Options are :

  • user is running a docker swarm command on manager without client certificate.
  • user have entered incorrect captcha.
  • user is not registered on docker hub.
  • user is running a docker command on UCP node without client certificate .

Answer : user is running a docker command on UCP node without client certificate .

Comment / Suggestion Section
Point our Mistakes and Post Your Suggestions
  • Which of the following units of the swarm instructs worker to run a task?
    Options are :
    
    Allocator
    Scheduler  - WRONG
    Orchestrator
    Dispatcher  - Correct 
    ------------------------------------
    
    Which of the following units of the swarm determines on which node a task will be scheduled? 
    Options are :
    
    Dispatcher - Wrong
    Scheduler - Correct
    Orchestrator
    Allocator
    
    Detailed description: https://www.vegaitsourcing.rs/media-center/blog/docker-series-docker-swarm-intro
    Reply
  • User
    Which of the following commands wifi automatically create a volume when a container is started?
    
    Options are :
    
    docker container run --name nginxtest --volumes=/app nginx'
    docker container run --name nginxtest -v /app:mount nginx'
    docker container run --name nginxtest --volumes myvol:/app:new nginx'
    docker container run --name nginxtest -v myvol:/app nginx' --> good answer
    Reply
  • Milan Milas
    Wrong answer
    Answer : docker service replica
    
    Docker service update --replicas 5 webapp
    Docker service scale webapp=5
    Reply
  • Milan Milas
    Answer should be (N-1)/2
    Reply
    • No. Correct answer: "Raft tolerates up to (N-2)/2 failures", becouse it is stupid and question is "is NOT true ". 
      Reply