Comments on Linux-Vserver on Debian Sarge

Author: BJ DierkesContact: wdierkes [at] 5dollarwhitebox [dot] orgUpdated: November 11th, 2005This document describes how to install and configure a Debian Sarge system to utilize the linux-vserver kernel patch allowing you run multiple virtual servers on a single machine.http://www.linux-vserver.org

14 Comment(s)

Add comment

Please register in our forum first to comment.

Comments

By: Anonymous

Check out this article about how to use vserver on a VLAN. Powerful stuff! http://this.is/promazin/?p=page&ID=1

By: Anonymous

Thanks for this neat little ref.

I would like to mention debian's kernel package system as described here[1], which is the debian way to compile custom kernels and create packages of it.

[1] http://newbiedoc.sourceforge.net/sy..

polarizers 2cent

By: Anonymous

It seems that in this setup the Debian patch-set for the kernel was not applied. This may or may not cause problems for some setups. Unfortunately, I don't know if the vserver patch will aply anywhere near 'cleanly' to a Debian-patched kernel (since I've never tried this with Debian.)

YMMV

Gaby

By: Anonymous

Another good tutorial for Debian+vserver here: http://deb.riseup.net/vserver/

By: Anonymous

for further resources:

  • http://deb.riseup.net/vserver/ (already mentioned by another commenter, but seconded here)
  • http://www.section6.net/wiki/index.php/Running_Vservers_on_Debian

i think every howto should show how to test a vserver after installation, if only to give the new vserver user a warm fuzzy feeling.

  • http://vserver.13thfloor.at/Stuff/SCRIPT/
  • http://linux-vserver.org/TestScripts

i've backported the util-vserver package from etch to sarge to gain hashify support, a really easy way to conserve space in your vserver chroots with hardlinks.

i'm kind of appalled that a "debian" how-to doesn't support the debian way of building kernels (ie kernel-package, kernel-source, & kernel-patch-vserver) considering that's nearly half the document.

i don't mess with the stock kernels because i rather debian manage security updates. actually, i'm using ubuntu's 2.6.10 kernel from hoary as i need the ata pass-through support for smart on sata drives, but ubuntu also supports its packages for 18 months (which is hopefully longer than debian post-woody). kernel-patch-vserver in sarge includes a patch for 2.6.10 that applies to ubuntu's kernel source rather cleanly, but not perfectly. i've already tested ubuntu breezy's 2.6.12 with the kernel patch for 2.6.12 in etch's kernel-patch-vserver and that works too (with fewer patch rejects).

besides the kernel documentation, this how-to is a good start.

By: themachine

I do agree... I should have done the kernel section the "debian way"... but I honestly have always delt with vanilla kernels... I didn't really feel that the kernel section was anything to be picky about, rather building vserver's after the re-compile and such... I will one day soon update this to utilize Debian's way.

Thanks for the comment!

By: Anonymous

i wouldn't have been picky about the kernel section except that it's almost half of your document. if it would have been a sentence or two ("make sure your kernel is compiled with the linux-vserver patch") it would have been overlooked, but it's hard to understand why a "linux-vserver for debian" document is half about compiling a non-debian kernel.

my recommendation: don't have a kernel section at all besides referencing a good "building kernels the debian way" document (see other comments for urls) and a note to include the kernel-patch-vserver package (or an upstream patch if necessary).

just curious: as you track upstream kernels, how do you address kernel security? do you always upgrade to the latest kernel (as upstream kernels only receive security support from lkml for the current version; or has this changed?) or do you provide your own security updates (backporting security fixes from the latest upstream kernel to whatever kernel you decided to standardize on)?

By: Anonymous

this didn't work for me, and I can't find any documentation about using vserver on a debian-amd64 box. Linux ruby 2.6.12.6 #1 Thu Dec 8 12:30:08 GMT 2005 x86_64 GNU/Linux error: I: Retrieving debootstrap.invalid_dists_sarge_Release I: Validating debootstrap.invalid_dists_sarge_Release E: Invalid Release file, no entry for main/binary-amd64/Packages

By: Anonymous

if you are trying to get the amd64 sarge release from debian.org that would explain your problem. debian only officially provides amd64 security support for sarge. see http://amd64.debian.net/ for more information (specifically http://amd64.debian.net/README.mirrors.html for installation mirrors and http://amd64.debian.net/docs/ for documentation).

as part of my vserver setup i use apt-proxy, so that the updating/upgrading of one vserver caches the packages locally for the other vservers to use when i update/upgrade them seconds later. and creating new vservers in really quick as i've pre-cached both sarge amd64 installation dvds (see apt-proxy documentation on "importing").

By: Anonymous

apt-get install vserver-debiantools
newvserver --mirror <url_from_list_http://amd64.debian.net/README.mirrors.html> --hostname x --domain y.z --ip 1.2.3.4
and have fun ;)

By: Anonymous

kernel          /vmlinuz-2.6.12.4-vs2.0 root=/dev/hda2 ro
initrd /initrd.img-2.6.12.4-vs2.0

These rows should be, or else it fails to boot

kernel /boot/vmlinuz-2.6.12.4-vs2.0 root=/dev/hda2 ro
initrd /boot/initrd.img-2.6.12.4-vs2.0

By: admin

It depends on your partitions. If you have a /boot partition, then

kernel /vmlinuz-2.6.12.4-vs2.0 root=/dev/hda2 ro

initrd /initrd.img-2.6.12.4-vs2.0

is correct. If you have not, then

kernel /boot/vmlinuz-2.6.12.4-vs2.0 root=/dev/hda2 ro

initrd /boot/initrd.img-2.6.12.4-vs2.0

should do.

By: Anonymous

Sorry, but you are not correct on this statement. Grub works from what it conciders it's "ROOT" specified by the line "root (hd0,0)". "root(hd0,0)" is the /boot partition.

Many variations work in this file... I have used anything from "/kernel-x.x.x" to "(hd0,0)/kernel-x.x.x" to "/boot/kernel-x.x.x". Thanks for your input though!

By: Anonymous

Building and installing a kernel the "Debian way" does not mean you have to use the Debian patched kernel. It works equally as well with a stock kernel.