Article ID: 122864, created on Sep 11, 2014, last review on Sep 21, 2014

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

Symptoms

  1. OS template cache cannot be updated with Segmentation fault error message:

    ~# vzpkg update cache centos-6-x86_64
    Update OS template cache for centos-6-x86_64 template
    Segmentation fault
    
  2. Container cannot be created and information about the OS template cannot be retrieved:

    ~# vzctl --verbose create 100600 --ostemplate centos-6-x86_64
    running: /usr/sbin/vzpkg info -q centos-6-x86_64 name
    Unable to get the full name for centos-6-x86_64
    Failed to create the Container private area
    
    ~# vzpkg info centos-6-x86_64
    Segmentation fault
    

Cause

The OS template package is corrupted, most likely the configuration files are zero-sized:

~# rpm -V centos-6-x86_64-ez-4.0.0-10.noarch
.M.......    /vz/template/centos
.M.......    /vz/template/centos/6
.M.......    /vz/template/centos/6/x86_64
.M.......    /vz/template/centos/6/x86_64/config
.M.......    /vz/template/centos/6/x86_64/config/os
.M.......    /vz/template/centos/6/x86_64/config/os/default
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/ct2vm
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/description
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/distribution
.M.......    /vz/template/centos/6/x86_64/config/os/default/doc
.M.....T.    /vz/template/centos/6/x86_64/config/os/default/doc/README
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/environment
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/mirrorlist
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/package_manager
SM5....T.  c /vz/template/centos/6/x86_64/config/os/default/packages
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/post-cache
SM5....T.  c /vz/template/centos/6/x86_64/config/os/default/post-install
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/post-upgrade
SM5....T.  c /vz/template/centos/6/x86_64/config/os/default/pre-cache
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/pre-upgrade
SM5....T.  c /vz/template/centos/6/x86_64/config/os/default/release
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/summary
SM5....T.  c /vz/template/centos/6/x86_64/config/os/default/upgradable_versions
.M5....T.  c /vz/template/centos/6/x86_64/config/os/default/version

Some files are zero-sized, e.g. due to file-system corruption or lack of disk space:

~# ll /vz/template/centos/6/x86_64/config/os/default
-rwxr-xr-x. 1 root root    0 Jul 13  2011 ct2vm
-rw-r--r--. 1 root root    0 Jul 13  2011 description
-rw-r--r--. 1 root root    0 Jul 13  2011 distribution
drwxr-xr-x. 2 root root 4096 Jun  9 19:24 doc
-rw-r--r--. 1 root root    0 Jul 13  2011 environment
-rw-r--r--. 1 root root    0 Jul 13  2011 mirrorlist
-rw-r--r--. 1 root root    0 Jul 13  2011 package_manager
-rw-r--r--  1 root root  830 Dec 17 15:52 packages
-rw-r--r--. 1 root root    0 Jul 13  2011 packages.rpmsave
-rwxr-xr-x. 1 root root    0 Jul 13  2011 post-cache
-rwxr-xr-x  1 root root 4467 Dec 17 15:52 post-install
-rwxr-xr-x. 1 root root    0 Jul 13  2011 post-install.rpmsave
-rwxr-xr-x. 1 root root    0 Jul 13  2011 post-upgrade
-rwxr-xr-x  1 root root  541 Dec 17 15:52 pre-cache
-rwxr-xr-x. 1 root root    0 Jul 13  2011 pre-cache.rpmsave
-rwxr-xr-x. 1 root root    0 Jul 13  2011 pre-upgrade
-rw-r--r--  1 root root    2 Dec 17 15:52 release
-rw-r--r--. 1 root root    0 Jul 13  2011 release.rpmsave
-rw-r--r--. 1 root root    0 Jul 13  2011 summary
-rw-r--r--  1 root root    0 Dec 17 15:52 upgradable_versions
-rw-r--r--. 1 root root    0 Jul 13  2011 upgradable_versions.rpmsave
-rw-r--r--. 1 root root    0 Jul 13  2011 version

Resolution

Reinstall the template RPM and create/update the template cache:

~# mv /vz/template/centos/6/x86_64/config/os/default{,_bad}
~# yum reinstall centos-6-x86_64-ez
~# vzpkg update cache centos-6-x86_64

Search Words

Unable to get the full name for

Segmentation fault

vzpkg update cache

Unable to get the full name for OS EZ template

e8e50b42231236b82df27684e7ec0beb 2897d76d56d2010f4e3a28f864d69223 d02f9caf3e11b191a38179103495106f c62e8726973f80975db0531f1ed5c6a2 0dd5b9380c7d4884d77587f3eb0fa8ef 0c05f0c76fec3dd785e9feafce1099a9

Email subscription for changes to this article
Save as PDF