Skip to main content

Configure Networking via YaST and Wicked on SUSE Linux Enterprise

Hands-On Lab

 

Photo of Ross Brunson

Ross Brunson

Linux Training Architect II

Length

00:30:00

Difficulty

Beginner

In this hands-on lab, we will be working with networking using YaST and Wicked. This is something every admin should know, and the steps in this lab are especially important to know in a DevOps scenario.

What are Hands-On Labs?

Hands-On Labs are scenario-based learning environments where learners can practice without consequences. Don't compromise a system or waste money on expensive downloads. Practice real-world skills without the real-world risk, no assembly required.

Configure Networking via YaST and Wicked on SUSE Linux Enterprise

Introduction

In this hands-on lab, we will be working with networking using YaST and Wicked. This is something every admin should know, and the steps in this lab are especially important to know in a DevOps scenario.

Solution

Log in to the Server1 server using the credentials provided:

ssh cloud_user@<SERVER1_PUBLIC_IP_ADDRESS>

Use Wicked to Get the IP Address of eth0 and Then Use YaST to Configure the Hostname handsonlab.net to Resolve to the eth0 IP Address

  1. Use Wicked to get the IP address of the eth0 interface:

    sudo wicked show all

    Copy the eth0 IP address.

  2. Use YaST to set the hostname:

    sudo yast
  3. In the ncurses interface, go to Network Services > Hostnames > Add.

  4. Enter the IP address of the eth0 adapter.

  5. Enter the hostname handsonlabs.net.

  6. Save and exit out of YaST.

Verify that DNS Resolution Is Set Correctly in nsswitch.conf and That Changes Are Present in /etc/hosts, and Verify with Curl

  1. Read the file, and look for the hostname:

    cat /etc/hosts
  2. Read nsswitch.conf:

    cat /etc/nsswitch.conf
  3. Make sure the dns line is set to files first:

    hosts:      files dns
  4. Curl the index:

    curl handsonlabs.net

    You should get an index page returned.

Conclusion

Congratulations on successfully completing this hands-on lab!