Service Management in Networks - Leischner

Practice sheet 4 - Ansible taster

For our home lab server we want to use automatic provisioning. One tool among others to perform this is Ansible. In the following we would like to familiarize ourselves with this tool.

For testing I have provided 3 nearly identical servers for you. The credentials for access you find in LEA. The servers are:

  • stud01: 2001:638:408:200::babe:0:1
  • stud02: 2001:638:408:200::babe:0:2
  • stud03: 2001:638:408:200::babe:0:3


Task 1 - Git for code

This task is to be solved in a separate git that we use only for training in Ansible. Therefore, create a git with the name pr04-ansible (to be used by your workgroup).


Task 2 - Watching/Reading

On the internet you will find a variety of sources about YAML and Ansible. The original sources are:

My recommendations for a fast and concise introduction to YAML and Ansible are:

Get familiar with YAML and Ansible by using appropriate sources.


Task 3 - Inventory

  1. Write an inventory file hosts containing your homelab servers (homelab) as well as other servers (others) you have access to via ssh .
  2. Test your file hosts by "pinging"
    • your homelab servers (may be only one) and
    • the other servers
  3. at the command line level. Write both commands into a file solution-task-3b.


Task 4 - My first playbook

Write a simple_upgrade_playbook.yaml such that you can update+upgrade the servers. Test your playbook. Analyze and describe your test results.

To submit on LEA: The description of the test results from task 4.


Please, submit your git pr04-ansible as a zip file and the description of the test results from task 4 to LEA - Lernen und Arbeiten online .


Impressum | Datenschutz |, last modification: 28.10.2018-10.29