Difference between revisions of "OpenSUSE template creation"

From OpenVZ Virtuozzo Containers Wiki
Jump to: navigation, search
m (fixed typo)
m (Formatting improvements)
Line 39: Line 39:
 
</code>
 
</code>
  
For Debian-based host you should put the archive inside <code>/var/lib/vz/template/cache</code>
+
{{Note|For Debian-based host you should put the archive inside <code>/var/lib/vz/template/cache</code>}}
  
 
[[Category: HOWTO]]
 
[[Category: HOWTO]]
 
[[Category: Templates]]
 
[[Category: Templates]]

Revision as of 09:15, 12 January 2008

Instructions manually create a minimal openSUSE 10.3 template.

Prerequisites

You need running openSUSE 10.3 installation.

Creating template

Preparing the base system

Run yast2 on your openSUSE 10.3 installation (this does not have to be your OpenVZ HN). Proceed with Software->Installation into directory.

Create device nodes

I suggest creating all required nodes directly in the \<DIRINSTALL\>/lib/udev/devices/, in that case you don't have to disable udev in startup scripts.

Change directory to \<DIRINSTALL\>/lib/udev/devices/ and execute the following commonds:

mknod -m 666 full c 1 7
mknod -m 600 initctl p
mknod -m 666 random c 1 8
mknod -m 444 urandom c 1 9

Disable parallel startup of services

Set RUN_PARALLEL variable in \<DIRINSTALL\>/etc/sysconfig/boot to "no".

Disable boot.klog

For some reason, klogd hangs when tries to retrieve kernel log. You need to disable it. Simply delete \<DIRINSTALL\>/etc/rc.d/boot.d/S08boot.klog

Create OS template

Create OS template cache by invoking the following command (from inside \<DIRINSTALL\></code): tar -czf /vz/template/cache/opensuse-10.3-i386-default.tar.gz ./

Yellowpin.svg Note: For Debian-based host you should put the archive inside /var/lib/vz/template/cache