Installing a VServer guest with debootstrap and softupdate: Difference between revisions

From FAIWiki
Jump to navigation Jump to search
(Initial version of the page.)
 
(adjusted some formatting)
Line 1: Line 1:
Many people don't use the -m fai VServer build method (maybe because it's broken?) but build their VServer guests without FAI, using debootstrap or any other standard method. A guest installed like that will now nothing about FAI, so in order to turn it into a FAI install client, some manual extra steps are necessary at least once. There are also some pitfalls.
Many people don't use the -m fai VServer build method (maybe because it's broken?) but build their VServer guests without FAI, using debootstrap or any other standard method. A guest installed like that will now nothing about FAI, so in order to turn it into a FAI install client, some manual extra steps are necessary at least once. There are also some pitfalls.


= Your guest cannot NFS mount by default =
= The guest cannot NFS mount by default =


For security reasons, the defaults do not allow a VServer guest to perform NFS mounts. In case your FAI config space lives on a separate physical server and therefore needs to be mounted through NFS, this will lead to a <tt>permission denied</tt> error.
For security reasons, the defaults do not allow a VServer guest to perform NFS mounts. In case your FAI config space lives on a separate physical server and therefore needs to be mounted through NFS, this will lead to a <tt>permission denied</tt> error.
Line 29: Line 29:
= The FAI client needs to know about your config space =
= The FAI client needs to know about your config space =


In <tt>/etc/fai/fai.conf</tt> look for the line:
In the file <tt>/etc/fai/fai.conf</tt> look for the line:


<pre>
#FAI_CONFIG_SRC=nfs://yourserver/$FAI_CONFIGDIR
#FAI_CONFIG_SRC=nfs://yourserver/$FAI_CONFIGDIR
</pre>


Uncomment and replace yourserver with the hostname of the sevrer that is exporting your config space via NFS.
Uncomment this line and replace <tt>yourserver</tt> with the hostname of the sevrer that is exporting your config space via NFS.


= We don't know our FAI classes yet =
= The guest does not yet have any FAI classes =


Make sure to run
Make sure to run


<code>
<pre>
fai softupdate -N
fai softupdate -N
</code>
</pre>


as the -N option will make sure that the class detection for your VServer guest is done from scratch. Without the -N option, you will just see an error message saying that /var/log/fai/classes was not found.
as the <tt>-N</tt> option will make sure that the class detection for your VServer guest is done from scratch. Without the <tt>-N</tt> option, you will just see an error message saying that <tt>/var/log/fai/classes</tt> was not found.

Revision as of 16:02, 11 October 2007

Many people don't use the -m fai VServer build method (maybe because it's broken?) but build their VServer guests without FAI, using debootstrap or any other standard method. A guest installed like that will now nothing about FAI, so in order to turn it into a FAI install client, some manual extra steps are necessary at least once. There are also some pitfalls.

The guest cannot NFS mount by default

For security reasons, the defaults do not allow a VServer guest to perform NFS mounts. In case your FAI config space lives on a separate physical server and therefore needs to be mounted through NFS, this will lead to a permission denied error.

To fix this problem, on the VServer host, create a file called

/etc/vservers/<vserver>/bcapabilities

with the following content:

CAP_SYS_ADMIN

If your VServer guest was already running, make sure to re-start it for these settings to become effective. (Q: Would there be a parameter to set this at guest build time???)

You need a FAI client on your guest

Before you can do anything else, you will need to install the fai-client package:

aptitude install fai-client

The FAI client needs to know about your config space

In the file /etc/fai/fai.conf look for the line:

#FAI_CONFIG_SRC=nfs://yourserver/$FAI_CONFIGDIR

Uncomment this line and replace yourserver with the hostname of the sevrer that is exporting your config space via NFS.

The guest does not yet have any FAI classes

Make sure to run

fai softupdate -N

as the -N option will make sure that the class detection for your VServer guest is done from scratch. Without the -N option, you will just see an error message saying that /var/log/fai/classes was not found.