Article ID: 125095, created on Apr 2, 2015, last review on Jun 17, 2016

  • Applies to:
  • Virtuozzo 6.0
  • Virtuozzo containers for Linux 4.7
  • Virtuozzo hypervisor

Symptoms

Containers based on SLES 9 and SLES 10 have no networking after starting on a server running kernel 2.6.32-042stab102.X and later. Major symptom is - loopback device is not configured:

[root@pvcfl ~]# vzlist 100500
      CTID      NPROC STATUS       IP_ADDR         HOSTNAME
    100500         13 running      10.39.92.141    -
[root@pvcfl ~]# vzctl enter 100500
entered into Container 100500
localhost:~ # ifconfig
localhost:~ # ifup lo

ERROR: No configuration found for lo
localhost:~ #

getcfg-interface command execution leads to segmentation fault:

localhost:~ # getcfg-interface -d . -f ifcfg- -- ''
Segmentation fault

Cause

Script ifup implies execution of getcfg-interface. Segmentation fault prevents loopback interface from starting, which is crucial for networking in the container.

The root cause of the issue is a bug in SLES, particularly in sysconfig package. It scans /sys/block folder and tries to iterate over list of interfaces, however there is no check that /sys/block directory is empty. It worked on previous kernels since /sys/block/ directory was not present there at all. Starting kernel from 2.6.32-042stab102.X directory is present, but empty, thus triggering this bug.

In order to bypass the bug in SLES 10, request with internal ID #PSBM-32744 was submitted.

Resolution

Permanent fix is planned to the future updates.

For now, it's possible to use one of the following workarounds:

Workaround 1:

Reboot into an older kernel, 2.6.32-042stab94.7 or older.

Workaround 2:

Create custom action script for container startup which would mount any non-empty directory into /sys/block:

~# cat /vz/private/<CTID>/scripts/start
#!/bin/bash
mount -o bind /etc /sys/block

Do not forget to set executable permissions:

~# chmod +x /vz/private/<CTID>/scripts/start

Note!: replace <CTID> with an actual container ID.

In order to automate the workaround #2 for all existing containers based on SLES 9 or SLES 10 you may download and execute attached script:

# wget http://kb.plesk.com/Attachments/kcs-49013/kb125095.sh
# chmod +x kb125095.sh
# ./kb125095.sh

Search Words

venet0 not configured

suse linux enterprise server

no networking

sles

loopback missing

a26b38f94253cdfbf1028d72cf3a498b 2897d76d56d2010f4e3a28f864d69223 e8e50b42231236b82df27684e7ec0beb d02f9caf3e11b191a38179103495106f 0dd5b9380c7d4884d77587f3eb0fa8ef 0c05f0c76fec3dd785e9feafce1099a9 c62e8726973f80975db0531f1ed5c6a2

Email subscription for changes to this article
Save as PDF