Subject: Re: [vserver] Problem with installing debian guest
From: Herbert Poetzl <herbert@13thfloor.at>
Date: Tue, 14 Jul 2009 16:47:35 +0200

On Tue, Jul 14, 2009 at 08:24:54AM -0600, David Vanfleet wrote:
>    Herbert, thanks for your response. I tried what you suggested,
>    first I created an empty /etc/default/rcS file inside of the lenny
>    guest and tried restarting it. This made the error go away and
>    no other errors were displayed but the guest did not start, it
>    appears that nothing happened. Next I copied the /etc/default/rcS
>    file from a running Debian Etch guest, and tried to restart it
>    but again the guest did not start. Also, I was looking around in
>    /etc/vservers/debian_lenny_template and comparing it with a working
>    guest (debian_etch_template), and noticed that the soft link to the
>    cache folder was pointing to an invalid location:

>        cache -> /etc/vservers/.defaults/cachebase/debian_lenny_template
>    I fixed this link but still nothing happened when
>    I tried to start it. I also noticed that the
>    /etc/vserver/debian_lenny_template/dlimits folder was missing,
>    so I recreated that modeling it after the same folder for my
>    debian_etch_template guest but again the guest would not start,
>    nothing appears to be happening. I'm not sure what to try next, any
>    ideas? There are probably some errors being thrown somewhere but I
>    don't know where they are? Thanks, David

nope, you just need to enable a single service inside
the guest which keeps the guest 'running' otherwise
the context is disposed right after startup

i.e. enable syslog or sshd as service inside the guest
(you can chroot into it or use the 'vserver .. start --rescue'
option for that ....

how you do that in debian? best ask a debian person.

best,
Herbert

>    Herbert Poetzl wrote:
> 
> On Mon, Jul 13, 2009 at 10:45:43PM -0600, David Vanfleet wrote:
> 
>    Hi, I'm runing Linux Vserver 2.2.0.7 on OpenSuse 10.3 with the
>    2.6.22.19 Kernel, and I'm trying to instill Debian (Lenny) as a
>    guest. I installed lenny successfully with the following command:
> 
>       vserver debian_lenny_template build \ -m debootstrap
>       \ --hostname debian_lenny_template.amwestonline.com
>       \ --interface eth0:66.62.37.145/24 \ -- -d lenny -m
>       [1][1]http://ftp.debian.org/debian
> 
>    However, when I tried to start the guest I get the following error:
> 
>      /etc/init.d/rc: line 74: /etc/default/rcS: No such file or
>      directory error: '/etc/init.d/rc' exited outside the expected
>      code flow. An error occured while executing the vserver startup
>      sequence; when there are no other messages, it is very likely
>      that the init-script (/etc/init.d/rc 3) failed. Common causes
>      are: * /etc/rc.d/rc on Fedora Core 1 and RH9 fails always; the
>      'apt-rpm' build method knows how to deal with this, but on existing
>      installations, appending 'true' to this file will help. Failed to
>      start vserver 'debian_lenny_template'
> 
> IIRC, debian changed something, and older util-vserver do not do the
> proper cleanup/setup inside a guest ... in your case, maybe creating
> this file (/etc/default/rcS) inside the guest will do the trick
> 
> best, Herbert
> 
>    I'm new to vserver but I understand that some of the services running
>    in the guest need to be turned off, the ones that access any hardware
>    devices. In this case I suspect that some service is trying to start
>    that is not valid in a guest. I'm not sure what needs to be done here
>    to fix this problem, I don't know what it means to append "true" to
>    some file, I'm not even user Fedora Core or RH9. Any help here would
>    be greatly appreciated. Thanks, David
> 
> References
> 
>    1. [2]http://ftp.debian.org/debian
> 
> References
> 
>    1 2                                    . http://ftp.debian.org/debian