jkt 05/10/06 16:42:48 Modified: xml/htdocs/doc/en vserver-howto.xml Log: #108259, "Update vserver howto to reflect latest changes" by hollow
Revision Changes Path 1.3 +66 -129 xml/htdocs/doc/en/vserver-howto.xml file : http://www.gentoo.org/cgi-bin/viewcvs.cgi/xml/htdocs/doc/en/vserver-howto.xml?rev=1.3&content-type=text/x-cvsweb-markup&cvsroot=gentoo plain: http://www.gentoo.org/cgi-bin/viewcvs.cgi/xml/htdocs/doc/en/vserver-howto.xml?rev=1.3&content-type=text/plain&cvsroot=gentoo diff : http://www.gentoo.org/cgi-bin/viewcvs.cgi/xml/htdocs/doc/en/vserver-howto.xml.diff?r1=1.2&r2=1.3&cvsroot=gentoo Index: vserver-howto.xml =================================================================== RCS file: /var/cvsroot/gentoo/xml/htdocs/doc/en/vserver-howto.xml,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- vserver-howto.xml 8 Aug 2005 11:08:24 -0000 1.2 +++ vserver-howto.xml 6 Oct 2005 16:42:48 -0000 1.3 @@ -1,5 +1,5 @@ <?xml version='1.0' encoding="UTF-8"?> -<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/vserver-howto.xml,v 1.2 2005/08/08 11:08:24 neysx Exp $ --> +<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/vserver-howto.xml,v 1.3 2005/10/06 16:42:48 jkt Exp $ --> <!DOCTYPE guide SYSTEM "/dtd/guide.dtd"> <guide link="/doc/en/vserver-howto.xml"> @@ -21,8 +21,8 @@ <!-- See http://creativecommons.org/licenses/by-sa/2.5 --> <license/> -<version>1.0</version> -<date>2005-06-17</date> +<version>1.1</version> +<date>2005-10-06</date> <chapter> <title>Introduction</title> @@ -83,7 +83,7 @@ </chapter> <chapter> -<title>Creating a VServer template</title> +<title>Host configuration</title> <section> <title>Install a VServer kernel</title> <body> @@ -102,13 +102,12 @@ # <i>make menuconfig</i> Linux VServer ---> -<comment>(Required by current utils)</comment> - [*] Enable Legacy Kernel API + [ ] Enable Legacy Kernel API <comment>(Do not set!)</comment> [ ] Disable Legacy Networking Kernel API <comment>(Highly recommended)</comment> [*] Enable Proc Security - [ ] Enable Hard CPU Limits + [*] Enable Hard CPU Limits Persistent Inode Context Tagging (UID24/GID24) ---> [ ] Tag NFSD User Auth and Files [ ] Compile Debugging Code @@ -124,7 +123,7 @@ # <i>make</i> <comment>(Installing)</comment> # <i>make modules_install</i> -# <i>cp arch/i386/boot/bzImage /boot/kernel-<KERNELVERSION>-vs<VSERVERVERSION></i> +# <i>cp arch/i386/boot/bzImage /boot/kernel-<KERNELVERSION>-vserver-<VSERVERVERSION></i> <comment>(Edit bootloader config file as required and)</comment> # <i>reboot</i> </pre> @@ -140,23 +139,25 @@ contains all necessary programs and many usefull features. </p> +<note> +The tools and features used in this HowTo require +<c>>=sys-apps/util-vserver-0.30.208-r3</c>. You may have to keyword it first. +</note> + <pre caption="Install vserver utils"> # <i>emerge util-vserver</i> </pre> <p> -If you use Proc Security you have to "unhide" certain files in your -<path>/proc</path> directory in order to make them available in virtual -servers. There is a script called <c>vprocunhide</c> in -<path>/usr/lib/util-vserver</path> which unhides files specified in -<path>/usr/lib/util-vserver/defaults/vprocunhide-files</path>. The util-vserver -ebuild installed a init-script which uses the <c>vprocunhide</c> command. Add -it to your runlevel: +You have to run the <c>vprocunhide</c> command after every reboot in order to +setup <path>/proc</path> permissions correctly for vserver use. An init script has +been installed by util-vserver. To use it you should add it to a +runlevel: </p> -<pre caption="vprocunhide init script"> -# <i>rc-update add vprocunhide default</i> -# <i>/etc/init.d/vprocunhide start</i> +<pre caption="vserver init script"> +# <i>rc-update add vservers default</i> +# <i>/etc/init.d/vservers start</i> </pre> <p> @@ -171,27 +172,19 @@ </body> </section> +</chapter> + +<chapter> +<title>Creating a guest template</title> <section> -<title>Basic Skeleton configuration</title> +<title>Install a vserver stage3</title> <body> <p> -You have to create some configuration files and directories to get your virtual -server up and running. We use the skeleton build mode from the util-vserver -package to setup our basic configuration. -</p> - -<p> -The util-vserver package uses <path>/vservers</path> to store all virtual -servers by default. You can put your servers somewhere else by specifying -<c>--rootdir=/path/to/vserver/root</c> to the build command below. -</p> - -<p> -There is a new baselayout-vserver ebuild in portage which supports the plain -init-style, i.e.; you don't have to use the gentoo init style anymore. The -plain init-style uses <c>init</c> and <path>/etc/inittab</path> to manage -runlevels and init scripts (considered more stable and is the default now). +We will use <c>vserver-new</c> to create the initial guest. You have to download +a vserver prepared stage3 from +<uri>http://dev.gentoo.org/~hollow/vserver/stages</uri> and the script will +guide you through the creation process. </p> <p> @@ -201,118 +194,63 @@ equivalent to the last two parts of the virtual servers IP). </p> -<pre caption="Basic configuration"> -# <i>vserver gentoo build -m skeleton \</i> +<pre caption="Start stage3 installation"> +# <i>vserver-new gentoo-template \</i> <i>--hostname gentoo \</i> - <i>--initstyle plain \</i> - <i>--context 1253</i> - <i>--interface gentoo=eth0:192.168.1.253/24</i> + <i>--context 1253 \</i> + <i>--interface eth0:192.168.1.253/24 \</i> + <i>stage3 /path/to/stage3-tarball.tar.bz2</i> </pre> -<impo> -Per default the virtual server is allowed to set the hostname itself. Be sure -to change <path>/etc/conf.d/hostname</path> in your virtual server later to -match the hostname above. -</impo> - -</body> -</section> -<section> -<title>Installing Gentoo installation files</title> -<body> - -<p> -We are creating a Gentoo template which we can copy later to get multiple -virtual servers easily. The vserver build-script created some basic directories -in <path>/vservers/gentoo</path> which are installed by a stage anyway, so we -remove them first. -</p> - -<pre caption="Remove skeleton files"> -# <i>rm -rf /vservers/gentoo/*</i> -</pre> - -<p> -You have to install a regular Gentoo system now. You can follow most of the -Gentoo Handbook with some limitations and additions: -</p> - -<ul> - <li>Replace <path>/mnt/gentoo</path> with <path>/vservers/gentoo</path></li> - <li> - Choose the <path>vserver/x86</path> profile in <uri - link="/doc/en/handbook/handbook-x86.xml?part=1&chap=6#doc_chap1_sect6">chapter - 6.a</uri> - </li> - <li> - Use the vserver stages available <uri - link="http://dev.gentoo.org/~hollow/vserver/stages/">here</uri>. - </li> -</ul> - -<p> -Now, follow the Gentoo Handbook from <uri -link="/doc/en/handbook/handbook-x86.xml?part=1&chap=5#doc_chap2"> chapter -5.b</uri> to chapter 7.a and <uri -link="/doc/en/handbook/handbook-x86.xml?part=1&chap=8#doc_chap3"> chapter -8.c</uri> to chapter 9.c -</p> - -- [email protected] mailing list
