Article ID: 117004, created on Aug 29, 2013, last review on Jun 17, 2016

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

Symptoms

Is there any way to upgrade the operating system inside a container? (for example, from CentOS 4 to CentOS 5?)

Cause

When declaring end-of-maintenance or end-of-life for an OS release, it is necessary to upgrade the environment to the actual/most recent version. Virtuozzo provides the information about possible upgrades in EZ templates.

Resolution

Note: Before performing an actual upgrade, check with a clone of the container or create a full backup.

  1. Using vzpkg upgrade CTID command for some containers, it is possible to upgrade the OS EZ template the container is based on to a newer version.

  2. Check the version of the OS template on which the container is based:

    ~# vzpkg list 222
    centos-5-x86_64                    2013-05-31 01:48:05
    
  3. Check the information about this OS template:

    ~# vzpkg info centos-5-x86_64
    name:
            centos-5-x86_64
    osname:
            centos
    version:
            5
    arch:
            x86_64
    config_path:
            /vz/template/centos/5/x86_64/config/os/default
    summary:
            CentOS 5 (for AMD64/Intel EM64T) EZ OS Template
    description:
            CentOS 5 (for AMD64/Intel EM64T) packaged as a Virtuozzo EZ Template.
    packages:
            authconfig
            bash
    ...
            gcc
    repositories:
            http://mirror.yandex.ru/centos/5/os/x86_64
            http://mirror.yandex.ru/centos/5/updates/x86_64
    package_manager:
            rpm44x64
    package_manager_type:
            rpm
    distribution:
            redhat-el5
    technologies:
            x86_64 nptl sysfs
    upgradable_versions:
            4
    cached:
            yes
    
  4. If the upgradable_versions section is present, this means the upgrade is possible (in the provided example, this means that the 222 container could have been created based on the centos-4-x86_64 template and later upgraded to centos-5-x86_64 using the vzpkg upgrade 222 command).

  5. For a container running on Parallels Cloud Server:

    • If the container is ploop-based (#115479), the operating system can be upgraded manually from inside the container. If new kernel version should be shown for container, one can change OSTEMPLATE parameter in ve.conf file of the container to the new OS version and restart the container before launching dist upgrade.
  6. If the container has application templates, then the same templates should be available for the resulting OS template.

    • For containers with Plesk, it is better to perform the migration using Plesk Migration Manager.

Search Words

vzpkg upgrade

os upgrade

container os upgrade

upgrade operating system in container

Ubuntu update

upgrade centos

обновление centos

a26b38f94253cdfbf1028d72cf3a498b 2897d76d56d2010f4e3a28f864d69223 d02f9caf3e11b191a38179103495106f e8e50b42231236b82df27684e7ec0beb 0dd5b9380c7d4884d77587f3eb0fa8ef

Email subscription for changes to this article
Save as PDF