Wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Docker-Containers

Total questions: 10

Worksheet time: 6mins

Name
Class
Date
1.

docker run --name elastic_training_ --net training_net -p 9200:9300 -it -m 1GB -v docker.elastic.co/elasticsearch/elasticsearch:8.12.2

a)

Local port 9200 maps to container port 9300

b)

Local port 9300 maps to container port 9300

2.

To solve this error: "Error response from daemon: Conflict. The container name "/kibana_training_" is already in use by container"

a)
  1. 1. stop container

  2. 2 remove container

  3. 3 restart container with same name

b)
  1. 1. stop container

  2. 2. restart container with same name

c)
  1. 1. stop container

  2. 2. remove container

  3. 3. start container with same name

d)
  1. 1. remove container

  2. 2. stop container with same name

3.

Which command fix this "max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]"?

a)

sysctl -w vm.max_map_count=262144

b)

sysctl vm.max_map_count=262144

c)

sysctl -v m.max_map_count=262144

d)

sysctl -x vm.max_map_count=262144

4.

Create a network NETWORK and add a container CONTAINER to this network

a)
  1. 1. docker network create NETWORK

  1. 2. docker network add NETWORK CONTAINER

b)
  1. 1. docker network create NETWORK

  1. 2. docker network connect NETWORK CONTAINER

c)
  1. 1. docker network add NETWORK

  1. 2. docker network connect NETWORK CONTAINER

d)
  1. 1. docker network connect NETWORK

  1. 2. docker network connect NETWORK CONTAINER

5.

This docker-compose will not work...

a)
  1. Still pending mapping port

b)

Still pending network definition

c)

Still pending the volumes

d)

Still pending ENV variables

6.

Is it possible to create different containers with just one Image?

a)

Yes, with the same container name

b)

Yes, with different container name

c)

No, a new image must be downloaded to create other container

d)

N/A

7.

docker network inspect training_net

a)

Show network properties

b)

Show network properties and containers added in this Network

c)

Wrong command

d)

Command deprecated

8.

You see this error : max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]" ..when...

a)

Try run docker command and there is an issue with mem

b)

Try to download an image and there is and issue on the volume

c)

Try to create a network and you do not have auth

d)

Try to add a container to a network without priviliges

9.

You have a container A attached to a NETWORK A. If you attach container A to a NETWORK B

a)

Container A will change to NETWORK B

b)

Container A will remain in NETWORK A and will be added to NETWORK B

c)

Error: Container A must be detached from NETWORK A first

d)

Error: You cannot attach containers to networks

10.

This command docker exec -it elastic_training_2 /bin/bash

a)

Raise an error

b)

Open a terminal inside container

c)

Open a terminal in WSL Windows

d)

Bad Syntax