Open main menu

OpenVZ Virtuozzo Containers Wiki β

Editing Installation on Debian 8

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision Your text
Line 14: Line 14:
 
  # Must boot with SystemV to release Systemd
 
  # Must boot with SystemV to release Systemd
 
  sudo reboot
 
  sudo reboot
  sudo apt-get --autoremove remove systemd
+
  sudo apt-get remove systemd
 +
sudo apt-get autoremove
 
  echo -e 'Package: *systemd*\nPin: release *\nPin-Priority: -1\n' | sudo tee /etc/apt/preferences.d/avoid-systemd
 
  echo -e 'Package: *systemd*\nPin: release *\nPin-Priority: -1\n' | sudo tee /etc/apt/preferences.d/avoid-systemd
  
Line 43: Line 44:
 
  VE_STOP_MODE=stop
 
  VE_STOP_MODE=stop
  
* Only Devuan: link to be recognised as Debian
+
== Patch VarLock directory creation ==
  if [ -f /etc/devuan_version ] ; then sudo ln -s /etc/devuan_version /etc/debian_version ; fi
+
This is necessary to vzeventd works on boot, because it doesn't automatically create VARLOCK directory on startup:
 +
Lines="$(cat /etc/init.d/vzeventd | grep -e '#.*INIT INFO' -ie '# .*Provides:' -ie '^# .*-St')"
 +
  Lines="$(echo "$Lines" | sed -e 's|vzeventd$|vzevent_pre|g' | sed -e 's| vz$| vzeventd|g')"
 +
echo "$Lines" | sudo tee /etc/init.d/vzevent_pre
 +
echo 'mkdir -p /var/lock/subsys' | sudo tee -a /etc/init.d/vzevent_pre
 +
sudo chmod +x /etc/init.d/vzevent_pre
 +
sudo insserv --default vzevent_pre
  
 
= '''Reboot into OpenVZ kernel''' =
 
= '''Reboot into OpenVZ kernel''' =
Line 60: Line 67:
  
 
  Packages="$(aptitude search ~i~nlinux-image- --display-format '%p' | grep -ve 'openvz')"
 
  Packages="$(aptitude search ~i~nlinux-image- --display-format '%p' | grep -ve 'openvz')"
  sudo apt-get --autoremove remove $Packages
+
  sudo apt-get remove $Packages
 +
sudo apt-get autoremove
  
 
(requires aptitude)
 
(requires aptitude)
Line 78: Line 86:
 
  sudo vztmpl-dl --gpg-check debian-8.0-x86_64-minimal
 
  sudo vztmpl-dl --gpg-check debian-8.0-x86_64-minimal
  
Alternatives:
+
Alternatively, you can also download precreated template caches from [[Download/template/precreated|Download » Template » Precreated]], or from one of the [https://mirrors.openvz.org/ mirrors]. Put those tarballs '''as-is (no unpacking needed)''' to the <tt>/vz/template/cache/</tt> directory.
* Download precreated template caches from [[Download/template/precreated|Download » Template » Precreated]] or from one of the [https://mirrors.openvz.org/ mirrors]. Put those tarballs '''as-is (no unpacking needed)''' to the <tt>/vz/template/cache/</tt> directory.
 
* '''[https://downloads.actiu.net/ctctl/ ctctl]''' helper to create Debian (or derivative) container without template (caches it as a local template). This tool manages unprivileged LXC containers too.
 
  
 
= Next steps =
 
= Next steps =

Please note that all contributions to OpenVZ Virtuozzo Containers Wiki may be edited, altered, or removed by other contributors. If you don't want your writing to be edited mercilessly, then don't submit it here.
If you are going to add external links to an article, read the External links policy first!

To edit this page, please answer the question that appears below (more info):

Cancel Editing help (opens in new window)

Templates used on this page: